documents.read
Read a ThinkBench document and return its current content as Markdown.
GET /api/v1/documents/{documentId}
- SDK:
tb.documents.read(input) - CLI:
thinkbench documents read - MCP tool:
documents_read
Input
| Field | Type | In | Description |
|---|---|---|---|
documentId |
string |
path | The document's id, from its URL or a listing. |
Output
| Field | Type | Description |
|---|---|---|
item |
DriveItem | |
markdown |
string |
|
prosemirrorDoc |
unknown |
|
authors |
object[] |
Who edited this most recently. |
Examples
curl
curl "https://app.thinkbench.com/api/v1/documents/<documentId>" \
-H "x-api-key: $THINKBENCH_API_KEY"TypeScript SDK
const result = await tb.documents.read({ documentId: "<documentId>" });CLI
thinkbench documents read --document-id "<documentId>"MCP
{
"name": "documents_read",
"arguments": {
"documentId": "<documentId>"
}
}Notes
The markdown and prosemirrorDoc projections come from one live snapshot
of the collaborative document, so they always agree — and both include edits
other people (or agents) are making right now, before they're saved to
version history.
To pull just the Markdown from the CLI:
npx thinkbench documents read --document-id "<documentId>" --pick markdown