Webhooks
ModelsExpand Collapse
unsafe_unwrap_webhook_event: object { data, timestamp, type }
The envelope for an objective event webhook delivery. Contains timestamp, event type, and the webhook data payload.
data: object { agent, agentVariation, objective, objectiveEvent }
The webhook data payload with flat top-level keys for agent, variation, objective, and event.
agent: object { id, accountId, createdAt, 5 more }
Standard metadata for persistent, named resources (e.g., agents, tools, prompts)
agentVariation: object { id, accountId, createdAt, 5 more }
Standard metadata for persistent, named resources (e.g., agents, tools, prompts)
objective: object { id, accountId, createdAt, 4 more }
Metadata for ephemeral operations and activities (e.g., objectives, executions, runs)
objectiveEvent: object { data, metadata, contextWindowId, info }
data: object { assistantMessage, contextWindowCompacted, error, 9 more }
assistantMessage: optional object { content, toolCalls }
tool: optional object { agent, cadenyaProvidedTool, tool }
CallableTool is a union that represents a tool that can be called by an agent. In Cadenya, a tool that is used within an agent objective might be a user-defined tool (IE: MCP, HTTP), another Agent (useful to separate context), or a Cadenya Tool (one Cadenya provides).
agent: optional object { id, accountId, createdAt, 5 more }
Standard metadata for persistent, named resources (e.g., agents, tools, prompts)
cadenyaProvidedTool: optional object { id, accountId, createdAt, 5 more }
Standard metadata for persistent, named resources (e.g., agents, tools, prompts)
tool: optional object { id, accountId, createdAt, 5 more }
Standard metadata for persistent, named resources (e.g., agents, tools, prompts)
contextWindowCompacted: optional object { messagesCompacted, newContextWindow, strategies, summary }
newContextWindow: optional object { completionTokens, objectiveId, previousWindowContinueInstructions, 2 more }
The new context window created by this compaction
completionTokens: optional number
A calculated value for how many completion tokens (output tokens) have been used in this context window
previousWindowContinueInstructions: optional string
The instructions for this window to continue from a previous window's chat history.
subObjectiveCreated: optional object { metadata }
metadata: optional object { id, accountId, createdAt, 4 more }
Metadata for ephemeral operations and activities (e.g., objectives, executions, runs)
metadata: object { id, accountId, createdAt, 4 more }
Metadata for ephemeral operations and activities (e.g., objectives, executions, runs)
info: optional object { createdBy, objective }
createdBy: optional object { metadata, spec }
Profile represents a human user at the account level. Profiles are account-scoped resources that can be associated with multiple workspaces through the Actor model. Authentication for profiles is handled via SSO/OAuth (WorkOS).
metadata: object { id, accountId, name, 3 more }
AccountResourceMetadata is used to represent a resource that is associated to an account but not to a workspace.
objective: optional object { id, accountId, createdAt, 4 more }
Metadata for ephemeral operations and activities (e.g., objectives, executions, runs)