MCP for agents
mdbin runs an MCP server, so a coding agent can read and publish documents directly — no browser, no copy-pasting a wall of Markdown into a chat window. Point Claude Code, Claude Desktop, Cursor or VS Code at it once and "publish these notes and give me the link" becomes a single step.
You'll need an account to create an API key.
Connecting
Create a key under Settings → API keys. It's shown once, at creation — copy
it then, because we store only a hash and can't show it to you again. Keys start with
mdb_. Delete one at any time and it stops working immediately.
The server lives at:
https://mdbin.app/mcp
and authenticates with a standard bearer header:
Authorization: Bearer mdb_your_key_here
For Claude Code, that's one command:
claude mcp add --transport http mdbin https://mdbin.app/mcp \
--header "Authorization: Bearer mdb_your_key_here"
The API keys page has ready-made config for Claude Desktop, Cursor and VS Code too — pick your client and copy the block.
What an agent can do
| Tool | What it does |
|---|---|
get_document |
Read any document by its ID, with its comments |
list_my_documents |
List what you've published |
list_my_comments |
List comments you've written |
create_document |
Publish a new document |
create_document_from_file |
Publish a file already on the agent's disk |
create_comment |
Comment on a document, anchored to a line |
delete_document |
Permanently delete one of your documents |
get_syntax_guide |
Look up mdbin's Markdown, Mermaid, PlantUML and FreeDraw syntax |
get_document works on any live document, not only your own — a slug is a public
URL, so anything readable in a browser is readable here. Everything else is scoped to
your account.
There is no edit tool. create_document publishes immediately and publicly, so an
agent should treat it as deliberate rather than a draft.
Publishing a file without burning context
create_document_from_file exists for a specific, annoying reason: tool arguments
are tokens the model writes. Handing a 200 KB file to create_document means the
agent re-types all 200 KB, costing tens of thousands of output tokens for a file
already sitting on its disk.
So the bytes leave the model's loop instead. The tool returns a one-shot curl
command, the agent runs it, and the file uploads straight from disk — the model never
reads the contents. The ticket is single-use and expires in ten minutes.
Worth knowing: forking isn't available on this path. Publishing a large local file and forking an existing document rarely happen together.
Comments stay anonymous
A comment your agent leaves carries the free-text name it supplies, or "Anonymous" — never your account. No tool returns the account behind a comment. See Accounts.
Comments anchor to a 0-based line of the document's Markdown source, so they sit
beside the passage they're about. get_document returns the source along with every
existing comment's anchor — read it and count, rather than guessing.
Teaching an agent the syntax
mdbin renders things standard Markdown doesn't: Mermaid, PlantUML, GitHub-style alerts, and FreeDraw, whose schema is specific to mdbin and documented nowhere else. No model can guess it.
get_syntax_guide serves these very pages on demand — call it with no topic for the
list, or with one to read the page. It's the same set of docs you're reading now, so
they can't drift apart.
Limits
Calls are capped at 120 per minute per IP and 60 per minute / 2,000 per day per account.
Publishing and commenting additionally spend the same budget as the website. An API key buys an agent a way in, not a second allowance — so a key can't be used to get around the limits that apply to everyone else.
Good to know
| Endpoint | https://mdbin.app/mcp (streamable HTTP) |
| Auth | Authorization: Bearer mdb_… |
| Key visibility | Shown once at creation; stored hashed |
| Reading | Any live document; writing is scoped to you |
| Editing | Not supported — publishing is immediate and public |
| Rate limits | 120/min per IP; 60/min and 2,000/day per account |