{"openapi":"3.0.0","paths":{"/api/v1/tools-v2":{"get":{"operationId":"ToolsV2Controller_list","parameters":[],"responses":{"200":{"description":""}},"tags":["ToolsV2"]}},"/anthropic/v1/messages":{"post":{"operationId":"AnthropicGatewayController_createMessage","parameters":[],"responses":{"200":{"description":""}},"tags":["AnthropicGateway"]}},"/api/v1/resource/agent/{id}/chat/batch":{"post":{"operationId":"AgentResourceController_chatBatch","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: agent-chat-batch-2026-06-01. Default when omitted: agent-chat-batch-2026-06-01.","schema":{"type":"string","enum":["agent-chat-batch-2026-06-01"],"default":"agent-chat-batch-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Whether all batch chat requests were accepted."},"conversationIds":{"type":"array","items":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"description":"Conversation UUID for each item in the batch, in request order."}},"required":["success","conversationIds"]}}}}},"tags":["AgentResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (agent-chat-batch-2026-06-01). When x-api-schema is omitted, the server expects the agent-chat-batch-2026-06-01 shape.","content":{"application/json":{"schema":{"minItems":1,"maxItems":50,"type":"array","items":{"type":"object","properties":{"message":{"type":"string","description":"User message to send to the agent for this turn."},"conversationId":{"description":"Existing conversation UUID. Omit to start a new conversation with the agent.","type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"mode":{"description":"Tool execution mode: \"auto\" (default) runs tools without approval; \"manual\" requires user approval before each tool call.","type":"string","enum":["auto","manual"]},"systemSuffix":{"description":"Additional system prompt text appended for this message only (not persisted on the agent).","type":"string"}},"required":["message"]},"description":"Batch of up to 50 chat requests against the same agent."}}}}}},"/api/v1/resource/agent/{id}/compare":{"post":{"operationId":"AgentResourceController_compare","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: agent-compare-2026-06-01. Default when omitted: agent-compare-2026-06-01.","schema":{"type":"string","enum":["agent-compare-2026-06-01"],"default":"agent-compare-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Whether all per-model chat requests were accepted."},"results":{"type":"array","items":{"type":"object","properties":{"model":{"type":"string","description":"LLM model identifier (Cotera model slug, e.g. \"azure-gpt-5.5\"). Must be a model enabled for the organization."},"conversationId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$","description":"Conversation UUID started for this model."}},"required":["model","conversationId"]},"description":"One started conversation per requested model, in request order."}},"required":["success","results"]}}}}},"tags":["AgentResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (agent-compare-2026-06-01). When x-api-schema is omitted, the server expects the agent-compare-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"User message to send to the agent for each model."},"models":{"minItems":1,"maxItems":10,"type":"array","items":{"type":"string","description":"LLM model identifier (Cotera model slug, e.g. \"azure-gpt-5.5\"). Must be a model enabled for the organization."},"description":"Models to compare. Each starts its own new conversation with the agent, overriding the agent default model."},"mode":{"description":"Tool execution mode applied to every comparison conversation: \"auto\" (default) runs tools without approval; \"manual\" requires user approval before each tool call.","type":"string","enum":["auto","manual"]},"systemSuffix":{"description":"Additional system prompt text appended for these messages only (not persisted on the agent).","type":"string"}},"required":["message","models"]}}}}}},"/api/v1/resource/agent/{id}/invoke":{"post":{"operationId":"AgentResourceController_invoke","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: agent-invoke-2026-06-01. Default when omitted: agent-invoke-2026-06-01.","schema":{"type":"string","enum":["agent-invoke-2026-06-01"],"default":"agent-invoke-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Whether the agent invocation completed successfully."},"result":{"type":"string","description":"Assistant reply text from the completed agent run (plain text or JSON string for structured outputs)."}},"required":["success","result"]}}}}},"tags":["AgentResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (agent-invoke-2026-06-01). When x-api-schema is omitted, the server expects the agent-invoke-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"prompt":{"type":"string","description":"User prompt to send to the agent. The request blocks until the agent finishes and returns the assistant reply text."},"systemSuffix":{"description":"Additional system prompt text appended for this invocation only (not persisted on the agent).","type":"string"},"model":{"description":"Overrides the agent's configured model for this invocation only.","type":"string"},"triggerSource":{"description":"Trigger source recorded on the run. Defaults to \"warehouse\" when omitted.","type":"string","enum":["chat","chat-bot","slack","linear","webhook","warehouse","cron","event","compaction-summary","workflow","system"]}},"required":["prompt"]}}}}}},"/api/v1/resource/agent/{id}/chat":{"post":{"operationId":"AgentResourceController_chat","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: agent-chat-2026-06-01. Default when omitted: agent-chat-2026-06-01.","schema":{"type":"string","enum":["agent-chat-2026-06-01"],"default":"agent-chat-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Whether the chat request was accepted and queued for processing."},"conversationId":{"description":"Conversation UUID for the chat turn (new or existing).","type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"}},"required":["success"]}}}}},"tags":["AgentResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (agent-chat-2026-06-01). When x-api-schema is omitted, the server expects the agent-chat-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"User message to send to the agent for this turn."},"conversationId":{"description":"Existing conversation UUID. Omit to start a new conversation with the agent.","type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"mode":{"description":"Tool execution mode: \"auto\" (default) runs tools without approval; \"manual\" requires user approval before each tool call.","type":"string","enum":["auto","manual"]},"systemSuffix":{"description":"Additional system prompt text appended for this message only (not persisted on the agent).","type":"string"}},"required":["message"]}}}}}},"/api/v1/resource/agent/{id}/update":{"post":{"operationId":"AgentResourceController_update","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: agent-update-2026-06-01. Default when omitted: agent-update-2026-06-01.","schema":{"type":"string","enum":["agent-update-2026-06-01"],"default":"agent-update-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{}}}}}},"tags":["AgentResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (agent-update-2026-06-01). When x-api-schema is omitted, the server expects the agent-update-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"editorState":{"description":"Updated TipTap document for the agent prompt. Omit to keep the current editor state.","type":"object","properties":{"type":{"type":"string","enum":["doc"],"description":"Root node type; always \"doc\"."},"content":{"description":"Top-level block nodes in document order.","type":"array","items":{"anyOf":[{"type":"object","properties":{"type":{"type":"string","enum":["text"]},"text":{"type":"string","description":"Text content."},"marks":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"Mark type (e.g. bold, italic, link)."},"attrs":{"type":"object"}},"required":["type"],"description":"Inline formatting applied to text."}}},"required":["type","text"]},{"type":"object","properties":{"type":{"type":"string","description":"Block or inline node type (paragraph, heading, mention, section, etc.)."},"attrs":{"description":"Node-specific attributes (e.g. mention id, heading level).","type":"object"},"content":{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},"marks":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"Mark type (e.g. bold, italic, link)."},"attrs":{"type":"object"}},"required":["type"],"description":"Inline formatting applied to text."}}},"required":["type"]}]}}},"required":["type"]},"model":{"description":"Updated LLM model. Omit to keep the current model.","type":"string"}}}}}}}},"/api/v1/resource/agent/{id}/archive":{"post":{"operationId":"AgentResourceController_archive","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"201":{"description":""}},"tags":["AgentResource"]}},"/api/v1/resource/agent/{id}/mentioned-tools-status":{"get":{"operationId":"AgentResourceController_getMentionedToolsStatus","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"tags":["AgentResource"]}},"/api/v1/resource/agent/{id}":{"post":{"operationId":"AgentResourceController_create","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: agent-create-2026-06-01. Default when omitted: agent-create-2026-06-01.","schema":{"type":"string","enum":["agent-create-2026-06-01"],"default":"agent-create-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"id":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$","description":"Agent UUID."},"orgId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$","description":"Owning organization UUID."},"ownerId":{"type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$","description":"User UUID that created/owns the agent."},"agentKey":{"type":"string","description":"Stable agent symbol/key used in workspace references."},"editorState":{"type":"object","properties":{"type":{"type":"string","enum":["doc"],"description":"Root node type; always \"doc\"."},"content":{"description":"Top-level block nodes in document order.","type":"array","items":{"anyOf":[{"type":"object","properties":{"type":{"type":"string","enum":["text"]},"text":{"type":"string","description":"Text content."},"marks":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"Mark type (e.g. bold, italic, link)."},"attrs":{"type":"object"}},"required":["type"],"description":"Inline formatting applied to text."}}},"required":["type","text"]},{"type":"object","properties":{"type":{"type":"string","description":"Block or inline node type (paragraph, heading, mention, section, etc.)."},"attrs":{"description":"Node-specific attributes (e.g. mention id, heading level).","type":"object"},"content":{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},"marks":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"Mark type (e.g. bold, italic, link)."},"attrs":{"type":"object"}},"required":["type"],"description":"Inline formatting applied to text."}}},"required":["type"]}]}}},"required":["type"],"description":"TipTap JSON document (Cotera DG DocumentEditor format). Defines agent instructions or document body, including @mentions of tools and other resources."},"model":{"type":"string","description":"LLM model identifier (Cotera model slug, e.g. \"azure-gpt-5.5\"). Must be a model enabled for the organization."},"locked":{"type":"boolean","description":"Whether the agent is locked and cannot be edited."},"createdAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$","description":"Creation timestamp (ISO 8601)."},"updatedAt":{"type":"string","format":"date-time","pattern":"^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$","description":"Last update timestamp (ISO 8601)."},"title":{"nullable":true,"description":"Display title derived from the first heading in editorState.","type":"string"},"description":{"nullable":true,"description":"Optional description derived from editor content.","type":"string"}},"required":["id","orgId","ownerId","agentKey","editorState","model","locked","createdAt","updatedAt","title","description"]}}}}},"tags":["AgentResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (agent-create-2026-06-01). When x-api-schema is omitted, the server expects the agent-create-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"editorState":{"type":"object","properties":{"type":{"type":"string","enum":["doc"],"description":"Root node type; always \"doc\"."},"content":{"description":"Top-level block nodes in document order.","type":"array","items":{"anyOf":[{"type":"object","properties":{"type":{"type":"string","enum":["text"]},"text":{"type":"string","description":"Text content."},"marks":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"Mark type (e.g. bold, italic, link)."},"attrs":{"type":"object"}},"required":["type"],"description":"Inline formatting applied to text."}}},"required":["type","text"]},{"type":"object","properties":{"type":{"type":"string","description":"Block or inline node type (paragraph, heading, mention, section, etc.)."},"attrs":{"description":"Node-specific attributes (e.g. mention id, heading level).","type":"object"},"content":{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},"marks":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"Mark type (e.g. bold, italic, link)."},"attrs":{"type":"object"}},"required":["type"],"description":"Inline formatting applied to text."}}},"required":["type"]}]}}},"required":["type"],"description":"TipTap JSON document (Cotera DG DocumentEditor format). Defines agent instructions or document body, including @mentions of tools and other resources."},"model":{"type":"string","description":"LLM model identifier (Cotera model slug, e.g. \"azure-gpt-5.5\"). Must be a model enabled for the organization."},"folderId":{"description":"Optional folder UUID to place the new agent in. When omitted, the agent is created in the caller organization root.","type":"string","format":"uuid","pattern":"^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"},"emoji":{"description":"Optional emoji shown on the agent resource card (e.g. \"🤖\"). Pass null to clear a previously set emoji.","nullable":true,"type":"string"}},"required":["editorState","model"]}}}}}},"/api/v1/resource/coco/invoke":{"post":{"operationId":"CocoResourceController_invoke","parameters":[{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: coco-invoke-2026-06-01. Default when omitted: coco-invoke-2026-06-01.","schema":{"type":"string","enum":["coco-invoke-2026-06-01"],"default":"coco-invoke-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean","description":"Whether the agent invocation completed successfully."},"result":{"type":"string","description":"Assistant reply text from the completed agent run (plain text or JSON string for structured outputs)."}},"required":["success","result"]}}}}},"tags":["CocoResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (coco-invoke-2026-06-01). When x-api-schema is omitted, the server expects the coco-invoke-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"prompt":{"type":"string","description":"User message for Coco. Blocks until the run completes and returns assistant reply text."},"systemSuffix":{"description":"Optional text appended to the Coco system prompt for this run.","type":"string"},"model":{"description":"Optional model override for this run only.","type":"string"},"triggerSource":{"description":"Trigger source recorded on the run. Defaults to \"chat-bot\" when omitted.","type":"string","enum":["chat","chat-bot","slack","linear","webhook","warehouse","cron","event","compaction-summary","workflow","system"]}},"required":["prompt"]}}}}}},"/api/v1/resource/chat/list":{"get":{"operationId":"ChatResourceController_listChats","parameters":[{"name":"limit","required":true,"in":"query","schema":{"type":"string"}},{"name":"offset","required":true,"in":"query","schema":{"type":"string"}},{"name":"search","required":true,"in":"query","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/status":{"get":{"operationId":"ChatResourceController_chatStatus","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/insights":{"get":{"operationId":"ChatResourceController_chatInsights","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/list":{"get":{"operationId":"ChatResourceController_listMessages","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/participants":{"get":{"operationId":"ChatResourceController_listParticipants","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/snapshot":{"get":{"operationId":"ChatResourceController_getConversationSnapshot","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/sub-agent-snapshot":{"get":{"operationId":"ChatResourceController_subAgentSnapshot","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/archive":{"post":{"operationId":"ChatResourceController_archive","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"201":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/messages/read":{"post":{"operationId":"ChatResourceController_markMessagesAsRead","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-messages-read-2026-06-01. Default when omitted: chat-messages-read-2026-06-01.","schema":{"type":"string","enum":["chat-messages-read-2026-06-01"],"default":"chat-messages-read-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-messages-read-2026-06-01). When x-api-schema is omitted, the server expects the chat-messages-read-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"messageIds":{"type":"array","items":{"type":"string"}}}}}}}}},"/api/v1/resource/chat/{id}/messages/unread":{"post":{"operationId":"ChatResourceController_markMessagesAsUnread","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-messages-unread-2026-06-01. Default when omitted: chat-messages-unread-2026-06-01.","schema":{"type":"string","enum":["chat-messages-unread-2026-06-01"],"default":"chat-messages-unread-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-messages-unread-2026-06-01). When x-api-schema is omitted, the server expects the chat-messages-unread-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"messageIds":{"type":"array","items":{"type":"string"}}},"required":["messageIds"]}}}}}},"/api/v1/resource/chat/{id}/actions":{"post":{"operationId":"ChatResourceController_addAction","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-actions-2026-06-01. Default when omitted: chat-actions-2026-06-01.","schema":{"type":"string","enum":["chat-actions-2026-06-01"],"default":"chat-actions-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-actions-2026-06-01). When x-api-schema is omitted, the server expects the chat-actions-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"action":{"type":"object","properties":{"type":{"type":"string"},"agentId":{"type":"string"},"artifactType":{"type":"string"},"artifactId":{"type":"string"},"data":{"type":"object"},"toolKey":{"type":"string"}},"required":["type"]}},"required":["action"]}}}}}},"/api/v1/resource/chat/{id}/tools/{toolCallId}/run":{"post":{"operationId":"ChatResourceController_runTool","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"toolCallId","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-tool-run-2026-06-01. Default when omitted: chat-tool-run-2026-06-01.","schema":{"type":"string","enum":["chat-tool-run-2026-06-01"],"default":"chat-tool-run-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"resumed":{"type":"boolean"}},"required":["success","resumed"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-tool-run-2026-06-01). When x-api-schema is omitted, the server expects the chat-tool-run-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"model":{"type":"string"},"action":{"type":"string","enum":["approve","deny"]},"reason":{"type":"string"},"skipResume":{"type":"boolean"}},"required":["model","action"]}}}}}},"/api/v1/resource/chat/{id}/tools/{toolCallId}/run-interrupted":{"post":{"operationId":"ChatResourceController_runInterruptedTool","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"toolCallId","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-tool-run-interrupted-2026-06-01. Default when omitted: chat-tool-run-interrupted-2026-06-01.","schema":{"type":"string","enum":["chat-tool-run-interrupted-2026-06-01"],"default":"chat-tool-run-interrupted-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"resumed":{"type":"boolean"}},"required":["success","resumed"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-tool-run-interrupted-2026-06-01). When x-api-schema is omitted, the server expects the chat-tool-run-interrupted-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"model":{"type":"string"},"input":{"type":"object"}},"required":["model","input"]}}}}}},"/api/v1/resource/chat/{id}/tools/submit":{"post":{"operationId":"ChatResourceController_submitTool","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-tool-submit-2026-06-01. Default when omitted: chat-tool-submit-2026-06-01.","schema":{"type":"string","enum":["chat-tool-submit-2026-06-01"],"default":"chat-tool-submit-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"},"conversationId":{"type":"string"},"resumed":{"type":"boolean"}},"required":["success","conversationId","resumed"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-tool-submit-2026-06-01). When x-api-schema is omitted, the server expects the chat-tool-submit-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"toolCallIds":{"type":"array","items":{"type":"string"}},"model":{"type":"string"},"result":{"type":"object"}},"required":["toolCallIds","model","result"]}}}}}},"/api/v1/resource/chat/{id}/stop":{"post":{"operationId":"ChatResourceController_stopChat","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"201":{"description":""}},"tags":["ChatResource"]}},"/api/v1/resource/chat/{id}/compact":{"post":{"operationId":"ChatResourceController_compact","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-compact-2026-06-01. Default when omitted: chat-compact-2026-06-01.","schema":{"type":"string","enum":["chat-compact-2026-06-01"],"default":"chat-compact-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-compact-2026-06-01). When x-api-schema is omitted, the server expects the chat-compact-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"model":{"type":"string"}},"required":["model"]}}}}}},"/api/v1/resource/chat/{id}/autocomplete":{"post":{"operationId":"ChatResourceController_autocomplete","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-autocomplete-2026-06-01. Default when omitted: chat-autocomplete-2026-06-01.","schema":{"type":"string","enum":["chat-autocomplete-2026-06-01"],"default":"chat-autocomplete-2026-06-01"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"completion":{"type":"string"}},"required":["completion"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-autocomplete-2026-06-01). When x-api-schema is omitted, the server expects the chat-autocomplete-2026-06-01 shape.","content":{"application/json":{"schema":{"type":"object","properties":{"text":{"type":"string"},"candidates":{"type":"array","items":{"type":"object","properties":{"referenceId":{"type":"string"},"label":{"type":"string"},"type":{"type":"string"}},"required":["referenceId","label","type"]}}},"required":["text","candidates"]}}}}}},"/api/v1/resource/chat/{id}":{"post":{"operationId":"ChatResourceController_chat","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}},{"name":"x-api-schema","in":"header","required":false,"description":"API schema version. Supported: chat-2026-06-01, chat-legacy. Default when omitted: chat-legacy.","schema":{"type":"string","enum":["chat-2026-06-01","chat-legacy"],"default":"chat-legacy"}}],"responses":{"201":{"description":"","content":{"application/json":{"schema":{"type":"object","properties":{"success":{"type":"boolean"}},"required":["success"]}}}}},"tags":["ChatResource"],"requestBody":{"required":true,"description":"JSON request body. The schema below reflects the latest version (chat-2026-06-01). When x-api-schema is omitted, the server expects the chat-legacy shape.","content":{"application/json":{"schema":{"type":"object","properties":{"context":{"type":"object","properties":{"systemSuffix":{"type":"string"},"toolIds":{"type":"array","items":{"type":"string"}},"orgId":{"type":"string"},"model":{"type":"string"},"agent":{"nullable":true,"type":"string"},"agentId":{"type":"string"},"mode":{"type":"string"},"planMode":{"type":"boolean"},"folderId":{"type":"string"},"trigger":{"type":"string","enum":["chat","chat-bot","slack","linear","webhook","warehouse","cron","event","compaction-summary","workflow","system"]}},"required":["toolIds","orgId","model","mode"]},"messages":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"role":{"type":"string","enum":["system","user","assistant"]},"parts":{"type":"array","items":{"anyOf":[{"type":"object","properties":{"type":{"type":"string","enum":["text"]},"text":{"type":"string"},"state":{"type":"string","enum":["streaming","done"]},"providerMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}}},"required":["type","text"]},{"type":"object","properties":{"type":{"type":"string","enum":["reasoning"]},"text":{"type":"string"},"state":{"type":"string","enum":["streaming","done"]},"providerMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}}},"required":["type","text"]},{"type":"object","properties":{"type":{"type":"string","enum":["source-url"]},"sourceId":{"type":"string"},"url":{"type":"string"},"title":{"type":"string"},"providerMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}}},"required":["type","sourceId","url"]},{"type":"object","properties":{"type":{"type":"string","enum":["source-document"]},"sourceId":{"type":"string"},"mediaType":{"type":"string"},"title":{"type":"string"},"filename":{"type":"string"},"providerMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}}},"required":["type","sourceId","mediaType","title"]},{"type":"object","properties":{"type":{"type":"string","enum":["file"]},"mediaType":{"type":"string"},"filename":{"type":"string"},"url":{"type":"string"},"providerMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}}},"required":["type","mediaType","url"]},{"type":"object","properties":{"type":{"type":"string","enum":["step-start"]}},"required":["type"]},{"type":"object","properties":{"type":{"type":"string","enum":["editor-state"]},"editorState":{"type":"object","properties":{"type":{"type":"string","enum":["doc"],"description":"Root node type; always \"doc\"."},"content":{"description":"Top-level block nodes in document order.","type":"array","items":{"anyOf":[{"type":"object","properties":{"type":{"type":"string","enum":["text"]},"text":{"type":"string","description":"Text content."},"marks":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"Mark type (e.g. bold, italic, link)."},"attrs":{"type":"object"}},"required":["type"],"description":"Inline formatting applied to text."}}},"required":["type","text"]},{"type":"object","properties":{"type":{"type":"string","description":"Block or inline node type (paragraph, heading, mention, section, etc.)."},"attrs":{"description":"Node-specific attributes (e.g. mention id, heading level).","type":"object"},"content":{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},"marks":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string","description":"Mark type (e.g. bold, italic, link)."},"attrs":{"type":"object"}},"required":["type"],"description":"Inline formatting applied to text."}}},"required":["type"]}]}}},"required":["type"],"description":"TipTap JSON document (Cotera DG DocumentEditor format). Defines agent instructions or document body, including @mentions of tools and other resources."}},"required":["type","editorState"]},{"type":"object","properties":{"type":{"type":"string","enum":["stored-system-message"]},"payload":{"anyOf":[{"type":"object","properties":{"t":{"type":"string","enum":["coco"]}},"required":["t"]},{"type":"object","properties":{"t":{"type":"string","enum":["ad-hoc"]},"message":{"type":"string"}},"required":["t","message"]}]}},"required":["type","payload"]},{"type":"object","properties":{"type":{"type":"string","pattern":"^data-.*"},"id":{"type":"string"},"data":{"type":"object"}},"required":["type","data"]},{"type":"object","properties":{"type":{"type":"string","enum":["dynamic-tool"]},"toolName":{"type":"string"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["input-streaming"]},"input":{"type":"object"},"providerExecuted":{"type":"boolean"},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"output":{"not":{"type":"object"}},"errorText":{"not":{"type":"object"}},"approval":{"not":{"type":"object"}}},"required":["type","toolName","toolCallId","state"]},{"type":"object","properties":{"type":{"type":"string","enum":["dynamic-tool"]},"toolName":{"type":"string"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["input-available"]},"input":{"type":"object"},"providerExecuted":{"type":"boolean"},"output":{"not":{"type":"object"}},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"not":{"type":"object"}}},"required":["type","toolName","toolCallId","state","input"]},{"type":"object","properties":{"type":{"type":"string","enum":["dynamic-tool"]},"toolName":{"type":"string"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["approval-requested"]},"input":{"type":"object"},"providerExecuted":{"type":"boolean"},"output":{"not":{"type":"object"}},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"not":{"type":"object"}},"reason":{"not":{"type":"object"}}},"required":["id"]}},"required":["type","toolName","toolCallId","state","input","approval"]},{"type":"object","properties":{"type":{"type":"string","enum":["dynamic-tool"]},"toolName":{"type":"string"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["approval-responded"]},"input":{"type":"object"},"providerExecuted":{"type":"boolean"},"output":{"not":{"type":"object"}},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"type":"boolean"},"reason":{"type":"string"}},"required":["id","approved"]}},"required":["type","toolName","toolCallId","state","input","approval"]},{"type":"object","properties":{"type":{"type":"string","enum":["dynamic-tool"]},"toolName":{"type":"string"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["output-available"]},"input":{"type":"object"},"providerExecuted":{"type":"boolean"},"output":{"type":"object"},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"resultProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"preliminary":{"type":"boolean"},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"type":"boolean","enum":[true]},"reason":{"type":"string"}},"required":["id","approved"]}},"required":["type","toolName","toolCallId","state","input","output"]},{"type":"object","properties":{"type":{"type":"string","enum":["dynamic-tool"]},"toolName":{"type":"string"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["output-error"]},"input":{"type":"object"},"rawInput":{"type":"object"},"providerExecuted":{"type":"boolean"},"output":{"not":{"type":"object"}},"errorText":{"type":"string"},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"resultProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"type":"boolean","enum":[true]},"reason":{"type":"string"}},"required":["id","approved"]}},"required":["type","toolName","toolCallId","state","errorText"]},{"type":"object","properties":{"type":{"type":"string","enum":["dynamic-tool"]},"toolName":{"type":"string"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["output-denied"]},"input":{"type":"object"},"providerExecuted":{"type":"boolean"},"output":{"type":"object"},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"type":"boolean","enum":[false]},"reason":{"type":"string"}},"required":["id","approved"]}},"required":["type","toolName","toolCallId","state","input","approval"]},{"type":"object","properties":{"type":{"type":"string","pattern":"^tool-.*"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["input-streaming"]},"providerExecuted":{"type":"boolean"},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"input":{"type":"object"},"output":{"not":{"type":"object"}},"errorText":{"not":{"type":"object"}},"approval":{"not":{"type":"object"}}},"required":["type","toolCallId","state"]},{"type":"object","properties":{"type":{"type":"string","pattern":"^tool-.*"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["input-available"]},"providerExecuted":{"type":"boolean"},"input":{"type":"object"},"output":{"not":{"type":"object"}},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"not":{"type":"object"}}},"required":["type","toolCallId","state","input"]},{"type":"object","properties":{"type":{"type":"string","pattern":"^tool-.*"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["approval-requested"]},"input":{"type":"object"},"providerExecuted":{"type":"boolean"},"output":{"not":{"type":"object"}},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"not":{"type":"object"}},"reason":{"not":{"type":"object"}}},"required":["id"]}},"required":["type","toolCallId","state","input","approval"]},{"type":"object","properties":{"type":{"type":"string","pattern":"^tool-.*"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["approval-responded"]},"input":{"type":"object"},"providerExecuted":{"type":"boolean"},"output":{"not":{"type":"object"}},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"type":"boolean"},"reason":{"type":"string"}},"required":["id","approved"]}},"required":["type","toolCallId","state","input","approval"]},{"type":"object","properties":{"type":{"type":"string","pattern":"^tool-.*"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["output-available"]},"providerExecuted":{"type":"boolean"},"input":{"type":"object"},"output":{"type":"object"},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"resultProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"preliminary":{"type":"boolean"},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"type":"boolean","enum":[true]},"reason":{"type":"string"}},"required":["id","approved"]}},"required":["type","toolCallId","state","input","output"]},{"type":"object","properties":{"type":{"type":"string","pattern":"^tool-.*"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["output-error"]},"providerExecuted":{"type":"boolean"},"input":{"type":"object"},"rawInput":{"type":"object"},"output":{"not":{"type":"object"}},"errorText":{"type":"string"},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"resultProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"type":"boolean","enum":[true]},"reason":{"type":"string"}},"required":["id","approved"]}},"required":["type","toolCallId","state","errorText"]},{"type":"object","properties":{"type":{"type":"string","pattern":"^tool-.*"},"toolCallId":{"type":"string"},"toolMetadata":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}},"state":{"type":"string","enum":["output-denied"]},"providerExecuted":{"type":"boolean"},"input":{"type":"object"},"output":{"type":"object"},"errorText":{"not":{"type":"object"}},"callProviderMetadata":{"type":"object","additionalProperties":{"type":"object","additionalProperties":{"anyOf":[{"type":"string","nullable":true,"enum":[null]},{"type":"string"},{"type":"number"},{"type":"boolean"},{"type":"object","additionalProperties":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}},{"type":"array","items":{"type":"object","description":"Nested TipTap content node (same shape as parent content items)."}}]}}},"approval":{"type":"object","properties":{"id":{"type":"string"},"approved":{"type":"boolean","enum":[false]},"reason":{"type":"string"}},"required":["id","approved"]}},"required":["type","toolCallId","state","input","approval"]}]}},"metadata":{"type":"object"},"messageType":{"description":"Visibility: chat (default), hidden, or compaction summary.","type":"string","enum":["chat","hidden","compaction"]}},"required":["id","role","parts"]}},"initialArtifacts":{"type":"array","items":{"type":"object"}},"initialToolKeys":{"type":"array","items":{"type":"string"}},"initialActions":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"shape":{"type":"object"}},"required":["type"]}},"interruptableTools":{"type":"array","items":{"type":"object","properties":{"toolKey":{"type":"string","pattern":"^client\\/[a-z0-9][a-z0-9-]*(\\/[a-zA-Z0-9][a-zA-Z0-9-]*)*$"},"name":{"type":"string","minLength":1},"description":{"type":"string","minLength":1},"inputSchema":{"type":"object"}},"required":["toolKey","name","description","inputSchema"]}}},"required":["context","messages"]}}}}}}},"info":{"title":"Cotera Public API","description":"Customer-facing Cotera HTTP API","version":"1.0"},"tags":[],"servers":[],"components":{"securitySchemes":{"bearer":{"scheme":"bearer","bearerFormat":"JWT","type":"http","description":"WorkOS access token or Cotera API JWT"}},"schemas":{}}}