Skip to content

REST API Overview

REST API Overview

The AgentWiki REST API is hosted on Cloudflare Workers at:

  • Base URL: https://api.agentwiki.cc
  • Specification: OpenAPI 3.1 (https://api.agentwiki.cc/openapi.json)
  • Interactive Playground: Interactive API Docs

Authentication

Pass your API key or JWT access token in the Authorization header:

Authorization: Bearer aw_xxxxxxxxxxxxxxxxxxxx

Try it in the sandbox

The sandbox runs the real API handlers against a disposable workspace, so you can call the API from the Interactive API Docs or curl without an account.

Terminal window
# 1. Get a one-hour token and a seeded workspace (sample folders, documents, tags, graph links)
curl -X POST https://api.agentwiki.cc/api/sandbox/token
# 2. Call any supported route through the sandbox prefix
curl https://api.agentwiki.cc/api/sandbox/api/documents \
-H "Authorization: Bearer <sandbox token>"
SandboxValue
Base URLhttps://api.agentwiki.cc/api/sandbox (select the sandbox server in the playground)
Token lifetime1 hour; 5 tokens per minute per IP
Request quota30 requests per minute per sandbox workspace, 500 credits per workspace
Available routesDocuments, Folders, Tags, Search, Knowledge Graph, Sharing, Reorder, Preferences, Analytics
Denied routes (403)Billing, Secrets, Members, AI settings, API Keys, Uploads, Import, Storage, Static Sites, Auth
Background jobsNot processed (embeddings, summaries, relationship extraction)
RetentionWorkspaces are deleted 24 hours after creation

Sandbox tokens are rejected on production routes, and production credentials are rejected in the sandbox.

Global Rate Limits

Endpoint GroupLimitWindow
General API100 requests60 seconds
Search50 requests60 seconds
Search (with AI Query Expansion)10 requests60 seconds
AI Generation15 requests60 seconds

Error Responses

All error responses adhere to standard JSON error envelopes:

{
"error": "Error message description",
"code": "OPTIONAL_ERROR_CODE"
}