Workspace API
Workspace Knowledge
Pages, folders, sections, files and revisions — the workspace's own reference material that Spec and MCP clients search and cite.
Knowledge is the workspace’s own reference material: playbooks, ICP notes, positioning, pricing, call notes. It is written as markdown pages arranged in folders, with uploaded files attached. Spec searches it before answering and cites what it used. The same routes serve the web app, API keys, Spec and the Developer MCP.
API keys need knowledge:read to search and read, and knowledge:write to create, edit, upload or remove. New keys and new MCP connections receive both. MCP connections made before Knowledge shipped must reconnect to pick them up.
Pages and folders
A page has a title, a folder path, an optional one-line description and a markdown body of up to 1,000,000 characters.
- A folder is a path such as
Go-to-market/Personas. Its segments are trimmed and empty ones dropped;''is the root. Paths are at most 5 levels deep, 100 characters a segment and 300 characters overall. Folders exist only as page paths: there is nothing to create or delete separately. - A title is at most 200 characters. It cannot contain
/or control characters, and it cannot look like a page id. - A page is addressed by its id or its ref,
folder/Title(justTitleat the root). URL-encode a ref in a path parameter:Go-to-market%2FICP. - The title is unique within its folder among live pages. A second
createwith the same folder and title answers409 path_title_taken. deletearchives a page. An archived page leaves search but stays readable by id;restorebrings it back.
Pages without a description get one written from their body after a save that leaves at least 200 characters. This is Parcel’s cost, not yours, and a description you set is never replaced.
Sections and search
Each page body is split into sections at its headings, and each converted file is split the same way. find searches sections (full text plus fuzzy heading matching) and returns the best matches with a snippet. Read the whole page, or just the section, with GET /workspace/knowledge/pages/{page}; a section id alone reads with GET /workspace/knowledge/sections/{section}.
Files
Upload DOCX, PPTX, XLSX, CSV, PDF, Markdown, plain text or an image, up to 20 MB each. A file is attached to a page; without page an upload makes a new page titled after the file.
- Word, Markdown and text files become the body of a page that has none. Other files stay attached and are searchable as their own sections.
- Conversion runs after the response. Poll the file’s
status:pendingwhile it converts, thenready,no_text(nothing readable, such as a scanned PDF) orfailedwith anerror. An image is stored, not read: it isreadywith no text. retryconverts a stored file again.removedeletes the file, its sections and the stored object; the page stays.downloadreturns the bytes exactly as uploaded.
Revisions and concurrency
Every write that changes a page records a revision with its author: the member, the Spec run, or the API key. A person’s saves fold into one revision for 10 minutes from its first save. List the newest 200, or read any one in full.
Every edit sends expected_revision. If the page has moved on, the write answers 409 revision_conflict with details.current_revision; read the page again and resend.
Plan, scopes and credits
Knowledge is on every plan, in the app, in Spec, and through API keys and MCP.
| Surface | Scope | Credits |
|---|---|---|
find, page reads, revisions, file reads and downloads | knowledge:read | 0 |
manage (and /batch), uploads (and /batch), retry, remove (and each /batch) | knowledge:write | 0 |
Errors
{ "error": { "code": "revision_conflict", "message": "The page changed while saving; read it again.", "details": { "current_revision": 4 } }}| Code | HTTP | Meaning |
|---|---|---|
bad_request | 400 | A field is missing or malformed (path, title, ref, id). A path or title refusal names it in details.field (path or title). |
page_not_found, section_not_found, revision_not_found, file_not_found | 404 | Nothing matches in this workspace. |
revision_conflict | 409 | expected_revision is stale; details.current_revision has the current one. |
not_unique | 409 | str_replace’s old_text occurs zero or several times; details.count says how many. |
path_title_taken | 409 | A live page already has that folder and title. |
page_archived | 409 | The page is archived; restore it first. |
file_busy | 409 | The file is still converting. |
file_missing | 409 | The stored object is gone; upload the file again. |
try_later | — | Batch item only: a retry batch converts 5 files a call; send the rest again. |
too_large | 413 | The body would pass 1,000,000 characters, or a file is over 20 MB. |