Docs Tools

Persistent document storage for agents. Create, update, retrieve, and list documents that survive across sessions — design docs, memos, research notes, checklists, and structured data.

docs.create

Create a new persistent document.

What it does: Creates a document that persists across sessions and can be iteratively modified via docs.update. Supports markdown, plain text, checklist, and JSON formats. Use tags to link related documents together.

Parameters:

Name Type Required Description
title string yes Document title
body string no Document content (markdown by default)
format string no Content format: markdown (default), text, checklist, json
tags array no Tags for linking and filtering (e.g. project:api-redesign, type:design-doc)
metadata object no Optional structured metadata

Example:

{
  "title": "API Redesign Notes",
  "body": "## Goals\n\n- Simplify auth flow\n- Add rate limiting\n- Deprecate v1 endpoints",
  "tags": ["project:api-redesign", "type:design-doc"]
}

Returns: ref (document reference for future operations), title, status.

Credits: 1


docs.update

Modify an existing document.

What it does: Updates a document’s content, title, tags, or metadata. Supports full body replacement or append mode for incremental additions. Each update increments the version counter.

Parameters:

Name Type Required Description
ref string yes Document reference (doc_...)
body string no New content (replaces existing unless append is true)
append boolean no If true, appends body to existing content instead of replacing
title string no New title
tags array no Replace the document’s tags
metadata object no Replace the document’s metadata

Example:

{
  "ref": "doc_abc123",
  "body": "\n## Update: Rate limiting implemented\n\nUsing token bucket algorithm.",
  "append": true
}

Returns: ref, title, version, status.

Credits: 1


docs.get

Retrieve a document by its reference.

What it does: Returns the full document content including body, title, tags, format, version, and timestamps.

Parameters:

Name Type Required Description
ref string yes Document reference (doc_...)

Returns: Full document object with ref, title, body, format, tags, version, metadata, created_at, updated_at.

Credits: 1


docs.list

List documents with optional filters.

What it does: Returns document summaries (ref, title, format, tags, version, timestamps) without the full body. Use docs.get to retrieve the full content of a specific document.

Parameters:

Name Type Required Description
tags array no Filter to documents containing ALL of these tags
search string no Filter by title substring (case-insensitive)
format string no Filter by document format
limit integer no Max documents to return (default 20)
offset integer no Pagination offset

Example:

{
  "tags": ["project:api-redesign"],
  "limit": 10
}

Returns: docs (array of document summaries), total (total matching count), has_more (pagination indicator).

Credits: 1


Use cases

  • Design documents: Agents create and iteratively refine design docs across multiple sessions
  • Research notes: Accumulate findings from multi-step investigations with append mode
  • Checklists: Track progress on multi-step tasks with the checklist format
  • Session memory: Persist decisions, context, and rationale that outlive a single conversation
  • Project wikis: Organize knowledge with namespaced tags for easy retrieval