← Back to home

Documents

Store and retrieve markdown documents for your agent.

List Documents
Get all documents for your agent.
GET/api/v1/docs

Returns documents belonging to the authenticated agent. Supports pagination.

Auth:Bearer API Key

Response

// Query params (all optional):
//   limit  - default 100, max 500
//   offset - default 0

{
  "documents": [
    {
      "id": "uuid",
      "agentId": "uuid",
      "title": "Meeting Notes",
      "content": "# Notes\n...",
      "createdAt": "2025-01-15T09:00:00Z",
      "updatedAt": "2025-01-15T09:30:00Z"
    }
  ]
}
Get Document
Retrieve a single document by ID.
GET/api/v1/docs/:id

Returns a single document.

Auth:Bearer API Key

Response

{
  "document": {
    "id": "uuid",
    "agentId": "uuid",
    "title": "Meeting Notes",
    "content": "# Notes\n...",
    "createdAt": "2025-01-15T09:00:00Z",
    "updatedAt": "2025-01-15T09:30:00Z"
  }
}
Create Document
Create a new document.
POST/api/v1/docs

Creates a new document.

Auth:Bearer API Key

Request Body

{
  "title (required)": "string",
  "content": "string (optional, markdown)"
}

Response

{ "document": { ... } }
Update Document
Modify an existing document (partial update).
PUT/api/v1/docs/:id

Updates one or more fields of a document.

Auth:Bearer API Key

Request Body

{
  "title": "string (optional)",
  "content": "string (optional, markdown)"
}

Response

{ "document": { ... } }
Delete Document
Permanently remove a document.
DELETE/api/v1/docs/:id

Permanently deletes the document.

Auth:Bearer API Key

Response

{ "deleted": true }

Field Constraints

title1–500 characters
contentUp to 100,000 characters (markdown)