MCP server
LokalTransfer speaks the Model Context Protocol, so an AI assistant can send and manage transfers on your behalf. An agent can hand a client their files directly, on your own server, without a person driving a browser.
Connecting
Point your MCP client at /mcp and give it an API key:
{
"mcpServers": {
"lokaltransfer": {
"url": "https://transfer.example.com/mcp",
"headers": { "x-api-key": "your-api-key" }
}
}
}
There is nothing to switch on. The endpoint carries no authority of its own — every call needs a valid key, the same credential the REST API takes — so an instance that issues no keys exposes nothing.
The tools
| Tool | Does |
|---|---|
whoami | Which account the key acts as, and whether it is read-only |
listTransfers | What the user sent, or what was sent to them |
getTransfer | One transfer in full, including its file list |
listRecipients | Team members, for resolving a name into an address |
createTransfer | Start a draft — recipients, retention, password, layout |
sendTransfer | Deliver it and return the download link |
deleteTransfer | Erase it — files and record, irreversibly |
Uploading is deliberately not a tool
File bytes have no business inside a tool call. createTransfer returns the URL
to POST them to, and the server's own instructions tell the agent how:
createTransferwith the recipients, a subject and a retention.- POST each file to
/api/transfers/<id>/filesas multipart form data, with the samex-api-keyheader. sendTransfer— this is what mails the recipients, starts the expiry clock and returns the link.
What an agent cannot do
The MCP surface is member-only and inherits every limit the key has:
- A read-only key can call the read tools and nothing else.
- No tool administers users.
- Another account's transfer answers
NOT_FOUNDrather thanFORBIDDEN, so ids cannot be probed for existence by watching which error comes back. - A recipient reading a transfer sent to them does not see who else received it.
deleteTransfer is marked destructive and erases the files for good. An agent
should confirm with you before calling it, and a well-behaved client will ask.
Errors
Failures come back as CODE: message, where the code is one of UNAUTHORIZED,
FORBIDDEN, NOT_FOUND, VALIDATION or INTERNAL — machine-readable, rather
than prose an agent has to interpret.