Coview agent instructions
Coview is an agent-human collaboration canvas. It lets you design with a human using web tools like HTML.
If the page URL contains an id, that id is the document id to use. For example, in https://coview.dev/d/my-document-id, use documentId "my-document-id".
Agent access options:
1. Direct agent API: https://api.coview.dev/v1/agent
2. Remote MCP server: https://mcp.coview.dev/
3. Document changes API: https://api.coview.dev/v1/documents/{documentId}/changes
Direct agent API:
Use POST https://api.coview.dev/v1/agent/{method} with a JSON body matching the method input schema. Read the full method catalog at /agent-api.txt or GET https://api.coview.dev/v1/agent.
All direct agent API method URLs:
- POST https://api.coview.dev/v1/agent/get_basic_info
- POST https://api.coview.dev/v1/agent/create_document
- POST https://api.coview.dev/v1/agent/get_canvas_state
- POST https://api.coview.dev/v1/agent/apply_operations
- POST https://api.coview.dev/v1/agent/finish_working_on_nodes
Example direct API call:
curl -s https://api.coview.dev/v1/agent/get_canvas_state \
-H "content-type: application/json" \
-d '{"documentId":"my-document-id"}'
Detailed documentation:
- /agent-api.txt has the complete direct API method list, schemas, and examples.
- GET https://api.coview.dev/v1/agent returns the machine-readable method catalog.
Remote MCP server:
https://mcp.coview.dev/
If your runtime supports remote MCP and does not already have callable Coview MCP tools, register or connect this remote MCP server URL before using MCP tools.
Examples for runtimes that support remote MCP:
- Claude Code: claude mcp add --transport http coview https://mcp.coview.dev/
- Generic Streamable HTTP MCP config: add a server named "coview" with url "https://mcp.coview.dev/".
- OpenAI Agents SDK: configure a hosted MCP tool with serverLabel "coview" and serverUrl "https://mcp.coview.dev/".
If the MCP endpoint returns guidance or exposes a guide tool, read that first. Then use the document id from the URL when calling tools that read or mutate the canvas.
Useful direct API flow:
1. Use create_document for a fresh canvas, or use the document id from the current Coview URL.
2. Read the current canvas with get_canvas_state.
3. Apply small operation batches with apply_operations.
4. Call finish_working_on_nodes after editing.
Document changes API:
- GET https://api.coview.dev/v1/documents/{documentId}/changes to read the current persisted store.
- POST https://api.coview.dev/v1/documents/{documentId}/changes with an operation_batch change to mutate the document.
Do not infer the document from the bundled asset names in index.html. The document is identified by the URL path id and edited through one of the agent access options above.