> For the complete documentation index, see [llms.txt](https://docs.concurrence.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.concurrence.com/api-reference/readme/platform/models-1.md).

# Models

## The AccessReviewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AccessReviewResponse":{"properties":{"generated_at":{"type":"string","title":"Generated At"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"credentials":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Credentials"},"total_credentials":{"type":"integer","title":"Total Credentials"},"jwt_credentials_note":{"type":"string","title":"Jwt Credentials Note"}},"type":"object","required":["generated_at","workspace_id","credentials","total_credentials","jwt_credentials_note"],"title":"AccessReviewResponse"}}}}
```

## The Action object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."}}}}
```

## The ActionPromiseCheck object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"}}}}
```

## The ActionState-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ActionState-Input":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."}}}}
```

## The ActionState-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."}}}}
```

## The ActiveEscalationItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ActiveEscalationItem":{"properties":{"call_entity_id":{"type":"string","format":"uuid","title":"Call Entity Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"escalation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Escalation Id","description":"Escalation event ID"},"status":{"type":"string","maxLength":64,"title":"Status","description":"Current escalation state"},"trigger":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger","description":"What triggered the escalation"},"trigger_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger Source","description":"Source system of the trigger"},"concept":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Concept","description":"Clinical concept that triggered escalation"},"operator_type":{"anyOf":[{"type":"string","enum":["clinical","administrative","crisis_counselor"]},{"type":"null"}],"title":"Operator Type","description":"Required operator specialization"},"regulatory_basis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Regulatory Basis","description":"Regulatory reason for escalation"},"immediate":{"type":"boolean","title":"Immediate","description":"Whether the escalation requires immediate attention"},"risk_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Risk Score","description":"Risk score 0.0 to 1.0"},"requested_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requested At","description":"ISO-8601 timestamp when escalation was requested"},"connected_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connected At","description":"ISO-8601 timestamp when operator connected"},"wait_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Wait Seconds","description":"Seconds the caller waited for an operator"},"operator_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Operator Entity Id","description":"Entity ID of the connected operator"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id","description":"Caller phone number"},"direction":{"anyOf":[{"type":"string","enum":["inbound","outbound","playground","simulated","test"]},{"type":"null"}],"title":"Direction","description":"Call direction"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number","description":"Service phone number"},"started_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Started At","description":"ISO-8601 timestamp when the call started"}},"type":"object","required":["call_entity_id","status","immediate"],"title":"ActiveEscalationItem","description":"A call with an active escalation, enriched from projected state."}}}}
```

## The ActiveEscalationListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ActiveEscalationListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ActiveEscalationItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ActiveEscalationListResponse"},"ActiveEscalationItem":{"properties":{"call_entity_id":{"type":"string","format":"uuid","title":"Call Entity Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"escalation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Escalation Id","description":"Escalation event ID"},"status":{"type":"string","maxLength":64,"title":"Status","description":"Current escalation state"},"trigger":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger","description":"What triggered the escalation"},"trigger_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger Source","description":"Source system of the trigger"},"concept":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Concept","description":"Clinical concept that triggered escalation"},"operator_type":{"anyOf":[{"type":"string","enum":["clinical","administrative","crisis_counselor"]},{"type":"null"}],"title":"Operator Type","description":"Required operator specialization"},"regulatory_basis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Regulatory Basis","description":"Regulatory reason for escalation"},"immediate":{"type":"boolean","title":"Immediate","description":"Whether the escalation requires immediate attention"},"risk_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Risk Score","description":"Risk score 0.0 to 1.0"},"requested_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requested At","description":"ISO-8601 timestamp when escalation was requested"},"connected_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connected At","description":"ISO-8601 timestamp when operator connected"},"wait_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Wait Seconds","description":"Seconds the caller waited for an operator"},"operator_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Operator Entity Id","description":"Entity ID of the connected operator"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id","description":"Caller phone number"},"direction":{"anyOf":[{"type":"string","enum":["inbound","outbound","playground","simulated","test"]},{"type":"null"}],"title":"Direction","description":"Call direction"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number","description":"Service phone number"},"started_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Started At","description":"ISO-8601 timestamp when the call started"}},"type":"object","required":["call_entity_id","status","immediate"],"title":"ActiveEscalationItem","description":"A call with an active escalation, enriched from projected state."}}}}
```

## The ActiveSession object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ActiveSession":{"properties":{"call_sid":{"type":"string","title":"Call Sid"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspace Id"},"caller_id":{"type":"string","title":"Caller Id"},"direction":{"type":"string","title":"Direction"},"duration_seconds":{"type":"number","title":"Duration Seconds"},"current_state":{"type":"string","title":"Current State","default":""},"scenario":{"type":"string","title":"Scenario","default":""}},"type":"object","required":["call_sid","caller_id","direction","duration_seconds"],"title":"ActiveSession"}}}}
```

## The AddColumnAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AddColumnAction":{"properties":{"op":{"type":"string","const":"add_column","title":"Op"},"column":{"$ref":"#/components/schemas/Column-Input"}},"type":"object","required":["op","column"],"title":"AddColumnAction"},"Column-Input":{"properties":{"name":{"$ref":"#/components/schemas/IdentifierString"},"type":{"$ref":"#/components/schemas/ColumnType"},"nullable":{"type":"boolean","title":"Nullable","default":true},"default":{"anyOf":[{"$ref":"#/components/schemas/Default"},{"type":"null"}]}},"type":"object","required":["name","type"],"title":"Column"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"},"ColumnType":{"type":"string","enum":["text","int","bigint","numeric","boolean","uuid","timestamptz","date","time","jsonb","bytea"]},"Default":{"properties":{"kind":{"type":"string","enum":["literal","uuid_v4","now","current_date"],"title":"Kind"},"value":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value","description":"Only meaningful for ``kind=\"literal\"``. Other kinds ignore it.\nA ``dict`` value is rendered as a JSONB literal — pair it with a\n``jsonb`` column."}},"type":"object","required":["kind"],"title":"Default"}}}}
```

## The AddIndexAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AddIndexAction":{"properties":{"op":{"type":"string","const":"add_index","title":"Op"},"index_name":{"$ref":"#/components/schemas/IdentifierString"},"columns":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1,"title":"Columns"}},"type":"object","required":["op","index_name","columns"],"title":"AddIndexAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The AddUniqueAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AddUniqueAction":{"properties":{"op":{"type":"string","const":"add_unique","title":"Op"},"columns":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1,"title":"Columns"},"constraint_name":{"anyOf":[{"$ref":"#/components/schemas/IdentifierString"},{"type":"null"}]}},"type":"object","required":["op","columns"],"title":"AddUniqueAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The AdvancedCallStatsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AdvancedCallStatsResponse":{"properties":{"summary":{"$ref":"#/components/schemas/AdvancedCallStatsSummary","description":"Calls in the window"},"trend":{"items":{"$ref":"#/components/schemas/AdvancedCallStatsTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"One point per bucket with calls"},"by_service":{"items":{"$ref":"#/components/schemas/ServiceCalls"},"type":"array","title":"By Service","description":"Calls per service, busiest first, ties by service_id; calls without a service are left out"},"by_direction":{"additionalProperties":{"$ref":"#/components/schemas/DirectionCalls"},"type":"object","title":"By Direction","description":"Calls per direction (inbound, outbound); calls without a direction are left out"},"groups":{"anyOf":[{"items":{"$ref":"#/components/schemas/ServiceCallStats"},"type":"array"},{"type":"null"}],"title":"Groups","description":"With group_by=service_id, one entry per service with calls in the window, ordered by service_id. A grouped answer holds at most 22,000 points in all (trend points, groups' trend points and breakdown rows); one that would hold more is a 422. Null without group_by."}},"type":"object","required":["summary","trend","by_service","by_direction"],"title":"AdvancedCallStatsResponse","description":"Percentile call metrics with a trend and by-service and by-direction breakdowns."},"AdvancedCallStatsSummary":{"properties":{"total_calls":{"type":"integer","title":"Total Calls","description":"Production calls in the window"},"completed":{"type":"integer","title":"Completed","description":"Calls not escalated to an operator (total_calls minus escalated)"},"escalated":{"type":"integer","title":"Escalated","description":"Calls escalated to an operator"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Mean call duration in seconds"},"p50_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Duration Seconds","description":"Median call duration in seconds"},"p95_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Duration Seconds","description":"95th-percentile call duration in seconds"},"p99_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P99 Duration Seconds","description":"99th-percentile call duration in seconds"},"avg_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality Score","description":"Mean quality score of scored calls (0-100)"},"p50_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality Score","description":"Median quality score (0-100)"},"p5_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P5 Quality Score","description":"5th-percentile quality score (0-100)"},"p95_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Quality Score","description":"95th-percentile quality score (0-100)"},"p95_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Latency Ms","description":"95th percentile of each call's average audio time-to-first-byte, in ms; /analytics/latency reports the same measure as p95_ttfb_ms but only matches this value when no direction or service scope is applied"}},"type":"object","required":["total_calls","completed","escalated"],"title":"AdvancedCallStatsSummary","description":"Production calls in the window: counts, durations, quality scores and audio latency."},"AdvancedCallStatsTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Bucket start as an ISO-8601 timestamp string (granularity follows `interval`)"},"calls":{"type":"integer","title":"Calls","description":"Production calls in the bucket"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Mean call duration in seconds"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Mean quality score of scored calls (0-100)"},"p50_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality","description":"Median quality score (0-100)"},"p95_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Latency Ms","description":"95th percentile of each call's average audio time-to-first-byte, in ms"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Escalated calls over calls in the bucket (0.0-1.0)"}},"type":"object","required":["date","calls","escalation_rate"],"title":"AdvancedCallStatsTrendPoint","description":"One interval bucket of the advanced call stats."},"ServiceCalls":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id","description":"The service"},"calls":{"type":"integer","title":"Calls","description":"Production calls"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Mean quality score of scored calls (0-100)"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Escalated calls over calls (0.0-1.0)"}},"type":"object","required":["service_id","calls","escalation_rate"],"title":"ServiceCalls","description":"One service's calls in ``by_service``."},"DirectionCalls":{"properties":{"calls":{"type":"integer","title":"Calls","description":"Production calls"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Mean quality score of scored calls (0-100)"}},"type":"object","required":["calls"],"title":"DirectionCalls","description":"One direction's calls in ``by_direction``."},"ServiceCallStats":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id","description":"The service"},"summary":{"$ref":"#/components/schemas/AdvancedCallStatsSummary","description":"The service's calls in the window"},"trend":{"items":{"$ref":"#/components/schemas/AdvancedCallStatsTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"The service's trend"}},"type":"object","required":["service_id","summary","trend"],"title":"ServiceCallStats","description":"One service's summary and trend: what the route returns for ``service_id`` set to it."}}}}
```

## The AdvancedCallStatsSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AdvancedCallStatsSummary":{"properties":{"total_calls":{"type":"integer","title":"Total Calls","description":"Production calls in the window"},"completed":{"type":"integer","title":"Completed","description":"Calls not escalated to an operator (total_calls minus escalated)"},"escalated":{"type":"integer","title":"Escalated","description":"Calls escalated to an operator"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Mean call duration in seconds"},"p50_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Duration Seconds","description":"Median call duration in seconds"},"p95_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Duration Seconds","description":"95th-percentile call duration in seconds"},"p99_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P99 Duration Seconds","description":"99th-percentile call duration in seconds"},"avg_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality Score","description":"Mean quality score of scored calls (0-100)"},"p50_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality Score","description":"Median quality score (0-100)"},"p5_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P5 Quality Score","description":"5th-percentile quality score (0-100)"},"p95_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Quality Score","description":"95th-percentile quality score (0-100)"},"p95_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Latency Ms","description":"95th percentile of each call's average audio time-to-first-byte, in ms; /analytics/latency reports the same measure as p95_ttfb_ms but only matches this value when no direction or service scope is applied"}},"type":"object","required":["total_calls","completed","escalated"],"title":"AdvancedCallStatsSummary","description":"Production calls in the window: counts, durations, quality scores and audio latency."}}}}
```

## The AdvancedCallStatsTrendPoint object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AdvancedCallStatsTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Bucket start as an ISO-8601 timestamp string (granularity follows `interval`)"},"calls":{"type":"integer","title":"Calls","description":"Production calls in the bucket"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Mean call duration in seconds"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Mean quality score of scored calls (0-100)"},"p50_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality","description":"Median quality score (0-100)"},"p95_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Latency Ms","description":"95th percentile of each call's average audio time-to-first-byte, in ms"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Escalated calls over calls in the bucket (0.0-1.0)"}},"type":"object","required":["date","calls","escalation_rate"],"title":"AdvancedCallStatsTrendPoint","description":"One interval bucket of the advanced call stats."}}}}
```

## The AgentAnalyticsEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentAnalyticsEntry":{"properties":{"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"agent_name":{"type":"string","title":"Agent Name"},"total_calls":{"type":"integer","title":"Total Calls"},"completed_calls":{"type":"integer","title":"Completed Calls"},"avg_duration_seconds":{"type":"number","title":"Avg Duration Seconds"},"completion_rate":{"type":"number","title":"Completion Rate"}},"type":"object","required":["agent_id","agent_name","total_calls","completed_calls","avg_duration_seconds","completion_rate"],"title":"AgentAnalyticsEntry"}}}}
```

## The AgentAnalyticsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentAnalyticsResponse":{"properties":{"agents":{"items":{"$ref":"#/components/schemas/AgentAnalyticsEntry"},"type":"array","title":"Agents"},"period":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Period"}},"type":"object","required":["agents"],"title":"AgentAnalyticsResponse"},"AgentAnalyticsEntry":{"properties":{"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"agent_name":{"type":"string","title":"Agent Name"},"total_calls":{"type":"integer","title":"Total Calls"},"completed_calls":{"type":"integer","title":"Completed Calls"},"avg_duration_seconds":{"type":"number","title":"Avg Duration Seconds"},"completion_rate":{"type":"number","title":"Completion Rate"}},"type":"object","required":["agent_id","agent_name","total_calls","completed_calls","avg_duration_seconds","completion_rate"],"title":"AgentAnalyticsEntry"}}}}
```

## The AgentIdentity object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentIdentity":{"properties":{"entry_actor_name":{"type":"string","title":"Entry Actor Name","default":""},"name":{"type":"string","title":"Name","default":""},"role":{"type":"string","title":"Role","default":""},"developed_by":{"type":"string","title":"Developed By","default":""},"instructions":{"type":"string","title":"Instructions","default":""},"initial_state":{"type":"string","title":"Initial State","default":""}},"type":"object","title":"AgentIdentity","description":"Who the agent is: the service's authored persona and its reference\ninstructions. Named ``AgentIdentity`` (not ``Identity``) to avoid colliding\nwith the existing ``config.models.Identity`` OpenAPI schema (a same-name\ncollision would force-rename that shipped schema, a breaking spec change)."}}}}
```

## The AgentListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AgentResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"AgentListResponse"},"AgentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"latest_version":{"type":"integer","title":"Latest Version","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","description","created_at","updated_at"],"title":"AgentResponse"}}}}
```

## The AgentProgram-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentProgram-Input":{"oneOf":[{"$ref":"#/components/schemas/WorkflowProgram"},{"$ref":"#/components/schemas/DirectProgram-Input"}],"discriminator":{"propertyName":"kind","mapping":{"direct":"#/components/schemas/DirectProgram-Input","workflow":"#/components/schemas/WorkflowProgram"}}},"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."},"DirectProgram-Input":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The AgentProgram-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentProgram-Output":{"oneOf":[{"$ref":"#/components/schemas/WorkflowProgram"},{"$ref":"#/components/schemas/DirectProgram-Output"}],"discriminator":{"propertyName":"kind","mapping":{"direct":"#/components/schemas/DirectProgram-Output","workflow":"#/components/schemas/WorkflowProgram"}}},"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."},"DirectProgram-Output":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The AgentResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"latest_version":{"type":"integer","title":"Latest Version","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","description","created_at","updated_at"],"title":"AgentResponse"}}}}
```

## The AgentVersion object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentVersion":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"version":{"type":"integer","title":"Version"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"initials":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Initials"},"identity":{"$ref":"#/components/schemas/Identity"},"background":{"type":"string","title":"Background"},"behaviors":{"items":{"type":"string"},"type":"array","title":"Behaviors"},"communication_patterns":{"items":{"type":"string"},"type":"array","title":"Communication Patterns"},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/VoiceConfig"},{"type":"null"}]},"program":{"$ref":"#/components/schemas/AgentProgram-Output"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","agent_id","version","identity","background","behaviors","communication_patterns"],"title":"AgentVersion","description":"A version of an Agent document."},"Identity":{"properties":{"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"developed_by":{"type":"string","title":"Developed By"},"default_spoken_language":{"type":"string","title":"Default Spoken Language"},"relationship_to_developer":{"$ref":"#/components/schemas/RelationshipToDeveloper"}},"type":"object","required":["name","role","developed_by","default_spoken_language"],"title":"Identity"},"RelationshipToDeveloper":{"properties":{"ownership":{"type":"string","title":"Ownership"},"type":{"type":"string","title":"Type"},"conversation_visibility":{"type":"string","title":"Conversation Visibility"},"thought_visibility":{"type":"string","title":"Thought Visibility"}},"type":"object","required":["ownership","type","conversation_visibility","thought_visibility"],"title":"RelationshipToDeveloper"},"VoiceConfig":{"properties":{"voice_id":{"type":"string","title":"Voice Id"},"stability":{"type":"number","title":"Stability","default":0},"similarity_boost":{"type":"number","title":"Similarity Boost","default":0},"style":{"type":"number","title":"Style","default":0},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"}},"type":"object","required":["voice_id"],"title":"VoiceConfig"},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"AgentProgram-Output":{"oneOf":[{"$ref":"#/components/schemas/WorkflowProgram"},{"$ref":"#/components/schemas/DirectProgram-Output"}],"discriminator":{"propertyName":"kind","mapping":{"direct":"#/components/schemas/DirectProgram-Output","workflow":"#/components/schemas/WorkflowProgram"}}},"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."},"DirectProgram-Output":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The AgentVersionListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentVersionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/AgentVersionResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"AgentVersionListResponse"},"AgentVersionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"version":{"type":"integer","title":"Version"},"name":{"type":"string","title":"Name"},"initials":{"type":"string","title":"Initials"},"identity":{"$ref":"#/components/schemas/Identity"},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/VoiceConfig"},{"type":"null"}]},"background":{"type":"string","title":"Background"},"behaviors":{"items":{"type":"string"},"type":"array","title":"Behaviors"},"communication_patterns":{"items":{"type":"string"},"type":"array","title":"Communication Patterns"},"program":{"$ref":"#/components/schemas/AgentProgram-Output","description":"What the version runs: ``workflow``, its service's context graph, or ``direct``, its own prompt and tools."},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","agent_id","version","name","initials","identity","voice_config","background","behaviors","communication_patterns","program","created_at","updated_at"],"title":"AgentVersionResponse"},"Identity":{"properties":{"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"developed_by":{"type":"string","title":"Developed By"},"default_spoken_language":{"type":"string","title":"Default Spoken Language"},"relationship_to_developer":{"$ref":"#/components/schemas/RelationshipToDeveloper"}},"type":"object","required":["name","role","developed_by","default_spoken_language"],"title":"Identity"},"RelationshipToDeveloper":{"properties":{"ownership":{"type":"string","title":"Ownership"},"type":{"type":"string","title":"Type"},"conversation_visibility":{"type":"string","title":"Conversation Visibility"},"thought_visibility":{"type":"string","title":"Thought Visibility"}},"type":"object","required":["ownership","type","conversation_visibility","thought_visibility"],"title":"RelationshipToDeveloper"},"VoiceConfig":{"properties":{"voice_id":{"type":"string","title":"Voice Id"},"stability":{"type":"number","title":"Stability","default":0},"similarity_boost":{"type":"number","title":"Similarity Boost","default":0},"style":{"type":"number","title":"Style","default":0},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"}},"type":"object","required":["voice_id"],"title":"VoiceConfig"},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"AgentProgram-Output":{"oneOf":[{"$ref":"#/components/schemas/WorkflowProgram"},{"$ref":"#/components/schemas/DirectProgram-Output"}],"discriminator":{"propertyName":"kind","mapping":{"direct":"#/components/schemas/DirectProgram-Output","workflow":"#/components/schemas/WorkflowProgram"}}},"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."},"DirectProgram-Output":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The AgentVersionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentVersionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"version":{"type":"integer","title":"Version"},"name":{"type":"string","title":"Name"},"initials":{"type":"string","title":"Initials"},"identity":{"$ref":"#/components/schemas/Identity"},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/VoiceConfig"},{"type":"null"}]},"background":{"type":"string","title":"Background"},"behaviors":{"items":{"type":"string"},"type":"array","title":"Behaviors"},"communication_patterns":{"items":{"type":"string"},"type":"array","title":"Communication Patterns"},"program":{"$ref":"#/components/schemas/AgentProgram-Output","description":"What the version runs: ``workflow``, its service's context graph, or ``direct``, its own prompt and tools."},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","agent_id","version","name","initials","identity","voice_config","background","behaviors","communication_patterns","program","created_at","updated_at"],"title":"AgentVersionResponse"},"Identity":{"properties":{"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"developed_by":{"type":"string","title":"Developed By"},"default_spoken_language":{"type":"string","title":"Default Spoken Language"},"relationship_to_developer":{"$ref":"#/components/schemas/RelationshipToDeveloper"}},"type":"object","required":["name","role","developed_by","default_spoken_language"],"title":"Identity"},"RelationshipToDeveloper":{"properties":{"ownership":{"type":"string","title":"Ownership"},"type":{"type":"string","title":"Type"},"conversation_visibility":{"type":"string","title":"Conversation Visibility"},"thought_visibility":{"type":"string","title":"Thought Visibility"}},"type":"object","required":["ownership","type","conversation_visibility","thought_visibility"],"title":"RelationshipToDeveloper"},"VoiceConfig":{"properties":{"voice_id":{"type":"string","title":"Voice Id"},"stability":{"type":"number","title":"Stability","default":0},"similarity_boost":{"type":"number","title":"Similarity Boost","default":0},"style":{"type":"number","title":"Style","default":0},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"}},"type":"object","required":["voice_id"],"title":"VoiceConfig"},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"AgentProgram-Output":{"oneOf":[{"$ref":"#/components/schemas/WorkflowProgram"},{"$ref":"#/components/schemas/DirectProgram-Output"}],"discriminator":{"propertyName":"kind","mapping":{"direct":"#/components/schemas/DirectProgram-Output","workflow":"#/components/schemas/WorkflowProgram"}}},"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."},"DirectProgram-Output":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The AlterAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AlterAction":{"anyOf":[{"$ref":"#/components/schemas/AddColumnAction"},{"$ref":"#/components/schemas/DropColumnAction"},{"$ref":"#/components/schemas/RenameColumnAction"},{"$ref":"#/components/schemas/ChangeColumnTypeAction"},{"$ref":"#/components/schemas/SetColumnNullableAction"},{"$ref":"#/components/schemas/SetColumnDefaultAction"},{"$ref":"#/components/schemas/DropColumnDefaultAction"},{"$ref":"#/components/schemas/AddUniqueAction"},{"$ref":"#/components/schemas/DropConstraintAction"},{"$ref":"#/components/schemas/AddIndexAction"},{"$ref":"#/components/schemas/DropIndexAction"}]},"AddColumnAction":{"properties":{"op":{"type":"string","const":"add_column","title":"Op"},"column":{"$ref":"#/components/schemas/Column-Input"}},"type":"object","required":["op","column"],"title":"AddColumnAction"},"Column-Input":{"properties":{"name":{"$ref":"#/components/schemas/IdentifierString"},"type":{"$ref":"#/components/schemas/ColumnType"},"nullable":{"type":"boolean","title":"Nullable","default":true},"default":{"anyOf":[{"$ref":"#/components/schemas/Default"},{"type":"null"}]}},"type":"object","required":["name","type"],"title":"Column"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"},"ColumnType":{"type":"string","enum":["text","int","bigint","numeric","boolean","uuid","timestamptz","date","time","jsonb","bytea"]},"Default":{"properties":{"kind":{"type":"string","enum":["literal","uuid_v4","now","current_date"],"title":"Kind"},"value":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value","description":"Only meaningful for ``kind=\"literal\"``. Other kinds ignore it.\nA ``dict`` value is rendered as a JSONB literal — pair it with a\n``jsonb`` column."}},"type":"object","required":["kind"],"title":"Default"},"DropColumnAction":{"properties":{"op":{"type":"string","const":"drop_column","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropColumnAction"},"RenameColumnAction":{"properties":{"op":{"type":"string","const":"rename_column","title":"Op"},"from":{"$ref":"#/components/schemas/IdentifierString"},"to":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","from","to"],"title":"RenameColumnAction"},"ChangeColumnTypeAction":{"properties":{"op":{"type":"string","const":"change_column_type","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"new_type":{"$ref":"#/components/schemas/ColumnType"}},"type":"object","required":["op","name","new_type"],"title":"ChangeColumnTypeAction"},"SetColumnNullableAction":{"properties":{"op":{"type":"string","const":"set_column_nullable","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"nullable":{"type":"boolean","title":"Nullable"}},"type":"object","required":["op","name","nullable"],"title":"SetColumnNullableAction"},"SetColumnDefaultAction":{"properties":{"op":{"type":"string","const":"set_column_default","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"default":{"$ref":"#/components/schemas/Default"}},"type":"object","required":["op","name","default"],"title":"SetColumnDefaultAction"},"DropColumnDefaultAction":{"properties":{"op":{"type":"string","const":"drop_column_default","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropColumnDefaultAction"},"AddUniqueAction":{"properties":{"op":{"type":"string","const":"add_unique","title":"Op"},"columns":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1,"title":"Columns"},"constraint_name":{"anyOf":[{"$ref":"#/components/schemas/IdentifierString"},{"type":"null"}]}},"type":"object","required":["op","columns"],"title":"AddUniqueAction"},"DropConstraintAction":{"properties":{"op":{"type":"string","const":"drop_constraint","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropConstraintAction"},"AddIndexAction":{"properties":{"op":{"type":"string","const":"add_index","title":"Op"},"index_name":{"$ref":"#/components/schemas/IdentifierString"},"columns":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1,"title":"Columns"}},"type":"object","required":["op","index_name","columns"],"title":"AddIndexAction"},"DropIndexAction":{"properties":{"op":{"type":"string","const":"drop_index","title":"Op"},"index_name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","index_name"],"title":"DropIndexAction"}}}}
```

## The AnalyticsDashboardResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AnalyticsDashboardResponse":{"properties":{"call_volume":{"$ref":"#/components/schemas/AnalyticsKpi","description":"Total calls in the period"},"avg_quality":{"$ref":"#/components/schemas/AnalyticsKpi","description":"Average quality score (0-100); higher is better"},"avg_ttfb_ms":{"$ref":"#/components/schemas/AnalyticsKpi","description":"Average audio time-to-first-byte in ms; lower is better"},"escalation_rate":{"$ref":"#/components/schemas/AnalyticsKpi","description":"Fraction of calls escalated; lower is better"},"tool_success_rate":{"$ref":"#/components/schemas/AnalyticsKpi","description":"Fraction of tool calls that succeeded; higher is better"},"avg_duration_s":{"$ref":"#/components/schemas/AnalyticsKpi","description":"Average call duration in seconds"},"period_days":{"type":"integer","title":"Period Days","description":"Length of the reporting period in days"}},"type":"object","required":["call_volume","avg_quality","avg_ttfb_ms","escalation_rate","tool_success_rate","avg_duration_s","period_days"],"title":"AnalyticsDashboardResponse","description":"Composite dashboard — six headline KPIs, each with a delta, plus the period length.\n\nHigher-is-better for ``call_volume``, ``avg_quality``, ``tool_success_rate``;\nhigher-is-worse for ``escalation_rate``, ``avg_ttfb_ms``, ``avg_duration_s``.\nConsumers must color deltas by that per-KPI polarity, not by delta sign alone."},"AnalyticsKpi":{"properties":{"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"Current-period value (None when no data)"},"delta_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Delta Pct","description":"Percent change vs the previous period, or None"}},"type":"object","title":"AnalyticsKpi","description":"A single headline KPI with its period-over-period change.\n\n``value`` is left broad (int for counts, float for rates/scores/durations,\n``None`` when the metric has no data for the period). ``delta_pct`` is the\nsigned percent change vs the previous equal-length period, or ``None`` when\na prior-period comparison is unavailable."}}}}
```

## The AnalyticsKpi object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AnalyticsKpi":{"properties":{"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"Current-period value (None when no data)"},"delta_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Delta Pct","description":"Percent change vs the previous period, or None"}},"type":"object","title":"AnalyticsKpi","description":"A single headline KPI with its period-over-period change.\n\n``value`` is left broad (int for counts, float for rates/scores/durations,\n``None`` when the metric has no data for the period). ``delta_pct`` is the\nsigned percent change vs the previous equal-length period, or ``None`` when\na prior-period comparison is unavailable."}}}}
```

## The AnalyticsUnavailableResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AnalyticsUnavailableResponse":{"properties":{"detail":{"type":"string","const":"Analytics unavailable","title":"Detail"}},"type":"object","required":["detail"],"title":"AnalyticsUnavailableResponse","description":"The 503 body when the route couldn't read its data."}}}}
```

## The AnnotationState object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."}}}}
```

## The AnyValue object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AnyValue":{"additionalProperties":true,"type":"object"}}}}
```

## The ApiKeyListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ApiKeyListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ApiKeyResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ApiKeyListResponse"},"ApiKeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"created_by_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Entity Id"},"created_by_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Credential Id"},"key_id":{"type":"string","title":"Key Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"role":{"type":"string","title":"Role"},"permissions":{"items":{"type":"string"},"type":"array","title":"Permissions"},"non_production":{"type":"boolean","title":"Non Production","description":"True for a test key: what it creates is stored with source `test` and kept out of production analytics."},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","created_by_entity_id","created_by_credential_id","key_id","name","role","permissions","non_production","expires_at","last_used_at","created_at","updated_at"],"title":"ApiKeyResponse"}}}}
```

## The ApiKeyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ApiKeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"created_by_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Entity Id"},"created_by_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Credential Id"},"key_id":{"type":"string","title":"Key Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"role":{"type":"string","title":"Role"},"permissions":{"items":{"type":"string"},"type":"array","title":"Permissions"},"non_production":{"type":"boolean","title":"Non Production","description":"True for a test key: what it creates is stored with source `test` and kept out of production analytics."},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"last_used_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Used At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","created_by_entity_id","created_by_credential_id","key_id","name","role","permissions","non_production","expires_at","last_used_at","created_at","updated_at"],"title":"ApiKeyResponse"}}}}
```

## The AppliedBehavior object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"}}}}
```

## The AppliedRate object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AppliedRate":{"properties":{"input_rate_effective_from":{"type":"string","format":"date","title":"Input Rate Effective From","description":"Inclusive first usage date for the input rate."},"input_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Input Rate Effective To","description":"Exclusive end usage date for the input rate; null means no end date."},"output_rate_effective_from":{"type":"string","format":"date","title":"Output Rate Effective From","description":"Inclusive first usage date for the output rate."},"output_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Output Rate Effective To","description":"Exclusive end usage date for the output rate; null means no end date."},"cached_rate_effective_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cached Rate Effective From","description":"Inclusive first usage date for the cached-input rate; null if no cached rate applied."},"cached_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cached Rate Effective To","description":"Exclusive end usage date for the cached-input rate; null if unbounded or no cached rate applied."},"min_input_tokens":{"type":"integer","title":"Min Input Tokens","description":"Inclusive lower bound on per-request context input tokens for the input-rate band."},"max_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Input Tokens","description":"Inclusive upper bound on per-request context input tokens; null means unbounded."},"input_per_million":{"type":"string","title":"Input Per Million","description":"USD per million uncached input tokens, as a decimal string."},"cached_input_per_million":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cached Input Per Million","description":"USD per million cached input tokens; null if no cached rate applied."},"output_per_million":{"type":"string","title":"Output Per Million","description":"USD per million output tokens, as a decimal string."}},"type":"object","required":["input_rate_effective_from","input_rate_effective_to","output_rate_effective_from","output_rate_effective_to","cached_rate_effective_from","cached_rate_effective_to","min_input_tokens","max_input_tokens","input_per_million","cached_input_per_million","output_per_million"],"title":"AppliedRate","description":"Rate record applied to this model during the requested period."}}}}
```

## The ArchiveResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ArchiveResponse":{"properties":{"surface_id":{"type":"string","format":"uuid","title":"Surface Id"},"status":{"type":"string","const":"archived","title":"Status"}},"type":"object","required":["surface_id","status"],"title":"ArchiveResponse"}}}}
```

## The ArchiveWorkspaceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ArchiveWorkspaceRequest":{"properties":{"slug":{"$ref":"#/components/schemas/SlugString"}},"type":"object","required":["slug"],"title":"ArchiveWorkspaceRequest"},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The AuditEventsListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuditEventsListResponse":{"properties":{"events":{"items":{"$ref":"#/components/schemas/src__routes__audit__AuditEventResponse"},"type":"array","title":"Events"},"total":{"type":"integer","title":"Total"},"limit":{"type":"integer","title":"Limit"},"offset":{"type":"integer","title":"Offset"},"has_more":{"type":"boolean","title":"Has More"}},"type":"object","required":["events","total","limit","offset","has_more"],"title":"AuditEventsListResponse"},"src__routes__audit__AuditEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique audit event identifier"},"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspace Id","description":"Workspace that owns this event; null for pre-workspace events (e.g. login)"},"timestamp":{"type":"string","title":"Timestamp","description":"ISO-8601 timestamp of the event"},"service":{"type":"string","title":"Service","description":"Service that produced the event"},"actor_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Actor Entity Id","description":"Entity ID of the actor who performed the action"},"actor_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Actor Credential Id","description":"Credential ID used by the actor"},"action":{"type":"string","title":"Action","description":"Action that was performed (e.g. 'entity.read')"},"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type","description":"Type of resource that was accessed"},"resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Id","description":"ID of the accessed resource"},"resource_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Name","description":"Human-readable name of the accessed resource"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"IP address of the actor"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent","description":"User-Agent header from the request"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional event-specific metadata"},"phi_accessed":{"type":"boolean","title":"Phi Accessed","description":"Whether protected health information was accessed","default":false}},"type":"object","required":["id","timestamp","service","action"],"title":"AuditEventResponse"}}}}
```

## The AuditExportChunk object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuditExportChunk":{"properties":{"chunk_index":{"type":"integer","title":"Chunk Index"},"row_count":{"type":"integer","title":"Row Count"},"byte_count":{"type":"integer","title":"Byte Count"},"external_link":{"type":"string","title":"External Link","description":"Short-lived presigned URL — download directly, do not proxy."},"expiration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expiration","description":"ISO-8601 expiry of the presigned link."}},"type":"object","required":["chunk_index","row_count","byte_count","external_link"],"title":"AuditExportChunk"}}}}
```

## The AuditExportRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuditExportRequest":{"properties":{"date_from":{"type":"string","format":"date-time","title":"Date From"},"date_to":{"type":"string","format":"date-time","title":"Date To"},"service":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Service","description":"Filter by service name."},"action":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Action","description":"Filter by action type."},"phi_only":{"type":"boolean","title":"Phi Only","default":false}},"type":"object","required":["date_from","date_to"],"title":"AuditExportRequest"}}}}
```

## The AuditExportResultResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuditExportResultResponse":{"properties":{"statement_id":{"type":"string","title":"Statement Id"},"status":{"type":"string","enum":["pending","ready"],"title":"Status"},"result_format":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Result Format","description":"Result file format (CSV)."},"total_row_count":{"type":"integer","title":"Total Row Count","default":0},"chunks":{"items":{"$ref":"#/components/schemas/AuditExportChunk"},"type":"array","title":"Chunks"}},"type":"object","required":["statement_id","status"],"title":"AuditExportResultResponse"},"AuditExportChunk":{"properties":{"chunk_index":{"type":"integer","title":"Chunk Index"},"row_count":{"type":"integer","title":"Row Count"},"byte_count":{"type":"integer","title":"Byte Count"},"external_link":{"type":"string","title":"External Link","description":"Short-lived presigned URL — download directly, do not proxy."},"expiration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expiration","description":"ISO-8601 expiry of the presigned link."}},"type":"object","required":["chunk_index","row_count","byte_count","external_link"],"title":"AuditExportChunk"}}}}
```

## The AuditExportSubmitResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuditExportSubmitResponse":{"properties":{"statement_id":{"type":"string","title":"Statement Id","description":"The export's handle: poll GET /export/{statement_id} for the links."},"status":{"type":"string","enum":["pending","ready"],"title":"Status","description":"pending: still running. ready: links available immediately."}},"type":"object","required":["statement_id","status"],"title":"AuditExportSubmitResponse"}}}}
```

## The AuditLogListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuditLogListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/src__routes__operators_models__AuditEventResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"AuditLogListResponse"},"src__routes__operators_models__AuditEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"event_type":{"type":"string","title":"Event Type","description":"Audit event type (e.g. operator.status_change)"},"data":{"additionalProperties":true,"type":"object","title":"Data","description":"Audit payload — shape varies by event_type"},"source":{"type":"string","title":"Source","description":"System that emitted the event"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At","description":"When the event was ingested"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the event occurred"}},"type":"object","required":["id","workspace_id","event_type","data","source"],"title":"AuditEventResponse"}}}}
```

## The AuditSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuditSummary":{"properties":{"event_count":{"type":"integer","title":"Event Count","default":0},"latest_event":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Latest Event"}},"type":"object","title":"AuditSummary"}}}}
```

## The AuditSummaryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuditSummaryResponse":{"properties":{"total_events":{"type":"integer","title":"Total Events"},"phi_access_events":{"type":"integer","title":"Phi Access Events"},"unique_actors":{"type":"integer","title":"Unique Actors"},"services_with_events":{"type":"integer","title":"Services With Events"}},"type":"object","required":["total_events","phi_access_events","unique_actors","services_with_events"],"title":"AuditSummaryResponse"}}}}
```

## The AuthInfoResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuthInfoResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"key_id":{"type":"string","title":"Key Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"expires_in_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expires In Seconds"}},"type":"object","required":["workspace_id","key_id","name","expires_at","expires_in_seconds"],"title":"AuthInfoResponse"}}}}
```

## The AuthoredLine object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AuthoredLine":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"kind":{"type":"string","enum":["disclosure","emergency","crisis","correction","safe_exit","authored"],"title":"Kind"},"text":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Text"},"text_truncated":{"type":"boolean","title":"Text Truncated","default":false},"completed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Completed"},"verbatim":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Verbatim"}},"type":"object","required":["kind"],"title":"AuthoredLine"}}}}
```

## The Availability object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Availability":{"properties":{"available":{"type":"boolean","title":"Available"},"reason":{"anyOf":[{"$ref":"#/components/schemas/AvailabilityReason"},{"type":"null"}]}},"type":"object","required":["available","reason"],"title":"Availability"},"AvailabilityReason":{"properties":{"code":{"type":"string","maxLength":128,"title":"Code"},"message":{"$ref":"#/components/schemas/DescriptionString"}},"type":"object","required":["code","message"],"title":"AvailabilityReason"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The AvailabilityDate object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AvailabilityDate":{"properties":{"date":{"type":"string","maxLength":16,"title":"Date"},"slots":{"items":{"$ref":"#/components/schemas/AvailabilitySlot"},"type":"array","maxItems":200,"title":"Slots"}},"type":"object","required":["date"],"title":"AvailabilityDate"},"AvailabilitySlot":{"properties":{"id":{"type":"string","maxLength":128,"title":"Id"},"start":{"type":"string","maxLength":16,"title":"Start"},"end":{"type":"string","maxLength":16,"title":"End"},"provider":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider"}},"type":"object","required":["id","start","end"],"title":"AvailabilitySlot"}}}}
```

## The AvailabilityReason object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AvailabilityReason":{"properties":{"code":{"type":"string","maxLength":128,"title":"Code"},"message":{"$ref":"#/components/schemas/DescriptionString"}},"type":"object","required":["code","message"],"title":"AvailabilityReason"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The AvailabilityResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AvailabilityResponse":{"properties":{"dates":{"items":{"$ref":"#/components/schemas/AvailabilityDate"},"type":"array","maxItems":64,"title":"Dates"}},"type":"object","title":"AvailabilityResponse","description":"Available appointment slots grouped by date."},"AvailabilityDate":{"properties":{"date":{"type":"string","maxLength":16,"title":"Date"},"slots":{"items":{"$ref":"#/components/schemas/AvailabilitySlot"},"type":"array","maxItems":200,"title":"Slots"}},"type":"object","required":["date"],"title":"AvailabilityDate"},"AvailabilitySlot":{"properties":{"id":{"type":"string","maxLength":128,"title":"Id"},"start":{"type":"string","maxLength":16,"title":"Start"},"end":{"type":"string","maxLength":16,"title":"End"},"provider":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider"}},"type":"object","required":["id","start","end"],"title":"AvailabilitySlot"}}}}
```

## The AvailabilitySlot object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AvailabilitySlot":{"properties":{"id":{"type":"string","maxLength":128,"title":"Id"},"start":{"type":"string","maxLength":16,"title":"Start"},"end":{"type":"string","maxLength":16,"title":"End"},"provider":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider"}},"type":"object","required":["id","start","end"],"title":"AvailabilitySlot"}}}}
```

## The BackgroundString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BackgroundString":{"type":"string","maxLength":10000}}}}
```

## The BargeInEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BargeInEvent":{"properties":{"type":{"const":"barge_in","default":"barge_in","title":"Type","type":"string"},"interrupted_text":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupted Text"},"discarded_texts":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"default":null,"title":"Discarded Texts"},"interrupted_speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupted Speaker Id"},"interrupting_speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupting Speaker Id"},"total_barge_ins":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Total Barge Ins"}},"title":"BargeInEvent","type":"object"}}}}
```

## The BatchDetail object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BatchDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"batch_id."},"source_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Source Id"},"dataset":{"type":"string","title":"Dataset"},"status":{"type":"string","title":"Status","description":"discovered | ready | processing | completed | failed."},"files_found":{"type":"integer","title":"Files Found"},"created_ts":{"type":"string","title":"Created Ts"},"files":{"items":{"$ref":"#/components/schemas/IntakeFileRow"},"type":"array","title":"Files","default":[]}},"type":"object","required":["id","dataset","status","files_found","created_ts"],"title":"BatchDetail"},"IntakeFileRow":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"file_id — used for download."},"filename":{"type":"string","title":"Filename"},"dataset":{"type":"string","title":"Dataset","description":"Schema slug (UI label \"Schema\")."},"schema_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schema Version","description":"The contract version this file validated against (e.g. ``v1``)."},"status":{"$ref":"#/components/schemas/_FileStatus"},"error_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Reason","description":"Null unless rejected/failed."},"size_bytes":{"type":"integer","title":"Size Bytes"},"ingested_at":{"type":"string","title":"Ingested At","description":"ISO-8601 timestamp the file was received."},"document_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Document Id","description":"The document this version belongs to. Null for snapshot and CSV rows; set for documents. The console\ngroups versions by it to show each document's version history."},"version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version","description":"The file's version number (per-document for documents, per-dataset for\nsnapshot). Lets the UI render a document's version history."},"source_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Type","description":"Origin of the document this version belongs to: ``manual`` for console uploads, ``google_shared_drive``\nfor the Drive connector. Null for snapshot and CSV rows."},"source_file_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source File Id","description":"The source's stable external id (e.g. the Google Drive file id) for the\ndocument. Lets the console show provenance and confirm a re-synced file\nbumped the *same* document. Null for manual uploads and snapshot rows."},"source_folder_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Folder Path","description":"Where the file lived within the mapped Drive folder tree, as a relative path with folder names joined by\n``/`` (e.g. ``clinical/notes``), and ``''`` at the mapped root. Lets the console show the original folder\nstructure. Null for manual uploads and snapshot rows."},"doc_metadata":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Doc Metadata","description":"Caller-supplied tags linking the document to a real-world subject, e.g. ``{\"patient_id\": \"…\"}``. Set at upload for the whole document version\nchain. ``{}`` for a document with no tags; null only for snapshot/CSV rows."}},"type":"object","required":["id","filename","dataset","status","size_bytes","ingested_at"],"title":"IntakeFileRow","description":"A file in the Files list."},"_FileStatus":{"type":"string","enum":["received","scanned","processing","curated","rejected","failed","held"]}}}}
```

## The BatchProcessingManifest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BatchProcessingManifest":{"properties":{"document_processing":{"additionalProperties":true,"type":"object","title":"Document Processing"},"files":{"items":{"$ref":"#/components/schemas/FileEntry"},"type":"array","title":"Files"}},"type":"object","required":["document_processing","files"],"title":"BatchProcessingManifest","description":"Per-file extraction parameters for a document batch's files that are still ``received``.\n\nThe batch extraction job reads this once per batch and extracts every file. One request per file would\nexceed the request timeout on large batches. The job authenticates with the same short-lived,\nworkspace-scoped token as the status write-back. ``document_processing`` applies to the whole dataset.\n``file_type`` is per file, because a dataset can accept more than one type.\n\n``source_file_id`` is an opaque id, set whenever the file's document has one. ``source_url`` is the Google Drive\nlink for a document that came from a Google Shared Drive, and is null otherwise. ``source_folder_path`` and\n``filename`` are free text that the operator named, so they are set only for datasets marked as containing\nno PHI. Otherwise they are null, so PHI never leaves the file's record."},"FileEntry":{"properties":{"file_id":{"type":"string","format":"uuid","title":"File Id"},"document_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Document Id"},"version":{"type":"integer","title":"Version"},"source_path":{"type":"string","title":"Source Path"},"file_type":{"type":"string","title":"File Type"},"content_type":{"type":"string","title":"Content Type"},"sha256":{"type":"string","title":"Sha256"},"size_bytes":{"type":"integer","title":"Size Bytes"},"ingested_at":{"type":"string","title":"Ingested At"},"contract_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contract Id"},"contract_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Version"},"source_file_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source File Id"},"source_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Url"},"source_folder_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Folder Path"},"filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filename"}},"type":"object","required":["file_id","version","source_path","file_type","content_type","sha256","size_bytes","ingested_at"],"title":"FileEntry"}}}}
```

## The BatchRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BatchRow":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"batch_id."},"source_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Source Id"},"dataset":{"type":"string","title":"Dataset"},"status":{"type":"string","title":"Status","description":"discovered | ready | processing | completed | failed."},"files_found":{"type":"integer","title":"Files Found"},"created_ts":{"type":"string","title":"Created Ts"}},"type":"object","required":["id","dataset","status","files_found","created_ts"],"title":"BatchRow","description":"A source-sync batch (Batches list / detail)."}}}}
```

## The BehaviorDecision object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BehaviorDecision":{"description":"What one caller turn's dynamic behavior decision did.\n\n``outcome``: ``applied`` put the chosen behavior in force; ``kept`` left the active one in force because\nthe model chose it again or said it stays; ``held`` left the active one in force because it was still\ninside its ``sticky_turns`` and the model chose none, chose another behavior under the confidence floor,\nor gave no usable answer (a different behavior chosen at or over the floor replaces it as ``applied``,\ninside its ``sticky_turns`` too); ``none``, ``below_floor`` and ``failed`` left nothing in force (no\nbehavior applies, a choice under the confidence floor, no usable answer); ``skipped`` ran no decision\n(``reason`` says why) and ended the active behavior; ``superseded`` was cancelled by the caller's next\nturn before it landed.","properties":{"outcome":{"$ref":"#/components/schemas/DynamicBehaviorOutcome"},"reason":{"anyOf":[{"$ref":"#/components/schemas/FailureReason"},{"$ref":"#/components/schemas/DynamicBehaviorSkip"},{"type":"null"}],"default":null,"description":"Why a decision failed or was skipped, or why a held behavior was held.","title":"Reason"},"behavior_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior in force after the decision.","title":"Behavior Id"},"behavior_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior in force. Null where none is, and before behaviors were versioned.","title":"Behavior Version"},"chosen_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior the model chose. Null when it chose none or gave no usable answer.","title":"Chosen Id"},"chosen_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior the model chose. Null where it chose none, and before behaviors were versioned.","title":"Chosen Version"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The choice's confidence. Null where the decision got no usable answer.","title":"Confidence"},"kept_by_predicate":{"default":false,"description":"Whether the active behavior stayed because the model said it stays, rather than by its choice.","title":"Kept By Predicate","type":"boolean"},"keep_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The confidence of the answer to whether the active behavior stays, when that was asked.","title":"Keep Confidence"},"candidate_count":{"default":0,"description":"How many behaviors the decision chose between, ``none`` aside.","title":"Candidate Count","type":"integer"},"latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Latency Ms"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"description":"The context graph version the conversation ran when the decision was made. Null on a direct program's\ndecision, which ran no context graph: ``program_digest`` names what it ran.","title":"Context Graph Version"},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"The direct program the conversation ran when the decision was made, by the digest its run records\n(``RunManifest.program_digest``). Null on a context graph's decision."},"selector_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"What a direct program's decision rendered its request from. Null on a context graph's decision, whose run\nrecords it (``RunManifest.dynamic_behavior_prompt_template_hash``)."},"cited_message_indexes":{"default":[],"description":"The messages the decision read the turn from: the agent's line before the turn, then the caller's.","items":{"type":"integer"},"title":"Cited Message Indexes","type":"array"}},"required":["outcome"],"title":"BehaviorDecision","type":"object"},"DynamicBehaviorOutcome":{"enum":["applied","kept","held","none","below_floor","failed","skipped","superseded"],"type":"string"},"FailureReason":{"enum":["refusal","out_of_set","malformed","http_4xx","http_retryable","connection","timeout","breaker_open","options_exceeded"],"type":"string"},"DynamicBehaviorSkip":{"enum":["emergency_floor","person_request","empathy_hold","suspended","no_candidates"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The BindingUpsertRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BindingUpsertRequest":{"properties":{"external_integration_id":{"type":"string","format":"uuid","title":"External Integration Id"},"external_subject_key":{"type":"string","maxLength":512,"minLength":1,"title":"External Subject Key"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"source":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Source","deprecated":true},"display_name":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Display Name"}},"additionalProperties":false,"type":"object","required":["external_integration_id","external_subject_key","entity_id"],"title":"BindingUpsertRequest"}}}}
```

## The BlocklistedNumberCheck object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"}}}}
```

## The Body\_upload\_intake\_file\_v1\_\_workspace\_id\_\_intake\_files\_post object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Body_upload_intake_file_v1__workspace_id__intake_files_post":{"properties":{"dataset":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Dataset"},"file":{"type":"string","contentMediaType":"application/octet-stream","title":"File"},"document_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Document Id"},"doc_metadata":{"anyOf":[{"type":"string","contentMediaType":"application/json","contentSchema":{"patternProperties":{"^[A-Za-z0-9_.-]+$":{"type":"string","maxLength":256,"minLength":1}},"propertyNames":{"maxLength":64,"minLength":1},"type":"object","maxProperties":32,"minProperties":1}},{"type":"null"}],"title":"Doc Metadata"}},"type":"object","required":["dataset","file"],"title":"Body_upload_intake_file_v1__workspace_id__intake_files_post"}}}}
```

## The Body\_voice-turn object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Body_voice-turn":{"properties":{"audio":{"type":"string","contentMediaType":"application/octet-stream","title":"Audio"},"phone_number":{"type":"string","maxLength":16,"pattern":"^\\+[1-9]\\d{1,14}$","title":"Phone Number"}},"type":"object","required":["audio","phone_number"],"title":"Body_voice-turn"}}}}
```

## The BookingRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BookingRequest":{"properties":{"slot_id":{"type":"string","maxLength":256,"minLength":1,"title":"Slot Id","description":"The FHIR Slot ID to book"}},"type":"object","required":["slot_id"],"title":"BookingRequest"}}}}
```

## The BookingResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BookingResponse":{"properties":{"status":{"type":"string","const":"pending","title":"Status","description":"Booking lifecycle status."},"message":{"type":"string","maxLength":512,"title":"Message"},"slot_id":{"type":"string","maxLength":256,"title":"Slot Id"}},"type":"object","required":["status","message","slot_id"],"title":"BookingResponse","description":"Acknowledgement returned when a booking request is accepted."}}}}
```

## The BooleanCount object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BooleanCount":{"properties":{"value":{"type":"boolean","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["value","count"],"title":"BooleanCount"}}}}
```

## The BooleanMetricValueResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BooleanMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"boolean","title":"Metric Type"},"value":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Value","description":"The value this row counts. A list-metrics latest row gives its period's more frequent value."},"distribution":{"items":{"$ref":"#/components/schemas/BooleanCount"},"type":"array","title":"Distribution","description":"Events per value in this row's period, most frequent first. A list-metrics latest row\nlists both values its period saw; any other row lists its own value.","default":[]}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"BooleanMetricValueResponse"},"BooleanCount":{"properties":{"value":{"type":"boolean","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["value","count"],"title":"BooleanCount"}}}}
```

## The BoundFamily object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BoundFamily":{"properties":{"version_set":{"$ref":"#/components/schemas/ReadinessLabel"},"family":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Family"},"source":{"type":"string","enum":["service","agent","engine_default","agent_missing"],"title":"Source"},"capabilities":{"anyOf":[{"$ref":"#/components/schemas/SessionCapabilities"},{"type":"null"}]},"dynamic_behaviors_configured":{"type":"boolean","title":"Dynamic Behaviors Configured"},"ignored_settings":{"items":{"type":"string"},"type":"array","title":"Ignored Settings","description":"The service settings, as dotted paths from the service (keyterms, voice_config.max_buffer_delay_ms), that the service sets to a non-default value and this family does not read. Advisory: the config is valid and saves, and a setting listed here may still be refused (see family_refusals). Empty, and not known, when ignored_settings_known is false."},"ignored_settings_known":{"type":"boolean","title":"Ignored Settings Known","description":"Whether ignored_settings was read: false when the version set's family is unknown or the stored service no longer validates, so an empty list says nothing."},"family_judgement":{"type":"string","enum":["judged","not_judged"],"title":"Family Judgement","description":"judged: family_refusals is every refusal the voice family contract and the family's delivery rules find for this version set, empty when the family runs it as authored. not_judged: the version set could not be judged (family_not_judged says why), so family_refusals may be incomplete and an empty one is never a pass."},"family_refusals":{"items":{"$ref":"#/components/schemas/FamilyRefusal"},"type":"array","title":"Family Refusals","description":"Each reason the family cannot run this version set as stored, with the code, message and fields a save refuses it with: the family's admission for the workspace when the service names the family, its delivery rules held to the whole config, then the contract's rules on the program the set's agent version runs. A client shows each one's code, message and fields and computes none. Messages have every digit redacted; a save plan's problems keep the exact text."},"family_not_judged":{"anyOf":[{"$ref":"#/components/schemas/FamilyNotJudged"},{"type":"null"}],"description":"Why the version set was not judged, when family_judgement is not_judged; null otherwise."}},"type":"object","required":["version_set","family","source","capabilities","dynamic_behaviors_configured","ignored_settings","ignored_settings_known","family_judgement","family_refusals","family_not_judged"],"title":"BoundFamily"},"ReadinessLabel":{"type":"string"},"SessionCapabilities":{"properties":{"multi_state":{"type":"boolean","title":"Multi State"},"dynamic_behaviors":{"type":"boolean","title":"Dynamic Behaviors"},"completion_navigation":{"type":"boolean","title":"Completion Navigation"},"channels":{"items":{"type":"string","enum":["app","phone","playground","test_call"]},"type":"array","title":"Channels"},"outbound_calls":{"type":"boolean","title":"Outbound Calls"},"operator_takeover":{"type":"boolean","title":"Operator Takeover"},"end_call":{"type":"boolean","title":"End Call"},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"authored_lines":{"type":"string","enum":["tts","model_checked","clips"],"title":"Authored Lines","default":"clips"},"floor_enforced":{"type":"boolean","title":"Floor Enforced","default":false},"state_carrier":{"anyOf":[{"type":"string","enum":["session_update_and_note","note_only"]},{"type":"null"}],"title":"State Carrier"},"typed_guardrails":{"type":"boolean","title":"Typed Guardrails","default":false}},"type":"object","required":["multi_state","dynamic_behaviors","completion_navigation","channels","outbound_calls","operator_takeover","end_call","warm_transfer","authored_lines","floor_enforced","state_carrier","typed_guardrails"],"title":"SessionCapabilities"},"FamilyRefusal":{"properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/FamilyRefusalCode"},{"type":"string","enum":["family_warm_transfer_unsupported","family_cannot_speak_service_lines"]}],"title":"Code"},"message":{"$ref":"#/components/schemas/ReadinessLabel","description":"Names the family and the fix, with every digit redacted."},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"What the author changes, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyRefusal"},"FamilyRefusalCode":{"type":"string","enum":["voice_family_not_served","voice_family_residency","voice_family_agent_version","voice_family_direct_program","voice_family_graph_shape","voice_family_guardrails","voice_family_dynamic_behaviors","voice_family_completion_navigation","voice_family_warm_transfer","voice_family_service_lines","voice_family_outbound","voice_family_settings"]},"FamilyNotJudged":{"properties":{"code":{"$ref":"#/components/schemas/FamilyNotJudgedCode"},"message":{"$ref":"#/components/schemas/ReadinessLabel"},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"Where the author looks, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyNotJudged"},"FamilyNotJudgedCode":{"type":"string","enum":["agent_version_missing","family_not_on_contract","voice_config_unreadable","graph_missing","graph_version_missing","graph_version_unreadable"]}}}}
```

## The BrandingConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."}}}}
```

## The BrandingSettingsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BrandingSettingsRequest":{"properties":{"branding":{"$ref":"#/components/schemas/BrandingConfig"}},"type":"object","required":["branding"],"title":"BrandingSettingsRequest","description":"Update workspace branding. All fields are optional, and only provided\nfields are changed. A field sent as ``null`` is cleared."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."}}}}
```

## The BrandingSettingsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BrandingSettingsResponse":{"properties":{"branding":{"$ref":"#/components/schemas/BrandingConfig"}},"type":"object","required":["branding"],"title":"BrandingSettingsResponse"},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."}}}}
```

## The BridgeRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BridgeRequest":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"},"objective":{"type":"string","maxLength":2000,"minLength":1,"title":"Objective"},"num_scenarios":{"type":"integer","maximum":50,"minimum":1,"title":"Num Scenarios","default":5},"max_turns":{"type":"integer","maximum":40,"minimum":1,"title":"Max Turns","default":20},"concurrency":{"type":"integer","maximum":20,"minimum":1,"title":"Concurrency","default":3},"branch_name":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Branch Name"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"Optional world entity UUID to bind caller context for every scenario session created by this bridge run. The value is forwarded to each scenario's session-create call and inherited by any forks; identical precedence rules apply per-session (entity match wins over phone, stale UUID falls back to phone lookup, malformed UUID returns 422). Use this to pin an entire regression suite to a specific test patient."},"tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Tags"},"target_spec":{"anyOf":[{"$ref":"#/components/schemas/TargetSpec"},{"type":"null"}]},"exploration":{"anyOf":[{"$ref":"#/components/schemas/ExplorationConfig"},{"type":"null"}]},"auto_target_spec":{"type":"boolean","title":"Auto Target Spec","default":false},"async_generation":{"type":"boolean","title":"Async Generation","default":false}},"type":"object","required":["service_id","objective"],"title":"BridgeRequest"},"TargetSpec":{"properties":{"desired_states":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"Desired States"},"non_desired_states":{"items":{"$ref":"#/components/schemas/NonDesiredState"},"type":"array","maxItems":50,"title":"Non Desired States"},"ordered_pathways":{"items":{"$ref":"#/components/schemas/OrderedPathway"},"type":"array","maxItems":20,"title":"Ordered Pathways"},"completion_criteria":{"$ref":"#/components/schemas/CompletionCriteria"}},"type":"object","title":"TargetSpec"},"NonDesiredState":{"properties":{"state":{"type":"string","maxLength":128,"title":"State"},"mode":{"type":"string","enum":["hard","soft"],"title":"Mode","default":"hard"}},"type":"object","required":["state"],"title":"NonDesiredState"},"OrderedPathway":{"properties":{"id":{"type":"string","maxLength":64,"title":"Id"},"sequence":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"minItems":1,"title":"Sequence"}},"type":"object","required":["id","sequence"],"title":"OrderedPathway"},"CompletionCriteria":{"properties":{"state_based":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"State Based"},"tool_based":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"Tool Based"}},"type":"object","title":"CompletionCriteria"},"ExplorationConfig":{"properties":{"coverage_driven_selection":{"type":"boolean","title":"Coverage Driven Selection","default":false},"enable_forking":{"type":"boolean","title":"Enable Forking","default":false},"max_forks_per_scenario":{"type":"integer","maximum":5,"minimum":0,"title":"Max Forks Per Scenario","default":2},"recommend_candidates":{"type":"integer","maximum":10,"minimum":1,"title":"Recommend Candidates","default":3}},"type":"object","title":"ExplorationConfig"}}}}
```

## The BridgeResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BridgeResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"scenarios":{"items":{"$ref":"#/components/schemas/Scenario"},"type":"array","title":"Scenarios"},"tool_execution":{"$ref":"#/components/schemas/SimulationToolExecution","description":"The tool settings the run executes with. A `/bridge` run simulates every tool."},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"inferred_target_spec":{"anyOf":[{"$ref":"#/components/schemas/TargetSpec"},{"type":"null"}]},"inferred_target_spec_rationale":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Inferred Target Spec Rationale"}},"type":"object","required":["run_id","status","scenarios","tool_execution"],"title":"BridgeResponse"},"Scenario":{"properties":{"description":{"type":"string","maxLength":512,"title":"Description"},"temperament":{"type":"string","maxLength":32,"title":"Temperament","default":"neutral"},"initial_message":{"type":"string","maxLength":1000,"title":"Initial Message"},"scenario_instructions":{"type":"string","maxLength":2000,"title":"Scenario Instructions"},"persona":{"$ref":"#/components/schemas/ScenarioPersona"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"}},"type":"object","required":["description","initial_message","scenario_instructions"],"title":"Scenario"},"ScenarioPersona":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name","default":""},"role":{"type":"string","maxLength":64,"title":"Role","default":"patient"},"communication_style":{"type":"string","maxLength":512,"title":"Communication Style","default":""},"default_language":{"type":"string","maxLength":16,"title":"Default Language","default":"en-US"},"background":{"type":"string","maxLength":2000,"title":"Background","default":""}},"type":"object","title":"ScenarioPersona"},"SimulationToolExecution":{"properties":{"live_read_tools":{"items":{"$ref":"#/components/schemas/SimulationToolName"},"type":"array","maxItems":64,"title":"Live Read Tools","description":"Read tools that run for real. Each must be a tool the service's simulations can call that `GET /services/{service_id}/tools/resolve` reports as `live_read_eligible`, with no entry in `tool_mocks`. Integration endpoints need `Integration:View`; platform functions and data queries need `Workspace:View`; world reads need `Service:Update`, which every launch requires. A case anchored to an external principal (an entity with an active external role assignment) runs its live reads as that principal, so it also needs `Conversation:CreateForPrincipal`."},"tool_mocks":{"additionalProperties":{"$ref":"#/components/schemas/SimulationToolMockValue"},"propertyNames":{"$ref":"#/components/schemas/SimulationToolName"},"type":"object","maxProperties":64,"title":"Tool Mocks","description":"Tool name to the result it returns in place of a call. Each must be a tool the service's simulations can call; a companion skill is mocked through the tools it calls."}},"additionalProperties":false,"type":"object","title":"SimulationToolExecution","description":"Which tools a simulation launch runs for real, and which return a configured result.\n\nEvery other tool is simulated and returns a dry-run placeholder. Writes never run\nfor real. The settings apply to every case, step and fork of the launch, and to a\nre-drive of an interrupted run. Empty, the default, simulates every tool."},"SimulationToolName":{"type":"string","maxLength":128,"minLength":1},"SimulationToolMockValue":{"type":"string","maxLength":16384},"TargetSpec":{"properties":{"desired_states":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"Desired States"},"non_desired_states":{"items":{"$ref":"#/components/schemas/NonDesiredState"},"type":"array","maxItems":50,"title":"Non Desired States"},"ordered_pathways":{"items":{"$ref":"#/components/schemas/OrderedPathway"},"type":"array","maxItems":20,"title":"Ordered Pathways"},"completion_criteria":{"$ref":"#/components/schemas/CompletionCriteria"}},"type":"object","title":"TargetSpec"},"NonDesiredState":{"properties":{"state":{"type":"string","maxLength":128,"title":"State"},"mode":{"type":"string","enum":["hard","soft"],"title":"Mode","default":"hard"}},"type":"object","required":["state"],"title":"NonDesiredState"},"OrderedPathway":{"properties":{"id":{"type":"string","maxLength":64,"title":"Id"},"sequence":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"minItems":1,"title":"Sequence"}},"type":"object","required":["id","sequence"],"title":"OrderedPathway"},"CompletionCriteria":{"properties":{"state_based":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"State Based"},"tool_based":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"Tool Based"}},"type":"object","title":"CompletionCriteria"}}}}
```

## The BriefResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BriefResponse":{"properties":{"event_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Event Id"},"target_entity_id":{"type":"string","format":"uuid","title":"Target Entity Id"},"target_entity_type":{"type":"string","enum":["patient","cohort","workspace","territory","emirate","district"],"title":"Target Entity Type"},"content_md":{"anyOf":[{"type":"string","maxLength":20000},{"type":"null"}],"title":"Content Md"},"content_json":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Content Json"},"version":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Version"},"evidence_event_ids":{"items":{"type":"string","format":"uuid"},"type":"array","maxItems":500,"title":"Evidence Event Ids"},"confidence":{"type":"number","maximum":1,"minimum":0,"title":"Confidence"},"event_count":{"type":"integer","minimum":0,"title":"Event Count"},"model_name":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Model Name"},"truncated":{"type":"boolean","title":"Truncated","default":false},"generated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Generated At"}},"type":"object","required":["event_id","target_entity_id","target_entity_type","content_json","confidence","event_count","generated_at"],"title":"BriefResponse","description":"Wire shape for a Self-Image brief.\n\n``event_id`` is null when no brief has ever been generated for the\nentity. All other fields are nullable in that case so the UI can\nrender a consistent empty state."}}}}
```

## The BriefingRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BriefingRequest":{"properties":{"call_sid":{"type":"string","maxLength":64,"minLength":1,"title":"Call Sid"}},"type":"object","required":["call_sid"],"title":"BriefingRequest","description":"Request for operator briefing on a specific call."}}}}
```

## The BriefingResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BriefingResponse":{"properties":{"call_sid":{"type":"string","title":"Call Sid"},"operator_id":{"type":"string","format":"uuid","title":"Operator Id"},"sections":{"items":{"$ref":"#/components/schemas/BriefingSection"},"type":"array","title":"Sections"},"generated_at":{"type":"string","format":"date-time","title":"Generated At"}},"type":"object","required":["call_sid","operator_id","sections","generated_at"],"title":"BriefingResponse","description":"Structured operator briefing for a call."},"BriefingSection":{"properties":{"title":{"type":"string","title":"Title"},"content":{"type":"string","title":"Content"}},"type":"object","required":["title","content"],"title":"BriefingSection","description":"A named section of the operator briefing."}}}}
```

## The BriefingSection object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"BriefingSection":{"properties":{"title":{"type":"string","title":"Title"},"content":{"type":"string","title":"Content"}},"type":"object","required":["title","content"],"title":"BriefingSection","description":"A named section of the operator briefing."}}}}
```

## The CallDetailResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallDetailResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid"},"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspace Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"direction":{"anyOf":[{"type":"string","enum":["inbound","outbound","playground","simulated","test"]},{"type":"null"}],"title":"Direction"},"status":{"type":"string","title":"Status","default":"completed"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"call_start_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Call Start Time"},"call_end_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Call End Time"},"call_duration_seconds":{"type":"number","title":"Call Duration Seconds","default":0},"media_start_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Media Start Time"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"manifest":{"anyOf":[{"$ref":"#/components/schemas/RunManifest"},{"type":"null"}]},"evidence":{"anyOf":[{"$ref":"#/components/schemas/CallEvidence"},{"type":"null"}]},"config":{"anyOf":[{"$ref":"#/components/schemas/ConversationConfig"},{"type":"null"}]},"turns":{"items":{"$ref":"#/components/schemas/Turn"},"type":"array","title":"Turns","default":[]},"states_visited":{"items":{"type":"string"},"type":"array","title":"States Visited","default":[]},"final_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final State"},"triggered_behaviors":{"items":{"type":"string"},"type":"array","title":"Triggered Behaviors","default":[]},"completion_reason":{"anyOf":[{"type":"string","enum":["completed","silence_hangup","abandoned","escalated","transferred","timeout","error","voicemail","no_answer","caller_hangup","forwarded","terminal_state","warm_transfer_completed","no_inbound_audio","cancelled","closed"]},{"type":"null"}],"title":"Completion Reason"},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ForwardingDetails"},{"type":"null"}]},"conference_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Conference Sid"},"participants":{"items":{"$ref":"#/components/schemas/Participant"},"type":"array","title":"Participants","default":[]},"barge_in_events":{"items":{"$ref":"#/components/schemas/BargeInEvent"},"type":"array","title":"Barge In Events","default":[]},"recording_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recording Path"},"twilio_recording_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Twilio Recording Sid"},"twilio_recording_duration":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Twilio Recording Duration"},"has_recording":{"type":"boolean","title":"Has Recording","default":false},"timeline":{"anyOf":[{"$ref":"#/components/schemas/PlaybackTimeline"},{"type":"null"}]},"call_analysis":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Call Analysis"},"source":{"anyOf":[{"type":"string","enum":["real","simulation","playground"]},{"type":"null"}],"title":"Source"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"score_rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Score Rationale"},"parent_session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Session Id"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index"},"escalation":{"anyOf":[{"$ref":"#/components/schemas/EscalationState"},{"type":"null"}]},"safety":{"anyOf":[{"$ref":"#/components/schemas/SafetyState"},{"type":"null"}]},"human_segments":{"items":{"$ref":"#/components/schemas/HumanSegment"},"type":"array","title":"Human Segments","default":[]},"audit":{"anyOf":[{"$ref":"#/components/schemas/AuditSummary"},{"type":"null"}]},"quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quality Score"},"conversation_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conversation Summary"},"safety_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Safety Summary"}},"type":"object","required":["id"],"title":"CallDetailResponse","description":"Full call detail — the canonical response for GET /calls/{call_id}.\n\nThis is the single source of truth for the call detail shape. The OpenAPI\nspec is generated from this model. The SDK TypeScript types are generated\nfrom the spec. The developer-console consumes SDK types directly."},"RunManifest":{"properties":{"agent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Id"},"agent_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version","description":"The agent version number the session loaded."},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version","description":"The context graph version number the session loaded. Null, with ``context_graph_id``, on a run of a direct\nprogram, which loads no graph."},"program_kind":{"anyOf":[{"type":"string","enum":["workflow","direct"]},{"type":"null"}],"title":"Program Kind","description":"What the session ran: ``workflow``, its service's context graph, or ``direct``, its agent version's own\nprompt and tools. Null on a run recorded before programs and on one whose engine failed to load."},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON of the direct program the session ran: its authored prompt as saved and\nits tool specs. Null on a workflow run, which its graph version identifies."},"version_set":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The service version set the session resolved its versions and models through, e.g. ``release``."},"platform_config_fingerprint":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the agent and graph version ids, the LLM model and, when the service pins dynamic\nbehaviors, each pinned set's id and version: one value per config generation."},"service_config_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON (keys sorted, no whitespace, non-ASCII escaped) of the whole service\nconfig the session received: the service, its agent and graph versions and the behaviors its version set\npins. Any edit to that config moves it, where the fingerprint follows only the versions, the model and the\npins, so two runs that record the same digest received the same config. Null when the session loaded none."},"image_sha":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The build the session ran on: the commit the agent-engine image was built from."},"runtime_release_id":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The runtime release of the pod the session ran on."},"llm_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that wrote the agent's replies: the engage model, or the realtime model on gpt_realtime."},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature","description":"The sampling temperature the reply requests set. Null where they set none and the model's own\ndefault applies: every voice call, and a text run on a model family that takes none. On a\nreasoning model it rides only the requests that carry tools."},"engage_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates the reply prompt renders from. Null on gpt_realtime, whose\ninstructions aren't rendered from them."},"rendered_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"SHA256 of the opening rendered instructions, without normalization."},"prompt_renderer":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Renderer that produced the recorded instructions."},"prompt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Model identifier submitted with these instructions; aliases are not resolved snapshots."},"navigation_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that chose each context-graph transition. Null on gpt_realtime, which doesn't navigate."},"navigation_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates each navigation decision renders from. Null on gpt_realtime."},"dynamic_behavior_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the template and fixed text each dynamic behavior decision renders from. Null on\ngpt_realtime, which runs no dynamic behavior, and when the service pins no enabled one."},"decider_kind":{"anyOf":[{"$ref":"#/components/schemas/DeciderKind"},{"type":"null"}],"description":"How the session's region decides: ``decisions``, OpenAI Decisions through the region's gateway.\nNavigation and the reply checks both decide through it."},"stt_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The speech-to-text vendor the call ran on: the one it opened with, or the one it failed over\nto. Null on a text run."},"stt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The vendor that voiced the call's replies. Null on a text run."},"tts_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_language":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The language the call's voice spoke: the one it opened in, or the caller's language once an\nin-house call switched to it. ``multilingual`` on a gpt_realtime call left to answer in the\ncaller's language. Null on a text run."},"emergency_floor_enforced":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Emergency Floor Enforced","description":"Whether the medical-emergency floor acted on what it caught, rather than only counting it."},"effect_shadow":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Effect Shadow","description":"Whether an in-house call also recorded each turn as effects, in shadow. Null off in-house voice."},"cooperative_stop":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cooperative Stop","description":"Whether an in-house call's teardown let its session stop on its own before cancelling it.\nNull off in-house voice."}},"type":"object","title":"RunManifest","description":"The configuration a run executed with: as its session started, and as it stood after\nany change the run made mid-way.\n\nA field is null when the session had nothing to record for it: a text run has no\nspeech models, and a gpt_realtime call whose engine failed to load has no agent or\ngraph version. Nothing here is read back from the service's current configuration."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DeciderKind":{"type":"string","const":"decisions"},"CallEvidence":{"properties":{"state_path":{"items":{"$ref":"#/components/schemas/StateVisit"},"type":"array","maxItems":200,"title":"State Path"},"authored_lines":{"items":{"$ref":"#/components/schemas/AuthoredLine"},"type":"array","maxItems":200,"title":"Authored Lines"},"tool_calls":{"items":{"$ref":"#/components/schemas/ToolOutcome"},"type":"array","maxItems":200,"title":"Tool Calls"},"safe_exits":{"items":{"$ref":"#/components/schemas/platform_lib__calls__evidence__CallEvidence__SafeExit"},"type":"array","maxItems":200,"title":"Safe Exits"},"truncated":{"type":"boolean","title":"Truncated","default":false},"invalid_entries":{"type":"integer","title":"Invalid Entries","default":0}},"type":"object","title":"CallEvidence","description":"Recorded facts only. Empty lists mean no evidence, not proof an action never occurred.\n\nEach list retains its first 200 records in journal order. Timestamps are the\nrecorded event times, not ingestion times. No tool arguments or results are copied."},"StateVisit":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"previous_state":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Previous State"},"state":{"type":"string","maxLength":512,"title":"State"}},"type":"object","required":["state"],"title":"StateVisit"},"AuthoredLine":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"kind":{"type":"string","enum":["disclosure","emergency","crisis","correction","safe_exit","authored"],"title":"Kind"},"text":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Text"},"text_truncated":{"type":"boolean","title":"Text Truncated","default":false},"completed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Completed"},"verbatim":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Verbatim"}},"type":"object","required":["kind"],"title":"AuthoredLine"},"ToolOutcome":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"name":{"type":"string","maxLength":512,"title":"Name"},"call_id":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Call Id"},"outcome":{"type":"string","enum":["succeeded","failed","not_executed","unknown"],"title":"Outcome"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["name","outcome"],"title":"ToolOutcome"},"platform_lib__calls__evidence__CallEvidence__SafeExit":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger"},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome"},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"Whether the disclosure completed before or during the exit."},"transfer_attempted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Transfer Attempted"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"}},"type":"object","required":["trigger","outcome","disclosure_heard"],"title":"SafeExit"},"ConversationConfig":{"properties":{"agent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Id"},"agent_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version"},"agent_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Name"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version"},"initial_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Initial State"},"gpt_audio_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gpt Audio Model"},"navigation_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Navigation Model"}},"type":"object","title":"ConversationConfig"},"Turn":{"properties":{"evidence":{"anyOf":[{"$ref":"#/components/schemas/TurnEvidence"},{"type":"null"}]},"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string"},{"type":"null"}],"title":"Id"},"engine_turn_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Engine Turn Id","description":"The engine turn whose trigger, state and timing this row carries: the turn its agent line\nanswers, or on a caller line nothing answered, the turn it opens. An agent line that names no\nturn (a filler, the emergency floor's script, a correction) takes the turn the call was in:\nthe caller turn whose words came last, or the turn of the last reply. Null on rows recorded\nbefore the id was stored, on calls no engine turn ran, and once the call's hot rows have\nexpired, about a day after it, when these rows are rebuilt from the saved transcript."},"trigger":{"type":"string","title":"Trigger","default":""},"user_transcript":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Transcript"},"agent_transcript":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Transcript"},"agent_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Action"},"interrupted":{"type":"boolean","title":"Interrupted","default":false},"incomplete":{"type":"boolean","title":"Incomplete","description":"The call ended while the caller was still saying ``user_transcript``, so nothing answered it.","default":false},"filler_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Type"},"speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Speaker Id"},"speaker_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Speaker Role"},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eot Confidence"},"state":{"type":"string","title":"State","default":""},"tool_calls":{"items":{"$ref":"#/components/schemas/ToolCall"},"type":"array","title":"Tool Calls","default":[]},"state_transitions":{"items":{"$ref":"#/components/schemas/StateTransition"},"type":"array","title":"State Transitions","default":[]},"inner_thoughts":{"items":{"type":"string"},"type":"array","title":"Inner Thoughts","default":[]},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"user_speech_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"User Speech Start Ms"},"user_speech_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"User Speech End Ms"},"agent_speech_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Speech Start Ms"},"agent_speech_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Speech End Ms"},"audio_window_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window Start Ms"},"audio_window_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window End Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Render Ms"},"audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Ttfb Ms"},"signal_kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signal Kind"},"signal_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signal Source"},"state_before":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Before"},"state_after":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State After"},"primary_effect_kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Effect Kind"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"tool_succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tool Succeeded"},"tool_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Tool Ms"},"modality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Modality"},"empathy_tier":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Tier"},"decision_bearing":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Decision Bearing"},"packet_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Packet Id","description":"The signal-engine packet the turn answers. Null when none was cut for it."},"dynamic_behavior":{"anyOf":[{"$ref":"#/components/schemas/AppliedBehavior"},{"type":"null"}],"description":"The dynamic behavior the agent line was rendered with. Null when none was in force."},"dynamic_behavior_decision":{"anyOf":[{"$ref":"#/components/schemas/BehaviorDecision"},{"type":"null"}],"description":"What the caller turn's dynamic behavior decision did. Null when none ran."}},"type":"object","title":"Turn"},"TurnEvidence":{"properties":{"authored_kind":{"anyOf":[{"type":"string","enum":["disclosure","emergency","crisis","correction","safe_exit","authored"]},{"type":"null"}],"title":"Authored Kind"},"completed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Completed"},"verbatim":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Verbatim"},"safe_exit":{"anyOf":[{"$ref":"#/components/schemas/SafeExitEvidence"},{"type":"null"}]}},"type":"object","title":"TurnEvidence","description":"Playback provenance supplied by the runtime, never guessed from transcript words."},"SafeExitEvidence":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger"},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome"},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"Whether the disclosure completed before or during the exit."},"transfer_attempted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Transfer Attempted"}},"type":"object","required":["trigger","outcome","disclosure_heard"],"title":"SafeExitEvidence"},"ToolCall":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"input":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input"},"output":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output"},"output_truncated":{"type":"boolean","title":"Output Truncated","default":false},"output_original_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Output Original Length"},"output_truncated_to":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Output Truncated To"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"executed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Executed"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"}},"type":"object","required":["tool_name"],"title":"ToolCall"},"StateTransition":{"properties":{"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"},"previous_state":{"type":"string","title":"Previous State","default":""},"next_state":{"type":"string","title":"Next State","default":""},"annotation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Annotation"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"from_state":{"type":"string","title":"From State","readOnly":true},"to_state":{"type":"string","title":"To State","readOnly":true}},"type":"object","required":["from_state","to_state"],"title":"StateTransition"},"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"BehaviorDecision":{"description":"What one caller turn's dynamic behavior decision did.\n\n``outcome``: ``applied`` put the chosen behavior in force; ``kept`` left the active one in force because\nthe model chose it again or said it stays; ``held`` left the active one in force because it was still\ninside its ``sticky_turns`` and the model chose none, chose another behavior under the confidence floor,\nor gave no usable answer (a different behavior chosen at or over the floor replaces it as ``applied``,\ninside its ``sticky_turns`` too); ``none``, ``below_floor`` and ``failed`` left nothing in force (no\nbehavior applies, a choice under the confidence floor, no usable answer); ``skipped`` ran no decision\n(``reason`` says why) and ended the active behavior; ``superseded`` was cancelled by the caller's next\nturn before it landed.","properties":{"outcome":{"$ref":"#/components/schemas/DynamicBehaviorOutcome"},"reason":{"anyOf":[{"$ref":"#/components/schemas/FailureReason"},{"$ref":"#/components/schemas/DynamicBehaviorSkip"},{"type":"null"}],"default":null,"description":"Why a decision failed or was skipped, or why a held behavior was held.","title":"Reason"},"behavior_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior in force after the decision.","title":"Behavior Id"},"behavior_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior in force. Null where none is, and before behaviors were versioned.","title":"Behavior Version"},"chosen_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior the model chose. Null when it chose none or gave no usable answer.","title":"Chosen Id"},"chosen_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior the model chose. Null where it chose none, and before behaviors were versioned.","title":"Chosen Version"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The choice's confidence. Null where the decision got no usable answer.","title":"Confidence"},"kept_by_predicate":{"default":false,"description":"Whether the active behavior stayed because the model said it stays, rather than by its choice.","title":"Kept By Predicate","type":"boolean"},"keep_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The confidence of the answer to whether the active behavior stays, when that was asked.","title":"Keep Confidence"},"candidate_count":{"default":0,"description":"How many behaviors the decision chose between, ``none`` aside.","title":"Candidate Count","type":"integer"},"latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Latency Ms"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"description":"The context graph version the conversation ran when the decision was made. Null on a direct program's\ndecision, which ran no context graph: ``program_digest`` names what it ran.","title":"Context Graph Version"},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"The direct program the conversation ran when the decision was made, by the digest its run records\n(``RunManifest.program_digest``). Null on a context graph's decision."},"selector_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"What a direct program's decision rendered its request from. Null on a context graph's decision, whose run\nrecords it (``RunManifest.dynamic_behavior_prompt_template_hash``)."},"cited_message_indexes":{"default":[],"description":"The messages the decision read the turn from: the agent's line before the turn, then the caller's.","items":{"type":"integer"},"title":"Cited Message Indexes","type":"array"}},"required":["outcome"],"title":"BehaviorDecision","type":"object"},"DynamicBehaviorOutcome":{"enum":["applied","kept","held","none","below_floor","failed","skipped","superseded"],"type":"string"},"FailureReason":{"enum":["refusal","out_of_set","malformed","http_4xx","http_retryable","connection","timeout","breaker_open","options_exceeded"],"type":"string"},"DynamicBehaviorSkip":{"enum":["emergency_floor","person_request","empathy_hold","suspended","no_candidates"],"type":"string"},"ForwardingDetails":{"properties":{"forward_to":{"type":"string","title":"Forward To"},"warm_transfer":{"type":"boolean","title":"Warm Transfer"},"forwarded_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Forwarded At"},"after_hours":{"type":"boolean","title":"After Hours","description":"The service's staffed hours sent this transfer to its after-hours line, whichever line was asked for.","default":false},"destination_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Destination Label","description":"The service's label for the line this transfer dialed, or ``forward_to`` for a static service's own line."},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"The key of the service's ``transfer_reasons`` the agent named for this transfer, None for a service that lists\nnone or a transfer the agent didn't make."}},"type":"object","required":["forward_to","warm_transfer"],"title":"ForwardingDetails"},"Participant":{"properties":{"participant_id":{"type":"string","title":"Participant Id"},"role":{"type":"string","enum":["caller","agent","operator"],"title":"Role"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"joined_at":{"type":"string","format":"date-time","title":"Joined At"},"left_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Left At"}},"type":"object","required":["participant_id","role","joined_at"],"title":"Participant"},"BargeInEvent":{"properties":{"type":{"const":"barge_in","default":"barge_in","title":"Type","type":"string"},"interrupted_text":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupted Text"},"discarded_texts":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"default":null,"title":"Discarded Texts"},"interrupted_speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupted Speaker Id"},"interrupting_speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupting Speaker Id"},"total_barge_ins":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Total Barge Ins"}},"title":"BargeInEvent","type":"object"},"PlaybackTimeline":{"properties":{"turns":{"items":{"$ref":"#/components/schemas/TurnTimeline"},"type":"array","title":"Turns"},"segments":{"items":{"$ref":"#/components/schemas/TimelineSegment"},"type":"array","title":"Segments"},"duration_seconds":{"type":"number","title":"Duration Seconds"},"timebase":{"anyOf":[{"$ref":"#/components/schemas/TimelineTimebase"},{"type":"null"}],"description":"Canonical timebase shared by waveform, overlays, seek state, zoom, and scroll transforms."},"lanes":{"items":{"$ref":"#/components/schemas/TimelineLaneDefinition"},"type":"array","title":"Lanes","description":"Canonical actor/system lane model. Every segment lane_id resolves against this collection.","default":[]},"total_user_speech_seconds":{"type":"number","title":"Total User Speech Seconds","default":0},"total_agent_speech_seconds":{"type":"number","title":"Total Agent Speech Seconds","default":0},"total_silence_seconds":{"type":"number","title":"Total Silence Seconds","default":0},"avg_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Processing Gap Ms"},"max_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Max Processing Gap Ms"},"avg_perceived_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Perceived Latency Ms"}},"type":"object","required":["turns","segments","duration_seconds"],"title":"PlaybackTimeline"},"TurnTimeline":{"properties":{"turn_index":{"type":"integer","title":"Turn Index","description":"The turn: its index in the response's ``turns`` on ``GET /conversations/{conversation_id}``,\nthe call-detail row the timeline was built from on ``GET /calls/{call_id}``."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on a turn\nbefore the first exchange."},"seek_to":{"type":"number","title":"Seek To"},"active_start":{"type":"number","title":"Active Start"},"active_end":{"type":"number","title":"Active End"}},"type":"object","required":["turn_index","seek_to","active_start","active_end"],"title":"TurnTimeline"},"TimelineSegment":{"properties":{"type":{"type":"string","enum":["agent_speech","barge_in","caller_speech","filler","filler_hesitation","filler_nav","greeting","interrupted_speech","processing_gap","silence","silence_check","state_transition","tool_call"],"title":"Type"},"lane":{"type":"string","enum":["agent","caller","events","operator","system","tool"],"title":"Lane"},"track":{"anyOf":[{"type":"string","enum":["agent","caller","operator","system","tool"]},{"type":"null"}],"title":"Track","description":"Actor-semantic display track for the segment. Inferred for legacy producers."},"lane_id":{"anyOf":[{"type":"string","maxLength":160,"minLength":1},{"type":"null"}],"title":"Lane Id","description":"Canonical lane id. Must match PlaybackTimeline.lanes[].id after platform normalization."},"order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Order","description":"Canonical event order after platform time/lane normalization."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor responsible for the segment. Inferred for legacy producers."},"start":{"type":"number","title":"Start"},"end":{"type":"number","title":"End"},"label":{"type":"string","title":"Label"},"turn_index":{"type":"integer","title":"Turn Index","description":"The segment's turn: its index in the response's ``turns`` on\n``GET /conversations/{conversation_id}``, the call-detail row the timeline was built from on\n``GET /calls/{call_id}``, or -1 when no turn owns it (a silence, a barge-in)."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the segment's turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on segments no\nexchange owns."},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eot Confidence"},"audio_window_start":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window Start"},"audio_window_end":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window End"},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Render Ms"},"audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Ttfb Ms"},"e2e_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"E2E Ttfb Ms"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"parent_call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Call Id"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"from_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From State"},"to_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"To State"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"}},"type":"object","required":["type","lane","start","end","label","turn_index"],"title":"TimelineSegment"},"TimelineActor":{"properties":{"kind":{"type":"string","enum":["agent","human","operator","system","tool"],"title":"Kind"},"role":{"type":"string","enum":["agent","caller","operator","runtime","state","tool"],"title":"Role"},"label":{"type":"string","title":"Label"},"participant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Id"}},"type":"object","required":["kind","role","label"],"title":"TimelineActor"},"TimelineTimebase":{"properties":{"unit":{"type":"string","const":"seconds","title":"Unit","description":"Timeline offsets are always seconds.","default":"seconds"},"origin":{"type":"string","enum":["media_start","call_start","synthetic"],"title":"Origin","description":"Zero point used for segment start/end offsets.","default":"media_start"},"start":{"type":"number","title":"Start","description":"Visible/canonical timeline range start in seconds.","default":0},"end":{"type":"number","title":"End","description":"Visible/canonical timeline range end in seconds.","default":0}},"type":"object","title":"TimelineTimebase"},"TimelineLaneDefinition":{"properties":{"id":{"type":"string","maxLength":160,"minLength":1,"title":"Id","description":"Stable canonical lane id used by timeline visualizations. Segments attach via TimelineSegment.lane_id; consumers should not re-infer lanes from CSS or pixel positions."},"track":{"type":"string","enum":["agent","caller","operator","system","tool"],"title":"Track","description":"High-level actor-semantic track for styling and grouping."},"label":{"type":"string","title":"Label","description":"Display label for the lane."},"order":{"type":"integer","title":"Order","description":"Stable vertical order within the timeline lane model."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor represented by this lane when applicable."}},"type":"object","required":["id","track","label","order"],"title":"TimelineLaneDefinition"},"EscalationState":{"properties":{"status":{"type":"string","title":"Status","default":"none"},"escalation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Escalation Id"},"requested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"Requested At"},"connected_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"Connected At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"Completed At"},"trigger":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger"},"trigger_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger Source"},"concept":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Concept"},"similarity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Similarity"},"agent_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Confidence"},"operator_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Operator Type"},"regulatory_basis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Regulatory Basis"},"immediate":{"type":"boolean","title":"Immediate","default":false},"risk_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Risk Score"},"operator_entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Operator Entity Id"},"wait_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Wait Seconds"},"handle_time_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Handle Time Seconds"},"human_segment_turn_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Human Segment Turn Count"}},"type":"object","title":"EscalationState"},"SafetyState":{"properties":{"peak_concern_level":{"type":"integer","title":"Peak Concern Level","default":0},"concern_turn_count":{"type":"integer","title":"Concern Turn Count","default":0},"trajectory":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trajectory"},"triage_history":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Triage History","default":[]},"concept_matches":{"items":{"$ref":"#/components/schemas/ConceptMatch"},"type":"array","title":"Concept Matches","default":[]}},"type":"object","title":"SafetyState"},"ConceptMatch":{"properties":{"concept":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Concept"},"similarity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Similarity"},"agent_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Action"},"agent_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Confidence"},"agent_reasoning":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Reasoning"},"at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"At"}},"type":"object","title":"ConceptMatch"},"HumanSegment":{"properties":{"speaker_role":{"type":"string","title":"Speaker Role"},"transcript":{"type":"string","title":"Transcript"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"}},"type":"object","required":["speaker_role","transcript"],"title":"HumanSegment"},"AuditSummary":{"properties":{"event_count":{"type":"integer","title":"Event Count","default":0},"latest_event":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Latest Event"}},"type":"object","title":"AuditSummary"}}}}
```

## The CallEvalResult object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallEvalResult":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"title":"Expected"},"actual":{"title":"Actual"},"rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Justification"},"cited_turns":{"items":{},"type":"array","title":"Cited Turns"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["workspace_id","conversation_id","eval_key","eval_type","status"],"title":"CallEvalResult","description":"One eval verdict for one production call, keyed by ``conversation_id``.\nMirrors the sim eval-result shape. ``justification`` and ``cited_turns`` come\nfrom the justified ai_query metric compute. PHI: ``justification`` / ``actual``\ncan echo live transcript content; never log them."}}}}
```

## The CallEvalResultsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallEvalResultsResponse":{"properties":{"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id"},"results":{"items":{"$ref":"#/components/schemas/CallEvalResult"},"type":"array","title":"Results"}},"type":"object","required":["conversation_id","results"],"title":"CallEvalResultsResponse"},"CallEvalResult":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"title":"Expected"},"actual":{"title":"Actual"},"rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Justification"},"cited_turns":{"items":{},"type":"array","title":"Cited Turns"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["workspace_id","conversation_id","eval_key","eval_type","status"],"title":"CallEvalResult","description":"One eval verdict for one production call, keyed by ``conversation_id``.\nMirrors the sim eval-result shape. ``justification`` and ``cited_turns`` come\nfrom the justified ai_query metric compute. PHI: ``justification`` / ``actual``\ncan echo live transcript content; never log them."}}}}
```

## The CallEvidence object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallEvidence":{"properties":{"state_path":{"items":{"$ref":"#/components/schemas/StateVisit"},"type":"array","maxItems":200,"title":"State Path"},"authored_lines":{"items":{"$ref":"#/components/schemas/AuthoredLine"},"type":"array","maxItems":200,"title":"Authored Lines"},"tool_calls":{"items":{"$ref":"#/components/schemas/ToolOutcome"},"type":"array","maxItems":200,"title":"Tool Calls"},"safe_exits":{"items":{"$ref":"#/components/schemas/platform_lib__calls__evidence__CallEvidence__SafeExit"},"type":"array","maxItems":200,"title":"Safe Exits"},"truncated":{"type":"boolean","title":"Truncated","default":false},"invalid_entries":{"type":"integer","title":"Invalid Entries","default":0}},"type":"object","title":"CallEvidence","description":"Recorded facts only. Empty lists mean no evidence, not proof an action never occurred.\n\nEach list retains its first 200 records in journal order. Timestamps are the\nrecorded event times, not ingestion times. No tool arguments or results are copied."},"StateVisit":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"previous_state":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Previous State"},"state":{"type":"string","maxLength":512,"title":"State"}},"type":"object","required":["state"],"title":"StateVisit"},"AuthoredLine":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"kind":{"type":"string","enum":["disclosure","emergency","crisis","correction","safe_exit","authored"],"title":"Kind"},"text":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Text"},"text_truncated":{"type":"boolean","title":"Text Truncated","default":false},"completed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Completed"},"verbatim":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Verbatim"}},"type":"object","required":["kind"],"title":"AuthoredLine"},"ToolOutcome":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"name":{"type":"string","maxLength":512,"title":"Name"},"call_id":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Call Id"},"outcome":{"type":"string","enum":["succeeded","failed","not_executed","unknown"],"title":"Outcome"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["name","outcome"],"title":"ToolOutcome"},"platform_lib__calls__evidence__CallEvidence__SafeExit":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger"},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome"},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"Whether the disclosure completed before or during the exit."},"transfer_attempted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Transfer Attempted"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"}},"type":"object","required":["trigger","outcome","disclosure_heard"],"title":"SafeExit"}}}}
```

## The CallIntelligenceDetail object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallIntelligenceDetail":{"properties":{"call_id":{"type":"string","title":"Call Id","description":"World entity ID for the call"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"direction":{"type":"string","enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","description":"Call direction","default":"inbound"},"duration_seconds":{"type":"number","title":"Duration Seconds","description":"Call duration in seconds","default":0},"quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quality Score","description":"Quality score 0.0 to 1.0"},"quality_breakdown":{"anyOf":[{"$ref":"#/components/schemas/QualityBreakdown"},{"type":"null"}],"description":"Detailed quality breakdown"},"key_moments":{"items":{"$ref":"#/components/schemas/KeyMoment"},"type":"array","title":"Key Moments","description":"Notable call events"},"risk_summary":{"anyOf":[{"$ref":"#/components/schemas/RiskSummary"},{"type":"null"}],"description":"Risk assessment"},"latency_summary":{"anyOf":[{"$ref":"#/components/schemas/LatencySummary"},{"type":"null"}],"description":"Audio latency metrics"},"conversation_summary":{"anyOf":[{"$ref":"#/components/schemas/ConversationSummary"},{"type":"null"}],"description":"Conversation flow metrics"},"tool_summary":{"anyOf":[{"$ref":"#/components/schemas/ToolSummary"},{"type":"null"}],"description":"Tool usage statistics"},"safety_summary":{"anyOf":[{"$ref":"#/components/schemas/SafetySummary"},{"type":"null"}],"description":"Safety filter results"},"operator_summary":{"anyOf":[{"$ref":"#/components/schemas/OperatorIntelligenceSummary"},{"type":"null"}],"description":"Operator intervention"},"completion_reason":{"anyOf":[{"type":"string","enum":["completed","silence_hangup","abandoned","escalated","transferred","timeout","error","voicemail","no_answer","caller_hangup","forwarded","terminal_state","warm_transfer_completed","no_inbound_audio","cancelled","closed"]},{"type":"null"}],"title":"Completion Reason","description":"Why the call ended"},"final_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final State","description":"Final conversation state name"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When intelligence was computed"}},"type":"object","required":["call_id"],"title":"CallIntelligenceDetail","description":"Layer 4 (Narrative) intelligence for a completed call.\n\nAggregated summaries, quality breakdown, and key moments — the\ninterpretive layer. Per-turn visualization data lives on the unified\ntimeline (call detail → PlaybackTimeline.segments), not here."},"QualityBreakdown":{"properties":{"score":{"type":"number","title":"Score"},"components":{"items":{"$ref":"#/components/schemas/QualityComponent"},"type":"array","title":"Components"},"workspace_avg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Workspace Avg"},"workspace_percentile":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Workspace Percentile"}},"type":"object","required":["score","components"],"title":"QualityBreakdown","description":"Structured breakdown of how quality score was computed."},"QualityComponent":{"properties":{"name":{"type":"string","enum":["latency","silence","barge_ins","loops","escalation","tool_failures"],"title":"Name","description":"Quality dimension"},"penalty":{"type":"number","title":"Penalty","description":"Penalty subtracted from the score"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"Raw measured value"},"threshold":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Threshold","description":"Threshold that was exceeded"},"severity":{"type":"string","enum":["none","minor","major","critical"],"title":"Severity","description":"Severity of the penalty","default":"none"}},"type":"object","required":["name","penalty"],"title":"QualityComponent","description":"Single quality score component with penalty and context."},"KeyMoment":{"properties":{"turn":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turn","description":"Turn index where the moment occurred"},"type":{"type":"string","enum":["latency_spike","silence","barge_in","loop","tool_failure","escalation","safety_flag","high_risk","elevated_risk"],"title":"Type","description":"Category of the moment"},"severity":{"type":"string","enum":["info","warning","error"],"title":"Severity","description":"Severity level","default":"warning"},"description":{"type":"string","title":"Description","description":"Human-readable description"}},"type":"object","required":["type","description"],"title":"KeyMoment","description":"Notable event during the call worth highlighting."},"RiskSummary":{"properties":{"composite_score":{"type":"number","title":"Composite Score","description":"Overall risk score 0.0 to 1.0","default":0},"level":{"type":"string","enum":["low","medium","high","critical"],"title":"Level","description":"Risk level","default":"low"}},"type":"object","title":"RiskSummary","description":"Aggregated risk signals across the call.\n\nFree-form residual on the raw ``risk_summary`` JSONB:\n``signals: list[{name, raw_score, weight, weighted_score, detail}]``\n— the per-signal breakdown that aggregates into ``composite_score``.\nNot exposed via this typed shape; consumers needing per-signal\ndetail read the JSONB endpoint."},"LatencySummary":{"properties":{"avg_engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Engine Ms","description":"Average reasoning-engine latency (ms)"},"p50_engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Engine Ms","description":"Median engine latency (ms)"},"p95_engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Engine Ms","description":"95th percentile engine latency (ms)"},"avg_audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Audio Ttfb Ms","description":"Average audio time-to-first-byte (ms)"},"p50_audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Audio Ttfb Ms","description":"Median audio TTFB (ms)"},"p95_audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Audio Ttfb Ms","description":"95th percentile audio TTFB (ms)"},"avg_nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Nav Ms","description":"Average navigation latency (ms)"},"avg_render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Render Ms","description":"Average render latency (ms)"},"turn_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turn Count","description":"Number of turns the latency averages were computed over"},"silence_ratio":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Silence Ratio","description":"Fraction of a voice call in which nobody spoke. Null when it wasn't measured."}},"type":"object","title":"LatencySummary","description":"Audio + engine latency metrics (one entry per turn averaged)."},"ConversationSummary":{"properties":{"turn_count":{"type":"integer","title":"Turn Count","description":"Total turn count for the call","default":0},"states_visited_count":{"type":"integer","title":"States Visited Count","description":"Number of states visited (including repeats)","default":0},"unique_states":{"type":"integer","title":"Unique States","description":"Number of distinct states visited","default":0},"loop_count":{"type":"integer","title":"Loop Count","description":"Number of detected state loops","default":0},"barge_in_count":{"type":"integer","title":"Barge In Count","description":"Number of caller interruptions","default":0}},"type":"object","title":"ConversationSummary","description":"Conversation flow metrics.\n\nFree-form residual on the raw ``conversation_summary`` JSONB:\n``text_intelligence: dict`` (text-channel intelligence\nsub-payload), and on the simulation path ``score``,\n``score_rationale``, ``terminal_reached``, ``states_visited``.\nOlder simulation rows also carry ``transcript_text: str`` (PHI)\nand ``tool_calls: list``. Not exposed via this typed shape."},"ToolSummary":{"properties":{"total_calls":{"type":"integer","title":"Total Calls","description":"Total tool invocations","default":0},"succeeded":{"type":"integer","title":"Succeeded","description":"Successful tool invocations","default":0},"failed":{"type":"integer","title":"Failed","description":"Failed tool invocations","default":0},"failure_rate":{"type":"number","title":"Failure Rate","description":"Tool failure rate 0.0 to 1.0","default":0}},"type":"object","title":"ToolSummary","description":"Tool usage statistics.\n\nFree-form residual on the raw ``tool_summary`` JSONB:\n``by_tool: list[{name, calls, succeeded, failed, avg_duration_ms}]``\n— per-tool breakdown. Not exposed via this typed shape."},"SafetySummary":{"properties":{"match_count":{"type":"integer","title":"Match Count","description":"Number of safety filter matches","default":0}},"type":"object","title":"SafetySummary","description":"Safety filter results.\n\nFree-form residual on the raw ``safety_summary`` JSONB:\n``actions: dict | list`` — escalation handler actions taken\nwhen ``match_count > 0``. Not exposed via this typed shape."},"OperatorIntelligenceSummary":{"properties":{"escalated":{"type":"boolean","title":"Escalated","description":"Whether the call was escalated to a human operator","default":false},"operator_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Operator Active","description":"Whether an operator was active during escalation. True = active; False = escalation occurred but no operator picked up; None = no escalation occurred (do NOT coerce to False)."}},"type":"object","title":"OperatorIntelligenceSummary","description":"Operator intervention summary.\n\nThree-valued semantics on ``operator_active``:\n- ``True``  — escalation occurred and an operator was active.\n- ``False`` — escalation occurred but no operator picked up.\n- ``None``  — no escalation occurred (producer omits the key).\n  Readers must distinguish; do not coerce ``None`` → ``False``."}}}}
```

## The CallIntelligenceMetricProjectionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallIntelligenceMetricProjectionRequest":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"call_sid":{"type":"string","maxLength":128,"minLength":1,"title":"Call Sid"},"service_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Service Id"},"direction":{"type":"string","enum":["inbound","outbound","playground","simulated","test"],"title":"Direction"},"duration_seconds":{"type":"number","minimum":0,"title":"Duration Seconds"},"quality_score":{"type":"number","maximum":100,"minimum":0,"title":"Quality Score"},"completion_reason":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Completion Reason"},"final_state":{"type":"string","maxLength":256,"title":"Final State","default":""},"ended_by":{"anyOf":[{"type":"string","enum":["caller","agent","system"]},{"type":"null"}],"title":"Ended By"},"ended_after_seconds":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}],"title":"Ended After Seconds"},"first_agent_audio_seconds":{"anyOf":[{"type":"number","minimum":0},{"type":"null"}],"title":"First Agent Audio Seconds"},"source":{"type":"string","enum":["real","simulation","playground"],"title":"Source"},"channel_kind":{"type":"string","maxLength":32,"minLength":1,"title":"Channel Kind","default":"voice"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"call_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Call Id"},"run_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"risk_summary":{"additionalProperties":true,"type":"object","title":"Risk Summary"},"latency_summary":{"additionalProperties":true,"type":"object","title":"Latency Summary"},"conversation_summary":{"additionalProperties":true,"type":"object","title":"Conversation Summary"},"tool_summary":{"additionalProperties":true,"type":"object","title":"Tool Summary"},"safety_summary":{"additionalProperties":true,"type":"object","title":"Safety Summary"},"operator_summary":{"additionalProperties":true,"type":"object","title":"Operator Summary"},"transfer_summary":{"additionalProperties":true,"type":"object","title":"Transfer Summary"},"simulation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Simulation"}},"additionalProperties":false,"type":"object","required":["workspace_id","call_sid","direction","duration_seconds","quality_score","source","created_at"],"title":"CallIntelligenceMetricProjectionRequest","description":"Internal projection request for the shared terminal artifact."}}}}
```

## The CallListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/CallSummary"},"type":"array","title":"Items"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Continuation Token"}},"type":"object","required":["items","total","has_more"],"title":"CallListResponse"},"CallSummary":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id","description":"World entity ID for this call"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"direction":{"anyOf":[{"type":"string","enum":["inbound","outbound","playground","simulated","test"]},{"type":"null"}],"title":"Direction","description":"Call direction"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number","description":"Service phone number"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id","description":"Caller phone number"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When the call started"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Call duration in seconds"},"status":{"anyOf":[{"type":"string","enum":["initiated","ringing","in-progress","completed","busy","no-answer","canceled","failed","unknown"]},{"type":"null"}],"title":"Status","description":"Call status"},"escalation_status":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Escalation Status","description":"Escalation state if any"},"turns":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turns","description":"Number of conversation turns"},"has_recording":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Recording","description":"Whether a recording is available"},"quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quality Score","description":"Quality score 0.0 to 1.0"},"final_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final State","description":"Final conversation state"},"completion_reason":{"anyOf":[{"type":"string","enum":["completed","silence_hangup","abandoned","escalated","transferred","timeout","error","voicemail","no_answer","caller_hangup","forwarded","terminal_state","warm_transfer_completed","no_inbound_audio","cancelled","closed"]},{"type":"null"}],"title":"Completion Reason","description":"Why the call ended"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service ID that handled the call"},"source":{"anyOf":[{"type":"string","enum":["real","simulation","playground"]},{"type":"null"}],"title":"Source","description":"Call source — real, simulation, or playground"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id","description":"Simulation run ID (simulation calls only)"},"parent_session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Session Id","description":"Parent session for forked simulations"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index","description":"Turn index where simulation forked"}},"type":"object","required":["entity_id"],"title":"CallSummary"}}}}
```

## The CallQualityAnalyticsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallQualityAnalyticsResponse":{"properties":{"summary":{"$ref":"#/components/schemas/CallQualitySummary","description":"Aggregate call-quality metrics for the period"},"trend":{"items":{"$ref":"#/components/schemas/CallQualityTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"Time series of call-quality metrics per interval bucket"},"quality_distribution":{"$ref":"#/components/schemas/CallQualityDistribution","description":"Call counts bucketed by quality-score band"}},"type":"object","required":["summary","trend","quality_distribution"],"title":"CallQualityAnalyticsResponse","description":"Call quality score trends, distribution, and summary over time."},"CallQualitySummary":{"properties":{"avg_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality Score","description":"Mean quality score across calls (0-100)"},"p50_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality Score","description":"Median quality score (0-100)"},"p95_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Quality Score","description":"95th-percentile quality score (0-100)"},"total_calls":{"type":"integer","title":"Total Calls","description":"Total number of calls in the period"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Fraction of calls escalated to an operator (0.0-1.0)"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Average call duration in seconds"}},"type":"object","required":["total_calls","escalation_rate"],"title":"CallQualitySummary","description":"Aggregate call-quality stats for the period."},"CallQualityTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Time bucket as an ISO-8601 timestamp string (granularity follows `interval`)"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Average quality score in this bucket (0-100)"},"call_count":{"type":"integer","title":"Call Count","description":"Number of calls in this bucket"},"escalation_count":{"type":"integer","title":"Escalation Count","description":"Number of escalated calls in this bucket"}},"type":"object","required":["date","call_count","escalation_count"],"title":"CallQualityTrendPoint","description":"Single time-bucket data point in the call-quality trend series."},"CallQualityDistribution":{"properties":{"excellent_90_100":{"type":"integer","title":"Excellent 90 100","description":"Calls with quality score 90-100"},"good_70_89":{"type":"integer","title":"Good 70 89","description":"Calls with quality score 70-89"},"fair_50_69":{"type":"integer","title":"Fair 50 69","description":"Calls with quality score 50-69"},"poor_0_49":{"type":"integer","title":"Poor 0 49","description":"Calls with quality score 0-49"}},"type":"object","required":["excellent_90_100","good_70_89","fair_50_69","poor_0_49"],"title":"CallQualityDistribution","description":"Call counts bucketed by quality-score band."}}}}
```

## The CallQualityDistribution object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallQualityDistribution":{"properties":{"excellent_90_100":{"type":"integer","title":"Excellent 90 100","description":"Calls with quality score 90-100"},"good_70_89":{"type":"integer","title":"Good 70 89","description":"Calls with quality score 70-89"},"fair_50_69":{"type":"integer","title":"Fair 50 69","description":"Calls with quality score 50-69"},"poor_0_49":{"type":"integer","title":"Poor 0 49","description":"Calls with quality score 0-49"}},"type":"object","required":["excellent_90_100","good_70_89","fair_50_69","poor_0_49"],"title":"CallQualityDistribution","description":"Call counts bucketed by quality-score band."}}}}
```

## The CallQualitySummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallQualitySummary":{"properties":{"avg_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality Score","description":"Mean quality score across calls (0-100)"},"p50_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality Score","description":"Median quality score (0-100)"},"p95_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Quality Score","description":"95th-percentile quality score (0-100)"},"total_calls":{"type":"integer","title":"Total Calls","description":"Total number of calls in the period"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Fraction of calls escalated to an operator (0.0-1.0)"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Average call duration in seconds"}},"type":"object","required":["total_calls","escalation_rate"],"title":"CallQualitySummary","description":"Aggregate call-quality stats for the period."}}}}
```

## The CallQualityTrendPoint object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallQualityTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Time bucket as an ISO-8601 timestamp string (granularity follows `interval`)"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Average quality score in this bucket (0-100)"},"call_count":{"type":"integer","title":"Call Count","description":"Number of calls in this bucket"},"escalation_count":{"type":"integer","title":"Escalation Count","description":"Number of escalated calls in this bucket"}},"type":"object","required":["date","call_count","escalation_count"],"title":"CallQualityTrendPoint","description":"Single time-bucket data point in the call-quality trend series."}}}}
```

## The CallStatsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallStatsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace identifier"},"period_start":{"type":"string","format":"date","title":"Period Start","description":"Start of the reporting period"},"period_end":{"type":"string","format":"date","title":"Period End","description":"End of the reporting period"},"total_calls":{"type":"integer","title":"Total Calls","description":"Total number of calls in the period"},"total_duration_seconds":{"type":"number","title":"Total Duration Seconds","description":"Sum of all call durations in seconds"},"avg_duration_seconds":{"type":"number","title":"Avg Duration Seconds","description":"Average call duration in seconds"},"calls_by_date":{"items":{"$ref":"#/components/schemas/DailyCallStat"},"type":"array","title":"Calls By Date","description":"Daily call volume breakdown"}},"type":"object","required":["workspace_id","period_start","period_end","total_calls","total_duration_seconds","avg_duration_seconds","calls_by_date"],"title":"CallStatsResponse"},"DailyCallStat":{"properties":{"date":{"type":"string","title":"Date","description":"Date string (YYYY-MM-DD)"},"count":{"type":"integer","title":"Count","description":"Number of calls on this date"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Average call duration in seconds"}},"type":"object","required":["date","count"],"title":"DailyCallStat","description":"Per-day call volume and duration."}}}}
```

## The CallSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallSummary":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id","description":"World entity ID for this call"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"direction":{"anyOf":[{"type":"string","enum":["inbound","outbound","playground","simulated","test"]},{"type":"null"}],"title":"Direction","description":"Call direction"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number","description":"Service phone number"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id","description":"Caller phone number"},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When the call started"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Call duration in seconds"},"status":{"anyOf":[{"type":"string","enum":["initiated","ringing","in-progress","completed","busy","no-answer","canceled","failed","unknown"]},{"type":"null"}],"title":"Status","description":"Call status"},"escalation_status":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Escalation Status","description":"Escalation state if any"},"turns":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turns","description":"Number of conversation turns"},"has_recording":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Recording","description":"Whether a recording is available"},"quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quality Score","description":"Quality score 0.0 to 1.0"},"final_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final State","description":"Final conversation state"},"completion_reason":{"anyOf":[{"type":"string","enum":["completed","silence_hangup","abandoned","escalated","transferred","timeout","error","voicemail","no_answer","caller_hangup","forwarded","terminal_state","warm_transfer_completed","no_inbound_audio","cancelled","closed"]},{"type":"null"}],"title":"Completion Reason","description":"Why the call ended"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service ID that handled the call"},"source":{"anyOf":[{"type":"string","enum":["real","simulation","playground"]},{"type":"null"}],"title":"Source","description":"Call source — real, simulation, or playground"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id","description":"Simulation run ID (simulation calls only)"},"parent_session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Session Id","description":"Parent session for forked simulations"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index","description":"Turn index where simulation forked"}},"type":"object","required":["entity_id"],"title":"CallSummary"}}}}
```

## The CallTranscriptResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallTranscriptResponse":{"properties":{"call_entity_id":{"type":"string","format":"uuid","title":"Call Entity Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid"},"total_segments":{"type":"integer","title":"Total Segments"},"segments":{"items":{"$ref":"#/components/schemas/TranscriptSegment"},"type":"array","title":"Segments"}},"type":"object","required":["call_entity_id","call_sid","total_segments","segments"],"title":"CallTranscriptResponse"},"TranscriptSegment":{"properties":{"speaker_role":{"type":"string","title":"Speaker Role"},"transcript":{"type":"string","title":"Transcript"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp"},"escalation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Escalation Id"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence"}},"type":"object","required":["speaker_role","transcript","timestamp","escalation_id","confidence"],"title":"TranscriptSegment"}}}}
```

## The CanonicalIdLookupString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CanonicalIdLookupString":{"type":"string","maxLength":256,"minLength":1}}}}
```

## The CanonicalIdString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CanonicalIdString":{"type":"string","maxLength":256,"minLength":3,"pattern":"^[A-Za-z0-9._-]+:[A-Za-z0-9._-]+:[A-Za-z0-9._-]+$"}}}}
```

## The CanonicalInboundEnvelopePayload object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CanonicalInboundEnvelopePayload":{"properties":{"channel_kind":{"$ref":"#/components/schemas/ChannelKind"},"use_case_id":{"type":"string","format":"uuid","title":"Use Case Id"},"inbound_message_ref":{"type":"string","maxLength":256,"minLength":1,"title":"Inbound Message Ref"},"caller_ref":{"type":"string","maxLength":320,"title":"Caller Ref","default":""},"content_parts":{"items":{"$ref":"#/components/schemas/ContentPartPayload"},"type":"array","maxItems":100,"minItems":1,"title":"Content Parts"},"parent_outbound_ref":{"type":"string","maxLength":256,"title":"Parent Outbound Ref","default":""},"subject":{"anyOf":[{"type":"string","maxLength":998},{"type":"null"}],"title":"Subject"},"authenticated":{"type":"boolean","title":"Authenticated","default":false},"idempotency_key":{"type":"string","maxLength":256,"title":"Idempotency Key","default":""},"occurred_at":{"type":"number","title":"Occurred At","default":0}},"type":"object","required":["channel_kind","use_case_id","inbound_message_ref","content_parts"],"title":"CanonicalInboundEnvelopePayload","description":"An inbound channel message, as the channel service posts it to the platform API.\n\n`caller_ref` is the authenticated sender, and it must be empty when `authenticated` is false."},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"ContentPartPayload":{"properties":{"type":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9._-]*$","title":"Type","default":"text"},"text":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}],"title":"Text"},"url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Url"},"media_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Media Type"},"provider_id":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider Id"},"metadata":{"additionalProperties":true,"type":"object","maxProperties":50,"title":"Metadata"}},"type":"object","title":"ContentPartPayload","description":"HTTP/WebSocket shape for a modality-neutral conversation content part."}}}}
```

## The CatalogEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CatalogEntry":{"properties":{"name":{"type":"string","title":"Name"},"layer":{"type":"string","title":"Layer"},"description":{"type":"string","title":"Description"},"row_count":{"type":"integer","title":"Row Count"},"exists":{"type":"boolean","title":"Exists"}},"type":"object","required":["name","layer","description","row_count","exists"],"title":"CatalogEntry"}}}}
```

## The CategoricalMetricValueResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CategoricalMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"categorical","title":"Metric Type"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value","description":"The category this row counts. A list-metrics latest row gives its period's most frequent category."},"distribution":{"items":{"$ref":"#/components/schemas/CategoryCount"},"type":"array","title":"Distribution","description":"Events per category in this row's period, most frequent first. A list-metrics latest row\nlists every category its period saw; any other row lists its own category.","default":[]}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"CategoricalMetricValueResponse"},"CategoryCount":{"properties":{"value":{"type":"string","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["value","count"],"title":"CategoryCount"}}}}
```

## The CategoryCount object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CategoryCount":{"properties":{"value":{"type":"string","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["value","count"],"title":"CategoryCount"}}}}
```

## The ChangeColumnTypeAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ChangeColumnTypeAction":{"properties":{"op":{"type":"string","const":"change_column_type","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"new_type":{"$ref":"#/components/schemas/ColumnType"}},"type":"object","required":["op","name","new_type"],"title":"ChangeColumnTypeAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"},"ColumnType":{"type":"string","enum":["text","int","bigint","numeric","boolean","uuid","timestamptz","date","time","jsonb","bytea"]}}}}
```

## The ChannelKind object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."}}}}
```

## The ChannelOverride object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."}}}}
```

## The ChannelTurnResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ChannelTurnResponse":{"properties":{"status":{"type":"string","enum":["accepted","skipped","duplicate"],"title":"Status"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"event_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Event Id"},"is_new_session":{"type":"boolean","title":"Is New Session","default":false}},"type":"object","required":["status"],"title":"ChannelTurnResponse"}}}}
```

## The ChannelType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ChannelType":{"type":"string","enum":["email","web"],"title":"ChannelType","description":"Delivery channels for surfaces."}}}}
```

## The ChatRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ChatRequest":{"properties":{"message":{"type":"string","maxLength":16000,"minLength":1,"title":"Message","description":"Insights chat user message."},"selection":{"anyOf":[{"$ref":"#/components/schemas/InsightSelection"},{"type":"null"}]}},"type":"object","required":["message"],"title":"ChatRequest"},"InsightSelection":{"properties":{"source_session_id":{"type":"string","format":"uuid","title":"Source Session Id"},"presentation_id":{"type":"string","format":"uuid","title":"Presentation Id"},"row_index":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Row Index"},"series_index":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Series Index"}},"additionalProperties":false,"type":"object","required":["source_session_id","presentation_id"],"title":"InsightSelection"}}}}
```

## The CheckerLabelCheck object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"}}}}
```

## The ClaimMappingItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClaimMappingItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"claim_namespace":{"type":"string","title":"Claim Namespace"},"claim_key":{"type":"string","title":"Claim Key"},"external_value":{"type":"string","title":"External Value"},"external_role_id":{"type":"string","format":"uuid","title":"External Role Id"},"status":{"type":"string","enum":["active","superseded"],"title":"Status"},"changed_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Changed By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","claim_namespace","claim_key","external_value","external_role_id","status","created_at"],"title":"ClaimMappingItem"}}}}
```

## The ClassUsage object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClassUsage":{"properties":{"usage_class":{"type":"string","title":"Usage Class"},"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["usage_class","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ClassUsage","description":"Usage attributed to one usage class."}}}}
```

## The ClientArtifact object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClientArtifact":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"payload":{"$ref":"#/components/schemas/ClientArtifactPayload"}},"type":"object","required":["type","schema_version","payload"],"title":"ClientArtifact","description":"A versioned JSON payload that a client can render as a product component."},"ClientArtifactPayload":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"}]},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]}}}}
```

## The ClientArtifactPayload object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClientArtifactPayload":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"}]},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]}}}}
```

## The ClientConfigResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClientConfigResponse":{"properties":{"google_maps_api_key":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Google Maps Api Key"}},"type":"object","title":"ClientConfigResponse","description":"Client-safe configuration values.\n\nValues returned here are safe to embed in browser-side code.\nAPI keys are restricted by HTTP referrer or similar origin\ncontrols at the provider level."}}}}
```

## The ClientOutputConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClientOutputConfig":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"json_schema":{"additionalProperties":true,"type":"object","title":"Json Schema"},"max_bytes":{"type":"integer","maximum":262144,"minimum":1,"title":"Max Bytes","default":262144},"external_user_enabled":{"type":"boolean","title":"External User Enabled","default":false}},"type":"object","required":["type","schema_version","json_schema"],"title":"ClientOutputConfig","description":"External-user-safe projection contract for a direct integration endpoint.\n\nThe endpoint's existing ``response_template`` performs the projection. With no\ntemplate, the parsed upstream JSON body is emitted unchanged."}}}}
```

## The ClinicOpenHoursParams object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClinicOpenHoursParams":{"properties":{"rule_kind":{"type":"string","const":"clinic_open_hours","title":"Rule Kind","default":"clinic_open_hours"},"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"monday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"tuesday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"wednesday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"thursday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"friday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"saturday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"sunday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]}},"type":"object","required":["timezone"],"title":"ClinicOpenHoursParams","description":"Workspace clinic open-hours by weekday.\n\nDays not present mean \"closed.\" Used by the rules engine to skip\nslots outside open hours and (combined with ``weekend_skip``) by the\nTMS-mapping release calculator."},"_DayHours":{"properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$","title":"Start"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$","title":"End"}},"type":"object","required":["start","end"],"title":"_DayHours","description":"Open-hours window for one weekday. Times in 24h ``HH:MM`` form,\ninterpreted in the rule set's ``timezone``."}}}}
```

## The ClusterForecastPointRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClusterForecastPointRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"cluster_name":{"type":"string","title":"Cluster Name"},"focus_area":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Focus Area"},"t":{"type":"number","title":"T"},"median":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Median"},"lower_95":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lower 95"},"upper_95":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Upper 95"},"observed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Observed"},"ym":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ym"},"is_historical":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Historical"}},"type":"object","required":["workspace_id","cluster_name","t"],"title":"ClusterForecastPointRow"}}}}
```

## The ClusterForecastResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClusterForecastResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/ClusterForecastPointRow"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"ClusterForecastResponse"},"ClusterForecastPointRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"cluster_name":{"type":"string","title":"Cluster Name"},"focus_area":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Focus Area"},"t":{"type":"number","title":"T"},"median":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Median"},"lower_95":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lower 95"},"upper_95":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Upper 95"},"observed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Observed"},"ym":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ym"},"is_historical":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Historical"}},"type":"object","required":["workspace_id","cluster_name","t"],"title":"ClusterForecastPointRow"}}}}
```

## The ClusterSummaryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClusterSummaryResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/ClusterSummaryRow"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"ClusterSummaryResponse"},"ClusterSummaryRow":{"properties":{"cluster_name":{"type":"string","title":"Cluster Name"},"cohort_size":{"type":"integer","title":"Cohort Size"},"mean_age":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Age"},"mean_bmi":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Bmi"},"mean_hba1c":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Hba1C"},"pct_male":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pct Male"},"pct_prediabetes":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pct Prediabetes"},"pct_t2d":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pct T2D"},"mean_y_hat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Y Hat"}},"type":"object","required":["cluster_name","cohort_size"],"title":"ClusterSummaryRow"}}}}
```

## The ClusterSummaryRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ClusterSummaryRow":{"properties":{"cluster_name":{"type":"string","title":"Cluster Name"},"cohort_size":{"type":"integer","title":"Cohort Size"},"mean_age":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Age"},"mean_bmi":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Bmi"},"mean_hba1c":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Hba1C"},"pct_male":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pct Male"},"pct_prediabetes":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pct Prediabetes"},"pct_t2d":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pct T2D"},"mean_y_hat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mean Y Hat"}},"type":"object","required":["cluster_name","cohort_size"],"title":"ClusterSummaryRow"}}}}
```

## The CoachingItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CoachingItem":{"properties":{"moment_timestamp":{"anyOf":[{"type":"number","maximum":86400,"minimum":0},{"type":"null"}],"title":"Moment Timestamp","description":"Position in the recording this coaching applies to (seconds)"},"observation":{"type":"string","maxLength":2000,"minLength":1,"title":"Observation","description":"What was observed in the audio at this moment"},"recommendation":{"type":"string","maxLength":2000,"minLength":1,"title":"Recommendation","description":"Specific improvement the agent should make"},"expected_impact":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Expected Impact","description":"How this improvement would change the interaction"}},"type":"object","required":["observation","recommendation"],"title":"CoachingItem","description":"A specific, actionable improvement tied to an exact moment in the call."}}}}
```

## The CollectionField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."}}}}
```

## The Column-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Column-Input":{"properties":{"name":{"$ref":"#/components/schemas/IdentifierString"},"type":{"$ref":"#/components/schemas/ColumnType"},"nullable":{"type":"boolean","title":"Nullable","default":true},"default":{"anyOf":[{"$ref":"#/components/schemas/Default"},{"type":"null"}]}},"type":"object","required":["name","type"],"title":"Column"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"},"ColumnType":{"type":"string","enum":["text","int","bigint","numeric","boolean","uuid","timestamptz","date","time","jsonb","bytea"]},"Default":{"properties":{"kind":{"type":"string","enum":["literal","uuid_v4","now","current_date"],"title":"Kind"},"value":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value","description":"Only meaningful for ``kind=\"literal\"``. Other kinds ignore it.\nA ``dict`` value is rendered as a JSONB literal — pair it with a\n``jsonb`` column."}},"type":"object","required":["kind"],"title":"Default"}}}}
```

## The Column-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Column-Output":{"properties":{"name":{"type":"string","title":"Name"},"data_type":{"type":"string","title":"Data Type","description":"Postgres-side type as reported by ``information_schema.columns``\n(e.g. ``uuid``, ``text``, ``timestamp with time zone``)."},"is_nullable":{"type":"boolean","title":"Is Nullable"},"default":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default","description":"Postgres-side default expression text, or NULL if no DEFAULT."}},"type":"object","required":["name","data_type","is_nullable","default"],"title":"Column"}}}}
```

## The ColumnType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ColumnType":{"type":"string","enum":["text","int","bigint","numeric","boolean","uuid","timestamptz","date","time","jsonb","bytea"]}}}}
```

## The CommandCenterAlert object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CommandCenterAlert":{"properties":{"level":{"type":"string","enum":["info","warning","critical"],"title":"Level"},"code":{"type":"string","title":"Code"},"message":{"type":"string","title":"Message"},"section":{"type":"string","title":"Section"}},"type":"object","required":["level","code","message","section"],"title":"CommandCenterAlert"}}}}
```

## The CommandCenterResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CommandCenterResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"voice":{"$ref":"#/components/schemas/VoiceMetrics","default":{"active_calls":0,"active_escalated":0,"calls_today":0,"escalation_rate_today":0}},"data_quality":{"$ref":"#/components/schemas/DataQualityMetrics","default":{"pending_reviews":0,"entities_total":0,"entities_merged_7d":0}},"identity":{"$ref":"#/components/schemas/IdentityMetrics","default":{"active_api_keys":0}},"alerts":{"items":{"$ref":"#/components/schemas/CommandCenterAlert"},"type":"array","title":"Alerts","default":[]},"degraded_sections":{"items":{"type":"string"},"type":"array","title":"Degraded Sections","default":[]},"generated_at":{"type":"string","title":"Generated At"},"cached":{"type":"boolean","title":"Cached","default":false}},"type":"object","required":["workspace_id","generated_at"],"title":"CommandCenterResponse"},"VoiceMetrics":{"properties":{"active_calls":{"type":"integer","title":"Active Calls","default":0},"active_escalated":{"type":"integer","title":"Active Escalated","default":0},"calls_today":{"type":"integer","title":"Calls Today","default":0},"avg_quality_score_today":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality Score Today"},"escalation_rate_today":{"type":"number","title":"Escalation Rate Today","default":0}},"type":"object","title":"VoiceMetrics"},"DataQualityMetrics":{"properties":{"pending_reviews":{"type":"integer","title":"Pending Reviews","default":0},"approval_rate_7d":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Approval Rate 7D"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"entities_total":{"type":"integer","title":"Entities Total","default":0},"entities_merged_7d":{"type":"integer","title":"Entities Merged 7D","default":0}},"type":"object","title":"DataQualityMetrics"},"IdentityMetrics":{"properties":{"active_api_keys":{"type":"integer","title":"Active Api Keys","default":0},"active_sessions":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Active Sessions"},"failed_auths_1h":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Failed Auths 1H"},"locked_accounts":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Locked Accounts"},"mfa_coverage_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mfa Coverage Pct"}},"type":"object","title":"IdentityMetrics"},"CommandCenterAlert":{"properties":{"level":{"type":"string","enum":["info","warning","critical"],"title":"Level"},"code":{"type":"string","title":"Code"},"message":{"type":"string","title":"Message"},"section":{"type":"string","title":"Section"}},"type":"object","required":["level","code","message","section"],"title":"CommandCenterAlert"}}}}
```

## The CompleteSimulationRunResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CompleteSimulationRunResponse":{"properties":{"status":{"type":"string","enum":["completed","failed"],"title":"Status"}},"type":"object","required":["status"],"title":"CompleteSimulationRunResponse"}}}}
```

## The CompletionCriteria object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CompletionCriteria":{"properties":{"state_based":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"State Based"},"tool_based":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"Tool Based"}},"type":"object","title":"CompletionCriteria"}}}}
```

## The ComplianceDashboardResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ComplianceDashboardResponse":{"properties":{"hipaa_status":{"type":"string","title":"Hipaa Status"},"retention_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Retention Days"},"legal_hold":{"type":"boolean","title":"Legal Hold"},"total_credentials":{"type":"integer","title":"Total Credentials"},"active_credentials":{"type":"integer","title":"Active Credentials"},"last_audit_export":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Audit Export"},"generated_at":{"type":"string","title":"Generated At"}},"type":"object","required":["hipaa_status","retention_days","legal_hold","total_credentials","active_credentials","last_audit_export","generated_at"],"title":"ComplianceDashboardResponse","description":"Composite compliance health overview."}}}}
```

## The ConceptMatch object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConceptMatch":{"properties":{"concept":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Concept"},"similarity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Similarity"},"agent_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Action"},"agent_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Confidence"},"agent_reasoning":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Reasoning"},"at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"At"}},"type":"object","title":"ConceptMatch"}}}}
```

## The ConcurrentStartBlockParams object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConcurrentStartBlockParams":{"properties":{"rule_kind":{"type":"string","const":"concurrent_start_block","title":"Rule Kind","default":"concurrent_start_block"}},"type":"object","title":"ConcurrentStartBlockParams","description":"Disallow two slots starting at the same time within a TMS scope.\nNo additional params — the discriminator is the whole config."}}}}
```

## The ConfidenceBucket object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConfidenceBucket":{"properties":{"confidence_range":{"type":"string","title":"Confidence Range","description":"Confidence level bucket label (e.g. 'raw', 'verified', 'authoritative')"},"count":{"type":"integer","title":"Count","description":"Number of events in this confidence bucket"}},"type":"object","required":["confidence_range","count"],"title":"ConfidenceBucket"}}}}
```

## The ConfigToPolicyRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConfigToPolicyRequest":{"properties":{"config":{"additionalProperties":true,"type":"object","title":"Config"}},"type":"object","required":["config"],"title":"ConfigToPolicyRequest"}}}}
```

## The ConfigToPolicyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConfigToPolicyResponse":{"properties":{"turn_policy":{"$ref":"#/components/schemas/TurnPolicyOverrides","description":"Only the fields the config sets. A field left out keeps its turn-policy default."}},"type":"object","required":["turn_policy"],"title":"ConfigToPolicyResponse"},"TurnPolicyOverrides":{"properties":{"greeting_shield_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Greeting Shield S"},"barge_in_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Barge In Enabled"},"block_forward_call":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Block Forward Call"},"context_strategy":{"anyOf":[{"type":"string","const":"compact"},{"type":"null"}],"title":"Context Strategy"},"degradation_threshold":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Degradation Threshold"},"block_forward_call_after_turns":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Block Forward Call After Turns"}},"type":"object","title":"TurnPolicyOverrides"}}}}
```

## The ConnectorHealthItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConnectorHealthItem":{"properties":{"source":{"type":"string","maxLength":256,"minLength":1,"title":"Source","description":"Operator-defined source identifier, as the source's events carry it (e.g. 'charm', 'careclinic', 'hazel'). Enum-like; never user input."},"events_per_minute":{"type":"number","minimum":0,"title":"Events Per Minute","description":"Mean events/min over the last hour (events_last_hour / 60)."},"events_last_hour":{"type":"integer","minimum":0,"title":"Events Last Hour"},"events_last_24h":{"type":"integer","minimum":0,"title":"Events Last 24H","description":"Events ingested in the last 24 hours (rolling, not calendar-day)."},"last_ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Ingested At"},"freshness":{"type":"string","enum":["fresh","stale","quiet","never"],"title":"Freshness","description":"fresh < 5min · stale 5-60min · quiet > 60min · never = no events in 24h"}},"type":"object","required":["source","events_per_minute","events_last_hour","events_last_24h","last_ingested_at","freshness"],"title":"ConnectorHealthItem"}}}}
```

## The ConnectorHealthResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConnectorHealthResponse":{"properties":{"sources":{"items":{"$ref":"#/components/schemas/ConnectorHealthItem"},"type":"array","maxItems":500,"title":"Sources"},"as_of":{"type":"string","format":"date-time","title":"As Of","description":"Server clock at query time (UTC)."},"read_model_status":{"type":"string","enum":["ready","empty","unavailable"],"title":"Read Model Status","description":"ready = the summary returned rows; empty = no summary rows; unavailable = read failed."},"read_model_synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Read Model Synced At","description":"The most recent time the connector health data in this response was synced."}},"type":"object","required":["as_of","read_model_status"],"title":"ConnectorHealthResponse"},"ConnectorHealthItem":{"properties":{"source":{"type":"string","maxLength":256,"minLength":1,"title":"Source","description":"Operator-defined source identifier, as the source's events carry it (e.g. 'charm', 'careclinic', 'hazel'). Enum-like; never user input."},"events_per_minute":{"type":"number","minimum":0,"title":"Events Per Minute","description":"Mean events/min over the last hour (events_last_hour / 60)."},"events_last_hour":{"type":"integer","minimum":0,"title":"Events Last Hour"},"events_last_24h":{"type":"integer","minimum":0,"title":"Events Last 24H","description":"Events ingested in the last 24 hours (rolling, not calendar-day)."},"last_ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Ingested At"},"freshness":{"type":"string","enum":["fresh","stale","quiet","never"],"title":"Freshness","description":"fresh < 5min · stale 5-60min · quiet > 60min · never = no events in 24h"}},"type":"object","required":["source","events_per_minute","events_last_hour","events_last_24h","last_ingested_at","freshness"],"title":"ConnectorHealthItem"}}}}
```

## The ConnectorResourcesResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConnectorResourcesResponse":{"properties":{"resource_type":{"type":"string","maxLength":256,"title":"Resource Type","description":"FHIR resource type (e.g. Patient, Condition, MedicationRequest)"},"data_source_id":{"type":"string","format":"uuid","title":"Data Source Id","description":"UUID of the connected data source"},"total":{"type":"integer","title":"Total","description":"Total number of matching resources"},"entries":{"items":{"additionalProperties":true,"type":"object"},"type":"array","maxItems":100,"title":"Entries","description":"Raw FHIR resource JSON objects"}},"type":"object","required":["resource_type","data_source_id","total","entries"],"title":"ConnectorResourcesResponse","description":"FHIR resources from a specific connected data source."}}}}
```

## The Constraint object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Constraint":{"properties":{"name":{"type":"string","title":"Name"},"definition":{"type":"string","title":"Definition","description":"``pg_get_constraintdef(oid)`` — the postgres-rendered definition."}},"type":"object","required":["name","definition"],"title":"Constraint"}}}}
```

## The ContactLine object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContactLine":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"type":"string","maxLength":16,"minLength":2,"title":"Number"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLine","description":"A service's declared contact line."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ContactLineInput object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContactLineInput":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"$ref":"#/components/schemas/DialE164"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLineInput","description":"Save-time number policy; persisted declarations remain readable after policy changes."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ContentPartPayload object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContentPartPayload":{"properties":{"type":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9._-]*$","title":"Type","default":"text"},"text":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}],"title":"Text"},"url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Url"},"media_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Media Type"},"provider_id":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider Id"},"metadata":{"additionalProperties":true,"type":"object","maxProperties":50,"title":"Metadata"}},"type":"object","title":"ContentPartPayload","description":"HTTP/WebSocket shape for a modality-neutral conversation content part."}}}}
```

## The ContextGraphListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContextGraphListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ContextGraphResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ContextGraphListResponse"},"ContextGraphResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"latest_version":{"type":"integer","title":"Latest Version","default":0},"state_count":{"type":"integer","title":"State Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","description","created_at","updated_at"],"title":"ContextGraphResponse"}}}}
```

## The ContextGraphResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContextGraphResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"latest_version":{"type":"integer","title":"Latest Version","default":0},"state_count":{"type":"integer","title":"State Count","default":0},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","description","created_at","updated_at"],"title":"ContextGraphResponse"}}}}
```

## The ContextGraphState-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContextGraphState-Input":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Input"},{"$ref":"#/components/schemas/DecisionState-Input"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Input"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Input","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Input","decision":"#/components/schemas/DecisionState-Input"}}},"ActionState-Input":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Input":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Input":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."}}}}
```

## The ContextGraphState-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."}}}}
```

## The ContextGraphVersion object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContextGraphVersion":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"context_graph_id":{"type":"string","format":"uuid","title":"Context Graph Id"},"version":{"type":"integer","title":"Version"},"description":{"type":"string","title":"Description"},"states":{"items":{"$ref":"#/components/schemas/ContextGraphState-Output"},"type":"array","title":"States"},"new_user_initial_state":{"type":"string","title":"New User Initial State"},"returning_user_initial_state":{"type":"string","title":"Returning User Initial State"},"terminal_state":{"type":"string","title":"Terminal State","default":""},"global_intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Intra State Navigation Guidelines","default":[]},"global_action_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Action Guidelines","default":[]},"global_boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Global Boundary Constraints","default":[]},"topology_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Topology Description"},"dynamic_behaviors":{"items":{"$ref":"#/components/schemas/DynamicBehavior"},"type":"array","maxItems":254,"title":"Dynamic Behaviors"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","context_graph_id","version","description","states","new_user_initial_state","returning_user_initial_state"],"title":"ContextGraphVersion","description":"A version of a hierarchical state machine (context graph)."},"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"DynamicBehavior":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Stable across versions: the same behavior keeps its id in every version that carries it. The client\ngenerates it. A resolved behavior carries its library set's id."},"version":{"anyOf":[{"type":"integer","maximum":2147483647,"minimum":1},{"type":"null"}],"title":"Version","description":"The version of the library set this was resolved from. Null on a behavior embedded on a context graph\nversion."},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name","description":"What authors call it. The selector reads it with the condition and examples, and the reply prompt never\ndoes."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled behavior stays on the version and is never offered.","default":true},"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force, and the only text of a behavior that\nreaches the reply prompt. Null: the behavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay.","default":"add"},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one.","default":[]},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on. It ends\nsooner when the selector chooses another behavior with enough confidence, and when a turn is skipped: a\nmedical emergency, a request for a person, an empathy hold, a suspended session, or a state the behavior\ndoes not apply in.","default":1},"tags":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10,"title":"Tags","description":"Labels for authors. They never reach a prompt.","default":[]}},"additionalProperties":false,"type":"object","required":["id","name","condition"],"title":"DynamicBehavior","description":"One authored behavior: embedded on a context graph version, or resolved from a library set version."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ContextGraphVersionListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContextGraphVersionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ContextGraphVersionResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ContextGraphVersionListResponse"},"ContextGraphVersionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"context_graph_id":{"type":"string","format":"uuid","title":"Context Graph Id"},"version":{"type":"integer","title":"Version"},"description":{"type":"string","title":"Description"},"states":{"items":{"$ref":"#/components/schemas/ContextGraphState-Output"},"type":"array","title":"States"},"new_user_initial_state":{"type":"string","title":"New User Initial State"},"returning_user_initial_state":{"type":"string","title":"Returning User Initial State"},"terminal_state":{"type":"string","title":"Terminal State"},"global_intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Intra State Navigation Guidelines"},"global_action_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Action Guidelines"},"global_boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Global Boundary Constraints"},"topology_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Topology Description"},"dynamic_behaviors":{"items":{"$ref":"#/components/schemas/DynamicBehavior"},"type":"array","title":"Dynamic Behaviors","description":"Deprecated: always empty. Dynamic behaviors are in the dynamic behavior sets library, pinned on a service's\nversion set.","deprecated":true},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","context_graph_id","version","description","states","new_user_initial_state","returning_user_initial_state","terminal_state","global_intra_state_navigation_guidelines","global_action_guidelines","global_boundary_constraints","topology_description","dynamic_behaviors","created_at","updated_at"],"title":"ContextGraphVersionResponse"},"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"DynamicBehavior":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Stable across versions: the same behavior keeps its id in every version that carries it. The client\ngenerates it. A resolved behavior carries its library set's id."},"version":{"anyOf":[{"type":"integer","maximum":2147483647,"minimum":1},{"type":"null"}],"title":"Version","description":"The version of the library set this was resolved from. Null on a behavior embedded on a context graph\nversion."},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name","description":"What authors call it. The selector reads it with the condition and examples, and the reply prompt never\ndoes."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled behavior stays on the version and is never offered.","default":true},"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force, and the only text of a behavior that\nreaches the reply prompt. Null: the behavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay.","default":"add"},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one.","default":[]},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on. It ends\nsooner when the selector chooses another behavior with enough confidence, and when a turn is skipped: a\nmedical emergency, a request for a person, an empathy hold, a suspended session, or a state the behavior\ndoes not apply in.","default":1},"tags":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10,"title":"Tags","description":"Labels for authors. They never reach a prompt.","default":[]}},"additionalProperties":false,"type":"object","required":["id","name","condition"],"title":"DynamicBehavior","description":"One authored behavior: embedded on a context graph version, or resolved from a library set version."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ContextGraphVersionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContextGraphVersionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"context_graph_id":{"type":"string","format":"uuid","title":"Context Graph Id"},"version":{"type":"integer","title":"Version"},"description":{"type":"string","title":"Description"},"states":{"items":{"$ref":"#/components/schemas/ContextGraphState-Output"},"type":"array","title":"States"},"new_user_initial_state":{"type":"string","title":"New User Initial State"},"returning_user_initial_state":{"type":"string","title":"Returning User Initial State"},"terminal_state":{"type":"string","title":"Terminal State"},"global_intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Intra State Navigation Guidelines"},"global_action_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Action Guidelines"},"global_boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Global Boundary Constraints"},"topology_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Topology Description"},"dynamic_behaviors":{"items":{"$ref":"#/components/schemas/DynamicBehavior"},"type":"array","title":"Dynamic Behaviors","description":"Deprecated: always empty. Dynamic behaviors are in the dynamic behavior sets library, pinned on a service's\nversion set.","deprecated":true},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","context_graph_id","version","description","states","new_user_initial_state","returning_user_initial_state","terminal_state","global_intra_state_navigation_guidelines","global_action_guidelines","global_boundary_constraints","topology_description","dynamic_behaviors","created_at","updated_at"],"title":"ContextGraphVersionResponse"},"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"DynamicBehavior":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Stable across versions: the same behavior keeps its id in every version that carries it. The client\ngenerates it. A resolved behavior carries its library set's id."},"version":{"anyOf":[{"type":"integer","maximum":2147483647,"minimum":1},{"type":"null"}],"title":"Version","description":"The version of the library set this was resolved from. Null on a behavior embedded on a context graph\nversion."},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name","description":"What authors call it. The selector reads it with the condition and examples, and the reply prompt never\ndoes."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled behavior stays on the version and is never offered.","default":true},"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force, and the only text of a behavior that\nreaches the reply prompt. Null: the behavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay.","default":"add"},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one.","default":[]},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on. It ends\nsooner when the selector chooses another behavior with enough confidence, and when a turn is skipped: a\nmedical emergency, a request for a person, an empathy hold, a suspended session, or a state the behavior\ndoes not apply in.","default":1},"tags":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10,"title":"Tags","description":"Labels for authors. They never reach a prompt.","default":[]}},"additionalProperties":false,"type":"object","required":["id","name","condition"],"title":"DynamicBehavior","description":"One authored behavior: embedded on a context graph version, or resolved from a library set version."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ContextKeySpec object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ContextKeySpec":{"properties":{"key":{"$ref":"#/components/schemas/SlugString"},"type":{"type":"string","enum":["string","number"],"title":"Type"},"description":{"$ref":"#/components/schemas/DescriptionString"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["key","type","description","required"],"title":"ContextKeySpec","description":"One key a conversation may supply as start-time context for a service.\n\nThe value is validated against ``type`` at conversation start; a tool can then\nbind the key to one of its parameters (injected, hidden from the model)."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The ConversationApprovalRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationApprovalRequest":{"properties":{"decision":{"type":"string","enum":["approve","reject"],"title":"Decision"},"reason":{"anyOf":[{"type":"string","maxLength":512,"minLength":1},{"type":"null"}],"title":"Reason"}},"additionalProperties":false,"type":"object","required":["decision"],"title":"ConversationApprovalRequest","description":"An external user's decision on a parked, approval-gated write in their own conversation."}}}}
```

## The ConversationAuditCheck object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationAuditCheck":{"type":"string","enum":["obvious_errors","missed_escalation","wrong_information","missed_safety_event"]}}}}
```

## The ConversationAuditSettings object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationAuditSettings":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"checks":{"items":{"$ref":"#/components/schemas/ConversationAuditCheck"},"type":"array","maxItems":4,"minItems":1,"title":"Checks"},"threshold":{"type":"integer","maximum":100,"minimum":1,"title":"Threshold","default":80}},"additionalProperties":false,"type":"object","title":"ConversationAuditSettings"},"ConversationAuditCheck":{"type":"string","enum":["obvious_errors","missed_escalation","wrong_information","missed_safety_event"]}}}}
```

## The ConversationCompletion object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationCompletion":{"properties":{"completion_reason":{"type":"string","enum":["completed","silence_hangup","abandoned","escalated","transferred","timeout","error","voicemail","no_answer","caller_hangup","forwarded","terminal_state","warm_transfer_completed","no_inbound_audio","cancelled","closed"],"title":"Completion Reason","description":"Canonical completion reason of the session that ended the conversation."},"final_state":{"$ref":"#/components/schemas/NameString","description":"Context-graph state the session ended in."},"ended_at":{"type":"string","format":"date-time","title":"Ended At","description":"When that session ended: the ended_at its session.ended world event carries."}},"type":"object","required":["completion_reason","final_state","ended_at"],"title":"ConversationCompletion","description":"How the session that ended a text conversation finished."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ConversationConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationConfig":{"properties":{"agent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Id"},"agent_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version"},"agent_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Name"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version"},"initial_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Initial State"},"gpt_audio_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gpt Audio Model"},"navigation_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Navigation Model"}},"type":"object","title":"ConversationConfig"}}}}
```

## The ConversationDetail object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationDetail":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"channel_kind":{"$ref":"#/components/schemas/ChannelKind"},"status":{"type":"string","enum":["active","closed","completed","in-progress","failed","paused"],"title":"Status"},"lifecycle":{"type":"string","enum":["active","dormant","closed"],"title":"Lifecycle"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"direction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Direction"},"turn_count":{"type":"integer","title":"Turn Count","default":0},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds"},"created_at":{"type":"string","title":"Created At"},"updated_at":{"type":"string","title":"Updated At"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Quality Score"},"has_recording":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Recording"},"completion_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completion Reason"},"escalation_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Escalation Status"},"final_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final State"},"tags":{"items":{"$ref":"#/components/schemas/ConversationTag"},"type":"array","title":"Tags","description":"The labels an app set on the conversation, by key. Empty when it has none."},"tool_execution":{"anyOf":[{"type":"string","const":"live"},{"type":"null"}],"title":"Tool Execution","description":"Stored explicit Playground tool policy. ``live`` runs its tools for real. Null means no explicit live policy: Playground and test conversations simulate, while ordinary production conversations retain their existing tool behavior."},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"What started the conversation. A text conversation reads ``test`` when a test key or the ``test`` marker started it, ``playground`` when the developer console Playground did, and null otherwise. A call reads the source its call intelligence recorded (``real``, ``simulation`` or ``playground``), and null when it recorded none, as a test call does."},"turns":{"items":{"$ref":"#/components/schemas/ConversationTurn"},"type":"array","title":"Turns","default":[]},"truncated":{"type":"boolean","title":"Truncated","description":"True when the conversation recorded more entries than one read takes (10,000), so the turns stop before the end of the conversation.","default":false},"plan":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Plan"},"voice":{"anyOf":[{"$ref":"#/components/schemas/VoiceDetail"},{"type":"null"}]},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider","description":"The voice runtime that handled the conversation, as its session recorded it at start: `concurrence` (also every text conversation) or `gpt_realtime`. Null when the conversation was recorded before the platform kept it, before a text conversation's first session starts, and for an external user."},"manifest":{"anyOf":[{"$ref":"#/components/schemas/RunManifest"},{"type":"null"}],"description":"What the conversation executed with, as its first session recorded it: the agent and context graph versions, the version set and config fingerprint, the digest of the whole service config it received, the build, the models and how they sampled, the prompt templates, the voice's language, the program flags and how the region decides. A call that changed its STT or its voice's language mid-call reads as it last stood. Null when the conversation was recorded before the platform kept it, before a text conversation's first session starts, and for an external user, since it names the workspace's agent, graph and models."}},"type":"object","required":["id","channel_kind","status","lifecycle","created_at","updated_at"],"title":"ConversationDetail"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"ConversationTag":{"properties":{"key":{"type":"string","maxLength":64,"minLength":1,"title":"Key"},"value":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Value","description":"Null for a bare label."}},"type":"object","required":["key"],"title":"ConversationTag"},"ConversationTurn":{"properties":{"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"Stable identifier of the user exchange this message belongs to, derived deterministically from (conversation_id, turn_index) — identical across ``POST /turns`` responses and re-reads of the conversation history. User and agent messages from the same exchange share this value. Null on messages that precede the first user turn (proactive greetings, channel-event preludes)."},"turn_index":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Turn Index","description":"Zero-based ordinal of the user exchange this message belongs to (0 = first user turn). Derived server-side from the conversation's user-turn count — never stored. Null exactly when ``turn_id`` is null."},"engine_turn_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Engine Turn Id","description":"The agent engine's id for the turn this message opens (a user message) or answers (an agent message). One exchange can hold several engine turns, such as a tool call and the reply to its result. Null when no engine turn is recorded on the message: a filler line, a text reply, a channel event, or an older conversation that didn't record it."},"role":{"type":"string","enum":["agent","user","system"],"title":"Role"},"text":{"type":"string","title":"Text"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State","description":"The context-graph state of the conversation at this message: for a user message, the state it arrived in; for an agent message, the state after the turn's transitions. Null when the record names no state."},"speech_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speech Start Ms","description":"Where this message's speech starts in the call's recording, in milliseconds from the start of the recording. A user message starts when the caller began speaking; an agent message when its first audio was sent, slightly before the caller heard it. Null when no position was recorded: text messages, agent lines that never played, and older calls that didn't record one."},"speech_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speech End Ms","description":"Where this message's speech ends in the call's recording, in milliseconds from the start of the recording: when the caller stopped speaking, or when the agent line's last audio was sent. Null when no position was recorded, such as on a caller's line the call ended during."},"filler_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Type","description":"On an agent line the agent spoke while working on the reply, the kind of filler it was, such as ``receipt``, ``empathy`` or ``working``. Null on a reply and on user and system messages."},"interrupted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Interrupted","description":"On an agent line in a call, whether the caller cut it off, before or while it played. Null on user, system and text messages, and where the record doesn't say."},"channel":{"anyOf":[{"$ref":"#/components/schemas/ChannelKind"},{"type":"null"}],"description":"Channel this turn occurred on. A conversation that switched channels has a self-describing per-turn history; null on turns written before per-turn attribution or on channel-less internal turns."},"content":{"items":{"$ref":"#/components/schemas/ContentPartPayload"},"type":"array","title":"Content","default":[]},"tool_calls":{"items":{"$ref":"#/components/schemas/ConversationToolCallDetail"},"type":"array","title":"Tool Calls","description":"Tool calls executed during this (agent) turn. Populated only when the request opts in via ``include_tool_calls=true``; empty otherwise and on turns that did not invoke tools.","default":[]},"artifacts":{"items":{"$ref":"#/components/schemas/ClientArtifact"},"type":"array","title":"Artifacts","description":"Validated client-safe outputs produced during this agent turn.","default":[]},"selected_action_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action Description","description":"Description of the context-graph action selected for this turn. Null means no action was selected or no selected action was recorded."},"state_transition":{"anyOf":[{"$ref":"#/components/schemas/ConversationTurnStateTransition"},{"type":"null"}],"description":"Context-graph state transition that occurred during this turn. Null means no transition took place or no transition was recorded. Deprecated: use state_transitions instead. If multiple transitions were recorded, this field reports the first source state and final destination state, with no exit condition.","deprecated":true},"state_transitions":{"items":{"$ref":"#/components/schemas/ConversationTurnStateTransition"},"type":"array","title":"State Transitions","description":"Ordered context-graph state transitions that occurred during this turn.","default":[]},"available_actions":{"items":{"$ref":"#/components/schemas/ConversationTurnAvailableAction"},"type":"array","title":"Available Actions","description":"Action choices available in the turn's resolved context-graph state. Empty when actions cannot be resolved or the resolved state is not an action state.","default":[]},"dynamic_behavior":{"anyOf":[{"$ref":"#/components/schemas/AppliedBehavior"},{"type":"null"}],"description":"On an agent message, the dynamic behavior its reply was rendered with. Null when none was in force, and on user and system messages."}},"type":"object","required":["role","text"],"title":"ConversationTurn"},"ContentPartPayload":{"properties":{"type":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9._-]*$","title":"Type","default":"text"},"text":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}],"title":"Text"},"url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Url"},"media_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Media Type"},"provider_id":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider Id"},"metadata":{"additionalProperties":true,"type":"object","maxProperties":50,"title":"Metadata"}},"type":"object","title":"ContentPartPayload","description":"HTTP/WebSocket shape for a modality-neutral conversation content part."},"ConversationToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"call_id":{"type":"string","title":"Call Id"},"input":{"additionalProperties":true,"type":"object","title":"Input"},"result":{"type":"string","title":"Result","default":""},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded","description":"Whether the tool call succeeded. Null when no result was recorded, for example while it still runs.","default":true},"duration_ms":{"anyOf":[{"type":"number","maximum":3600000,"minimum":0},{"type":"null"}],"title":"Duration Ms","description":"Wall-clock tool execution time in milliseconds, measured at the engage_step call site. Omitted (null) on legacy turns that did not capture timing."},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Failure detail recorded for the tool call when ``succeeded`` is false. Null on successful calls or when no message was captured."}},"type":"object","required":["tool_name","call_id"],"title":"ConversationToolCallDetail"},"ClientArtifact":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"payload":{"$ref":"#/components/schemas/ClientArtifactPayload"}},"type":"object","required":["type","schema_version","payload"],"title":"ClientArtifact","description":"A versioned JSON payload that a client can render as a product component."},"ClientArtifactPayload":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"}]},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]},"ConversationTurnStateTransition":{"properties":{"from":{"type":"string","title":"From","description":"Source context-graph state before the turn's state transition."},"to":{"type":"string","title":"To","description":"Destination context-graph state after the turn's state transition."},"exit_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exit Condition","description":"The exit condition the agent took out of ``from``, as the context graph worded it when the hop was taken. Null on a hop out of an annotation state, which has no exit conditions, and on a hop recorded without one. Never read from the current graph."}},"type":"object","required":["from","to"],"title":"ConversationTurnStateTransition"},"ConversationTurnAvailableAction":{"properties":{"description":{"type":"string","title":"Description","description":"Human-readable description of an action available in the turn's state."}},"type":"object","required":["description"],"title":"ConversationTurnAvailableAction"},"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"VoiceDetail":{"properties":{"recording_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recording Path"},"twilio_recording_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Twilio Recording Sid"},"twilio_recording_duration":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Twilio Recording Duration"},"has_recording":{"type":"boolean","title":"Has Recording","default":false},"barge_in_events":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Barge In Events","default":[]},"states_visited":{"items":{"type":"string"},"type":"array","title":"States Visited","default":[]},"participants":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Participants","default":[]},"config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Config"},"call_analysis":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Call Analysis"},"forwarding":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Forwarding"},"escalation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Escalation"},"safety":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Safety"},"quality_breakdown":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Quality Breakdown"},"risk_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Risk Summary"},"latency_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Latency Summary"},"conversation_metrics":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conversation Metrics"},"tool_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tool Summary"},"safety_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Safety Summary"},"operator_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Operator Summary"},"safe_exit":{"anyOf":[{"$ref":"#/components/schemas/src__services__safe_exit_reader__SafeExit"},{"type":"null"}],"description":"The call's safe exit, from its ``call.minimal_risk`` event. Null when the call didn't take it."},"timeline":{"anyOf":[{"$ref":"#/components/schemas/ConversationTimeline"},{"type":"null"}],"description":"Where the call's lines sit in its recording, from the positions its turns carry, with the wait from each user message to the first reply. ``turn_index`` on its turns and segments is a position in this response's ``turns``, not a turn's own ``turn_index``, which counts exchanges. ``turn_id`` names that turn's exchange. A truncated read's timeline stops where its turns do. An agent line's span is from when its first audio was sent to when its last was, ahead of when the caller finished hearing it, so the timeline places no silence. Tool calls and state transitions record no position, so they stay on the turns. Null when no line has a recorded start and end."}},"type":"object","title":"VoiceDetail"},"src__services__safe_exit_reader__SafeExit":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger","description":"Why the call took the safe exit."},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome","description":"``mrc_transferred`` once the hand-off to the human line was placed, ``mrc_failed`` when the hand-off raised\n(the caller may still be on the line), else ``mrc_ended`` (hung up). The conversation's ``completion_reason``\nreads these as ``transferred`` and ``error``."},"lines_played":{"items":{"type":"string","enum":["disclosure","transfer","end","fallback_missed","hearing_failure"]},"type":"array","title":"Lines Played","description":"The script lines that played whole, in order. ``disclosure`` is the AI and recording notice."},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"The caller had heard all of the AI and recording notice before the exit began, so the exit did not\nplay it again. When false, the notice was heard only if ``lines_played`` holds ``disclosure``."},"trigger_description":{"type":"string","title":"Trigger Description","description":"``trigger`` in plain words.","readOnly":true}},"type":"object","required":["trigger","outcome","lines_played","disclosure_heard","trigger_description"],"title":"SafeExit","description":"The call's safe exit: the agent stopped and a fixed script handed the caller to a person or ended the call."},"ConversationTimeline":{"properties":{"turns":{"items":{"$ref":"#/components/schemas/TurnTimeline"},"type":"array","title":"Turns","description":"One entry per message whose speech has a recorded start and end: ``seek_to`` and ``active_start`` are where it starts and ``active_end`` where it ends, in seconds from the start of the recording."},"segments":{"items":{"$ref":"#/components/schemas/TimelineSegment"},"type":"array","title":"Segments","description":"Each placed line's speech (``caller_speech``, ``agent_speech``, ``filler``, or ``interrupted_speech`` for a reply the caller cut off; a filler stays ``filler`` when cut off, and its turn's ``filler_type`` and ``interrupted`` say both) and each ``processing_gap``: the wait from a user message's end to the first reply after it, when that reply started once the user had stopped. A line already playing when the user started answers an earlier message. Later lines start no wait: the caller had heard the agent, and an agent line's end is when its audio was sent, so the time after it isn't measured. A gap's ``e2e_ttfb_ms`` is the wait the caller heard, to the first filler that started after their line or to the reply. A wait is placed only where the user message, the reply and every line that played between them have a start and an end, so every gap ends at a line in ``turns``. Ordered by start, then end."},"avg_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Processing Gap Ms","description":"Mean of the placed processing gaps, in ms. Null when there are none."},"max_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Max Processing Gap Ms","description":"Longest placed processing gap, in ms. Null when there are none."},"avg_perceived_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Perceived Latency Ms","description":"Mean of the placed gaps' ``e2e_ttfb_ms``. Null when there are none."}},"type":"object","required":["turns","segments"],"title":"ConversationTimeline","description":"Where a voice call's lines sit in its recording, and the waits between them."},"TurnTimeline":{"properties":{"turn_index":{"type":"integer","title":"Turn Index","description":"The turn: its index in the response's ``turns`` on ``GET /conversations/{conversation_id}``,\nthe call-detail row the timeline was built from on ``GET /calls/{call_id}``."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on a turn\nbefore the first exchange."},"seek_to":{"type":"number","title":"Seek To"},"active_start":{"type":"number","title":"Active Start"},"active_end":{"type":"number","title":"Active End"}},"type":"object","required":["turn_index","seek_to","active_start","active_end"],"title":"TurnTimeline"},"TimelineSegment":{"properties":{"type":{"type":"string","enum":["agent_speech","barge_in","caller_speech","filler","filler_hesitation","filler_nav","greeting","interrupted_speech","processing_gap","silence","silence_check","state_transition","tool_call"],"title":"Type"},"lane":{"type":"string","enum":["agent","caller","events","operator","system","tool"],"title":"Lane"},"track":{"anyOf":[{"type":"string","enum":["agent","caller","operator","system","tool"]},{"type":"null"}],"title":"Track","description":"Actor-semantic display track for the segment. Inferred for legacy producers."},"lane_id":{"anyOf":[{"type":"string","maxLength":160,"minLength":1},{"type":"null"}],"title":"Lane Id","description":"Canonical lane id. Must match PlaybackTimeline.lanes[].id after platform normalization."},"order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Order","description":"Canonical event order after platform time/lane normalization."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor responsible for the segment. Inferred for legacy producers."},"start":{"type":"number","title":"Start"},"end":{"type":"number","title":"End"},"label":{"type":"string","title":"Label"},"turn_index":{"type":"integer","title":"Turn Index","description":"The segment's turn: its index in the response's ``turns`` on\n``GET /conversations/{conversation_id}``, the call-detail row the timeline was built from on\n``GET /calls/{call_id}``, or -1 when no turn owns it (a silence, a barge-in)."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the segment's turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on segments no\nexchange owns."},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eot Confidence"},"audio_window_start":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window Start"},"audio_window_end":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window End"},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Render Ms"},"audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Ttfb Ms"},"e2e_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"E2E Ttfb Ms"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"parent_call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Call Id"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"from_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From State"},"to_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"To State"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"}},"type":"object","required":["type","lane","start","end","label","turn_index"],"title":"TimelineSegment"},"TimelineActor":{"properties":{"kind":{"type":"string","enum":["agent","human","operator","system","tool"],"title":"Kind"},"role":{"type":"string","enum":["agent","caller","operator","runtime","state","tool"],"title":"Role"},"label":{"type":"string","title":"Label"},"participant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Id"}},"type":"object","required":["kind","role","label"],"title":"TimelineActor"},"RunManifest":{"properties":{"agent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Id"},"agent_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version","description":"The agent version number the session loaded."},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version","description":"The context graph version number the session loaded. Null, with ``context_graph_id``, on a run of a direct\nprogram, which loads no graph."},"program_kind":{"anyOf":[{"type":"string","enum":["workflow","direct"]},{"type":"null"}],"title":"Program Kind","description":"What the session ran: ``workflow``, its service's context graph, or ``direct``, its agent version's own\nprompt and tools. Null on a run recorded before programs and on one whose engine failed to load."},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON of the direct program the session ran: its authored prompt as saved and\nits tool specs. Null on a workflow run, which its graph version identifies."},"version_set":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The service version set the session resolved its versions and models through, e.g. ``release``."},"platform_config_fingerprint":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the agent and graph version ids, the LLM model and, when the service pins dynamic\nbehaviors, each pinned set's id and version: one value per config generation."},"service_config_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON (keys sorted, no whitespace, non-ASCII escaped) of the whole service\nconfig the session received: the service, its agent and graph versions and the behaviors its version set\npins. Any edit to that config moves it, where the fingerprint follows only the versions, the model and the\npins, so two runs that record the same digest received the same config. Null when the session loaded none."},"image_sha":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The build the session ran on: the commit the agent-engine image was built from."},"runtime_release_id":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The runtime release of the pod the session ran on."},"llm_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that wrote the agent's replies: the engage model, or the realtime model on gpt_realtime."},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature","description":"The sampling temperature the reply requests set. Null where they set none and the model's own\ndefault applies: every voice call, and a text run on a model family that takes none. On a\nreasoning model it rides only the requests that carry tools."},"engage_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates the reply prompt renders from. Null on gpt_realtime, whose\ninstructions aren't rendered from them."},"rendered_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"SHA256 of the opening rendered instructions, without normalization."},"prompt_renderer":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Renderer that produced the recorded instructions."},"prompt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Model identifier submitted with these instructions; aliases are not resolved snapshots."},"navigation_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that chose each context-graph transition. Null on gpt_realtime, which doesn't navigate."},"navigation_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates each navigation decision renders from. Null on gpt_realtime."},"dynamic_behavior_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the template and fixed text each dynamic behavior decision renders from. Null on\ngpt_realtime, which runs no dynamic behavior, and when the service pins no enabled one."},"decider_kind":{"anyOf":[{"$ref":"#/components/schemas/DeciderKind"},{"type":"null"}],"description":"How the session's region decides: ``decisions``, OpenAI Decisions through the region's gateway.\nNavigation and the reply checks both decide through it."},"stt_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The speech-to-text vendor the call ran on: the one it opened with, or the one it failed over\nto. Null on a text run."},"stt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The vendor that voiced the call's replies. Null on a text run."},"tts_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_language":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The language the call's voice spoke: the one it opened in, or the caller's language once an\nin-house call switched to it. ``multilingual`` on a gpt_realtime call left to answer in the\ncaller's language. Null on a text run."},"emergency_floor_enforced":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Emergency Floor Enforced","description":"Whether the medical-emergency floor acted on what it caught, rather than only counting it."},"effect_shadow":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Effect Shadow","description":"Whether an in-house call also recorded each turn as effects, in shadow. Null off in-house voice."},"cooperative_stop":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cooperative Stop","description":"Whether an in-house call's teardown let its session stop on its own before cancelling it.\nNull off in-house voice."}},"type":"object","title":"RunManifest","description":"The configuration a run executed with: as its session started, and as it stood after\nany change the run made mid-way.\n\nA field is null when the session had nothing to record for it: a text run has no\nspeech models, and a gpt_realtime call whose engine failed to load has no agent or\ngraph version. Nothing here is read back from the service's current configuration."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DeciderKind":{"type":"string","const":"decisions"}}}}
```

## The ConversationStatusTransitionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationStatusTransitionRequest":{"properties":{"status":{"type":"string","enum":["completed","closed"],"title":"Status"},"reason":{"type":"string","maxLength":64,"minLength":1,"title":"Reason","description":"Low-cardinality transition tag (e.g. hsm_terminal, use_case_rebind) recorded on the audit event and the conversation world event."},"completion":{"anyOf":[{"$ref":"#/components/schemas/ConversationCompletion"},{"type":"null"}],"description":"How the session that ended the conversation finished, written on the row with the status. Omitted when no session ended it (a use-case rebind retirement)."}},"type":"object","required":["status","reason"],"title":"ConversationStatusTransitionRequest"},"ConversationCompletion":{"properties":{"completion_reason":{"type":"string","enum":["completed","silence_hangup","abandoned","escalated","transferred","timeout","error","voicemail","no_answer","caller_hangup","forwarded","terminal_state","warm_transfer_completed","no_inbound_audio","cancelled","closed"],"title":"Completion Reason","description":"Canonical completion reason of the session that ended the conversation."},"final_state":{"$ref":"#/components/schemas/NameString","description":"Context-graph state the session ended in."},"ended_at":{"type":"string","format":"date-time","title":"Ended At","description":"When that session ended: the ended_at its session.ended world event carries."}},"type":"object","required":["completion_reason","final_state","ended_at"],"title":"ConversationCompletion","description":"How the session that ended a text conversation finished."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ConversationStatusTransitionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationStatusTransitionResponse":{"properties":{"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id"},"status":{"type":"string","enum":["completed","closed"],"title":"Status"}},"type":"object","required":["conversation_id","status"],"title":"ConversationStatusTransitionResponse"}}}}
```

## The ConversationSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationSummary":{"properties":{"turn_count":{"type":"integer","title":"Turn Count","description":"Total turn count for the call","default":0},"states_visited_count":{"type":"integer","title":"States Visited Count","description":"Number of states visited (including repeats)","default":0},"unique_states":{"type":"integer","title":"Unique States","description":"Number of distinct states visited","default":0},"loop_count":{"type":"integer","title":"Loop Count","description":"Number of detected state loops","default":0},"barge_in_count":{"type":"integer","title":"Barge In Count","description":"Number of caller interruptions","default":0}},"type":"object","title":"ConversationSummary","description":"Conversation flow metrics.\n\nFree-form residual on the raw ``conversation_summary`` JSONB:\n``text_intelligence: dict`` (text-channel intelligence\nsub-payload), and on the simulation path ``score``,\n``score_rationale``, ``terminal_reached``, ``states_visited``.\nOlder simulation rows also carry ``transcript_text: str`` (PHI)\nand ``tool_calls: list``. Not exposed via this typed shape."}}}}
```

## The ConversationTag object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationTag":{"properties":{"key":{"type":"string","maxLength":64,"minLength":1,"title":"Key"},"value":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Value","description":"Null for a bare label."}},"type":"object","required":["key"],"title":"ConversationTag"}}}}
```

## The ConversationTagsPatch object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationTagsPatch":{"properties":{"updates":{"items":{"$ref":"#/components/schemas/ConversationTag"},"type":"array","maxItems":20,"title":"Updates","description":"Tags to set: a key not yet on the conversation is added, and one that is has its value replaced."},"deletes":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":20,"title":"Deletes","description":"Keys to remove. A key the conversation does not carry is ignored."}},"type":"object","title":"ConversationTagsPatch"},"ConversationTag":{"properties":{"key":{"type":"string","maxLength":64,"minLength":1,"title":"Key"},"value":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Value","description":"Null for a bare label."}},"type":"object","required":["key"],"title":"ConversationTag"}}}}
```

## The ConversationTagsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationTagsResponse":{"properties":{"tags":{"items":{"$ref":"#/components/schemas/ConversationTag"},"type":"array","title":"Tags"}},"type":"object","required":["tags"],"title":"ConversationTagsResponse"},"ConversationTag":{"properties":{"key":{"type":"string","maxLength":64,"minLength":1,"title":"Key"},"value":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Value","description":"Null for a bare label."}},"type":"object","required":["key"],"title":"ConversationTag"}}}}
```

## The ConversationThreadRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationThreadRequest":{"properties":{"channel_kind":{"$ref":"#/components/schemas/ChannelKind"},"provider":{"$ref":"#/components/schemas/ProviderType"},"provider_thread_id":{"type":"string","maxLength":512,"minLength":1,"title":"Provider Thread Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"context":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"}]},"type":"object","title":"Context"}},"type":"object","required":["channel_kind","provider","provider_thread_id"],"title":"ConversationThreadRequest"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"ProviderType":{"type":"string","enum":["twilio","websocket","ses","sendblue","meta"],"title":"ProviderType","description":"Messaging provider that implements a channel.\n\nMultiple providers may serve the same ChannelKind."}}}}
```

## The ConversationThreadResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationThreadResponse":{"properties":{"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"channel_kind":{"$ref":"#/components/schemas/ChannelKind"},"provider":{"$ref":"#/components/schemas/ProviderType"},"provider_thread_id":{"type":"string","maxLength":512,"minLength":1,"title":"Provider Thread Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"status":{"type":"string","const":"active","title":"Status"},"created_at":{"type":"number","title":"Created At"},"created":{"type":"boolean","title":"Created"},"turn_count":{"type":"integer","minimum":0,"title":"Turn Count","default":0}},"type":"object","required":["conversation_id","workspace_id","channel_kind","provider","provider_thread_id","status","created_at","created"],"title":"ConversationThreadResponse"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"ProviderType":{"type":"string","enum":["twilio","websocket","ses","sendblue","meta"],"title":"ProviderType","description":"Messaging provider that implements a channel.\n\nMultiple providers may serve the same ChannelKind."}}}}
```

## The ConversationTimeline object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationTimeline":{"properties":{"turns":{"items":{"$ref":"#/components/schemas/TurnTimeline"},"type":"array","title":"Turns","description":"One entry per message whose speech has a recorded start and end: ``seek_to`` and ``active_start`` are where it starts and ``active_end`` where it ends, in seconds from the start of the recording."},"segments":{"items":{"$ref":"#/components/schemas/TimelineSegment"},"type":"array","title":"Segments","description":"Each placed line's speech (``caller_speech``, ``agent_speech``, ``filler``, or ``interrupted_speech`` for a reply the caller cut off; a filler stays ``filler`` when cut off, and its turn's ``filler_type`` and ``interrupted`` say both) and each ``processing_gap``: the wait from a user message's end to the first reply after it, when that reply started once the user had stopped. A line already playing when the user started answers an earlier message. Later lines start no wait: the caller had heard the agent, and an agent line's end is when its audio was sent, so the time after it isn't measured. A gap's ``e2e_ttfb_ms`` is the wait the caller heard, to the first filler that started after their line or to the reply. A wait is placed only where the user message, the reply and every line that played between them have a start and an end, so every gap ends at a line in ``turns``. Ordered by start, then end."},"avg_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Processing Gap Ms","description":"Mean of the placed processing gaps, in ms. Null when there are none."},"max_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Max Processing Gap Ms","description":"Longest placed processing gap, in ms. Null when there are none."},"avg_perceived_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Perceived Latency Ms","description":"Mean of the placed gaps' ``e2e_ttfb_ms``. Null when there are none."}},"type":"object","required":["turns","segments"],"title":"ConversationTimeline","description":"Where a voice call's lines sit in its recording, and the waits between them."},"TurnTimeline":{"properties":{"turn_index":{"type":"integer","title":"Turn Index","description":"The turn: its index in the response's ``turns`` on ``GET /conversations/{conversation_id}``,\nthe call-detail row the timeline was built from on ``GET /calls/{call_id}``."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on a turn\nbefore the first exchange."},"seek_to":{"type":"number","title":"Seek To"},"active_start":{"type":"number","title":"Active Start"},"active_end":{"type":"number","title":"Active End"}},"type":"object","required":["turn_index","seek_to","active_start","active_end"],"title":"TurnTimeline"},"TimelineSegment":{"properties":{"type":{"type":"string","enum":["agent_speech","barge_in","caller_speech","filler","filler_hesitation","filler_nav","greeting","interrupted_speech","processing_gap","silence","silence_check","state_transition","tool_call"],"title":"Type"},"lane":{"type":"string","enum":["agent","caller","events","operator","system","tool"],"title":"Lane"},"track":{"anyOf":[{"type":"string","enum":["agent","caller","operator","system","tool"]},{"type":"null"}],"title":"Track","description":"Actor-semantic display track for the segment. Inferred for legacy producers."},"lane_id":{"anyOf":[{"type":"string","maxLength":160,"minLength":1},{"type":"null"}],"title":"Lane Id","description":"Canonical lane id. Must match PlaybackTimeline.lanes[].id after platform normalization."},"order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Order","description":"Canonical event order after platform time/lane normalization."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor responsible for the segment. Inferred for legacy producers."},"start":{"type":"number","title":"Start"},"end":{"type":"number","title":"End"},"label":{"type":"string","title":"Label"},"turn_index":{"type":"integer","title":"Turn Index","description":"The segment's turn: its index in the response's ``turns`` on\n``GET /conversations/{conversation_id}``, the call-detail row the timeline was built from on\n``GET /calls/{call_id}``, or -1 when no turn owns it (a silence, a barge-in)."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the segment's turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on segments no\nexchange owns."},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eot Confidence"},"audio_window_start":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window Start"},"audio_window_end":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window End"},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Render Ms"},"audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Ttfb Ms"},"e2e_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"E2E Ttfb Ms"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"parent_call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Call Id"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"from_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From State"},"to_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"To State"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"}},"type":"object","required":["type","lane","start","end","label","turn_index"],"title":"TimelineSegment"},"TimelineActor":{"properties":{"kind":{"type":"string","enum":["agent","human","operator","system","tool"],"title":"Kind"},"role":{"type":"string","enum":["agent","caller","operator","runtime","state","tool"],"title":"Role"},"label":{"type":"string","title":"Label"},"participant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Id"}},"type":"object","required":["kind","role","label"],"title":"TimelineActor"}}}}
```

## The ConversationToolCallDetail object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"call_id":{"type":"string","title":"Call Id"},"input":{"additionalProperties":true,"type":"object","title":"Input"},"result":{"type":"string","title":"Result","default":""},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded","description":"Whether the tool call succeeded. Null when no result was recorded, for example while it still runs.","default":true},"duration_ms":{"anyOf":[{"type":"number","maximum":3600000,"minimum":0},{"type":"null"}],"title":"Duration Ms","description":"Wall-clock tool execution time in milliseconds, measured at the engage_step call site. Omitted (null) on legacy turns that did not capture timing."},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Failure detail recorded for the tool call when ``succeeded`` is false. Null on successful calls or when no message was captured."}},"type":"object","required":["tool_name","call_id"],"title":"ConversationToolCallDetail"}}}}
```

## The ConversationTurn object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationTurn":{"properties":{"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"Stable identifier of the user exchange this message belongs to, derived deterministically from (conversation_id, turn_index) — identical across ``POST /turns`` responses and re-reads of the conversation history. User and agent messages from the same exchange share this value. Null on messages that precede the first user turn (proactive greetings, channel-event preludes)."},"turn_index":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Turn Index","description":"Zero-based ordinal of the user exchange this message belongs to (0 = first user turn). Derived server-side from the conversation's user-turn count — never stored. Null exactly when ``turn_id`` is null."},"engine_turn_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Engine Turn Id","description":"The agent engine's id for the turn this message opens (a user message) or answers (an agent message). One exchange can hold several engine turns, such as a tool call and the reply to its result. Null when no engine turn is recorded on the message: a filler line, a text reply, a channel event, or an older conversation that didn't record it."},"role":{"type":"string","enum":["agent","user","system"],"title":"Role"},"text":{"type":"string","title":"Text"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State","description":"The context-graph state of the conversation at this message: for a user message, the state it arrived in; for an agent message, the state after the turn's transitions. Null when the record names no state."},"speech_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speech Start Ms","description":"Where this message's speech starts in the call's recording, in milliseconds from the start of the recording. A user message starts when the caller began speaking; an agent message when its first audio was sent, slightly before the caller heard it. Null when no position was recorded: text messages, agent lines that never played, and older calls that didn't record one."},"speech_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speech End Ms","description":"Where this message's speech ends in the call's recording, in milliseconds from the start of the recording: when the caller stopped speaking, or when the agent line's last audio was sent. Null when no position was recorded, such as on a caller's line the call ended during."},"filler_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Type","description":"On an agent line the agent spoke while working on the reply, the kind of filler it was, such as ``receipt``, ``empathy`` or ``working``. Null on a reply and on user and system messages."},"interrupted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Interrupted","description":"On an agent line in a call, whether the caller cut it off, before or while it played. Null on user, system and text messages, and where the record doesn't say."},"channel":{"anyOf":[{"$ref":"#/components/schemas/ChannelKind"},{"type":"null"}],"description":"Channel this turn occurred on. A conversation that switched channels has a self-describing per-turn history; null on turns written before per-turn attribution or on channel-less internal turns."},"content":{"items":{"$ref":"#/components/schemas/ContentPartPayload"},"type":"array","title":"Content","default":[]},"tool_calls":{"items":{"$ref":"#/components/schemas/ConversationToolCallDetail"},"type":"array","title":"Tool Calls","description":"Tool calls executed during this (agent) turn. Populated only when the request opts in via ``include_tool_calls=true``; empty otherwise and on turns that did not invoke tools.","default":[]},"artifacts":{"items":{"$ref":"#/components/schemas/ClientArtifact"},"type":"array","title":"Artifacts","description":"Validated client-safe outputs produced during this agent turn.","default":[]},"selected_action_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action Description","description":"Description of the context-graph action selected for this turn. Null means no action was selected or no selected action was recorded."},"state_transition":{"anyOf":[{"$ref":"#/components/schemas/ConversationTurnStateTransition"},{"type":"null"}],"description":"Context-graph state transition that occurred during this turn. Null means no transition took place or no transition was recorded. Deprecated: use state_transitions instead. If multiple transitions were recorded, this field reports the first source state and final destination state, with no exit condition.","deprecated":true},"state_transitions":{"items":{"$ref":"#/components/schemas/ConversationTurnStateTransition"},"type":"array","title":"State Transitions","description":"Ordered context-graph state transitions that occurred during this turn.","default":[]},"available_actions":{"items":{"$ref":"#/components/schemas/ConversationTurnAvailableAction"},"type":"array","title":"Available Actions","description":"Action choices available in the turn's resolved context-graph state. Empty when actions cannot be resolved or the resolved state is not an action state.","default":[]},"dynamic_behavior":{"anyOf":[{"$ref":"#/components/schemas/AppliedBehavior"},{"type":"null"}],"description":"On an agent message, the dynamic behavior its reply was rendered with. Null when none was in force, and on user and system messages."}},"type":"object","required":["role","text"],"title":"ConversationTurn"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"ContentPartPayload":{"properties":{"type":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9._-]*$","title":"Type","default":"text"},"text":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}],"title":"Text"},"url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Url"},"media_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Media Type"},"provider_id":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider Id"},"metadata":{"additionalProperties":true,"type":"object","maxProperties":50,"title":"Metadata"}},"type":"object","title":"ContentPartPayload","description":"HTTP/WebSocket shape for a modality-neutral conversation content part."},"ConversationToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"call_id":{"type":"string","title":"Call Id"},"input":{"additionalProperties":true,"type":"object","title":"Input"},"result":{"type":"string","title":"Result","default":""},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded","description":"Whether the tool call succeeded. Null when no result was recorded, for example while it still runs.","default":true},"duration_ms":{"anyOf":[{"type":"number","maximum":3600000,"minimum":0},{"type":"null"}],"title":"Duration Ms","description":"Wall-clock tool execution time in milliseconds, measured at the engage_step call site. Omitted (null) on legacy turns that did not capture timing."},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Failure detail recorded for the tool call when ``succeeded`` is false. Null on successful calls or when no message was captured."}},"type":"object","required":["tool_name","call_id"],"title":"ConversationToolCallDetail"},"ClientArtifact":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"payload":{"$ref":"#/components/schemas/ClientArtifactPayload"}},"type":"object","required":["type","schema_version","payload"],"title":"ClientArtifact","description":"A versioned JSON payload that a client can render as a product component."},"ClientArtifactPayload":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"}]},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]},"ConversationTurnStateTransition":{"properties":{"from":{"type":"string","title":"From","description":"Source context-graph state before the turn's state transition."},"to":{"type":"string","title":"To","description":"Destination context-graph state after the turn's state transition."},"exit_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exit Condition","description":"The exit condition the agent took out of ``from``, as the context graph worded it when the hop was taken. Null on a hop out of an annotation state, which has no exit conditions, and on a hop recorded without one. Never read from the current graph."}},"type":"object","required":["from","to"],"title":"ConversationTurnStateTransition"},"ConversationTurnAvailableAction":{"properties":{"description":{"type":"string","title":"Description","description":"Human-readable description of an action available in the turn's state."}},"type":"object","required":["description"],"title":"ConversationTurnAvailableAction"},"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"}}}}
```

## The ConversationTurnAvailableAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationTurnAvailableAction":{"properties":{"description":{"type":"string","title":"Description","description":"Human-readable description of an action available in the turn's state."}},"type":"object","required":["description"],"title":"ConversationTurnAvailableAction"}}}}
```

## The ConversationTurnListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationTurnListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ConversationTurn"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"},"truncated":{"type":"boolean","title":"Truncated","description":"True when the conversation recorded more entries than one read takes (10,000), so the turns stop before the end of the conversation."}},"type":"object","required":["items","has_more","truncated"],"title":"ConversationTurnListResponse"},"ConversationTurn":{"properties":{"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"Stable identifier of the user exchange this message belongs to, derived deterministically from (conversation_id, turn_index) — identical across ``POST /turns`` responses and re-reads of the conversation history. User and agent messages from the same exchange share this value. Null on messages that precede the first user turn (proactive greetings, channel-event preludes)."},"turn_index":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Turn Index","description":"Zero-based ordinal of the user exchange this message belongs to (0 = first user turn). Derived server-side from the conversation's user-turn count — never stored. Null exactly when ``turn_id`` is null."},"engine_turn_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Engine Turn Id","description":"The agent engine's id for the turn this message opens (a user message) or answers (an agent message). One exchange can hold several engine turns, such as a tool call and the reply to its result. Null when no engine turn is recorded on the message: a filler line, a text reply, a channel event, or an older conversation that didn't record it."},"role":{"type":"string","enum":["agent","user","system"],"title":"Role"},"text":{"type":"string","title":"Text"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State","description":"The context-graph state of the conversation at this message: for a user message, the state it arrived in; for an agent message, the state after the turn's transitions. Null when the record names no state."},"speech_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speech Start Ms","description":"Where this message's speech starts in the call's recording, in milliseconds from the start of the recording. A user message starts when the caller began speaking; an agent message when its first audio was sent, slightly before the caller heard it. Null when no position was recorded: text messages, agent lines that never played, and older calls that didn't record one."},"speech_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speech End Ms","description":"Where this message's speech ends in the call's recording, in milliseconds from the start of the recording: when the caller stopped speaking, or when the agent line's last audio was sent. Null when no position was recorded, such as on a caller's line the call ended during."},"filler_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Type","description":"On an agent line the agent spoke while working on the reply, the kind of filler it was, such as ``receipt``, ``empathy`` or ``working``. Null on a reply and on user and system messages."},"interrupted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Interrupted","description":"On an agent line in a call, whether the caller cut it off, before or while it played. Null on user, system and text messages, and where the record doesn't say."},"channel":{"anyOf":[{"$ref":"#/components/schemas/ChannelKind"},{"type":"null"}],"description":"Channel this turn occurred on. A conversation that switched channels has a self-describing per-turn history; null on turns written before per-turn attribution or on channel-less internal turns."},"content":{"items":{"$ref":"#/components/schemas/ContentPartPayload"},"type":"array","title":"Content","default":[]},"tool_calls":{"items":{"$ref":"#/components/schemas/ConversationToolCallDetail"},"type":"array","title":"Tool Calls","description":"Tool calls executed during this (agent) turn. Populated only when the request opts in via ``include_tool_calls=true``; empty otherwise and on turns that did not invoke tools.","default":[]},"artifacts":{"items":{"$ref":"#/components/schemas/ClientArtifact"},"type":"array","title":"Artifacts","description":"Validated client-safe outputs produced during this agent turn.","default":[]},"selected_action_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action Description","description":"Description of the context-graph action selected for this turn. Null means no action was selected or no selected action was recorded."},"state_transition":{"anyOf":[{"$ref":"#/components/schemas/ConversationTurnStateTransition"},{"type":"null"}],"description":"Context-graph state transition that occurred during this turn. Null means no transition took place or no transition was recorded. Deprecated: use state_transitions instead. If multiple transitions were recorded, this field reports the first source state and final destination state, with no exit condition.","deprecated":true},"state_transitions":{"items":{"$ref":"#/components/schemas/ConversationTurnStateTransition"},"type":"array","title":"State Transitions","description":"Ordered context-graph state transitions that occurred during this turn.","default":[]},"available_actions":{"items":{"$ref":"#/components/schemas/ConversationTurnAvailableAction"},"type":"array","title":"Available Actions","description":"Action choices available in the turn's resolved context-graph state. Empty when actions cannot be resolved or the resolved state is not an action state.","default":[]},"dynamic_behavior":{"anyOf":[{"$ref":"#/components/schemas/AppliedBehavior"},{"type":"null"}],"description":"On an agent message, the dynamic behavior its reply was rendered with. Null when none was in force, and on user and system messages."}},"type":"object","required":["role","text"],"title":"ConversationTurn"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"ContentPartPayload":{"properties":{"type":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9._-]*$","title":"Type","default":"text"},"text":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}],"title":"Text"},"url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Url"},"media_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Media Type"},"provider_id":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider Id"},"metadata":{"additionalProperties":true,"type":"object","maxProperties":50,"title":"Metadata"}},"type":"object","title":"ContentPartPayload","description":"HTTP/WebSocket shape for a modality-neutral conversation content part."},"ConversationToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"call_id":{"type":"string","title":"Call Id"},"input":{"additionalProperties":true,"type":"object","title":"Input"},"result":{"type":"string","title":"Result","default":""},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded","description":"Whether the tool call succeeded. Null when no result was recorded, for example while it still runs.","default":true},"duration_ms":{"anyOf":[{"type":"number","maximum":3600000,"minimum":0},{"type":"null"}],"title":"Duration Ms","description":"Wall-clock tool execution time in milliseconds, measured at the engage_step call site. Omitted (null) on legacy turns that did not capture timing."},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Failure detail recorded for the tool call when ``succeeded`` is false. Null on successful calls or when no message was captured."}},"type":"object","required":["tool_name","call_id"],"title":"ConversationToolCallDetail"},"ClientArtifact":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"payload":{"$ref":"#/components/schemas/ClientArtifactPayload"}},"type":"object","required":["type","schema_version","payload"],"title":"ClientArtifact","description":"A versioned JSON payload that a client can render as a product component."},"ClientArtifactPayload":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"}]},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]},"ConversationTurnStateTransition":{"properties":{"from":{"type":"string","title":"From","description":"Source context-graph state before the turn's state transition."},"to":{"type":"string","title":"To","description":"Destination context-graph state after the turn's state transition."},"exit_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exit Condition","description":"The exit condition the agent took out of ``from``, as the context graph worded it when the hop was taken. Null on a hop out of an annotation state, which has no exit conditions, and on a hop recorded without one. Never read from the current graph."}},"type":"object","required":["from","to"],"title":"ConversationTurnStateTransition"},"ConversationTurnAvailableAction":{"properties":{"description":{"type":"string","title":"Description","description":"Human-readable description of an action available in the turn's state."}},"type":"object","required":["description"],"title":"ConversationTurnAvailableAction"},"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"}}}}
```

## The ConversationTurnStateTransition object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ConversationTurnStateTransition":{"properties":{"from":{"type":"string","title":"From","description":"Source context-graph state before the turn's state transition."},"to":{"type":"string","title":"To","description":"Destination context-graph state after the turn's state transition."},"exit_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exit Condition","description":"The exit condition the agent took out of ``from``, as the context graph worded it when the hop was taken. Null on a hop out of an annotation state, which has no exit conditions, and on a hop recorded without one. Never read from the current graph."}},"type":"object","required":["from","to"],"title":"ConversationTurnStateTransition"}}}}
```

## The CostModelsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CostModelsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"models":{"items":{"$ref":"#/components/schemas/ModelCost"},"type":"array","title":"Models"}},"type":"object","required":["workspace_id","period","calculation_run_id","models"],"title":"CostModelsResponse","description":"Cost grouped by model, returned for `group_by=model`."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"ModelCost":{"properties":{"model_id":{"type":"string","title":"Model Id"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Model priced subtotal rounded to cents; can be partial when is_priced is false. Null if none is priced."},"cost_share":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Share","description":"Model priced subtotal / all model priced subtotals in the selected scope, after any service filter.\nIncludes partial subtotals; null when this model has no priced cost or the denominator is zero."},"is_priced":{"type":"boolean","title":"Is Priced","description":"Whether every contributing usage row for this model is priced; false can coexist with a priced subtotal."},"unpriced_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unpriced Reason","description":"One reason contributing usage could not be priced; null when all usage is priced."},"applied_rates":{"items":{"$ref":"#/components/schemas/AppliedRate"},"type":"array","title":"Applied Rates","description":"Effective-date and context-band rates used for this model."}},"type":"object","required":["model_id","calculated_cost_usd","cost_share","is_priced","unpriced_reason","applied_rates"],"title":"ModelCost","description":"Cost and pricing status for one model."},"AppliedRate":{"properties":{"input_rate_effective_from":{"type":"string","format":"date","title":"Input Rate Effective From","description":"Inclusive first usage date for the input rate."},"input_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Input Rate Effective To","description":"Exclusive end usage date for the input rate; null means no end date."},"output_rate_effective_from":{"type":"string","format":"date","title":"Output Rate Effective From","description":"Inclusive first usage date for the output rate."},"output_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Output Rate Effective To","description":"Exclusive end usage date for the output rate; null means no end date."},"cached_rate_effective_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cached Rate Effective From","description":"Inclusive first usage date for the cached-input rate; null if no cached rate applied."},"cached_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cached Rate Effective To","description":"Exclusive end usage date for the cached-input rate; null if unbounded or no cached rate applied."},"min_input_tokens":{"type":"integer","title":"Min Input Tokens","description":"Inclusive lower bound on per-request context input tokens for the input-rate band."},"max_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Input Tokens","description":"Inclusive upper bound on per-request context input tokens; null means unbounded."},"input_per_million":{"type":"string","title":"Input Per Million","description":"USD per million uncached input tokens, as a decimal string."},"cached_input_per_million":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cached Input Per Million","description":"USD per million cached input tokens; null if no cached rate applied."},"output_per_million":{"type":"string","title":"Output Per Million","description":"USD per million output tokens, as a decimal string."}},"type":"object","required":["input_rate_effective_from","input_rate_effective_to","output_rate_effective_from","output_rate_effective_to","cached_rate_effective_from","cached_rate_effective_to","min_input_tokens","max_input_tokens","input_per_million","cached_input_per_million","output_per_million"],"title":"AppliedRate","description":"Rate record applied to this model during the requested period."}}}}
```

## The CostOverviewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CostOverviewResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"totals":{"$ref":"#/components/schemas/CostTotals"},"services":{"items":{"$ref":"#/components/schemas/ServiceCost"},"type":"array","title":"Services","description":"Services ordered by descending calculated cost."}},"type":"object","required":["workspace_id","period","calculation_run_id","totals","services"],"title":"CostOverviewResponse","description":"Cost overview returned when `group_by` is omitted."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"CostTotals":{"properties":{"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Priced subtotal rounded to cents; excludes unpriced usage. Zero for no usage, null if none can be priced."},"cost_per_conversation_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost Per Conversation Usd","description":"Priced linked cost divided by distinct priced linked conversations; cents, or null without a denominator."},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any usage in the period could not be priced."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens","description":"Tokens excluded from calculated cost because no rate applied."}},"type":"object","required":["calculated_cost_usd","cost_per_conversation_usd","has_unpriced_usage","unpriced_tokens"],"title":"CostTotals","description":"Workspace cost totals for the requested period."},"ServiceCost":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service identifier, or null for cost that could not be attributed."},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"This service's priced subtotal rounded to cents; excludes unpriced usage, null if none can be priced."},"cost_share":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Share","description":"Service priced subtotal / total priced cost in the selected scope, after any service filter.\nNull when the service has no priced cost or the denominator is zero or unavailable."}},"type":"object","required":["service_id","calculated_cost_usd","cost_share"],"title":"ServiceCost","description":"Cost attributed to one service."}}}}
```

## The CostResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CostResponse":{"anyOf":[{"$ref":"#/components/schemas/CostOverviewResponse"},{"$ref":"#/components/schemas/CostModelsResponse"}]},"CostOverviewResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"totals":{"$ref":"#/components/schemas/CostTotals"},"services":{"items":{"$ref":"#/components/schemas/ServiceCost"},"type":"array","title":"Services","description":"Services ordered by descending calculated cost."}},"type":"object","required":["workspace_id","period","calculation_run_id","totals","services"],"title":"CostOverviewResponse","description":"Cost overview returned when `group_by` is omitted."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"CostTotals":{"properties":{"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Priced subtotal rounded to cents; excludes unpriced usage. Zero for no usage, null if none can be priced."},"cost_per_conversation_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost Per Conversation Usd","description":"Priced linked cost divided by distinct priced linked conversations; cents, or null without a denominator."},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any usage in the period could not be priced."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens","description":"Tokens excluded from calculated cost because no rate applied."}},"type":"object","required":["calculated_cost_usd","cost_per_conversation_usd","has_unpriced_usage","unpriced_tokens"],"title":"CostTotals","description":"Workspace cost totals for the requested period."},"ServiceCost":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service identifier, or null for cost that could not be attributed."},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"This service's priced subtotal rounded to cents; excludes unpriced usage, null if none can be priced."},"cost_share":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Share","description":"Service priced subtotal / total priced cost in the selected scope, after any service filter.\nNull when the service has no priced cost or the denominator is zero or unavailable."}},"type":"object","required":["service_id","calculated_cost_usd","cost_share"],"title":"ServiceCost","description":"Cost attributed to one service."},"CostModelsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"models":{"items":{"$ref":"#/components/schemas/ModelCost"},"type":"array","title":"Models"}},"type":"object","required":["workspace_id","period","calculation_run_id","models"],"title":"CostModelsResponse","description":"Cost grouped by model, returned for `group_by=model`."},"ModelCost":{"properties":{"model_id":{"type":"string","title":"Model Id"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Model priced subtotal rounded to cents; can be partial when is_priced is false. Null if none is priced."},"cost_share":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Share","description":"Model priced subtotal / all model priced subtotals in the selected scope, after any service filter.\nIncludes partial subtotals; null when this model has no priced cost or the denominator is zero."},"is_priced":{"type":"boolean","title":"Is Priced","description":"Whether every contributing usage row for this model is priced; false can coexist with a priced subtotal."},"unpriced_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unpriced Reason","description":"One reason contributing usage could not be priced; null when all usage is priced."},"applied_rates":{"items":{"$ref":"#/components/schemas/AppliedRate"},"type":"array","title":"Applied Rates","description":"Effective-date and context-band rates used for this model."}},"type":"object","required":["model_id","calculated_cost_usd","cost_share","is_priced","unpriced_reason","applied_rates"],"title":"ModelCost","description":"Cost and pricing status for one model."},"AppliedRate":{"properties":{"input_rate_effective_from":{"type":"string","format":"date","title":"Input Rate Effective From","description":"Inclusive first usage date for the input rate."},"input_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Input Rate Effective To","description":"Exclusive end usage date for the input rate; null means no end date."},"output_rate_effective_from":{"type":"string","format":"date","title":"Output Rate Effective From","description":"Inclusive first usage date for the output rate."},"output_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Output Rate Effective To","description":"Exclusive end usage date for the output rate; null means no end date."},"cached_rate_effective_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cached Rate Effective From","description":"Inclusive first usage date for the cached-input rate; null if no cached rate applied."},"cached_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cached Rate Effective To","description":"Exclusive end usage date for the cached-input rate; null if unbounded or no cached rate applied."},"min_input_tokens":{"type":"integer","title":"Min Input Tokens","description":"Inclusive lower bound on per-request context input tokens for the input-rate band."},"max_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Input Tokens","description":"Inclusive upper bound on per-request context input tokens; null means unbounded."},"input_per_million":{"type":"string","title":"Input Per Million","description":"USD per million uncached input tokens, as a decimal string."},"cached_input_per_million":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cached Input Per Million","description":"USD per million cached input tokens; null if no cached rate applied."},"output_per_million":{"type":"string","title":"Output Per Million","description":"USD per million output tokens, as a decimal string."}},"type":"object","required":["input_rate_effective_from","input_rate_effective_to","output_rate_effective_from","output_rate_effective_to","cached_rate_effective_from","cached_rate_effective_to","min_input_tokens","max_input_tokens","input_per_million","cached_input_per_million","output_per_million"],"title":"AppliedRate","description":"Rate record applied to this model during the requested period."}}}}
```

## The CostTotals object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CostTotals":{"properties":{"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Priced subtotal rounded to cents; excludes unpriced usage. Zero for no usage, null if none can be priced."},"cost_per_conversation_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost Per Conversation Usd","description":"Priced linked cost divided by distinct priced linked conversations; cents, or null without a denominator."},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any usage in the period could not be priced."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens","description":"Tokens excluded from calculated cost because no rate applied."}},"type":"object","required":["calculated_cost_usd","cost_per_conversation_usd","has_unpriced_usage","unpriced_tokens"],"title":"CostTotals","description":"Workspace cost totals for the requested period."}}}}
```

## The Counterfactual object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Counterfactual":{"properties":{"timestamp_seconds":{"anyOf":[{"type":"number","maximum":86400,"minimum":0},{"type":"null"}],"title":"Timestamp Seconds","description":"When the alternative action was available (seconds)"},"actual":{"type":"string","maxLength":2000,"minLength":1,"title":"Actual","description":"What the agent actually did"},"alternative":{"type":"string","maxLength":2000,"minLength":1,"title":"Alternative","description":"What it could have done instead"},"predicted_impact":{"type":"string","maxLength":2000,"minLength":1,"title":"Predicted Impact","description":"How the call would have gone differently"}},"type":"object","required":["actual","alternative","predicted_impact"],"title":"Counterfactual","description":"An alternative action that would have meaningfully changed the call outcome."}}}}
```

## The CoverageEdge object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CoverageEdge":{"properties":{"source":{"type":"string","title":"Source"},"target":{"type":"string","title":"Target"},"type":{"type":"string","enum":["transition","self_loop"],"title":"Type"},"theoretical":{"type":"boolean","title":"Theoretical","description":"The transition is an exit condition in the service's context graph."},"observed":{"type":"boolean","title":"Observed"},"frequency":{"type":"integer","title":"Frequency"},"first_seen_turn":{"type":"integer","title":"First Seen Turn","description":"Index of the first turn that took this edge, or -1."}},"type":"object","required":["source","target","type","theoretical","observed","frequency","first_seen_turn"],"title":"CoverageEdge"}}}}
```

## The CoverageFork object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CoverageFork":{"properties":{"parent_session_id":{"type":"string","title":"Parent Session Id"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index"},"children":{"items":{"type":"string"},"type":"array","title":"Children"}},"type":"object","required":["parent_session_id","fork_turn_index","children"],"title":"CoverageFork"}}}}
```

## The CoveragePath object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CoveragePath":{"properties":{"trajectory":{"items":{"type":"string"},"type":"array","title":"Trajectory","description":"The states the sessions moved through, in order."},"session_count":{"type":"integer","title":"Session Count"},"session_ids":{"items":{"type":"string"},"type":"array","title":"Session Ids"},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"average_turns":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Turns"},"is_complete":{"type":"boolean","title":"Is Complete","description":"At least one session on the path reached a terminal state."}},"type":"object","required":["trajectory","session_count","session_ids","average_score","average_turns","is_complete"],"title":"CoveragePath"}}}}
```

## The CoverageSession object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CoverageSession":{"properties":{"metric_status":{"anyOf":[{"type":"string","enum":["pending","available","unavailable"]},{"type":"null"}],"title":"Metric Status"},"metric_result_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Metric Result Count"},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"immediate_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Immediate Score","description":"The session's score, the same value as score."},"immediate_score_rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Immediate Score Rationale"},"session_id":{"type":"string","title":"Session Id"},"parent_session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Session Id"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"total_turns":{"type":"integer","title":"Total Turns"},"terminal_reached":{"type":"boolean","title":"Terminal Reached"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["session_id","parent_session_id","fork_turn_index","tags","total_turns","terminal_reached","score","created_at"],"title":"CoverageSession"}}}}
```

## The CoverageStateNode object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CoverageStateNode":{"properties":{"id":{"type":"string","title":"Id","description":"The state name."},"type":{"type":"string","title":"Type","description":"The state type in the context graph, or `unknown` for a state seen only in turns."},"theoretical":{"type":"boolean","title":"Theoretical","description":"The state is in the service's context graph."},"observed":{"type":"boolean","title":"Observed","description":"At least one stored turn started in this state."},"turn_count":{"type":"integer","title":"Turn Count"},"session_count":{"type":"integer","title":"Session Count"},"self_loop_count":{"type":"integer","title":"Self Loop Count"},"transition_out_count":{"type":"integer","title":"Transition Out Count"},"pass_count":{"type":"integer","title":"Pass Count"},"fail_count":{"type":"integer","title":"Fail Count"},"unknown_count":{"type":"integer","title":"Unknown Count"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"first_seen_turn":{"type":"integer","title":"First Seen Turn","description":"Index of the first turn that started in this state, or -1."},"tools_used":{"items":{"type":"string"},"type":"array","title":"Tools Used"},"average_empathy_tier":{"type":"number","title":"Average Empathy Tier"},"average_engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Engine Ms"},"average_nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Nav Ms"}},"type":"object","required":["id","type","theoretical","observed","turn_count","session_count","self_loop_count","transition_out_count","pass_count","fail_count","unknown_count","is_terminal","first_seen_turn","tools_used","average_empathy_tier","average_engine_ms","average_nav_ms"],"title":"CoverageStateNode"}}}}
```

## The CoverageTree object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CoverageTree":{"properties":{"root_sessions":{"items":{"type":"string"},"type":"array","title":"Root Sessions"},"forks":{"items":{"$ref":"#/components/schemas/CoverageFork"},"type":"array","title":"Forks"}},"type":"object","required":["root_sessions","forks"],"title":"CoverageTree"},"CoverageFork":{"properties":{"parent_session_id":{"type":"string","title":"Parent Session Id"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index"},"children":{"items":{"type":"string"},"type":"array","title":"Children"}},"type":"object","required":["parent_session_id","fork_turn_index","children"],"title":"CoverageFork"}}}}
```

## The CoverageTurn object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CoverageTurn":{"properties":{"session_id":{"type":"string","title":"Session Id"},"turn_index":{"type":"integer","title":"Turn Index"},"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"caller_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Text"},"agent_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Text"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called"},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details"},"empathy_tier":{"type":"integer","title":"Empathy Tier"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"global_index":{"type":"integer","title":"Global Index"}},"type":"object","required":["session_id","turn_index","state_before","state_after","state_changed","caller_text","agent_text","tools_called","tool_call_details","empathy_tier","is_terminal","created_at","global_index"],"title":"CoverageTurn"},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."}}}}
```

## The CreateAgentRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateAgentRequest":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"description":{"$ref":"#/components/schemas/DescriptionString","default":""}},"type":"object","required":["name"],"title":"CreateAgentRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The CreateAgentVersionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateAgentVersionRequest":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"initials":{"type":"string","maxLength":10,"title":"Initials","default":""},"identity":{"$ref":"#/components/schemas/Identity"},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/VoiceConfig"},{"type":"null"}]},"background":{"$ref":"#/components/schemas/BackgroundString","default":""},"behaviors":{"items":{"type":"string","maxLength":2000},"type":"array","maxItems":200,"title":"Behaviors"},"communication_patterns":{"items":{"type":"string","maxLength":2000},"type":"array","maxItems":200,"title":"Communication Patterns"},"program":{"$ref":"#/components/schemas/AgentProgram-Input","description":"What the version runs. Omitted: its service's context graph. A direct program is the version's own\nauthored prompt and tool grants, and a service that pins the version runs it without loading a graph."}},"type":"object","required":["name","identity"],"title":"CreateAgentVersionRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"Identity":{"properties":{"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"developed_by":{"type":"string","title":"Developed By"},"default_spoken_language":{"type":"string","title":"Default Spoken Language"},"relationship_to_developer":{"$ref":"#/components/schemas/RelationshipToDeveloper"}},"type":"object","required":["name","role","developed_by","default_spoken_language"],"title":"Identity"},"RelationshipToDeveloper":{"properties":{"ownership":{"type":"string","title":"Ownership"},"type":{"type":"string","title":"Type"},"conversation_visibility":{"type":"string","title":"Conversation Visibility"},"thought_visibility":{"type":"string","title":"Thought Visibility"}},"type":"object","required":["ownership","type","conversation_visibility","thought_visibility"],"title":"RelationshipToDeveloper"},"VoiceConfig":{"properties":{"voice_id":{"type":"string","title":"Voice Id"},"stability":{"type":"number","title":"Stability","default":0},"similarity_boost":{"type":"number","title":"Similarity Boost","default":0},"style":{"type":"number","title":"Style","default":0},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"}},"type":"object","required":["voice_id"],"title":"VoiceConfig"},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"BackgroundString":{"type":"string","maxLength":10000},"AgentProgram-Input":{"oneOf":[{"$ref":"#/components/schemas/WorkflowProgram"},{"$ref":"#/components/schemas/DirectProgram-Input"}],"discriminator":{"propertyName":"kind","mapping":{"direct":"#/components/schemas/DirectProgram-Input","workflow":"#/components/schemas/WorkflowProgram"}}},"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."},"DirectProgram-Input":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The CreateApiKeyRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateApiKeyRequest":{"properties":{"name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"duration_days":{"type":"integer","maximum":90,"minimum":1,"title":"Duration Days"},"role":{"$ref":"#/components/schemas/PlatformRole","default":"member"},"permissions":{"items":{"type":"string"},"type":"array","maxItems":128,"title":"Permissions","description":"Permission names. Max 128 entries; each entry up to 128 chars."},"non_production":{"type":"boolean","title":"Non Production","description":"Create a test key. Conversations, sessions and outbound calls made with it are stored with source `test`: analytics, production evaluations and billing leave them out, and their tools run in simulation mode, returning a dry-run result instead of reaching an integration. The setting is made here and never changes; rotating the key keeps it. Requires `Workspace.update` (admin or owner).","default":false}},"type":"object","required":["duration_days"],"title":"CreateApiKeyRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"PlatformRole":{"type":"string","enum":["owner","admin","member","operator","viewer"],"title":"PlatformRole"}}}}
```

## The CreateApiKeyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateApiKeyResponse":{"properties":{"key_id":{"type":"string","title":"Key Id"},"api_key":{"type":"string","title":"Api Key"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"role":{"type":"string","title":"Role"},"permissions":{"items":{"type":"string"},"type":"array","title":"Permissions"},"non_production":{"type":"boolean","title":"Non Production","description":"True for a test key: what it creates is stored with source `test`."},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"created_by_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Entity Id"},"created_by_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Credential Id"}},"type":"object","required":["key_id","api_key","name","role","permissions","non_production","expires_at","created_by_entity_id","created_by_credential_id"],"title":"CreateApiKeyResponse"}}}}
```

## The CreateContextGraphRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateContextGraphRequest":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"description":{"$ref":"#/components/schemas/DescriptionString","default":""}},"type":"object","required":["name"],"title":"CreateContextGraphRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The CreateContextGraphVersionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateContextGraphVersionRequest":{"properties":{"description":{"$ref":"#/components/schemas/DescriptionString","default":""},"states":{"items":{"$ref":"#/components/schemas/ContextGraphState-Input"},"type":"array","title":"States"},"new_user_initial_state":{"type":"string","title":"New User Initial State"},"returning_user_initial_state":{"type":"string","title":"Returning User Initial State"},"terminal_state":{"type":"string","title":"Terminal State","description":"The state that completes the conversation once navigation reaches it. Left out, the graph has none, and the\ncaller or the agent ends the call.","default":""},"global_intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Intra State Navigation Guidelines","default":[]},"global_action_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Action Guidelines","default":[]},"global_boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Global Boundary Constraints","default":[]},"topology_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Topology Description"},"dynamic_behaviors":{"anyOf":[{"items":{"$ref":"#/components/schemas/DynamicBehavior"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behaviors","description":"Deprecated: a context graph version carries no dynamic behaviors, so this takes only ``[]`` and can be left\nout. Author behaviors in the dynamic behavior sets library and pin them on a service's version set.","deprecated":true}},"type":"object","required":["states","new_user_initial_state","returning_user_initial_state"],"title":"CreateContextGraphVersionRequest"},"DescriptionString":{"type":"string","maxLength":2000},"ContextGraphState-Input":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Input"},{"$ref":"#/components/schemas/DecisionState-Input"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Input"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Input","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Input","decision":"#/components/schemas/DecisionState-Input"}}},"ActionState-Input":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Input":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Input":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"DynamicBehavior":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Stable across versions: the same behavior keeps its id in every version that carries it. The client\ngenerates it. A resolved behavior carries its library set's id."},"version":{"anyOf":[{"type":"integer","maximum":2147483647,"minimum":1},{"type":"null"}],"title":"Version","description":"The version of the library set this was resolved from. Null on a behavior embedded on a context graph\nversion."},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name","description":"What authors call it. The selector reads it with the condition and examples, and the reply prompt never\ndoes."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled behavior stays on the version and is never offered.","default":true},"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force, and the only text of a behavior that\nreaches the reply prompt. Null: the behavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay.","default":"add"},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one.","default":[]},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on. It ends\nsooner when the selector chooses another behavior with enough confidence, and when a turn is skipped: a\nmedical emergency, a request for a person, an empathy hold, a suspended session, or a state the behavior\ndoes not apply in.","default":1},"tags":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10,"title":"Tags","description":"Labels for authors. They never reach a prompt.","default":[]}},"additionalProperties":false,"type":"object","required":["id","name","condition"],"title":"DynamicBehavior","description":"One authored behavior: embedded on a context graph version, or resolved from a library set version."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The CreateConversationRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateConversationRequest":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"channel":{"$ref":"#/components/schemas/ChannelKind","default":"web"},"recipient":{"anyOf":[{"$ref":"#/components/schemas/PhoneE164"},{"type":"null"}],"description":"Destination address for an outbound conversation (E.164 for sms/imessage). Required for non-web."},"use_case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Use Case Id","description":"The use case the outbound conversation is sent through. Required for non-web; the sender (FROM) is resolved from it, never caller-supplied. Must be owned by this workspace."},"instruction":{"anyOf":[{"$ref":"#/components/schemas/BackgroundString"},{"type":"null"}],"description":"Optional context steering what the agent opens with on an outbound conversation."},"force_new":{"type":"boolean","title":"Force New","description":"Outbound thread-keyed channels (sms/imessage) only: close any existing ACTIVE conversation on the computed provider thread (recipient + use case) before dispatching, so the opener materializes a brand-new conversation instead of continuing the old thread. Rejected with 422 on channel=web — every web create already starts a new conversation, so force_new is meaningless there.","default":false},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"type":"object","maxProperties":50,"title":"Context","description":"Start-time context (key-value pairs) for the conversation. Validated against the owning service's accepted_context schema: unknown keys, missing required keys, or type mismatches are rejected with 422. Tools may bind individual keys to their parameters."},"tags":{"items":{"$ref":"#/components/schemas/ConversationTag"},"type":"array","maxItems":20,"title":"Tags","description":"Labels to set on the conversation, at most 20, each a key and an optional value. Change them later with PATCH /v1/{workspace_id}/conversations/{conversation_id}/tags."},"source":{"anyOf":[{"type":"string","enum":["playground","test"]},{"type":"null"}],"title":"Source","description":"Marks the conversation as test traffic. Set ``playground`` when the developer console Playground starts the conversation: a Playground session writes only to conversations a Playground session or test credential started, never a real one. Set ``test`` from your own test harness: the conversation is stored with source ``test``. Every turn on a ``playground`` or ``test`` conversation runs as a test turn, as for a conversation started with a test key, whatever its ``entity_id``. It stays out of analytics, production evaluations, EHR sync and billing, and its tools simulate unless a Playground conversation explicitly requests ``tool_execution=live``. Live tools retain test classification but can change connected systems. ``test`` needs ``Workspace.update`` (admin or owner) unless the key is already a test key. Web only (422 on another channel); an external user gets 403."},"tool_execution":{"anyOf":[{"type":"string","const":"live"},{"type":"null"}],"title":"Tool Execution","description":"``live`` runs this Playground conversation's tools for real: its integration calls reach the connected systems and can change them. Null (default) keeps Playground and test tools simulated; ordinary production conversations retain their existing tool behavior. Only with ``source`` ``playground`` on the web channel (422 otherwise), only for a workspace admin or owner on a production credential (403 otherwise), and fixed for the conversation's life. The conversation retains test classification and is excluded from automatic EHR sync and billing."}},"type":"object","required":["service_id"],"title":"CreateConversationRequest"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"BackgroundString":{"type":"string","maxLength":10000},"ConversationTag":{"properties":{"key":{"type":"string","maxLength":64,"minLength":1,"title":"Key"},"value":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Value","description":"Null for a bare label."}},"type":"object","required":["key"],"title":"ConversationTag"}}}}
```

## The CreateDashboardRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateDashboardRequest":{"properties":{"slug":{"type":"string","maxLength":128,"minLength":2,"pattern":"^[a-z0-9][a-z0-9\\-]*$","title":"Slug"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"page_context":{"anyOf":[{"type":"string","enum":["home","patients","calls","data","analytics","pipeline","operators","surfaces","compliance","custom"]},{"type":"null"}],"title":"Page Context"},"panels":{"items":{"additionalProperties":true,"type":"object"},"type":"array","maxItems":50,"title":"Panels"},"filters":{"items":{"additionalProperties":true,"type":"object"},"type":"array","maxItems":20,"title":"Filters"},"refresh_interval":{"type":"integer","maximum":86400,"minimum":10,"title":"Refresh Interval","default":300}},"type":"object","required":["slug","title"],"title":"CreateDashboardRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The CreateDataSourceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateDataSourceRequest":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"display_name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"source_type":{"type":"string","enum":["ehr","fhir_store","snowflake"],"title":"Source Type"},"connection_config":{"additionalProperties":true,"type":"object","title":"Connection Config"},"entity_types":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":100,"title":"Entity Types"},"field_mappings":{"additionalProperties":true,"type":"object","title":"Field Mappings"},"sync_strategy":{"type":"string","enum":["manual","scheduled","webhook","continuous"],"title":"Sync Strategy","default":"manual"},"sync_schedule":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Sync Schedule"}},"type":"object","required":["name","source_type"],"title":"CreateDataSourceRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The CreateDynamicBehaviorSetRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateDynamicBehaviorSetRequest":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id","description":"The set's id, unique across workspaces. Omitted, the platform generates it; setting it needs the\n``platform:admin`` scope. A client that derives it from something stable, as an import does from its\nworkspace's id and the source's id, gets a conflict instead of a second set when it creates the set again."},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name","description":"What authors call it. Unique in the workspace among sets that aren't archived, whatever the case. The\nselector reads it with the condition and examples, and the reply prompt never does."},"tags":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10,"title":"Tags","description":"Labels for authors. They never reach a prompt."},"first_version":{"$ref":"#/components/schemas/CreateDynamicBehaviorSetVersionRequest","description":"Version 1, written with the set."}},"additionalProperties":false,"type":"object","required":["name","first_version"],"title":"CreateDynamicBehaviorSetRequest","description":"A new set, written with its first version."},"CreateDynamicBehaviorSetVersionRequest":{"properties":{"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force. The selector never reads it. Null: the\nbehavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay. A replace-mode version needs an\ninstruction.","default":"add"},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on.","default":1},"note":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}],"description":"What changed, for the people reading the set's history. It never reaches a prompt."}},"additionalProperties":false,"type":"object","required":["condition"],"title":"CreateDynamicBehaviorSetVersionRequest","description":"The next version of a set, or the first version of a new one."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The CreateDynamicBehaviorSetVersionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateDynamicBehaviorSetVersionRequest":{"properties":{"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force. The selector never reads it. Null: the\nbehavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay. A replace-mode version needs an\ninstruction.","default":"add"},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on.","default":1},"note":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}],"description":"What changed, for the people reading the set's history. It never reaches a prompt."}},"additionalProperties":false,"type":"object","required":["condition"],"title":"CreateDynamicBehaviorSetVersionRequest","description":"The next version of a set, or the first version of a new one."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The CreateOperationGrantRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateOperationGrantRequest":{"properties":{"credential_id":{"type":"string","format":"uuid","title":"Credential Id"},"operation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Operation Id"},"function_name":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Function Name"},"operation_kind":{"type":"string","enum":["data_query","function"],"title":"Operation Kind"},"action":{"type":"string","enum":["read","write","invoke"],"title":"Action"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"}},"additionalProperties":false,"type":"object","required":["credential_id","operation_kind","action","expires_at"],"title":"CreateOperationGrantRequest"}}}}
```

## The CreateOperatorRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateOperatorRequest":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"email":{"type":"string","format":"email","title":"Email","description":"The operator's email. Unique in the workspace in any letter case, and fixed once registered."},"type":{"type":"string","enum":["clinical","administrative","crisis_counselor"],"title":"Type","default":"clinical"},"skills":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":50,"title":"Skills"},"connection_method":{"type":"string","enum":["browser","phone"],"title":"Connection Method","default":"phone"},"phone_number":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"role":{"type":"string","enum":["operator","supervisor","admin"],"title":"Role","default":"operator"}},"type":"object","required":["name","email"],"title":"CreateOperatorRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DialE164":{"type":"string","maxLength":16,"minLength":2}}}}
```

## The CreateOutboundCallRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateOutboundCallRequest":{"properties":{"phone_to":{"$ref":"#/components/schemas/DialE164","description":"Destination phone number in E.164 format, the direct number: one with an extension is refused."},"use_case_id":{"type":"string","format":"uuid","title":"Use Case Id","description":"Use case ID. The call goes out from a phone number bound to this use case."},"patient_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Patient Entity Id","description":"Patient entity UUID in the world model. Optional: leave out both patient_entity_id and patient_canonical_id for a call with no patient. When given, it must exist in the workspace as a person entity. Not together with patient_canonical_id."},"patient_canonical_id":{"anyOf":[{"$ref":"#/components/schemas/CanonicalIdString"},{"type":"null"}],"description":"Patient world model canonical_id of the form 'source:resource_type:id' (e.g. 'charmhealth:Patient:67890'). The structural regex on CanonicalIdString rejects spaces, names, DOBs, and similar regulated content so PHI cannot leak into audit events or pipeline projections. The raw value is deliberately not recorded in the outbound.initiated event: correlation back to the source system is via the resolved entity_id joined to the entity projection's canonical_id. Resolved against the SDP-projected entity table; an entity created moments ago may not yet be visible if the projection is lagging. Optional: leave out both patient_canonical_id and patient_entity_id for a call with no patient. Not together with patient_entity_id."},"reason":{"$ref":"#/components/schemas/NameString","description":"Why the call is being made (e.g. appointment_reminder, follow_up, lab_results)."},"system_prompt":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}],"title":"System Prompt","description":"Optional system prompt override for this call."},"goal":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}],"description":"What the call should accomplish. Injected into agent context."},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10},{"type":"null"}],"title":"Tags","description":"Classification tags for analytics."},"metadata":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Metadata","description":"Arbitrary key-value pairs for external system correlation."},"context":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"}]},"type":"object","title":"Context","description":"Start-time key-value context; validated against the service's accepted_context and injected into bound tool params."},"derived_from_call_sid":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Derived From Call Sid","description":"Prior call_sid if this is a callback from a previous call."},"idempotency_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Idempotency Key","description":"Client-provided idempotency key, scoped to the workspace. Once a call is placed with a key, a retry with it gets that call for an hour instead of placing a second one. If omitted, every request is a new call."},"outbound_task_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Outbound Task Entity Id","description":"World model outbound_task entity ID for completion feedback."}},"type":"object","required":["phone_to","use_case_id","reason"],"title":"CreateOutboundCallRequest","description":"Request body for creating an outbound call.\n\n``use_case_id`` is required: the call goes out from a phone number bound\nto that use case, the only way its caller ID is chosen."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"CanonicalIdString":{"type":"string","maxLength":256,"minLength":3,"pattern":"^[A-Za-z0-9._-]+:[A-Za-z0-9._-]+:[A-Za-z0-9._-]+$"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The CreateOutboundCallResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateOutboundCallResponse":{"properties":{"call_sid":{"type":"string","title":"Call Sid","description":"Twilio call SID for the outbound call"},"status":{"type":"string","title":"Status","description":"Initial call status (typically 'queued')"},"phone_from":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone From","description":"Resolved caller ID when use_case_id was used."},"setup_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Setup Id","description":"The channel setup's ID when use_case_id was used."},"event_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Event Id","description":"World event ID for the outbound.initiated event."}},"type":"object","required":["call_sid","status"],"title":"CreateOutboundCallResponse","description":"Response from creating an outbound call."}}}}
```

## The CreatePinRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreatePinRequest":{"properties":{"session_id":{"type":"string","format":"uuid","title":"Session Id"},"presentation_id":{"type":"string","format":"uuid","title":"Presentation Id"},"question":{"type":"string","maxLength":16000,"minLength":1,"title":"Question"}},"additionalProperties":false,"type":"object","required":["session_id","presentation_id","question"],"title":"CreatePinRequest"}}}}
```

## The CreateProductionEvalDefinitionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateProductionEvalDefinitionRequest":{"properties":{"eval_key":{"type":"string","maxLength":128,"minLength":1,"title":"Eval Key"},"eval_type":{"$ref":"#/components/schemas/ProductionEvalType"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"expected":{"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"active":{"type":"boolean","title":"Active","default":true}},"type":"object","required":["eval_key","eval_type"],"title":"CreateProductionEvalDefinitionRequest"},"ProductionEvalType":{"type":"string","enum":["metric"],"title":"ProductionEvalType"}}}}
```

## The CreateRunRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateRunRequest":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"},"branch_name":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Branch Name"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Tags"}},"type":"object","required":["service_id"],"title":"CreateRunRequest"}}}}
```

## The CreateSchedulingRuleSetRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSchedulingRuleSetRequest":{"properties":{"agent_kind":{"type":"string","enum":["tms","ketamine","general"],"title":"Agent Kind"},"params":{"oneOf":[{"$ref":"#/components/schemas/ClinicOpenHoursParams"},{"$ref":"#/components/schemas/TMSMappingReleaseParams"},{"$ref":"#/components/schemas/TMSSessionGridParams"},{"$ref":"#/components/schemas/KetamineBlockOverlapParams"},{"$ref":"#/components/schemas/NinetyDayRollingParams"},{"$ref":"#/components/schemas/ConcurrentStartBlockParams"}],"title":"Params","description":"Per-rule-kind typed parameters. The ``rule_kind`` discriminator field selects the params shape; one row per (agent_kind, rule_kind) per workspace.","discriminator":{"propertyName":"rule_kind","mapping":{"clinic_open_hours":"#/components/schemas/ClinicOpenHoursParams","concurrent_start_block":"#/components/schemas/ConcurrentStartBlockParams","ketamine_block_overlap":"#/components/schemas/KetamineBlockOverlapParams","ninety_day_rolling":"#/components/schemas/NinetyDayRollingParams","tms_mapping_release":"#/components/schemas/TMSMappingReleaseParams","tms_session_grid":"#/components/schemas/TMSSessionGridParams"}}},"is_active":{"type":"boolean","title":"Is Active","default":true}},"type":"object","required":["agent_kind","params"],"title":"CreateSchedulingRuleSetRequest"},"ClinicOpenHoursParams":{"properties":{"rule_kind":{"type":"string","const":"clinic_open_hours","title":"Rule Kind","default":"clinic_open_hours"},"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"monday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"tuesday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"wednesday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"thursday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"friday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"saturday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"sunday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]}},"type":"object","required":["timezone"],"title":"ClinicOpenHoursParams","description":"Workspace clinic open-hours by weekday.\n\nDays not present mean \"closed.\" Used by the rules engine to skip\nslots outside open hours and (combined with ``weekend_skip``) by the\nTMS-mapping release calculator."},"_DayHours":{"properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$","title":"Start"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$","title":"End"}},"type":"object","required":["start","end"],"title":"_DayHours","description":"Open-hours window for one weekday. Times in 24h ``HH:MM`` form,\ninterpreted in the rule set's ``timezone``."},"TMSMappingReleaseParams":{"properties":{"rule_kind":{"type":"string","const":"tms_mapping_release","title":"Rule Kind","default":"tms_mapping_release"},"reservation_window_hours":{"type":"integer","maximum":720,"minimum":0,"title":"Reservation Window Hours"},"weekend_skip":{"type":"boolean","title":"Weekend Skip","default":true}},"type":"object","required":["reservation_window_hours"],"title":"TMSMappingReleaseParams","description":"How long before a TMS mapping appointment its slot is released\nback to the pool. ``weekend_skip=True`` adds Saturday + Sunday days\nto the wall-clock countdown (clinic doesn't release on weekends)."},"TMSSessionGridParams":{"properties":{"rule_kind":{"type":"string","const":"tms_session_grid","title":"Rule Kind","default":"tms_session_grid"},"interval_minutes":{"type":"integer","maximum":120,"minimum":5,"title":"Interval Minutes"},"boundary_minutes":{"items":{"type":"integer"},"type":"array","maxItems":60,"minItems":1,"title":"Boundary Minutes"}},"type":"object","required":["interval_minutes","boundary_minutes"],"title":"TMSSessionGridParams","description":"TMS sessions only start at fixed minute-of-hour boundaries\n(e.g. ``:00`` and ``:30``) so the technician can run them\nback-to-back without gaps."},"KetamineBlockOverlapParams":{"properties":{"rule_kind":{"type":"string","const":"ketamine_block_overlap","title":"Rule Kind","default":"ketamine_block_overlap"},"window_days":{"type":"integer","maximum":365,"minimum":1,"title":"Window Days"}},"type":"object","required":["window_days"],"title":"KetamineBlockOverlapParams","description":"How many days after a ketamine session to block follow-up\nappointments (clinical safety window)."},"NinetyDayRollingParams":{"properties":{"rule_kind":{"type":"string","const":"ninety_day_rolling","title":"Rule Kind","default":"ninety_day_rolling"},"days":{"type":"integer","maximum":365,"minimum":1,"title":"Days"}},"type":"object","required":["days"],"title":"NinetyDayRollingParams","description":"Rolling-window cap on appointments per patient (e.g. 90 days\nbetween TMS sessions)."},"ConcurrentStartBlockParams":{"properties":{"rule_kind":{"type":"string","const":"concurrent_start_block","title":"Rule Kind","default":"concurrent_start_block"}},"type":"object","title":"ConcurrentStartBlockParams","description":"Disallow two slots starting at the same time within a TMS scope.\nNo additional params — the discriminator is the whole config."}}}}
```

## The CreateServiceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateServiceRequest":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"description":{"$ref":"#/components/schemas/DescriptionString","default":""},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id","description":"The context graph the service's workflow agent versions run: one of this workspace's. Leave it out, or send\nnull, for a service that binds no graph. Every version set of such a service runs an agent version whose program\nis direct and pins no context graph version."},"keyterms":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":500,"title":"Keyterms"},"is_active":{"type":"boolean","title":"Is Active","default":true},"version_sets":{"additionalProperties":{"$ref":"#/components/schemas/VersionSet-Input"},"type":"object","title":"Version Sets","default":{}},"tags":{"items":{"$ref":"#/components/schemas/ServiceTag"},"type":"array","maxItems":50,"title":"Tags"},"tool_capacity":{"type":"integer","maximum":10,"minimum":1,"title":"Tool Capacity","default":3},"channel_type":{"type":"string","enum":["voice","text"],"title":"Channel Type","default":"voice"},"environment":{"type":"string","enum":["sandbox","production"],"title":"Environment","default":"production"},"demo_mode":{"type":"boolean","title":"Demo Mode","description":"Voice calls on this service open with only the recording notice, without the AI disclosure. For demos only,\nnever for a service that takes real callers.","default":false},"platform_caller_verification":{"type":"boolean","title":"Platform Caller Verification","description":"Whether the platform verifies a caller who may match a patient record by full name and date of\nbirth. Off, the agent never asks a caller to verify, and every platform tool that reads a patient\nrecord refuses. The service's integration tools run either way, unless one of them verifies its\ncallers (`caller_verification_endpoint_id`).","default":true},"caller_verification_endpoint_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Caller Verification Endpoint Id","description":"The integration endpoint that verifies this service's callers, on a service with\n`platform_caller_verification` and `allow_unverified_integration_results` false. The endpoint has to\nbe one of this workspace's, declare `declarations.verifies`, and never wait for approval under its\nintegration's `approval_policy`. A successful call verifies the caller as the one patient its response\nnames there, once per conversation. The reads of that integration that declare the patient they read\nrefuse until then, and then run only for that patient, and the agent may share what they return.\nNaming one needs `Service.update`."},"allow_unverified_integration_results":{"type":"boolean","title":"Allow Unverified Integration Results","description":"A dangerous bypass, off by default. On, results from the service's integration endpoints, reads and\nwrites, never count as a patient record for the output checker's unverified-caller check\n(`output_checks.phi_unverified`, which runs only on a service that sets it to `cut`), so the agent may read\nthem back to any caller, verified or not. Writes are still held to everything else, the platform's own\npatient reads still refuse until the caller verifies, and data queries and skills still count. Never on\nbeside `caller_verification_endpoint_id`. Every change is audited.","default":false},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/ServiceVoiceConfig-Input"},{"type":"null"}]},"accepted_context":{"items":{"$ref":"#/components/schemas/ContextKeySpec"},"type":"array","maxItems":100,"title":"Accepted Context"},"crisis_call_911_reply":{"anyOf":[{"$ref":"#/components/schemas/CrisisCall911Reply"},{"type":"null"}]},"contact_lines":{"items":{"$ref":"#/components/schemas/ContactLineInput"},"type":"array","maxItems":50,"title":"Contact Lines","description":"Declared direct contact lines. Public emergency and N11 short codes are refused."},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending","description":"How a voice call ends after a medical emergency's script: ``stay_on_line`` (the default) or\n``end_after_script``, which plays the authored closing line and then ends the call. A self-harm or\ncrisis statement keeps the call open in either.","default":"stay_on_line"},"output_checks":{"anyOf":[{"$ref":"#/components/schemas/ServiceOutputChecksRequest"},{"type":"null"}],"description":"Which reply checks run. A key left out inherits the workspace default (`GET /v1/{workspace_id}/settings/safety`),\nand the platform default where the workspace sets none. Setting any key needs `Service.update`."},"emergency_floor":{"anyOf":[{"$ref":"#/components/schemas/ServiceEmergencyFloorRequest"},{"type":"null"}],"description":"How the medical-emergency and crisis floor acts on the service's text conversations, voice notes and\nsimulations. A key left out inherits the workspace default, and the platform default where the workspace sets\nnone. Setting any key needs `Service.update`."},"conversation_audit":{"anyOf":[{"$ref":"#/components/schemas/ConversationAuditSettings"},{"type":"null"}],"description":"The post-call transcript quality audit. Left out, it is off. See `ConversationAuditSettings`."},"declared_languages":{"anyOf":[{"items":{"type":"string","enum":["en","es","ar","fr","de","pt","zh","ja","ko"]},"type":"array","maxItems":9,"minItems":1},{"type":"null"}],"title":"Declared Languages","description":"The languages this service serves, as ISO 639-1 codes: a non-empty list of distinct supported\nlanguages. Omit or null for none declared, which serves only the agent's default language."}},"type":"object","required":["name","agent_id"],"title":"CreateServiceRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"VersionSet-Input":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"ServiceTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"ServiceTag"},"ServiceVoiceConfig-Input":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingConfig-Input"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingConfig-Input":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to"],"title":"ServiceForwardingConfig","description":"Per-service call-forwarding destination + transfer mechanism.\n\nThis block gates the ``forward_call`` tool: None means the agent cannot\ntransfer at all. When present, ``forward_to`` picks the destination mode,\nand the tool schema follows it — a static service gets an argument-less\ntool, a dynamic one gets a required ``phone_number`` that must be one of\n``approved_destinations`` (none approved means no tool). Nothing cascades:\na service is one mode or the other. ``fallback_to`` is no mode: it is the\nline the safe exit dials, in either, and ``forward_call`` never offers it.\nA call tagged as a test reaches only ``test_destinations``, in either mode, unless\nits caller is one of ``verification_callers``.\n``hours`` is none either: on a dynamic service, a transfer outside its staffed\nhours dials ``after_hours_destination`` whichever approved line was asked for, unless that line keeps\nhours of its own in ``destination_hours``.\nA dynamic service can also name a ``default_destination``, the line a transfer that names none dials. A service\nin either mode can list the ``transfer_reasons`` each of its transfers names and the call records."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."},"ContextKeySpec":{"properties":{"key":{"$ref":"#/components/schemas/SlugString"},"type":{"type":"string","enum":["string","number"],"title":"Type"},"description":{"$ref":"#/components/schemas/DescriptionString"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["key","type","description","required"],"title":"ContextKeySpec","description":"One key a conversation may supply as start-time context for a service.\n\nThe value is validated against ``type`` at conversation start; a tool can then\nbind the key to one of its parameters (injected, hidden from the model)."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"CrisisCall911Reply":{"properties":{"en":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1},"es":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1}},"additionalProperties":false,"type":"object","required":["en","es"],"title":"CrisisCall911Reply","description":"Per-service wording added when a caller already in crisis asks for emergency dispatch."},"ContactLineInput":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"$ref":"#/components/schemas/DialE164"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLineInput","description":"Save-time number policy; persisted declarations remain readable after policy changes."},"ServiceOutputChecksRequest":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck","description":"On a voice call, `cut` stops a reply that reads something from a patient's record to a caller who has not\nverified, and the caller hears a correction in its place. `off`, the platform default, does not run the check."},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck","description":"`cut`, the platform default, stops a reply that speaks a number on the platform phone blocklist, and the caller\nhears the no-confirmed-number correction in its place. `off` lets the reply speak it. A listed number is still\nnever dialed and is still refused as a destination."},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck","description":"`cut`, the platform default, stops a reply that spells back, letter by letter, a word close to but not the one\nthe caller just said. `off` lets the spelling play."},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that gives dosing advice or tells the caller to change a medication. `cut` (the platform default)\nreplaces it with a correction, `count` lets it play and counts it, `off` lets it play."},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says what is wrong with the caller, or that a symptom needs no care. `cut`, `count` or `off`."},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says a booking, message or other action is done when no write on the call backs it. `cut`,\n`count` or `off`."},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says emergency help is called, sent or on the way. `cut`, `count` or `off`."},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck","description":"A reply that called no tool and tells the caller the agent is doing something now, on text or a realtime call.\n`retry`, the platform default, gives the agent one more go with a note to act or say what it can't do. `off`\nsends the reply as written."},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck","description":"Text only. A reply that says something was done for the client, such as an escalation, a handoff or a message\npassed to a team, when no tool that succeeded in the turn did it. `off`, the platform default, does not read the\nreply. `log` reads it and counts a claim it finds; the reply goes out as written. `enforce` holds the reply back\nand gives the agent one more go with a note to call the tool first or not claim it; a second reply that still\nclaims it goes out cut before the claim, with the false-confirmation correction in its place."}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecksRequest","description":"The reply checks a service or a workspace sets. A key left out inherits: a service's from the workspace default,\nthe workspace's from the platform default. Every key can be set to `off`."},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"},"ServiceEmergencyFloorRequest":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor","description":"A message that says the person is thinking about harming or killing themselves. `enforce`, the platform default,\nanswers it with the floor's crisis script (the region's crisis line, the service's crisis contacts and the\nemergency number) in place of the agent's reply. `off` leaves it to the agent."},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor","description":"A message that describes a medical emergency, such as chest pain or trouble breathing. `shadow`, the platform\ndefault, detects and counts it and opens the floor's hold, and the agent's reply goes out. `enforce` answers it\nwith the floor's emergency-number script instead. `off` leaves it to the agent."},"held_text":{"$ref":"#/components/schemas/HeldTextFloor","description":"A message on a conversation an operator holds. `enforce`, the platform default, answers it with the floor's\nscript when it names any emergency. `off` leaves every held message to the operator."}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloorRequest","description":"How the medical-emergency and crisis floor acts on text conversations (SMS, email, web chat and the other\nmessaging channels), voice notes and simulations. A key left out inherits: a service's from the workspace default,\nthe workspace's from the platform default, which is today's behavior. Every key can be set to `off`, and then the\nfloor neither replaces nor alters the reply: the agent's own reply and tools run, no hold opens, and the hit is\nonly counted. A voice call's floor is not set here."},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"},"ConversationAuditSettings":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"checks":{"items":{"$ref":"#/components/schemas/ConversationAuditCheck"},"type":"array","maxItems":4,"minItems":1,"title":"Checks"},"threshold":{"type":"integer","maximum":100,"minimum":1,"title":"Threshold","default":80}},"additionalProperties":false,"type":"object","title":"ConversationAuditSettings"},"ConversationAuditCheck":{"type":"string","enum":["obvious_errors","missed_escalation","wrong_information","missed_safety_event"]}}}}
```

## The CreateSessionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSessionRequest":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"},"branch_name":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Branch Name"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Tags"},"caller_id":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Caller Id","description":"Simulated caller phone number used to resolve patient context when `entity_id` is not provided (or does not match a row). Omitted/blank values are normalized to the `sim-orchestrator` sentinel, which yields no phone match and an empty caller context — same default the voice test-call WebSocket uses, so patient lookups resolve consistently across modalities."},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"Optional world entity UUID to bind caller context directly. Precedence rules: (1) when this resolves to a world entity in the workspace, it WINS — `caller_id` is not used for identity resolution, and the resolution provenance is `entity_id_lookup`; (2) when this is a well-formed UUID with no matching entity (stale, deleted, wrong workspace), the session falls back to phone lookup against `caller_id` (provenance `phone_lookup`) — no error is raised, the sim is survivable; (3) malformed UUIDs are rejected with HTTP 422 before the session starts. The supplied `caller_id` is still recorded on the active call and surfaced in the greeting metadata in case (1)."},"expected_service_config_digest":{"anyOf":[{"type":"string","maxLength":71,"pattern":"^sha256:[0-9a-f]{64}$"},{"type":"null"}],"title":"Expected Service Config Digest","description":"The candidate the session must run: the `service_config_digest` the service's `configuration-identity` answers for its default version set. Every turn of the session, and of its forks, runs only on a configuration with this digest. One that has since changed fails the create or the step with HTTP 409 `simulation_config_mismatch`, and a fork branch with that `error`. Omitted, the session runs whatever configuration the service has at each turn."}},"type":"object","required":["service_id"],"title":"CreateSessionRequest"}}}}
```

## The CreateSimulationCaseItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSimulationCaseItem":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description"},"persona":{"additionalProperties":true,"type":"object","title":"Persona"},"scenario":{"$ref":"#/components/schemas/SimulationCaseScenario"},"grounding":{"$ref":"#/components/schemas/SimulationCaseGrounding"},"evals":{"items":{"$ref":"#/components/schemas/SimulationCaseEval"},"type":"array","maxItems":100,"title":"Evals"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Tags"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"}},"additionalProperties":false,"type":"object","required":["description","scenario"],"title":"CreateSimulationCaseItem","description":"One durable simulation case to create."},"SimulationCaseScenario":{"properties":{"instructions":{"type":"string","maxLength":10000,"minLength":1,"title":"Instructions"},"initial_message":{"type":"string","maxLength":2000,"title":"Initial Message","default":""},"temperament":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Temperament"}},"type":"object","required":["instructions"],"title":"SimulationCaseScenario","description":"Runnable patient-side scenario content for a saved case."},"SimulationCaseGrounding":{"properties":{"patient_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Patient Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Start context a run of this case begins with: key-value pairs, each key one the service accepts (`accepted_context`) and each value a string or a number. A tool parameter the service's graph binds to a key is filled from it on every turn and branch. A run is refused, and a suite skips the case, when a required key is missing, a key is not one the service accepts, or a value has the wrong type. A launch's own `context` is added to it and wins where both name a key."}},"type":"object","title":"SimulationCaseGrounding","description":"Optional bindings that start the sim from existing workspace data."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"SimulationCaseEval":{"oneOf":[{"$ref":"#/components/schemas/SimulationCaseMetricEval"},{"$ref":"#/components/schemas/SimulationCaseAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseBooleanAssertionEval"}]},"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"},"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."},"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."}}}}
```

## The CreateSimulationCasesRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSimulationCasesRequest":{"properties":{"cases":{"items":{"$ref":"#/components/schemas/CreateSimulationCaseItem"},"type":"array","maxItems":100,"minItems":1,"title":"Cases"}},"additionalProperties":false,"type":"object","required":["cases"],"title":"CreateSimulationCasesRequest"},"CreateSimulationCaseItem":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description"},"persona":{"additionalProperties":true,"type":"object","title":"Persona"},"scenario":{"$ref":"#/components/schemas/SimulationCaseScenario"},"grounding":{"$ref":"#/components/schemas/SimulationCaseGrounding"},"evals":{"items":{"$ref":"#/components/schemas/SimulationCaseEval"},"type":"array","maxItems":100,"title":"Evals"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Tags"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"}},"additionalProperties":false,"type":"object","required":["description","scenario"],"title":"CreateSimulationCaseItem","description":"One durable simulation case to create."},"SimulationCaseScenario":{"properties":{"instructions":{"type":"string","maxLength":10000,"minLength":1,"title":"Instructions"},"initial_message":{"type":"string","maxLength":2000,"title":"Initial Message","default":""},"temperament":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Temperament"}},"type":"object","required":["instructions"],"title":"SimulationCaseScenario","description":"Runnable patient-side scenario content for a saved case."},"SimulationCaseGrounding":{"properties":{"patient_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Patient Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Start context a run of this case begins with: key-value pairs, each key one the service accepts (`accepted_context`) and each value a string or a number. A tool parameter the service's graph binds to a key is filled from it on every turn and branch. A run is refused, and a suite skips the case, when a required key is missing, a key is not one the service accepts, or a value has the wrong type. A launch's own `context` is added to it and wins where both name a key."}},"type":"object","title":"SimulationCaseGrounding","description":"Optional bindings that start the sim from existing workspace data."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"SimulationCaseEval":{"oneOf":[{"$ref":"#/components/schemas/SimulationCaseMetricEval"},{"$ref":"#/components/schemas/SimulationCaseAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseBooleanAssertionEval"}]},"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"},"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."},"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."}}}}
```

## The CreateSimulationCasesResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSimulationCasesResponse":{"properties":{"cases":{"items":{"$ref":"#/components/schemas/SimulationCaseResponse"},"type":"array","title":"Cases"}},"type":"object","required":["cases"],"title":"CreateSimulationCasesResponse"},"SimulationCaseResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"description":{"type":"string","maxLength":2000,"title":"Description"},"persona":{"additionalProperties":true,"type":"object","title":"Persona"},"scenario":{"$ref":"#/components/schemas/SimulationCaseScenario"},"grounding":{"$ref":"#/components/schemas/SimulationCaseGrounding"},"evals":{"items":{"$ref":"#/components/schemas/StoredSimulationCaseEval"},"type":"array","title":"Evals"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","description","scenario"],"title":"SimulationCaseResponse","description":"HTTP response shape for durable simulation cases."},"SimulationCaseScenario":{"properties":{"instructions":{"type":"string","maxLength":10000,"minLength":1,"title":"Instructions"},"initial_message":{"type":"string","maxLength":2000,"title":"Initial Message","default":""},"temperament":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Temperament"}},"type":"object","required":["instructions"],"title":"SimulationCaseScenario","description":"Runnable patient-side scenario content for a saved case."},"SimulationCaseGrounding":{"properties":{"patient_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Patient Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Start context a run of this case begins with: key-value pairs, each key one the service accepts (`accepted_context`) and each value a string or a number. A tool parameter the service's graph binds to a key is filled from it on every turn and branch. A run is refused, and a suite skips the case, when a required key is missing, a key is not one the service accepts, or a value has the wrong type. A launch's own `context` is added to it and wins where both name a key."}},"type":"object","title":"SimulationCaseGrounding","description":"Optional bindings that start the sim from existing workspace data."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"StoredSimulationCaseEval":{"oneOf":[{"$ref":"#/components/schemas/SimulationCaseMetricEval"},{"$ref":"#/components/schemas/SimulationCaseAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseBooleanAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseLegacyAssertionEval"}]},"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"},"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."},"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."},"SimulationCaseLegacyAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","maxLength":128,"minLength":1,"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"},"grading":{"type":"string","const":"legacy_verdict","title":"Grading","description":"How this assertion is graded: a pass or fail verdict from the legacy judge, with no observed value.","default":"legacy_verdict"}},"type":"object","required":["type","key","assertion_kind","description","expected","params","weight","grading"],"title":"SimulationCaseLegacyAssertionEval","description":"An assertion saved before ``llm_boolean``: ``llm_judge`` or a free-text kind. Returned by reads only.\n\nThe legacy judge grades it with a pass or fail verdict and records no observed\nvalue. Case writes reject this shape, so rewrite it as an ``llm_boolean`` or a\ndeterministic assertion before saving the case's ``evals`` again."}}}}
```

## The CreateSimulationRunResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSimulationRunResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"branch_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch Name"},"status":{"type":"string","const":"running","title":"Status"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"}},"type":"object","required":["id","workspace_id","service_id","branch_name","status","tags"],"title":"CreateSimulationRunResponse"}}}}
```

## The CreateSimulationSuiteRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSimulationSuiteRequest":{"properties":{"name":{"type":"string","maxLength":128,"minLength":1,"title":"Name"},"description":{"type":"string","maxLength":2000,"title":"Description","default":""},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","maxItems":500,"title":"Case Ids"},"required_tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Required Tags"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Tags"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"}},"additionalProperties":false,"type":"object","required":["name"],"title":"CreateSimulationSuiteRequest"}}}}
```

## The CreateSkillRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSkillRequest":{"properties":{"slug":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Slug"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"$ref":"#/components/schemas/DescriptionString"},"system_prompt":{"anyOf":[{"$ref":"#/components/schemas/BackgroundString"},{"type":"null"}]},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"result_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result Schema"},"model":{"type":"string","maxLength":128,"minLength":1,"title":"Model","description":"Anthropic model id the skill runs on. A retired Claude id is a 422 that names its successor.","default":"claude-sonnet-5-5"},"max_tokens":{"type":"integer","maximum":200000,"minimum":1,"title":"Max Tokens","default":4096},"max_result_chars":{"type":"integer","maximum":200000,"minimum":1,"title":"Max Result Chars","default":2000},"max_input_tokens":{"anyOf":[{"type":"integer","maximum":2000000,"minimum":1},{"type":"null"}],"title":"Max Input Tokens"},"timeout_s":{"type":"number","maximum":900,"minimum":0.1,"title":"Timeout S","default":60},"thinking_effort":{"anyOf":[{"$ref":"#/components/schemas/ThinkingEffort"},{"type":"null"}]},"temperature":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Temperature","description":"Anthropic sampling temperature (0-1). Ignored on models that reject sampling params (Opus 4.7+/Fable, which 400 otherwise). Set at most one of temperature/top_p -- Claude 4+ rejects both; the runtime keeps temperature and drops top_p."},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P","description":"Anthropic nucleus sampling (0-1). Ignored on sampling-param-rejecting models; see temperature."},"enable_caching":{"type":"boolean","title":"Enable Caching","default":true},"enable_citations":{"type":"boolean","title":"Enable Citations","default":false},"use_structured_output":{"type":"boolean","title":"Use Structured Output","default":false},"integration_tools":{"items":{"$ref":"#/components/schemas/IntegrationToolRef-Input"},"type":"array","maxItems":50,"title":"Integration Tools"},"static_tools":{"items":{"$ref":"#/components/schemas/StaticToolDef-Input"},"type":"array","maxItems":50,"title":"Static Tools"},"enabled":{"type":"boolean","title":"Enabled","default":true},"max_agent_turns":{"type":"integer","maximum":200,"minimum":1,"title":"Max Agent Turns","default":20},"checkpoint_enabled":{"type":"boolean","title":"Checkpoint Enabled","default":true},"approval_required":{"type":"boolean","title":"Approval Required","default":false},"write_kind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"null"}],"description":"What this skill's writes do, for its sub-tool calls to an endpoint whose kind ``varies``\n(one generic GraphQL endpoint that books, cancels and reads). Sub-tool endpoints with their\nown kind write that kind whatever the skill says. Leave unset when unknown."}},"type":"object","required":["slug","name","description","input_schema"],"title":"CreateSkillRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"BackgroundString":{"type":"string","maxLength":10000},"ThinkingEffort":{"type":"string","enum":["low","medium","high"]},"IntegrationToolRef-Input":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string","maxLength":256,"minLength":1},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","maxProperties":50,"title":"Skill Input Bindings","description":"Endpoint parameter -> parent skill input mappings injected at dispatch."}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef","description":"Reference to an integration endpoint by integration + endpoint name."},"StaticToolDef-Input":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef","description":"A built-in tool available to companion agents."},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]}}}}
```

## The CreateSurfaceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSurfaceRequest":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"fields":{"items":{"$ref":"#/components/schemas/SurfaceField"},"type":"array","maxItems":200,"minItems":1,"title":"Fields"},"channel":{"$ref":"#/components/schemas/ChannelType","default":"web"},"use_case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Use Case Id"},"conversation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Conversation Id","description":"The text conversation the surface is for. Its submission is delivered to that\nconversation's agent, which answers it even when the conversation has gone idle."},"expires_in_hours":{"type":"integer","maximum":8760,"minimum":1,"title":"Expires In Hours","default":168},"context":{"additionalProperties":true,"type":"object","title":"Context","default":{}},"resource_type":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Resource Type"},"branding":{"anyOf":[{"$ref":"#/components/schemas/BrandingConfig"},{"type":"null"}]},"sections":{"anyOf":[{"items":{"$ref":"#/components/schemas/SurfaceSection"},"type":"array"},{"type":"null"}],"title":"Sections"},"completion_title":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"}},"type":"object","required":["entity_id","title","fields"],"title":"CreateSurfaceRequest","description":"Request to create a new surface.\n\nThe agent generates a SurfaceSpec and sends it here."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"SurfaceField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"prefill_value":{"anyOf":[{},{"type":"null"}],"title":"Prefill Value"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"}},"type":"object","required":["key","label","field_type"],"title":"SurfaceField","description":"A single data collection field in a surface spec.\n\nGenerated by agents from HSM analysis. Each field maps\nto a specific piece of data the world model needs."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"ChannelType":{"type":"string","enum":["email","web"],"title":"ChannelType","description":"Delivery channels for surfaces."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."},"SurfaceSection":{"properties":{"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["title","field_keys"],"title":"SurfaceSection","description":"A page/step in a multi-page surface form."}}}}
```

## The CreateSurfaceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateSurfaceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_id":{"type":"string","format":"uuid","title":"Event Id"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"title":{"type":"string","title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"$ref":"#/components/schemas/SurfaceStatus"},"channel":{"$ref":"#/components/schemas/ChannelType"},"use_case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Use Case Id"},"fields_count":{"type":"integer","title":"Fields Count"},"expires_at":{"type":"string","title":"Expires At"},"created_at":{"type":"string","title":"Created At"},"token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Token"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"}},"type":"object","required":["id","event_id","entity_id","title","status","channel","fields_count","expires_at","created_at"],"title":"CreateSurfaceResponse"},"SurfaceStatus":{"type":"string","enum":["created","pending_review","delivered","opened","partial","completed","expired","archived"],"title":"SurfaceStatus","description":"Lifecycle status of a surface."},"ChannelType":{"type":"string","enum":["email","web"],"title":"ChannelType","description":"Delivery channels for surfaces."}}}}
```

## The CreateTriggerRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateTriggerRequest":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"event_type":{"$ref":"#/components/schemas/TriggerableEvent"},"event_filter":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Event Filter"},"action_id":{"type":"string","format":"uuid","title":"Action Id"},"input_template":{"additionalProperties":true,"type":"object","title":"Input Template"},"schedule":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Schedule"},"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone","default":"UTC"},"threshold":{"anyOf":[{"$ref":"#/components/schemas/TriggerThreshold"},{"type":"null"}],"description":"Event triggers only: fire once count matching events arrive within window_minutes, then hold off for cooldown_minutes. Omitted, the trigger fires on every matching event. Refused on a cron trigger."}},"type":"object","required":["name","event_type","action_id"],"title":"CreateTriggerRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"TriggerableEvent":{"type":"string","enum":["amigo.trigger.cron","appointment.booked","appointment.cancelled","appointment.confirmed","booking.requested","call.ended","call.failure_signal","call.intelligence","call.outcome","channel.message.received","conversation.channel_switched","conversation.started","conversation.turn_recorded","coverage.created","entity.enriched","entity.resolved","medication.refill_requested","outbound.initiated","outbound.scheduled","patient.created","patient.updated","relationship.established","review.approve","review.correct","review.reject","surface.created","surface.submitted","ticket.created","triage.completed","trigger.completed","trigger.failed","trigger.fired"],"title":"TriggerableEvent","description":"Closed set of world events that trigger definitions may subscribe to.\n\nThe database column intentionally remains text for compatibility with old\nrows, but API writes must choose from this list so typoed event names do\nnot silently create never-matching triggers."},"TriggerThreshold":{"properties":{"count":{"type":"integer","maximum":100,"minimum":1,"title":"Count"},"window_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Window Minutes"},"cooldown_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Cooldown Minutes","default":60}},"additionalProperties":false,"type":"object","required":["count","window_minutes"],"title":"TriggerThreshold","description":"How many matching events an event trigger waits for before it fires: ``count`` of them inside the last\n``window_minutes``. Once it fires, it holds off for ``cooldown_minutes`` however many more arrive."}}}}
```

## The CreateWorkspaceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CreateWorkspaceRequest":{"properties":{"slug":{"$ref":"#/components/schemas/SlugString"},"name":{"$ref":"#/components/schemas/StrippedNonemptyString"},"backend_org_id":{"anyOf":[{"$ref":"#/components/schemas/StrippedNonemptyString"},{"type":"null"}]},"membership_provisioning":{"type":"string","enum":["domain_policies","explicit"],"title":"Membership Provisioning","description":"Create-only membership mode. Explicit excludes automatic domain policies; owner bootstrap, invitations and administrator grants remain available.","default":"domain_policies"}},"type":"object","required":["slug","name"],"title":"CreateWorkspaceRequest","description":"Request body for ``POST /v1/me/workspaces``."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"StrippedNonemptyString":{"type":"string","minLength":1}}}}
```

## The CrisisCall911Reply object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CrisisCall911Reply":{"properties":{"en":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1},"es":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1}},"additionalProperties":false,"type":"object","required":["en","es"],"title":"CrisisCall911Reply","description":"Per-service wording added when a caller already in crisis asks for emergency dispatch."},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The CustomTokenExchangeAuthDict object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CustomTokenExchangeAuthDict":{"properties":{"type":{"type":"string","const":"custom_token_exchange","title":"Type"},"exchange_url":{"type":"string","title":"Exchange Url"},"body_encoding":{"type":"string","enum":["json","form"],"title":"Body Encoding"},"static_headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Headers"},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields"},"param_headers":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueDict"},"type":"object","title":"Param Headers"},"param_body_fields":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueDict"},"type":"object","title":"Param Body Fields"},"response_token_path":{"type":"string","title":"Response Token Path"},"identity_bindings":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Bindings"},"identity_binding_test_values":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Binding Test Values"}},"type":"object","required":["type","exchange_url","body_encoding","static_headers","static_body_fields","param_headers","param_body_fields","response_token_path","identity_bindings"],"title":"CustomTokenExchangeAuthDict","description":"Pre-flight exchange that mints a downstream bearer.\n\nDownstream call always receives ``Authorization: Bearer {token}``. No\nin-process caching — every call mints fresh."},"ParamValueDict":{"properties":{"param_name":{"type":"string","title":"Param Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["param_name","description"],"title":"ParamValueDict","description":"Routing target for one per-request parameter on the exchange call.\n\nPaired with a wire-name (header / body-field key) on\n``CustomTokenExchangeAuthDict.param_headers`` / ``param_body_fields``."}}}}
```

## The CustomTokenExchangeAuthRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CustomTokenExchangeAuthRequest":{"properties":{"type":{"type":"string","const":"custom_token_exchange","title":"Type","default":"custom_token_exchange"},"exchange_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Exchange Url"},"body_encoding":{"type":"string","enum":["json","form"],"title":"Body Encoding","description":"``json`` (default) sends static_body_fields + param_body_fields as JSON; ``form`` sends as application/x-www-form-urlencoded.","default":"json"},"static_headers":{"patternProperties":{"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$":{"type":"string"}},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","title":"Static Headers","description":"Workspace-level headers on the exchange request (keys are RFC 7230 tchar). Values may contain ``{secret}`` placeholder.","default":{}},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields","description":"Workspace-level body fields keyed by RFC 6901 JSON Pointer (e.g. ``/meta/tool_name``\nfor nested fields, or ``/foo`` for a root-level field). Values may contain ``{secret}``\nplaceholder.","default":{}},"param_headers":{"patternProperties":{"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$":{"$ref":"#/components/schemas/ParamValueRequest"}},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","title":"Param Headers","description":"Per-request params routed to headers on the exchange request, keyed by wire-name.","default":{}},"param_body_fields":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueRequest"},"type":"object","title":"Param Body Fields","description":"Per-request params routed to body fields on the exchange request, keyed by RFC 6901 JSON Pointer.","default":{}},"identity_bindings":{"additionalProperties":{"type":"string","enum":["principal.subject_key","principal.subject_id","external_user.subject_key"]},"type":"object","maxProperties":50,"title":"Identity Bindings","description":"Maps a declared ``param_name`` to the verified identity attribute that supplies it\nat dispatch. A bound param is dropped from the LLM-facing tool schema and injected from the\nverified session context (never model-supplied), closing the per-user-identity impersonation hole.\nKeys MUST reference a ``param_name`` declared on ``param_headers`` / ``param_body_fields``.","default":{}},"identity_binding_test_values":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Binding Test Values","description":"Author-configured test values for identity-bound params.\n\nOnly ``external_user.subject_key`` bindings may carry test values. Runtime\ndispatch uses them only when a backend execution path explicitly opts in.","default":{}},"response_token_path":{"type":"string","title":"Response Token Path","description":"RFC 6901 JSON Pointer into the exchange response body that extracts the bearer token\n(e.g. ``/access_token`` or ``/data/bearer``). NO default — every config commits explicitly."}},"type":"object","required":["exchange_url","response_token_path"],"title":"CustomTokenExchangeAuthRequest","description":"Pre-flight exchange that mints a downstream bearer.\n\nReplaces legacy ``json_token_exchange`` AND ``bearer_token_exchange``.\nPath-shaped fields (``response_token_path``, ``static_body_fields`` keys,\n``param_body_fields`` keys) MUST be valid RFC 6901 JSON Pointer — one\nsyntax throughout."},"ParamValueRequest":{"properties":{"param_name":{"type":"string","title":"Param Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["param_name","description"],"title":"ParamValueRequest","description":"Routing target for a single per-request parameter on the exchange call.\n\nPaired with a wire-name (header / body-field key) on\n``CustomTokenExchangeAuthRequest.param_headers`` / ``param_body_fields``."}}}}
```

## The DailyCallStat object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DailyCallStat":{"properties":{"date":{"type":"string","title":"Date","description":"Date string (YYYY-MM-DD)"},"count":{"type":"integer","title":"Count","description":"Number of calls on this date"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Average call duration in seconds"}},"type":"object","required":["date","count"],"title":"DailyCallStat","description":"Per-day call volume and duration."}}}}
```

## The DailyCallVolume object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DailyCallVolume":{"properties":{"date":{"type":"string","title":"Date","description":"ISO-8601 date (YYYY-MM-DD)"},"count":{"type":"integer","title":"Count","description":"Number of calls on this date"}},"type":"object","required":["date","count"],"title":"DailyCallVolume","description":"Call volume for a single date."}}}}
```

## The DailyUsage object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DailyUsage":{"properties":{"usage_date":{"type":"string","format":"date","title":"Usage Date"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["usage_date","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"DailyUsage","description":"Token usage for one calendar date."}}}}
```

## The DashboardDefinitionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DashboardDefinitionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspace Id"},"slug":{"type":"string","title":"Slug","description":"URL-safe identifier"},"title":{"type":"string","title":"Title","description":"Dashboard display title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description"},"page_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Page Context","description":"Developer console page where this dashboard renders"},"panels":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Panels","description":"Ordered list of panel definitions"},"filters":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Filters","description":"Dashboard-level filter controls"},"refresh_interval":{"type":"integer","title":"Refresh Interval","description":"Auto-refresh interval in seconds"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the dashboard is active"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"Creator identifier"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the dashboard was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the dashboard was last updated"}},"type":"object","required":["id","slug","title","panels","filters","refresh_interval","is_active"],"title":"DashboardDefinitionResponse"}}}}
```

## The DashboardExecuteResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DashboardExecuteResponse":{"properties":{"dashboard_id":{"type":"string","format":"uuid","title":"Dashboard Id"},"results":{"items":{"$ref":"#/components/schemas/PanelResultResponse"},"type":"array","title":"Results"}},"type":"object","required":["dashboard_id","results"],"title":"DashboardExecuteResponse"},"PanelResultResponse":{"properties":{"panel_id":{"type":"string","title":"Panel Id","description":"Panel identifier from the definition"},"columns":{"items":{"type":"string"},"type":"array","title":"Columns","description":"Column names"},"rows":{"items":{"items":{},"type":"array"},"type":"array","title":"Rows","description":"Result rows"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if query failed"}},"type":"object","required":["panel_id","columns","rows"],"title":"PanelResultResponse"}}}}
```

## The DashboardListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DashboardListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DashboardDefinitionResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"DashboardListResponse"},"DashboardDefinitionResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspace Id"},"slug":{"type":"string","title":"Slug","description":"URL-safe identifier"},"title":{"type":"string","title":"Title","description":"Dashboard display title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description"},"page_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Page Context","description":"Developer console page where this dashboard renders"},"panels":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Panels","description":"Ordered list of panel definitions"},"filters":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Filters","description":"Dashboard-level filter controls"},"refresh_interval":{"type":"integer","title":"Refresh Interval","description":"Auto-refresh interval in seconds"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the dashboard is active"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"Creator identifier"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the dashboard was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the dashboard was last updated"}},"type":"object","required":["id","slug","title","panels","filters","refresh_interval","is_active"],"title":"DashboardDefinitionResponse"}}}}
```

## The DashboardResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DashboardResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"operators":{"$ref":"#/components/schemas/OperatorStatusCounts"},"active_escalations":{"type":"integer","title":"Active Escalations"},"escalations_today":{"$ref":"#/components/schemas/EscalationDailyStats"},"recent_escalations":{"items":{"$ref":"#/components/schemas/ActiveEscalationItem"},"type":"array","title":"Recent Escalations"}},"type":"object","required":["workspace_id","operators","active_escalations","escalations_today","recent_escalations"],"title":"DashboardResponse"},"OperatorStatusCounts":{"properties":{"total":{"type":"integer","title":"Total"},"online":{"type":"integer","title":"Online"},"busy":{"type":"integer","title":"Busy"},"offline":{"type":"integer","title":"Offline"}},"type":"object","required":["total","online","busy","offline"],"title":"OperatorStatusCounts"},"EscalationDailyStats":{"properties":{"requested":{"type":"integer","title":"Requested","default":0},"connected":{"type":"integer","title":"Connected","default":0},"completed":{"type":"integer","title":"Completed","default":0},"avg_wait_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Wait Seconds"},"avg_handle_time_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Handle Time Seconds"}},"type":"object","title":"EscalationDailyStats"},"ActiveEscalationItem":{"properties":{"call_entity_id":{"type":"string","format":"uuid","title":"Call Entity Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"escalation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Escalation Id","description":"Escalation event ID"},"status":{"type":"string","maxLength":64,"title":"Status","description":"Current escalation state"},"trigger":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger","description":"What triggered the escalation"},"trigger_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger Source","description":"Source system of the trigger"},"concept":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Concept","description":"Clinical concept that triggered escalation"},"operator_type":{"anyOf":[{"type":"string","enum":["clinical","administrative","crisis_counselor"]},{"type":"null"}],"title":"Operator Type","description":"Required operator specialization"},"regulatory_basis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Regulatory Basis","description":"Regulatory reason for escalation"},"immediate":{"type":"boolean","title":"Immediate","description":"Whether the escalation requires immediate attention"},"risk_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Risk Score","description":"Risk score 0.0 to 1.0"},"requested_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Requested At","description":"ISO-8601 timestamp when escalation was requested"},"connected_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connected At","description":"ISO-8601 timestamp when operator connected"},"wait_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Wait Seconds","description":"Seconds the caller waited for an operator"},"operator_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Operator Entity Id","description":"Entity ID of the connected operator"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id","description":"Caller phone number"},"direction":{"anyOf":[{"type":"string","enum":["inbound","outbound","playground","simulated","test"]},{"type":"null"}],"title":"Direction","description":"Call direction"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number","description":"Service phone number"},"started_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Started At","description":"ISO-8601 timestamp when the call started"}},"type":"object","required":["call_entity_id","status","immediate"],"title":"ActiveEscalationItem","description":"A call with an active escalation, enriched from projected state."}}}}
```

## The DataCollectionState-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataCollectionState-Input":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The DataCollectionState-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The DataFreshness object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataFreshness":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshness","description":"How fresh a query's rows must be to be stated as current."}}}}
```

## The DataFreshnessBody object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataFreshnessBody":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"additionalProperties":false,"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshnessBody","description":"The freshness a create or PATCH names. A key it doesn't have, such as a unit, is a 422."}}}}
```

## The DataQualityMetrics object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataQualityMetrics":{"properties":{"pending_reviews":{"type":"integer","title":"Pending Reviews","default":0},"approval_rate_7d":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Approval Rate 7D"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"entities_total":{"type":"integer","title":"Entities Total","default":0},"entities_merged_7d":{"type":"integer","title":"Entities Merged 7D","default":0}},"type":"object","title":"DataQualityMetrics"}}}}
```

## The DataQualityResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataQualityResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace identifier"},"period_start":{"type":"string","format":"date","title":"Period Start","description":"Start of the reporting period"},"period_end":{"type":"string","format":"date","title":"Period End","description":"End of the reporting period"},"confidence_distribution":{"items":{"$ref":"#/components/schemas/ConfidenceBucket"},"type":"array","title":"Confidence Distribution","description":"Overall confidence distribution across buckets"},"confidence_by_source":{"additionalProperties":{"items":{"$ref":"#/components/schemas/ConfidenceBucket"},"type":"array"},"type":"object","title":"Confidence By Source","description":"Confidence distribution broken down by event source"},"review_pipeline":{"additionalProperties":true,"type":"object","title":"Review Pipeline","description":"Review pipeline throughput statistics"},"timeseries":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Timeseries","description":"Daily confidence averages and event counts"},"total_events":{"type":"integer","title":"Total Events","description":"Total number of events in the period"}},"type":"object","required":["workspace_id","period_start","period_end","confidence_distribution","confidence_by_source","review_pipeline","timeseries","total_events"],"title":"DataQualityResponse","description":"Data quality metrics — confidence distribution, review pipeline stats."},"ConfidenceBucket":{"properties":{"confidence_range":{"type":"string","title":"Confidence Range","description":"Confidence level bucket label (e.g. 'raw', 'verified', 'authoritative')"},"count":{"type":"integer","title":"Count","description":"Number of events in this confidence bucket"}},"type":"object","required":["confidence_range","count"],"title":"ConfidenceBucket"}}}}
```

## The DataQueryDeclarations object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataQueryDeclarations":{"properties":{"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nparameters name (``params``, each one of the query's ``parameters``), the ones its rows hold\n(``response``, where ``records`` points into the rows the query returns, a list of objects keyed\nby column, so the empty pointer is every row), or none (``none``: practice data, such as\narticles, locations or opening hours). Null when undeclared: the voice agent then counts a\ncall's result as one that may hold a patient's record."},"freshness":{"anyOf":[{"$ref":"#/components/schemas/DataFreshness"},{"type":"null"}],"description":"None: rows are returned as they are, with no staleness."}},"type":"object","title":"DataQueryDeclarations","description":"What a data query's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses. A reader ignores a key it doesn't\nknow, so a later declaration never breaks an older reader."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"DataFreshness":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshness","description":"How fresh a query's rows must be to be stated as current."}}}}
```

## The DataQueryDeclarationsBody object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataQueryDeclarationsBody":{"properties":{"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nparameters name (``params``, each one of the query's ``parameters``), the ones its rows hold\n(``response``, where ``records`` points into the rows the query returns, a list of objects keyed\nby column, so the empty pointer is every row), or none (``none``: practice data, such as\narticles, locations or opening hours). Null when undeclared: the voice agent then counts a\ncall's result as one that may hold a patient's record."},"freshness":{"anyOf":[{"$ref":"#/components/schemas/DataFreshnessBody"},{"type":"null"}],"description":"None: rows are returned as they are, with no staleness."}},"additionalProperties":false,"type":"object","title":"DataQueryDeclarationsBody","description":"The declarations a create or PATCH names. One a data query can't make, such as an endpoint's\n``writes`` or a misspelled ``reads``, is a 422, never a key dropped with a 200. Only the write\nboundary refuses one: a reader ignores a key it doesn't know (``DataQueryDeclarations``)."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"DataFreshnessBody":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"additionalProperties":false,"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshnessBody","description":"The freshness a create or PATCH names. A key it doesn't have, such as a unit, is a 422."}}}}
```

## The DataQueryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataQueryResponse":{"properties":{"items":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Items"},"count":{"type":"integer","title":"Count"},"has_more":{"type":"boolean","title":"Has More"}},"type":"object","required":["items","count","has_more"],"title":"DataQueryResponse"}}}}
```

## The DataResidency object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataResidency":{"type":"string","enum":["any","regional"]}}}}
```

## The DataResidencySettingsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataResidencySettingsResponse":{"properties":{"data_residency":{"$ref":"#/components/schemas/DataResidency"},"region":{"type":"string","enum":["us-east-1","ap-southeast-2","eu-central-1","ca-central-1"],"title":"Region"},"geography":{"type":"string","title":"Geography"}},"type":"object","required":["data_residency","region","geography"],"title":"DataResidencySettingsResponse"},"DataResidency":{"type":"string","enum":["any","regional"]}}}}
```

## The DataSourceListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataSourceListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DataSourceResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"DataSourceListResponse"},"DataSourceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"source_type":{"type":"string","enum":["ehr","fhir_store","snowflake"],"title":"Source Type"},"connection_config":{"additionalProperties":true,"type":"object","title":"Connection Config"},"entity_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Entity Types"},"field_mappings":{"additionalProperties":true,"type":"object","title":"Field Mappings"},"sync_strategy":{"type":"string","enum":["manual","scheduled","webhook","continuous"],"title":"Sync Strategy"},"sync_schedule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Schedule"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","display_name","source_type","connection_config","entity_types","field_mappings","sync_strategy","sync_schedule","is_active","created_at","updated_at"],"title":"DataSourceResponse"}}}}
```

## The DataSourceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataSourceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"source_type":{"type":"string","enum":["ehr","fhir_store","snowflake"],"title":"Source Type"},"connection_config":{"additionalProperties":true,"type":"object","title":"Connection Config"},"entity_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Entity Types"},"field_mappings":{"additionalProperties":true,"type":"object","title":"Field Mappings"},"sync_strategy":{"type":"string","enum":["manual","scheduled","webhook","continuous"],"title":"Sync Strategy"},"sync_schedule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Schedule"},"is_active":{"type":"boolean","title":"Is Active"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","display_name","source_type","connection_config","entity_types","field_mappings","sync_strategy","sync_schedule","is_active","created_at","updated_at"],"title":"DataSourceResponse"}}}}
```

## The DataSourceStatusResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataSourceStatusResponse":{"properties":{"data_source_id":{"type":"string","format":"uuid","title":"Data Source Id"},"name":{"type":"string","title":"Name"},"is_active":{"type":"boolean","title":"Is Active"},"event_count":{"type":"integer","title":"Event Count"},"synced_count":{"type":"integer","title":"Synced Count"},"failed_count":{"type":"integer","title":"Failed Count"}},"type":"object","required":["data_source_id","name","is_active","event_count","synced_count","failed_count"],"title":"DataSourceStatusResponse"}}}}
```

## The DataSourceSyncHistoryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataSourceSyncHistoryResponse":{"properties":{"data_source_id":{"type":"string","format":"uuid","title":"Data Source Id"},"name":{"type":"string","title":"Name"},"timeline":{"items":{"$ref":"#/components/schemas/SyncHistoryEntry"},"type":"array","title":"Timeline"},"recent_failures":{"items":{"$ref":"#/components/schemas/SyncFailureEntry"},"type":"array","title":"Recent Failures"}},"type":"object","required":["data_source_id","name","timeline","recent_failures"],"title":"DataSourceSyncHistoryResponse"},"SyncHistoryEntry":{"properties":{"date":{"type":"string","title":"Date"},"event_count":{"type":"integer","title":"Event Count"},"synced_count":{"type":"integer","title":"Synced Count"},"failed_count":{"type":"integer","title":"Failed Count"}},"type":"object","required":["date","event_count","synced_count","failed_count"],"title":"SyncHistoryEntry"},"SyncFailureEntry":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"event_type":{"type":"string","title":"Event Type"},"fhir_resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Type"},"fhir_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Id"},"sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Error"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["event_id","event_type","fhir_resource_type","fhir_resource_id","sync_error","created_at"],"title":"SyncFailureEntry"}}}}
```

## The DataTemplate-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataTemplate-Input":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"fields":{"items":{"$ref":"#/components/schemas/DataTemplateField"},"type":"array","maxItems":50,"minItems":1,"title":"Fields"}},"type":"object","required":["name","fields"],"title":"DataTemplate","description":"Named field template — reusable across multiple outreach rules."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DataTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"path":{"type":"string","maxLength":256,"minLength":1,"title":"Path","description":"Dot-notation path into entity state (e.g. demographics.date_of_birth)"}},"type":"object","required":["key","label","path"],"title":"DataTemplateField","description":"A field in a data template — maps to entity state path for gap detection."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."}}}}
```

## The DataTemplate-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataTemplate-Output":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"fields":{"items":{"$ref":"#/components/schemas/DataTemplateField"},"type":"array","maxItems":50,"minItems":1,"title":"Fields"}},"type":"object","required":["name","fields"],"title":"DataTemplate","description":"Named field template — reusable across multiple outreach rules."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DataTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"path":{"type":"string","maxLength":256,"minLength":1,"title":"Path","description":"Dot-notation path into entity state (e.g. demographics.date_of_birth)"}},"type":"object","required":["key","label","path"],"title":"DataTemplateField","description":"A field in a data template — maps to entity state path for gap detection."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."}}}}
```

## The DataTemplateField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DataTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"path":{"type":"string","maxLength":256,"minLength":1,"title":"Path","description":"Dot-notation path into entity state (e.g. demographics.date_of_birth)"}},"type":"object","required":["key","label","path"],"title":"DataTemplateField","description":"A field in a data template — maps to entity state path for gap detection."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."}}}}
```

## The DatasetRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DatasetRow":{"properties":{"name":{"type":"string","title":"Name","description":"Dataset slug (UI label \"Schema\")."},"schema_version":{"type":"string","title":"Schema Version"},"field_count":{"type":"integer","title":"Field Count"},"file_type":{"type":"string","title":"File Type","description":"Primary/representative file type (the first accepted type)."},"accepted_file_types":{"items":{"type":"string"},"type":"array","title":"Accepted File Types","description":"Document datasets: the full accepted-type set. Empty for snapshot\nor legacy single-type documents (the UI falls back to ``file_type``).","default":[]},"ingestion_mode":{"type":"string","title":"Ingestion Mode","description":"`snapshot` (CSV/Excel → CDC) or `document` (PDF/docx → extraction)."},"limits":{"$ref":"#/components/schemas/Limits"}},"type":"object","required":["name","schema_version","field_count","file_type","ingestion_mode","limits"],"title":"DatasetRow","description":"A registered schema in the Schemas list."},"Limits":{"properties":{"max_size_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Size Mb"}},"type":"object","title":"Limits"}}}}
```

## The DatasetUpdateRunResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DatasetUpdateRunResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"dataset":{"type":"string","title":"Dataset"},"status":{"$ref":"#/components/schemas/_DatasetUpdateStatus"},"source_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Source Ids"},"batch_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Batch Ids"},"materialize_run_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Materialize Run Id"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"created_at":{"type":"string","title":"Created At"},"updated_at":{"type":"string","title":"Updated At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"}},"type":"object","required":["run_id","dataset","status","source_ids","batch_ids","created_at","updated_at"],"title":"DatasetUpdateRunResponse","description":"Durable status for one dataset update action."},"_DatasetUpdateStatus":{"type":"string","enum":["checking_drive","preparing","publishing","completed","needs_review","failed"]}}}}
```

## The DeciderKind object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DeciderKind":{"type":"string","const":"decisions"}}}}
```

## The DecisionFactor object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DecisionFactor":{"properties":{"factor":{"type":"string","maxLength":2000,"minLength":1,"title":"Factor","description":"What specifically drove this decision - exact words heard or tone described"},"source_type":{"type":"string","title":"Source Type","description":"Category of the audio input"}},"type":"object","required":["factor","source_type"],"title":"DecisionFactor","description":"A specific audio input that drove an agent decision."}}}}
```

## The DecisionState-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DecisionState-Input":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."}}}}
```

## The DecisionState-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."}}}}
```

## The DecompositionRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DecompositionRow":{"properties":{"feature_name":{"type":"string","title":"Feature Name"},"beta":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Beta"},"delta_x":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Delta X"},"contribution":{"type":"number","title":"Contribution"},"family":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Family"},"ci_lo":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Ci Lo"},"ci_hi":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Ci Hi"}},"type":"object","required":["feature_name","contribution"],"title":"DecompositionRow"}}}}
```

## The Default object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Default":{"properties":{"kind":{"type":"string","enum":["literal","uuid_v4","now","current_date"],"title":"Kind"},"value":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value","description":"Only meaningful for ``kind=\"literal\"``. Other kinds ignore it.\nA ``dict`` value is rendered as a JSONB literal — pair it with a\n``jsonb`` column."}},"type":"object","required":["kind"],"title":"Default"}}}}
```

## The DeleteSimulationCoverageGraphResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DeleteSimulationCoverageGraphResponse":{"properties":{"deleted_runs":{"type":"integer","title":"Deleted Runs"},"deleted_sessions":{"type":"integer","title":"Deleted Sessions"},"deleted_turns":{"type":"integer","title":"Deleted Turns"}},"type":"object","required":["deleted_runs","deleted_sessions","deleted_turns"],"title":"DeleteSimulationCoverageGraphResponse"}}}}
```

## The DeliverSurfaceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DeliverSurfaceRequest":{"properties":{"channel_address":{"type":"string","maxLength":256,"minLength":1,"title":"Channel Address","description":"Delivery address (phone number, email, etc.)"}},"type":"object","required":["channel_address"],"title":"DeliverSurfaceRequest","description":"Request to mark a surface as delivered."}}}}
```

## The DeliverSurfaceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DeliverSurfaceResponse":{"properties":{"surface_id":{"type":"string","format":"uuid","title":"Surface Id"},"status":{"type":"string","enum":["delivered","pending_review"],"title":"Status"},"channel":{"anyOf":[{"$ref":"#/components/schemas/ChannelType"},{"type":"null"}]},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"},"channel_address":{"type":"string","title":"Channel Address"},"message_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message Id"},"from_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From Number"},"from_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From Address"},"delivery_provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivery Provider"},"delivered_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivered At"}},"type":"object","required":["surface_id","status","channel_address"],"title":"DeliverSurfaceResponse"},"ChannelType":{"type":"string","enum":["email","web"],"title":"ChannelType","description":"Delivery channels for surfaces."}}}}
```

## The DemoDefinition object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DemoDefinition":{"properties":{"id":{"type":"string","maxLength":80,"minLength":1,"title":"Id"},"description":{"type":"string","maxLength":1024,"minLength":1,"title":"Description"},"population":{"type":"string","maxLength":512,"minLength":1,"title":"Population"},"time_basis":{"type":"string","maxLength":512,"minLength":1,"title":"Time Basis"},"units":{"type":"string","maxLength":128,"minLength":1,"title":"Units"}},"additionalProperties":false,"type":"object","required":["id","description","population","time_basis","units"],"title":"DemoDefinition"}}}}
```

## The DemoHomeAgent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DemoHomeAgent":{"properties":{"id":{"$ref":"#/components/schemas/FactId"},"name":{"$ref":"#/components/schemas/FactLabel"}},"additionalProperties":false,"type":"object","required":["id","name"],"title":"DemoHomeAgent"},"FactId":{"type":"string","maxLength":200,"minLength":1},"FactLabel":{"type":"string","maxLength":256,"minLength":1}}}}
```

## The DemoHomeCheck object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DemoHomeCheck":{"properties":{"id":{"$ref":"#/components/schemas/FactId"},"conversation_id":{"$ref":"#/components/schemas/FactId"},"check_key":{"$ref":"#/components/schemas/FactLabel"},"passed":{"type":"boolean","title":"Passed"},"definition_id":{"$ref":"#/components/schemas/FactId"}},"additionalProperties":false,"type":"object","required":["id","conversation_id","check_key","passed","definition_id"],"title":"DemoHomeCheck"},"FactId":{"type":"string","maxLength":200,"minLength":1},"FactLabel":{"type":"string","maxLength":256,"minLength":1}}}}
```

## The DemoHomeConversation object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DemoHomeConversation":{"properties":{"id":{"$ref":"#/components/schemas/FactId"},"agent_id":{"anyOf":[{"$ref":"#/components/schemas/FactId"},{"type":"null"}]},"started_at":{"type":"string","format":"date-time","title":"Started At"},"channel_kind":{"anyOf":[{"$ref":"#/components/schemas/FactLabel"},{"type":"null"}]},"is_production":{"type":"boolean","title":"Is Production"},"safety_status":{"anyOf":[{"$ref":"#/components/schemas/FactLabel"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["id","agent_id","started_at","channel_kind","is_production","safety_status"],"title":"DemoHomeConversation"},"FactId":{"type":"string","maxLength":200,"minLength":1},"FactLabel":{"type":"string","maxLength":256,"minLength":1}}}}
```

## The DemoHomeResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DemoHomeResponse":{"properties":{"source":{"$ref":"#/components/schemas/DemoSource"},"agents":{"items":{"$ref":"#/components/schemas/DemoHomeAgent"},"type":"array","maxItems":5000,"title":"Agents"},"conversations":{"items":{"$ref":"#/components/schemas/DemoHomeConversation"},"type":"array","maxItems":5000,"title":"Conversations"},"checks":{"items":{"$ref":"#/components/schemas/DemoHomeCheck"},"type":"array","maxItems":5000,"title":"Checks"}},"additionalProperties":false,"type":"object","required":["source","agents","conversations","checks"],"title":"DemoHomeResponse"},"DemoSource":{"properties":{"kind":{"type":"string","const":"published_demo","title":"Kind","default":"published_demo"},"synthetic":{"type":"boolean","const":true,"title":"Synthetic","default":true},"dataset_version":{"type":"string","pattern":"^r[12]_[0-9]{8}_[a-f0-9]{64}$","title":"Dataset Version"},"as_of_date":{"type":"string","format":"date","title":"As Of Date"},"data_through":{"type":"string","format":"date","title":"Data Through"},"event_window_start":{"type":"string","format":"date-time","title":"Event Window Start"},"event_window_end":{"type":"string","format":"date-time","title":"Event Window End"},"observed_before":{"type":"string","format":"date-time","title":"Observed Before"},"recipe_version":{"type":"string","maxLength":100,"minLength":1,"title":"Recipe Version"},"content_sha256":{"type":"string","pattern":"^[a-f0-9]{64}$","title":"Content Sha256"},"logical_table":{"type":"string","title":"Logical Table"},"snapshot_table":{"type":"string","title":"Snapshot Table"},"definitions":{"additionalProperties":{"type":"string"},"type":"object","title":"Definitions"},"table_map":{"additionalProperties":{"$ref":"#/components/schemas/DemoTable"},"type":"object","title":"Table Map"},"definition_records":{"items":{"$ref":"#/components/schemas/DemoDefinition"},"type":"array","title":"Definition Records","default":[]},"event_window_scope":{"anyOf":[{"type":"string","const":"conversations"},{"type":"null"}],"title":"Event Window Scope"}},"additionalProperties":false,"type":"object","required":["dataset_version","as_of_date","data_through","event_window_start","event_window_end","observed_before","recipe_version","content_sha256","logical_table","snapshot_table","definitions"],"title":"DemoSource","description":"Captured provenance, safe to expose with authorized selected evidence."},"DemoTable":{"properties":{"physical_table":{"type":"string","title":"Physical Table"},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"row_count":{"type":"integer","maximum":5000,"minimum":0,"title":"Row Count"},"description":{"type":"string","maxLength":2048,"title":"Description"}},"additionalProperties":false,"type":"object","required":["physical_table","columns","row_count","description"],"title":"DemoTable"},"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"},"DemoDefinition":{"properties":{"id":{"type":"string","maxLength":80,"minLength":1,"title":"Id"},"description":{"type":"string","maxLength":1024,"minLength":1,"title":"Description"},"population":{"type":"string","maxLength":512,"minLength":1,"title":"Population"},"time_basis":{"type":"string","maxLength":512,"minLength":1,"title":"Time Basis"},"units":{"type":"string","maxLength":128,"minLength":1,"title":"Units"}},"additionalProperties":false,"type":"object","required":["id","description","population","time_basis","units"],"title":"DemoDefinition"},"DemoHomeAgent":{"properties":{"id":{"$ref":"#/components/schemas/FactId"},"name":{"$ref":"#/components/schemas/FactLabel"}},"additionalProperties":false,"type":"object","required":["id","name"],"title":"DemoHomeAgent"},"FactId":{"type":"string","maxLength":200,"minLength":1},"FactLabel":{"type":"string","maxLength":256,"minLength":1},"DemoHomeConversation":{"properties":{"id":{"$ref":"#/components/schemas/FactId"},"agent_id":{"anyOf":[{"$ref":"#/components/schemas/FactId"},{"type":"null"}]},"started_at":{"type":"string","format":"date-time","title":"Started At"},"channel_kind":{"anyOf":[{"$ref":"#/components/schemas/FactLabel"},{"type":"null"}]},"is_production":{"type":"boolean","title":"Is Production"},"safety_status":{"anyOf":[{"$ref":"#/components/schemas/FactLabel"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["id","agent_id","started_at","channel_kind","is_production","safety_status"],"title":"DemoHomeConversation"},"DemoHomeCheck":{"properties":{"id":{"$ref":"#/components/schemas/FactId"},"conversation_id":{"$ref":"#/components/schemas/FactId"},"check_key":{"$ref":"#/components/schemas/FactLabel"},"passed":{"type":"boolean","title":"Passed"},"definition_id":{"$ref":"#/components/schemas/FactId"}},"additionalProperties":false,"type":"object","required":["id","conversation_id","check_key","passed","definition_id"],"title":"DemoHomeCheck"}}}}
```

## The DemoSource object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DemoSource":{"properties":{"kind":{"type":"string","const":"published_demo","title":"Kind","default":"published_demo"},"synthetic":{"type":"boolean","const":true,"title":"Synthetic","default":true},"dataset_version":{"type":"string","pattern":"^r[12]_[0-9]{8}_[a-f0-9]{64}$","title":"Dataset Version"},"as_of_date":{"type":"string","format":"date","title":"As Of Date"},"data_through":{"type":"string","format":"date","title":"Data Through"},"event_window_start":{"type":"string","format":"date-time","title":"Event Window Start"},"event_window_end":{"type":"string","format":"date-time","title":"Event Window End"},"observed_before":{"type":"string","format":"date-time","title":"Observed Before"},"recipe_version":{"type":"string","maxLength":100,"minLength":1,"title":"Recipe Version"},"content_sha256":{"type":"string","pattern":"^[a-f0-9]{64}$","title":"Content Sha256"},"logical_table":{"type":"string","title":"Logical Table"},"snapshot_table":{"type":"string","title":"Snapshot Table"},"definitions":{"additionalProperties":{"type":"string"},"type":"object","title":"Definitions"},"table_map":{"additionalProperties":{"$ref":"#/components/schemas/DemoTable"},"type":"object","title":"Table Map"},"definition_records":{"items":{"$ref":"#/components/schemas/DemoDefinition"},"type":"array","title":"Definition Records","default":[]},"event_window_scope":{"anyOf":[{"type":"string","const":"conversations"},{"type":"null"}],"title":"Event Window Scope"}},"additionalProperties":false,"type":"object","required":["dataset_version","as_of_date","data_through","event_window_start","event_window_end","observed_before","recipe_version","content_sha256","logical_table","snapshot_table","definitions"],"title":"DemoSource","description":"Captured provenance, safe to expose with authorized selected evidence."},"DemoTable":{"properties":{"physical_table":{"type":"string","title":"Physical Table"},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"row_count":{"type":"integer","maximum":5000,"minimum":0,"title":"Row Count"},"description":{"type":"string","maxLength":2048,"title":"Description"}},"additionalProperties":false,"type":"object","required":["physical_table","columns","row_count","description"],"title":"DemoTable"},"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"},"DemoDefinition":{"properties":{"id":{"type":"string","maxLength":80,"minLength":1,"title":"Id"},"description":{"type":"string","maxLength":1024,"minLength":1,"title":"Description"},"population":{"type":"string","maxLength":512,"minLength":1,"title":"Population"},"time_basis":{"type":"string","maxLength":512,"minLength":1,"title":"Time Basis"},"units":{"type":"string","maxLength":128,"minLength":1,"title":"Units"}},"additionalProperties":false,"type":"object","required":["id","description","population","time_basis","units"],"title":"DemoDefinition"}}}}
```

## The DemoTable object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DemoTable":{"properties":{"physical_table":{"type":"string","title":"Physical Table"},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"row_count":{"type":"integer","maximum":5000,"minimum":0,"title":"Row Count"},"description":{"type":"string","maxLength":2048,"title":"Description"}},"additionalProperties":false,"type":"object","required":["physical_table","columns","row_count","description"],"title":"DemoTable"},"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"}}}}
```

## The DescriptionString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The DestinationHours object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"DialE164":{"type":"string","maxLength":16,"minLength":2}}}}
```

## The DestroySessionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DestroySessionResponse":{"properties":{"status":{"type":"string","const":"destroyed","title":"Status","description":"Session destruction status"}},"type":"object","required":["status"],"title":"DestroySessionResponse"}}}}
```

## The DialE164 object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DialE164":{"type":"string","maxLength":16,"minLength":2}}}}
```

## The Dialability object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Dialability":{"properties":{"label":{"$ref":"#/components/schemas/ReadinessLabel"},"channel":{"anyOf":[{"$ref":"#/components/schemas/ReadinessLabel"},{"type":"null"}]},"will_dial":{"type":"boolean","title":"Will Dial","description":"Passes the use case's current dial gate when this line is selected."},"reason":{"anyOf":[{"$ref":"#/components/schemas/UseCaseDialability"},{"type":"string","const":"use_case_missing"}],"title":"Reason"}},"type":"object","required":["label","channel","will_dial","reason"],"title":"Dialability"},"ReadinessLabel":{"type":"string"},"UseCaseDialability":{"type":"string","enum":["own_number","listed","not_listed"]}}}}
```

## The DirectProgram-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DirectProgram-Input":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The DirectProgram-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DirectProgram-Output":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The DirectionCalls object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DirectionCalls":{"properties":{"calls":{"type":"integer","title":"Calls","description":"Production calls"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Mean quality score of scored calls (0-100)"}},"type":"object","required":["calls"],"title":"DirectionCalls","description":"One direction's calls in ``by_direction``."}}}}
```

## The DocumentProcessingSpec object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DocumentProcessingSpec":{"properties":{"retain_source":{"type":"boolean","title":"Retain Source","default":true},"extraction_mode":{"type":"string","enum":["text_extract","OCR","hybrid"],"title":"Extraction Mode","default":"text_extract"}},"type":"object","title":"DocumentProcessingSpec","description":"Processing config for a document dataset (``ingestion_mode=document``).\n\nDocuments have no schema, primary key or change data capture, so this config is what the contract carries\ninstead."}}}}
```

## The DriveFolderMapping object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DriveFolderMapping":{"properties":{"folder_id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Folder Id"},"dataset":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Dataset"},"contains_phi":{"type":"boolean","title":"Contains Phi","default":true}},"type":"object","required":["folder_id","dataset"],"title":"DriveFolderMapping","description":"One Google Drive folder ↔ one intake dataset.\n\n``folder_id`` is the Drive folder id (the identity — never the folder name,\nwhich can be renamed/moved). One folder maps to exactly one dataset."}}}}
```

## The DropColumnAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DropColumnAction":{"properties":{"op":{"type":"string","const":"drop_column","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropColumnAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The DropColumnDefaultAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DropColumnDefaultAction":{"properties":{"op":{"type":"string","const":"drop_column_default","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropColumnDefaultAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The DropConstraintAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DropConstraintAction":{"properties":{"op":{"type":"string","const":"drop_constraint","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropConstraintAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The DropIndexAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DropIndexAction":{"properties":{"op":{"type":"string","const":"drop_index","title":"Op"},"index_name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","index_name"],"title":"DropIndexAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The DynamicBehavior object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehavior":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Stable across versions: the same behavior keeps its id in every version that carries it. The client\ngenerates it. A resolved behavior carries its library set's id."},"version":{"anyOf":[{"type":"integer","maximum":2147483647,"minimum":1},{"type":"null"}],"title":"Version","description":"The version of the library set this was resolved from. Null on a behavior embedded on a context graph\nversion."},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name","description":"What authors call it. The selector reads it with the condition and examples, and the reply prompt never\ndoes."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled behavior stays on the version and is never offered.","default":true},"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force, and the only text of a behavior that\nreaches the reply prompt. Null: the behavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay.","default":"add"},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one.","default":[]},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on. It ends\nsooner when the selector chooses another behavior with enough confidence, and when a turn is skipped: a\nmedical emergency, a request for a person, an empathy hold, a suspended session, or a state the behavior\ndoes not apply in.","default":1},"tags":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10,"title":"Tags","description":"Labels for authors. They never reach a prompt.","default":[]}},"additionalProperties":false,"type":"object","required":["id","name","condition"],"title":"DynamicBehavior","description":"One authored behavior: embedded on a context graph version, or resolved from a library set version."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The DynamicBehaviorMode object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"}}}}
```

## The DynamicBehaviorOutcome object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorOutcome":{"enum":["applied","kept","held","none","below_floor","failed","skipped","superseded"],"type":"string"}}}}
```

## The DynamicBehaviorSetListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorSetListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DynamicBehaviorSetResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"DynamicBehaviorSetListResponse"},"DynamicBehaviorSetResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"latest_version":{"type":"integer","minimum":1,"title":"Latest Version"},"archived_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archived At","description":"When it was archived. Null: not archived."},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","tags","latest_version","archived_at","created_by","created_at","updated_at"],"title":"DynamicBehaviorSetResponse","description":"A set in the library, without its versions."}}}}
```

## The DynamicBehaviorSetResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorSetResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"latest_version":{"type":"integer","minimum":1,"title":"Latest Version"},"archived_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Archived At","description":"When it was archived. Null: not archived."},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","tags","latest_version","archived_at","created_by","created_at","updated_at"],"title":"DynamicBehaviorSetResponse","description":"A set in the library, without its versions."}}}}
```

## The DynamicBehaviorSetUsageResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorSetUsageResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PinningService"},"type":"array","title":"Items","description":"The services whose version sets pin the set, by name."},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"DynamicBehaviorSetUsageResponse"},"PinningService":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"The service's id."},"name":{"type":"string","title":"Name","description":"The service's name."},"version_sets":{"items":{"$ref":"#/components/schemas/PinningVersionSet"},"type":"array","title":"Version Sets"}},"type":"object","required":["id","name","version_sets"],"title":"PinningService"},"PinningVersionSet":{"properties":{"name":{"type":"string","title":"Name","description":"The version set's name."},"version":{"type":"integer","title":"Version","description":"The version of the set it runs."},"enabled":{"type":"boolean","title":"Enabled"},"states":{"items":{"type":"string"},"type":"array","title":"States","description":"The states it applies in. Empty: every one."}},"type":"object","required":["name","version","enabled","states"],"title":"PinningVersionSet"}}}}
```

## The DynamicBehaviorSetVersionListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorSetVersionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DynamicBehaviorSetVersionResponse"},"type":"array","title":"Items","description":"Newest version first."},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"DynamicBehaviorSetVersionListResponse"},"DynamicBehaviorSetVersionResponse":{"properties":{"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force. The selector never reads it. Null: the\nbehavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay. A replace-mode version needs an\ninstruction.","default":"add"},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on.","default":1},"note":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}],"description":"What changed, for the people reading the set's history. It never reaches a prompt."},"set_id":{"type":"string","format":"uuid","title":"Set Id"},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["condition","set_id","version","created_by","created_at"],"title":"DynamicBehaviorSetVersionResponse","description":"One version of a set, as it was written."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The DynamicBehaviorSetVersionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorSetVersionResponse":{"properties":{"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force. The selector never reads it. Null: the\nbehavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay. A replace-mode version needs an\ninstruction.","default":"add"},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on.","default":1},"note":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}],"description":"What changed, for the people reading the set's history. It never reaches a prompt."},"set_id":{"type":"string","format":"uuid","title":"Set Id"},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["condition","set_id","version","created_by","created_at"],"title":"DynamicBehaviorSetVersionResponse","description":"One version of a set, as it was written."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The DynamicBehaviorSkip object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorSkip":{"enum":["emergency_floor","person_request","empathy_hold","suspended","no_candidates"],"type":"string"}}}}
```

## The EagerEvalResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EagerEvalResponse":{"properties":{"status":{"type":"string","enum":["evaluated","skipped_over_cap","skipped_data_residency"],"title":"Status"},"eval_count":{"type":"integer","title":"Eval Count"}},"type":"object","required":["status","eval_count"],"title":"EagerEvalResponse","description":"``evaluated`` with an ``eval_count`` of 0 is a call with no active definitions to run.\n``skipped_data_residency`` is a call the judge never saw: the workspace's data residency\nforbids its model."}}}}
```

## The EffectiveGrant object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EffectiveGrant":{"properties":{"resource_type":{"$ref":"#/components/schemas/_ResourceType"},"resource_key":{"type":"string","title":"Resource Key"},"access":{"$ref":"#/components/schemas/_Access"}},"type":"object","required":["resource_type","resource_key","access"],"title":"EffectiveGrant"},"_ResourceType":{"type":"string","enum":["integration_endpoint","skill","kb_scope"]},"_Access":{"type":"string","enum":["read","write"]}}}}
```

## The EffectiveHarness object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EffectiveHarness":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"The release tag, or ``in-tree``. None when ``error`` is set."},"asset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256"},"source":{"type":"string","enum":["pin","harness_default","invalid_pin"],"title":"Source","description":"``invalid_pin``: the service stores a pin of this harness that no longer validates. The entry names no\nrelease, so the harness has nothing to run until the pin is set again. A ``pin`` or ``harness_default`` with an\n``error`` names a release the platform may no longer run, and names no release either."},"contract_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Version","description":"The contract the release was built on, from the registry. None for ``in-tree`` and when ``error`` is set."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the harness has nothing to run on the service: its stored pin is invalid, or its pin or default names a\nrelease or a policy the platform may no longer run (revoked, unregistered, or off the supported contract range),\nor its pin names a harness the service does not run.\nSet, the entry names no release and no policy, so the harness has nothing to run. None otherwise."},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"The policy release the harness runs the values of: the pin's, else the default's. None when neither names one,\nand when ``error`` is set."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","source","contract_version","error","policy"],"title":"EffectiveHarness","description":"The release one harness runs on a service, and where that came from. ``repo``, ``asset`` and ``sha256`` are\nNone for ``in-tree``. agent-engine loads the wheel it baked at ``/opt/harnesses/<sha256>/``."},"HarnessKind":{"type":"string","enum":["voice","text"]},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."}}}}
```

## The EffectiveVoice object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EffectiveVoice":{"properties":{"session_provider":{"type":"string","const":"gpt_realtime","title":"Session Provider"},"model":{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"],"title":"Model"},"voice":{"type":"string","maxLength":256,"title":"Voice"},"reasoning_effort":{"type":"string","enum":["minimal","low","medium","high","xhigh"],"title":"Reasoning Effort"}},"type":"object","required":["session_provider","model","voice","reasoning_effort"],"title":"EffectiveVoice"}}}}
```

## The EgressIpsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EgressIpsResponse":{"properties":{"egress_ips":{"items":{"type":"string"},"type":"array","title":"Egress Ips"},"region":{"type":"string","title":"Region"},"note":{"type":"string","title":"Note"}},"type":"object","required":["egress_ips","region","note"],"title":"EgressIpsResponse"}}}}
```

## The ElevenRealtimeSessionConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."}}}}
```

## The EmotionalShift object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EmotionalShift":{"properties":{"timestamp_seconds":{"anyOf":[{"type":"number","maximum":86400,"minimum":0},{"type":"null"}],"title":"Timestamp Seconds","description":"When the shift occurred (seconds from start)"},"from_state":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"From State","description":"Emotional state before the shift"},"to_state":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"To State","description":"Emotional state after the shift"},"trigger":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Trigger","description":"What caused the shift - exact words and tone"},"agent_awareness":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Agent Awareness","description":"Whether the agent noticed and responded to this shift"}},"type":"object","title":"EmotionalShift","description":"A critical emotional state change detected in the caller's voice."}}}}
```

## The EndpointDeclarations-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EndpointDeclarations-Input":{"properties":{"writes":{"anyOf":[{"$ref":"#/components/schemas/EndpointWrites-Input"},{"type":"null"}],"description":"What a successful call writes and how its response reports it. Null when undeclared: the\nvoice agent then never treats the endpoint's calls as a booking or cancellation."},"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nrequest names (``params``), the ones its response holds (``response``), or none (``none``).\nNull when undeclared."},"verifies":{"anyOf":[{"$ref":"#/components/schemas/VerifiesCaller-Input"},{"type":"null"}],"description":"How a successful call verifies the caller, and as which patient, for a service that names\nthis endpoint its verifier (``Service.caller_verification_endpoint_id``). Null when undeclared:\na call verifies nobody."}},"type":"object","title":"EndpointDeclarations","description":"What an endpoint's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses."},"EndpointWrites-Input":{"properties":{"kind":{"$ref":"#/components/schemas/EndpointWriteKind","description":"What the write does, ``none`` when the endpoint never writes, ``varies`` when the\ncompanion skill that calls it says, or ``verification`` for a step that verifies the caller\nby sending or checking a one-time code, which the voice agent runs without asking the caller\nto agree or read back its destination first."},"success":{"anyOf":[{"$ref":"#/components/schemas/WriteSuccess"},{"type":"null"}],"description":"How the response says the write happened. Required unless ``kind`` is ``none``. A ``field`` or\n``graphql`` rule reads the write from the body: the member the pointer names, in a JSON object or\narray or a form-encoded body, or a GraphQL response's ``errors`` or ``data``. A 2xx whose body\ndoesn't hold it, such as an HTML page, plain text, an empty 204, JSON that doesn't parse, JSON\nwithout the field, or JSON that isn't a GraphQL response, such as a gateway's own, leaves the\nwrite's outcome unknown: the vendor may have made it. So does a GraphQL answer with errors\nthat neither says the mutation was refused or never ran nor holds its result, such as a payload\nnulled by an error below the mutation's field, which came after the write, an error with no\npath beside ``data``, or a null ``data`` in a document of more than one mutation, which hides\nwhat the ones before the failing one did. A field with another value, or a GraphQL error at the\nmutation's own field, with that field null, or in an answer with no ``data``, is a write that\ndidn't happen."}},"type":"object","required":["kind"],"title":"EndpointWrites","description":"What a successful call to an endpoint writes, and how its response reports the write."},"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]},"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"VerifiesCaller-Input":{"properties":{"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the identifier of\nthe patient the caller verified as, such as ``/patient/id``: the identifier the service's reads\nname the patient by. Only a string there with more than whitespace in it verifies anyone, never a\nnumber, and never a value the model sent."},"success":{"$ref":"#/components/schemas/VerificationSuccess","description":"How the response says the caller verified: any 2xx (``http_status``), or a field holding the\nvalue that means they did (``field``). A response that doesn't say so verifies nobody, whatever\nidentifier it holds. The author vouches that it says so only once the caller proved who they are\n(a code checked, a name and date of birth matched), never on a lookup or a code sent, and that\n``patient`` names the patient the vendor matched, not a copy of something the request sent."}},"type":"object","required":["patient","success"],"title":"VerifiesCaller","description":"A successful call verifies the caller as one patient: the one its response names. Declaring it\nopens nothing: only a service that names the endpoint its verifier\n(``Service.caller_verification_endpoint_id``) verifies anyone by it."},"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}}}}}
```

## The EndpointDeclarations-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EndpointDeclarations-Output":{"properties":{"writes":{"anyOf":[{"$ref":"#/components/schemas/EndpointWrites-Output"},{"type":"null"}],"description":"What a successful call writes and how its response reports it. Null when undeclared: the\nvoice agent then never treats the endpoint's calls as a booking or cancellation."},"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nrequest names (``params``), the ones its response holds (``response``), or none (``none``).\nNull when undeclared."},"verifies":{"anyOf":[{"$ref":"#/components/schemas/VerifiesCaller-Output"},{"type":"null"}],"description":"How a successful call verifies the caller, and as which patient, for a service that names\nthis endpoint its verifier (``Service.caller_verification_endpoint_id``). Null when undeclared:\na call verifies nobody."}},"type":"object","title":"EndpointDeclarations","description":"What an endpoint's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses."},"EndpointWrites-Output":{"properties":{"kind":{"$ref":"#/components/schemas/EndpointWriteKind","description":"What the write does, ``none`` when the endpoint never writes, ``varies`` when the\ncompanion skill that calls it says, or ``verification`` for a step that verifies the caller\nby sending or checking a one-time code, which the voice agent runs without asking the caller\nto agree or read back its destination first."},"success":{"anyOf":[{"$ref":"#/components/schemas/WriteSuccess"},{"type":"null"}],"description":"How the response says the write happened. Required unless ``kind`` is ``none``. A ``field`` or\n``graphql`` rule reads the write from the body: the member the pointer names, in a JSON object or\narray or a form-encoded body, or a GraphQL response's ``errors`` or ``data``. A 2xx whose body\ndoesn't hold it, such as an HTML page, plain text, an empty 204, JSON that doesn't parse, JSON\nwithout the field, or JSON that isn't a GraphQL response, such as a gateway's own, leaves the\nwrite's outcome unknown: the vendor may have made it. So does a GraphQL answer with errors\nthat neither says the mutation was refused or never ran nor holds its result, such as a payload\nnulled by an error below the mutation's field, which came after the write, an error with no\npath beside ``data``, or a null ``data`` in a document of more than one mutation, which hides\nwhat the ones before the failing one did. A field with another value, or a GraphQL error at the\nmutation's own field, with that field null, or in an answer with no ``data``, is a write that\ndidn't happen."}},"type":"object","required":["kind"],"title":"EndpointWrites","description":"What a successful call to an endpoint writes, and how its response reports the write."},"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]},"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"VerifiesCaller-Output":{"properties":{"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the identifier of\nthe patient the caller verified as, such as ``/patient/id``: the identifier the service's reads\nname the patient by. Only a string there with more than whitespace in it verifies anyone, never a\nnumber, and never a value the model sent."},"success":{"$ref":"#/components/schemas/VerificationSuccess","description":"How the response says the caller verified: any 2xx (``http_status``), or a field holding the\nvalue that means they did (``field``). A response that doesn't say so verifies nobody, whatever\nidentifier it holds. The author vouches that it says so only once the caller proved who they are\n(a code checked, a name and date of birth matched), never on a lookup or a code sent, and that\n``patient`` names the patient the vendor matched, not a copy of something the request sent."}},"type":"object","required":["patient","success"],"title":"VerifiesCaller","description":"A successful call verifies the caller as one patient: the one its response names. Declaring it\nopens nothing: only a service that names the endpoint its verifier\n(``Service.caller_verification_endpoint_id``) verifies anyone by it."},"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}}}}}
```

## The EndpointReads object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."}}}}
```

## The EndpointResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EndpointResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Endpoint ID — stable, used in subsequent GET/PATCH/DELETE/test URLs."},"name":{"type":"string","title":"Name","description":"Slug-like identifier. Unique per integration; immutable post-create."},"description":{"type":"string","title":"Description","description":"LLM-facing description."},"method":{"type":"string","enum":["GET","POST","PUT","PATCH","DELETE"],"title":"Method","description":"HTTP method."},"path":{"type":"string","title":"Path","description":"URL path appended to the integration's base_url."},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","description":"JSON Schema for the tool's input arguments."},"headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Headers","description":"Static headers or exact ``$param.<name>`` input-parameter bindings."},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields","description":"Static body fields merged into every request. Keys are RFC 6901 JSON Pointers\n(e.g. ``/meta/tool_name`` for nested, ``/foo`` for a root-level field)."},"body_format":{"type":"string","enum":["json","form"],"title":"Body Format","description":"Outbound body encoding.","default":"json"},"response_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Response Template","description":"Jinja template rendered against the parsed JSON response."},"client_output":{"anyOf":[{"$ref":"#/components/schemas/ClientOutputConfig"},{"type":"null"}],"description":"Opt-in typed artifact contract for external-user conversation delivery."},"declarations":{"$ref":"#/components/schemas/EndpointDeclarations-Output","description":"What the endpoint's author declares about its calls. A declaration left out is unknown:\nwith no `writes`, the voice agent never treats the endpoint's calls as a booking or cancellation."},"max_response_length":{"type":"integer","title":"Max Response Length","description":"Truncate the final rendered string to this many chars.","default":0},"timeout_seconds":{"type":"number","title":"Timeout Seconds","description":"Per-request timeout.","default":30},"max_retries":{"type":"integer","title":"Max Retries","description":"How many times a failed call goes out again. A read goes again after a status in `retry_on_status`,\na timeout or a connection that failed. A write goes again only after a 429 or 503 that\n`retry_on_status` lists, or a connection that never opened. Integration writes carry no idempotency key, so a write\nthat timed out, lost its connection or got any other status may already have been made, and isn't\nsent again. A write is a call to an endpoint that declares `declarations.writes` of any kind but\n`none`, or declares nothing and uses POST, PUT, PATCH or DELETE. An endpoint that only reads over\nPOST can declare `declarations.writes.kind` `none` to retry like a read.","default":2},"retry_on_status":{"items":{"type":"integer"},"type":"array","uniqueItems":true,"title":"Retry On Status","description":"HTTP statuses after which a failed call goes out again, up to `max_retries` times. A write goes\nagain only after a 429 or 503 listed here: any other status, 502 and 504 included, can follow a\nwrite the vendor made, so a write that gets one isn't sent again. An endpoint that only reads over\nPOST can declare `declarations.writes.kind` `none` to retry on every status listed here."}},"type":"object","required":["id","name","description","method","path","declarations"],"title":"EndpointResponse","description":"Per-endpoint response."},"ClientOutputConfig":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"json_schema":{"additionalProperties":true,"type":"object","title":"Json Schema"},"max_bytes":{"type":"integer","maximum":262144,"minimum":1,"title":"Max Bytes","default":262144},"external_user_enabled":{"type":"boolean","title":"External User Enabled","default":false}},"type":"object","required":["type","schema_version","json_schema"],"title":"ClientOutputConfig","description":"External-user-safe projection contract for a direct integration endpoint.\n\nThe endpoint's existing ``response_template`` performs the projection. With no\ntemplate, the parsed upstream JSON body is emitted unchanged."},"EndpointDeclarations-Output":{"properties":{"writes":{"anyOf":[{"$ref":"#/components/schemas/EndpointWrites-Output"},{"type":"null"}],"description":"What a successful call writes and how its response reports it. Null when undeclared: the\nvoice agent then never treats the endpoint's calls as a booking or cancellation."},"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nrequest names (``params``), the ones its response holds (``response``), or none (``none``).\nNull when undeclared."},"verifies":{"anyOf":[{"$ref":"#/components/schemas/VerifiesCaller-Output"},{"type":"null"}],"description":"How a successful call verifies the caller, and as which patient, for a service that names\nthis endpoint its verifier (``Service.caller_verification_endpoint_id``). Null when undeclared:\na call verifies nobody."}},"type":"object","title":"EndpointDeclarations","description":"What an endpoint's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses."},"EndpointWrites-Output":{"properties":{"kind":{"$ref":"#/components/schemas/EndpointWriteKind","description":"What the write does, ``none`` when the endpoint never writes, ``varies`` when the\ncompanion skill that calls it says, or ``verification`` for a step that verifies the caller\nby sending or checking a one-time code, which the voice agent runs without asking the caller\nto agree or read back its destination first."},"success":{"anyOf":[{"$ref":"#/components/schemas/WriteSuccess"},{"type":"null"}],"description":"How the response says the write happened. Required unless ``kind`` is ``none``. A ``field`` or\n``graphql`` rule reads the write from the body: the member the pointer names, in a JSON object or\narray or a form-encoded body, or a GraphQL response's ``errors`` or ``data``. A 2xx whose body\ndoesn't hold it, such as an HTML page, plain text, an empty 204, JSON that doesn't parse, JSON\nwithout the field, or JSON that isn't a GraphQL response, such as a gateway's own, leaves the\nwrite's outcome unknown: the vendor may have made it. So does a GraphQL answer with errors\nthat neither says the mutation was refused or never ran nor holds its result, such as a payload\nnulled by an error below the mutation's field, which came after the write, an error with no\npath beside ``data``, or a null ``data`` in a document of more than one mutation, which hides\nwhat the ones before the failing one did. A field with another value, or a GraphQL error at the\nmutation's own field, with that field null, or in an answer with no ``data``, is a write that\ndidn't happen."}},"type":"object","required":["kind"],"title":"EndpointWrites","description":"What a successful call to an endpoint writes, and how its response reports the write."},"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]},"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"VerifiesCaller-Output":{"properties":{"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the identifier of\nthe patient the caller verified as, such as ``/patient/id``: the identifier the service's reads\nname the patient by. Only a string there with more than whitespace in it verifies anyone, never a\nnumber, and never a value the model sent."},"success":{"$ref":"#/components/schemas/VerificationSuccess","description":"How the response says the caller verified: any 2xx (``http_status``), or a field holding the\nvalue that means they did (``field``). A response that doesn't say so verifies nobody, whatever\nidentifier it holds. The author vouches that it says so only once the caller proved who they are\n(a code checked, a name and date of birth matched), never on a lookup or a code sent, and that\n``patient`` names the patient the vendor matched, not a copy of something the request sent."}},"type":"object","required":["patient","success"],"title":"VerifiesCaller","description":"A successful call verifies the caller as one patient: the one its response names. Declaring it\nopens nothing: only a service that names the endpoint its verifier\n(``Service.caller_verification_endpoint_id``) verifies anyone by it."},"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}}}}}
```

## The EndpointWriteKind object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]}}}}
```

## The EndpointWrites-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EndpointWrites-Input":{"properties":{"kind":{"$ref":"#/components/schemas/EndpointWriteKind","description":"What the write does, ``none`` when the endpoint never writes, ``varies`` when the\ncompanion skill that calls it says, or ``verification`` for a step that verifies the caller\nby sending or checking a one-time code, which the voice agent runs without asking the caller\nto agree or read back its destination first."},"success":{"anyOf":[{"$ref":"#/components/schemas/WriteSuccess"},{"type":"null"}],"description":"How the response says the write happened. Required unless ``kind`` is ``none``. A ``field`` or\n``graphql`` rule reads the write from the body: the member the pointer names, in a JSON object or\narray or a form-encoded body, or a GraphQL response's ``errors`` or ``data``. A 2xx whose body\ndoesn't hold it, such as an HTML page, plain text, an empty 204, JSON that doesn't parse, JSON\nwithout the field, or JSON that isn't a GraphQL response, such as a gateway's own, leaves the\nwrite's outcome unknown: the vendor may have made it. So does a GraphQL answer with errors\nthat neither says the mutation was refused or never ran nor holds its result, such as a payload\nnulled by an error below the mutation's field, which came after the write, an error with no\npath beside ``data``, or a null ``data`` in a document of more than one mutation, which hides\nwhat the ones before the failing one did. A field with another value, or a GraphQL error at the\nmutation's own field, with that field null, or in an answer with no ``data``, is a write that\ndidn't happen."}},"type":"object","required":["kind"],"title":"EndpointWrites","description":"What a successful call to an endpoint writes, and how its response reports the write."},"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]},"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."}}}}
```

## The EndpointWrites-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EndpointWrites-Output":{"properties":{"kind":{"$ref":"#/components/schemas/EndpointWriteKind","description":"What the write does, ``none`` when the endpoint never writes, ``varies`` when the\ncompanion skill that calls it says, or ``verification`` for a step that verifies the caller\nby sending or checking a one-time code, which the voice agent runs without asking the caller\nto agree or read back its destination first."},"success":{"anyOf":[{"$ref":"#/components/schemas/WriteSuccess"},{"type":"null"}],"description":"How the response says the write happened. Required unless ``kind`` is ``none``. A ``field`` or\n``graphql`` rule reads the write from the body: the member the pointer names, in a JSON object or\narray or a form-encoded body, or a GraphQL response's ``errors`` or ``data``. A 2xx whose body\ndoesn't hold it, such as an HTML page, plain text, an empty 204, JSON that doesn't parse, JSON\nwithout the field, or JSON that isn't a GraphQL response, such as a gateway's own, leaves the\nwrite's outcome unknown: the vendor may have made it. So does a GraphQL answer with errors\nthat neither says the mutation was refused or never ran nor holds its result, such as a payload\nnulled by an error below the mutation's field, which came after the write, an error with no\npath beside ``data``, or a null ``data`` in a document of more than one mutation, which hides\nwhat the ones before the failing one did. A field with another value, or a GraphQL error at the\nmutation's own field, with that field null, or in an answer with no ``data``, is a write that\ndidn't happen."}},"type":"object","required":["kind"],"title":"EndpointWrites","description":"What a successful call to an endpoint writes, and how its response reports the write."},"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]},"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."}}}}
```

## The EnrichmentHistoryEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentHistoryEntry":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"value":{"title":"Value"},"value_type":{"type":"string","enum":["string","number","boolean","date","enum","json"],"title":"Value Type"},"confidence":{"type":"number","title":"Confidence"},"source":{"type":"string","title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At"},"ingested_at":{"type":"string","format":"date-time","title":"Ingested At"},"supersedes":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supersedes"},"is_current":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Current"}},"type":"object","required":["event_id","value","value_type","confidence","source","ingested_at","is_current"],"title":"EnrichmentHistoryEntry"}}}}
```

## The EnrichmentHistoryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentHistoryResponse":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"key":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z0-9][a-z0-9_\\-]*$","title":"Key"},"history":{"items":{"$ref":"#/components/schemas/EnrichmentHistoryEntry"},"type":"array","title":"History"},"dropped_count":{"type":"integer","title":"Dropped Count","default":0}},"type":"object","required":["entity_id","key","history"],"title":"EnrichmentHistoryResponse"},"EnrichmentHistoryEntry":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"value":{"title":"Value"},"value_type":{"type":"string","enum":["string","number","boolean","date","enum","json"],"title":"Value Type"},"confidence":{"type":"number","title":"Confidence"},"source":{"type":"string","title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At"},"ingested_at":{"type":"string","format":"date-time","title":"Ingested At"},"supersedes":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supersedes"},"is_current":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Current"}},"type":"object","required":["event_id","value","value_type","confidence","source","ingested_at","is_current"],"title":"EnrichmentHistoryEntry"}}}}
```

## The EnrichmentKeyCreateBody object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentKeyCreateBody":{"properties":{"entity_type":{"type":"string","maxLength":64,"minLength":1,"title":"Entity Type"},"key":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z0-9][a-z0-9_\\-]*$","title":"Key"},"value_type":{"type":"string","enum":["string","number","boolean","date","enum","json"],"title":"Value Type"},"allowed_values":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Allowed Values","description":"Required when value_type=enum. Ignored otherwise."},"source_hint":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"min_confidence":{"type":"number","maximum":1,"minimum":0,"title":"Min Confidence","default":0},"is_pii":{"type":"boolean","title":"Is Pii","default":false},"tags":{"items":{"type":"string","const":"memory_extract"},"type":"array","title":"Tags","description":"Routing tags. 'memory_extract' opts this key into memory extraction — the conversation extractor will infer it from transcripts as a workspace-custom memory dimension (person keys with a description only)."}},"type":"object","required":["entity_type","key","value_type"],"title":"EnrichmentKeyCreateBody"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The EnrichmentKeyListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentKeyListResponse":{"properties":{"keys":{"items":{"$ref":"#/components/schemas/EnrichmentKeyResponse"},"type":"array","title":"Keys"}},"type":"object","required":["keys"],"title":"EnrichmentKeyListResponse"},"EnrichmentKeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"entity_type":{"type":"string","maxLength":64,"minLength":1,"title":"Entity Type"},"key":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z0-9][a-z0-9_\\-]*$","title":"Key"},"value_type":{"type":"string","enum":["string","number","boolean","date","enum","json"],"title":"Value Type"},"allowed_values":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Allowed Values"},"source_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Hint"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"min_confidence":{"type":"number","title":"Min Confidence"},"is_pii":{"type":"boolean","title":"Is Pii"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","entity_type","key","value_type","min_confidence","is_pii","created_at","updated_at"],"title":"EnrichmentKeyResponse"}}}}
```

## The EnrichmentKeyPatchBody object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentKeyPatchBody":{"properties":{"allowed_values":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Allowed Values"},"source_hint":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"min_confidence":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Min Confidence"},"is_pii":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Pii"},"tags":{"anyOf":[{"items":{"type":"string","const":"memory_extract"},"type":"array"},{"type":"null"}],"title":"Tags","description":"Replaces the full tags list when set. Pass [] to remove all tags."}},"type":"object","title":"EnrichmentKeyPatchBody"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The EnrichmentKeyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentKeyResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"entity_type":{"type":"string","maxLength":64,"minLength":1,"title":"Entity Type"},"key":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z0-9][a-z0-9_\\-]*$","title":"Key"},"value_type":{"type":"string","enum":["string","number","boolean","date","enum","json"],"title":"Value Type"},"allowed_values":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Allowed Values"},"source_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Hint"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"min_confidence":{"type":"number","title":"Min Confidence"},"is_pii":{"type":"boolean","title":"Is Pii"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","entity_type","key","value_type","min_confidence","is_pii","created_at","updated_at"],"title":"EnrichmentKeyResponse"}}}}
```

## The EnrichmentListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentListResponse":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"values":{"items":{"$ref":"#/components/schemas/EnrichmentValueResponse"},"type":"array","title":"Values"}},"type":"object","required":["entity_id","values"],"title":"EnrichmentListResponse"},"EnrichmentValueResponse":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z0-9][a-z0-9_\\-]*$","title":"Key"},"value":{"title":"Value"},"value_type":{"type":"string","enum":["string","number","boolean","date","enum","json"],"title":"Value Type"},"confidence":{"type":"number","title":"Confidence"},"source":{"type":"string","title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At"},"event_id":{"type":"string","format":"uuid","title":"Event Id"},"overlay_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Overlay Status"}},"type":"object","required":["key","value","value_type","confidence","source","event_id"],"title":"EnrichmentValueResponse"}}}}
```

## The EnrichmentValueResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentValueResponse":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z0-9][a-z0-9_\\-]*$","title":"Key"},"value":{"title":"Value"},"value_type":{"type":"string","enum":["string","number","boolean","date","enum","json"],"title":"Value Type"},"confidence":{"type":"number","title":"Confidence"},"source":{"type":"string","title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At"},"event_id":{"type":"string","format":"uuid","title":"Event Id"},"overlay_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Overlay Status"}},"type":"object","required":["key","value","value_type","confidence","source","event_id"],"title":"EnrichmentValueResponse"}}}}
```

## The EnrichmentWriteBody object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EnrichmentWriteBody":{"properties":{"value":{"title":"Value","description":"Scalar or JSON-compatible value to store."},"value_type":{"anyOf":[{"type":"string","enum":["string","number","boolean","date","enum","json"]},{"type":"null"}],"title":"Value Type","description":"Overrides the registry value_type when set. Rarely needed."},"source":{"type":"string","maxLength":64,"minLength":1,"title":"Source","description":"Write source — e.g. manual, forms, auto_enrich.","default":"manual"},"source_system":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Source System","description":"Subsystem / connector identifier."},"confidence":{"type":"number","maximum":1,"minimum":0,"title":"Confidence","description":"Write confidence. Must be >= registry min_confidence for the key.","default":1},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At","description":"When the value became true (UTC). Defaults to ingested_at."}},"type":"object","required":["value"],"title":"EnrichmentWriteBody"}}}}
```

## The EntityEventResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"domain":{"type":"string","title":"Domain"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"event_type":{"type":"string","title":"Event Type"},"event_subtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Event Subtype"},"fhir_resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Type"},"fhir_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Id"},"data":{"additionalProperties":true,"type":"object","title":"Data"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","default":"manual"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence","default":1},"produced_by_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Produced By Agent"},"display_name":{"anyOf":[{"$ref":"#/components/schemas/EventDisplayNameString"},{"type":"null"}]},"status":{"anyOf":[{"$ref":"#/components/schemas/EventStatusString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/EventDescriptionString"},{"type":"null"}]},"outcome":{"anyOf":[{"$ref":"#/components/schemas/EventOutcomeString"},{"type":"null"}]},"channel":{"anyOf":[{"$ref":"#/components/schemas/EventChannelString"},{"type":"null"}]},"call_sid":{"anyOf":[{"$ref":"#/components/schemas/EventCallSidString"},{"type":"null"}]},"direction":{"anyOf":[{"$ref":"#/components/schemas/EventDirectionString"},{"type":"null"}]},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds"},"amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Amount"},"supersedes":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supersedes"},"is_current":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Current","default":true},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At"},"synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Synced At"},"sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Error"},"sync_status":{"anyOf":[{"type":"string","enum":["pending","synced","failed","processing","not_applicable"]},{"type":"null"}],"title":"Sync Status"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the event was created"}},"type":"object","required":["id","domain","event_type"],"title":"EntityEventResponse"},"EventDisplayNameString":{"type":"string","maxLength":512},"EventStatusString":{"type":"string","maxLength":128},"EventDescriptionString":{"type":"string","maxLength":4096},"EventOutcomeString":{"type":"string","maxLength":256},"EventChannelString":{"type":"string","maxLength":64},"EventCallSidString":{"type":"string","maxLength":128},"EventDirectionString":{"type":"string","maxLength":64}}}}
```

## The EntityListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityListResponse":{"properties":{"entities":{"items":{"$ref":"#/components/schemas/EntityResponse"},"type":"array","title":"Entities"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More"},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["entities","total","has_more"],"title":"EntityListResponse"},"EntityResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"entity_type":{"type":"string","title":"Entity Type"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"external_ids":{"additionalProperties":true,"type":"object","title":"External Ids"},"state":{"additionalProperties":true,"type":"object","title":"State","description":"Full JSONB state blob. Prefer typed fields below.","deprecated":true},"has_projection":{"type":"boolean","title":"Has Projection","default":false},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Display name (person, organization)"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"Primary phone number (E.164)"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Primary email address"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date","description":"Date of birth (YYYY-MM-DD)"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender","description":"Gender"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn","description":"Medical record number"},"appointment_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appointment Status","description":"Appointment status (booked, confirmed, cancelled)"},"appointment_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Appointment Start","description":"Appointment start time (UTC)"},"appointment_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Appointment End","description":"Appointment end time (UTC)"},"appointment_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appointment Type","description":"Appointment/visit type"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Organization domain"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry","description":"Organization industry"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"direction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Direction","description":"Call direction (inbound, outbound)"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Call duration in seconds"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Entity status"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Primary data source"},"first_seen_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"First Seen At"},"last_event_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Event At"},"event_count":{"type":"integer","title":"Event Count","default":0},"confidence":{"type":"number","title":"Confidence","default":1},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the entity was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the entity was last updated"}},"type":"object","required":["id","workspace_id","entity_type"],"title":"EntityResponse"}}}}
```

## The EntityRelationshipResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityRelationshipResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"source_entity_id":{"type":"string","format":"uuid","title":"Source Entity Id"},"source_entity_type":{"type":"string","title":"Source Entity Type"},"target_entity_id":{"type":"string","format":"uuid","title":"Target Entity Id"},"target_entity_type":{"type":"string","title":"Target Entity Type"},"relationship":{"type":"string","title":"Relationship"},"data":{"additionalProperties":true,"type":"object","title":"Data"},"confidence":{"type":"number","title":"Confidence","default":1},"discovered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Discovered By"},"is_current":{"type":"boolean","title":"Is Current","default":true},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the relationship was created"}},"type":"object","required":["id","source_entity_id","source_entity_type","target_entity_id","target_entity_type","relationship"],"title":"EntityRelationshipResponse"}}}}
```

## The EntityRelationshipsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityRelationshipsResponse":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"relationships":{"items":{"$ref":"#/components/schemas/EntityRelationshipResponse"},"type":"array","title":"Relationships"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["entity_id","relationships","total"],"title":"EntityRelationshipsResponse"},"EntityRelationshipResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"source_entity_id":{"type":"string","format":"uuid","title":"Source Entity Id"},"source_entity_type":{"type":"string","title":"Source Entity Type"},"target_entity_id":{"type":"string","format":"uuid","title":"Target Entity Id"},"target_entity_type":{"type":"string","title":"Target Entity Type"},"relationship":{"type":"string","title":"Relationship"},"data":{"additionalProperties":true,"type":"object","title":"Data"},"confidence":{"type":"number","title":"Confidence","default":1},"discovered_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Discovered By"},"is_current":{"type":"boolean","title":"Is Current","default":true},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the relationship was created"}},"type":"object","required":["id","source_entity_id","source_entity_type","target_entity_id","target_entity_type","relationship"],"title":"EntityRelationshipResponse"}}}}
```

## The EntityResolutionMetrics object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityResolutionMetrics":{"properties":{"total_same_as_edges":{"type":"integer","title":"Total Same As Edges"},"recent_merges_24h":{"type":"integer","title":"Recent Merges 24H"}},"type":"object","required":["total_same_as_edges","recent_merges_24h"],"title":"EntityResolutionMetrics"}}}}
```

## The EntityResolveExternalId object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityResolveExternalId":{"properties":{"system":{"$ref":"#/components/schemas/ExternalSystemString","description":"External system label (lowercase, e.g. 'epic')."},"value":{"$ref":"#/components/schemas/ExternalValueString","description":"System-issued identifier."}},"type":"object","required":["system","value"],"title":"EntityResolveExternalId","description":"Reference to an external-system identifier.\n\n``system`` labels which system minted the value (``epic``, ``charm``,\n``charmhealth``, …). Resolution probes the canonical entity map\nwith the candidate key forms\n``{system}:{ResourceType}:{value}`` (Patient / Practitioner /\nOrganization / Appointment) plus the bare ``value`` — so ``system``\nconstrains the probe keys, and the request's ``entity_type``\nconstrains the map slice. External aliases that were never minted as\ncanonical keys (the legacy ``external_ids`` JSONB junk-drawer\nentries) are no longer resolvable."},"ExternalSystemString":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z0-9_\\-]+$"},"ExternalValueString":{"type":"string","maxLength":256,"minLength":1}}}}
```

## The EntityResolveMatch object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityResolveMatch":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"entity_type":{"type":"string","title":"Entity Type"},"confidence":{"type":"number","maximum":1,"minimum":0,"title":"Confidence","description":"Match confidence (0-1)."},"matched_on":{"items":{"type":"string","enum":["entity_id","phone","email","canonical_id","external_id"]},"type":"array","title":"Matched On","description":"Identifier kinds that actually matched this row."},"summary":{"$ref":"#/components/schemas/EntityResolveSummary"}},"type":"object","required":["entity_id","entity_type","confidence","summary"],"title":"EntityResolveMatch","description":"One candidate match with provenance + confidence."},"EntityResolveSummary":{"properties":{"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id","description":"Canonical-map value when resolved through the map, else the entity's MRN."},"external_ids":{"additionalProperties":true,"type":"object","title":"External Ids","description":"Always {} — external aliases live in the canonical entity map, not on the serving row."},"last_event_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Event At"},"event_count":{"type":"integer","title":"Event Count","default":0},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Always [] — no tags column on the synced serving table."}},"type":"object","title":"EntityResolveSummary","description":"Compact identity card returned for each match.\n\nExcludes full entity state — fetch via\n``GET /v1/{ws}/entities/{entity_id}`` if needed. The fields here are\nthe ones a UI / agent needs to confirm \"yes, that's the right\nperson\" before paying for the full state read.\n\nStage-7 narrowing (resolver serves from ``entities_synced`` +\nthe canonical entity map; fields retained for wire compatibility):\n``external_ids`` is always ``{}`` and ``tags`` is always ``[]`` —\nneither survives on the synced serving table. ``canonical_id`` is\nthe canonical-map value when the row resolved through the map, else\nthe entity's MRN."}}}}
```

## The EntityResolveRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityResolveRequest":{"properties":{"entity_type":{"$ref":"#/components/schemas/EntityTypeString","description":"Required entity type filter (e.g. 'person'). Narrows the scan to the right index."},"phone":{"anyOf":[{"$ref":"#/components/schemas/PhoneE164"},{"type":"null"}],"description":"E.164 phone number."},"email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Email","description":"Primary email (case-insensitive match)."},"canonical_id":{"anyOf":[{"$ref":"#/components/schemas/CanonicalIdLookupString"},{"type":"null"}],"description":"Canonical identifier as carried by the canonical entity map (e.g. 'charm:Patient:42'; a raw MRN resolves only when a producer minted it as the canonical_id)."},"external_id":{"anyOf":[{"$ref":"#/components/schemas/EntityResolveExternalId"},{"type":"null"}],"description":"External-system identifier reference."},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"Direct UUID lookup. Useful for confirming an entity exists / re-fetching summary."},"limit":{"type":"integer","maximum":50,"minimum":1,"title":"Limit","description":"Maximum candidates to return.","default":25}},"type":"object","required":["entity_type"],"title":"EntityResolveRequest","description":"Polymorphic identifier query.\n\nProvide ``entity_type`` plus any subset of identifier fields. Each\nidentifier is OR-ed in SQL; matches are ranked by confidence and\nby the number of identifiers that actually matched the row.\nReturns at most ``limit`` candidates (default 25, max 50).\n\nFor latency-sensitive callers (inbound voice, webhook handlers),\npass exactly one identifier — the indexed lookup is sub-10ms.\nMulti-identifier queries are useful for confirming a row matches\non more than one signal (phone + email + MRN)."},"EntityTypeString":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z0-9_]+$"},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"CanonicalIdLookupString":{"type":"string","maxLength":256,"minLength":1},"EntityResolveExternalId":{"properties":{"system":{"$ref":"#/components/schemas/ExternalSystemString","description":"External system label (lowercase, e.g. 'epic')."},"value":{"$ref":"#/components/schemas/ExternalValueString","description":"System-issued identifier."}},"type":"object","required":["system","value"],"title":"EntityResolveExternalId","description":"Reference to an external-system identifier.\n\n``system`` labels which system minted the value (``epic``, ``charm``,\n``charmhealth``, …). Resolution probes the canonical entity map\nwith the candidate key forms\n``{system}:{ResourceType}:{value}`` (Patient / Practitioner /\nOrganization / Appointment) plus the bare ``value`` — so ``system``\nconstrains the probe keys, and the request's ``entity_type``\nconstrains the map slice. External aliases that were never minted as\ncanonical keys (the legacy ``external_ids`` JSONB junk-drawer\nentries) are no longer resolvable."},"ExternalSystemString":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z0-9_\\-]+$"},"ExternalValueString":{"type":"string","maxLength":256,"minLength":1}}}}
```

## The EntityResolveResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityResolveResponse":{"properties":{"matches":{"items":{"$ref":"#/components/schemas/EntityResolveMatch"},"type":"array","title":"Matches"},"total":{"type":"integer","minimum":0,"title":"Total","description":"Number of candidates returned."}},"type":"object","required":["total"],"title":"EntityResolveResponse"},"EntityResolveMatch":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"entity_type":{"type":"string","title":"Entity Type"},"confidence":{"type":"number","maximum":1,"minimum":0,"title":"Confidence","description":"Match confidence (0-1)."},"matched_on":{"items":{"type":"string","enum":["entity_id","phone","email","canonical_id","external_id"]},"type":"array","title":"Matched On","description":"Identifier kinds that actually matched this row."},"summary":{"$ref":"#/components/schemas/EntityResolveSummary"}},"type":"object","required":["entity_id","entity_type","confidence","summary"],"title":"EntityResolveMatch","description":"One candidate match with provenance + confidence."},"EntityResolveSummary":{"properties":{"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id","description":"Canonical-map value when resolved through the map, else the entity's MRN."},"external_ids":{"additionalProperties":true,"type":"object","title":"External Ids","description":"Always {} — external aliases live in the canonical entity map, not on the serving row."},"last_event_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Event At"},"event_count":{"type":"integer","title":"Event Count","default":0},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Always [] — no tags column on the synced serving table."}},"type":"object","title":"EntityResolveSummary","description":"Compact identity card returned for each match.\n\nExcludes full entity state — fetch via\n``GET /v1/{ws}/entities/{entity_id}`` if needed. The fields here are\nthe ones a UI / agent needs to confirm \"yes, that's the right\nperson\" before paying for the full state read.\n\nStage-7 narrowing (resolver serves from ``entities_synced`` +\nthe canonical entity map; fields retained for wire compatibility):\n``external_ids`` is always ``{}`` and ``tags`` is always ``[]`` —\nneither survives on the synced serving table. ``canonical_id`` is\nthe canonical-map value when the row resolved through the map, else\nthe entity's MRN."}}}}
```

## The EntityResolveSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityResolveSummary":{"properties":{"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id","description":"Canonical-map value when resolved through the map, else the entity's MRN."},"external_ids":{"additionalProperties":true,"type":"object","title":"External Ids","description":"Always {} — external aliases live in the canonical entity map, not on the serving row."},"last_event_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Event At"},"event_count":{"type":"integer","title":"Event Count","default":0},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Always [] — no tags column on the synced serving table."}},"type":"object","title":"EntityResolveSummary","description":"Compact identity card returned for each match.\n\nExcludes full entity state — fetch via\n``GET /v1/{ws}/entities/{entity_id}`` if needed. The fields here are\nthe ones a UI / agent needs to confirm \"yes, that's the right\nperson\" before paying for the full state read.\n\nStage-7 narrowing (resolver serves from ``entities_synced`` +\nthe canonical entity map; fields retained for wire compatibility):\n``external_ids`` is always ``{}`` and ``tags`` is always ``[]`` —\nneither survives on the synced serving table. ``canonical_id`` is\nthe canonical-map value when the row resolved through the map, else\nthe entity's MRN."}}}}
```

## The EntityResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"entity_type":{"type":"string","title":"Entity Type"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"external_ids":{"additionalProperties":true,"type":"object","title":"External Ids"},"state":{"additionalProperties":true,"type":"object","title":"State","description":"Full JSONB state blob. Prefer typed fields below.","deprecated":true},"has_projection":{"type":"boolean","title":"Has Projection","default":false},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Display name (person, organization)"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"Primary phone number (E.164)"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Primary email address"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date","description":"Date of birth (YYYY-MM-DD)"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender","description":"Gender"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn","description":"Medical record number"},"appointment_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appointment Status","description":"Appointment status (booked, confirmed, cancelled)"},"appointment_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Appointment Start","description":"Appointment start time (UTC)"},"appointment_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Appointment End","description":"Appointment end time (UTC)"},"appointment_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appointment Type","description":"Appointment/visit type"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Organization domain"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry","description":"Organization industry"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"direction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Direction","description":"Call direction (inbound, outbound)"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Call duration in seconds"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Entity status"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Primary data source"},"first_seen_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"First Seen At"},"last_event_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Event At"},"event_count":{"type":"integer","title":"Event Count","default":0},"confidence":{"type":"number","title":"Confidence","default":1},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the entity was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the entity was last updated"}},"type":"object","required":["id","workspace_id","entity_type"],"title":"EntityResponse"}}}}
```

## The EntityStatsSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityStatsSummary":{"properties":{"total_entities":{"type":"integer","title":"Total Entities"},"total_events":{"type":"integer","title":"Total Events"},"sync_pending":{"type":"integer","title":"Sync Pending"},"sync_synced":{"type":"integer","title":"Sync Synced"},"sync_failed":{"type":"integer","title":"Sync Failed"},"by_event_type":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Event Type"}},"type":"object","required":["total_entities","total_events","sync_pending","sync_synced","sync_failed"],"title":"EntityStatsSummary"}}}}
```

## The EntityTimelineResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityTimelineResponse":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"events":{"items":{"$ref":"#/components/schemas/EntityEventResponse"},"type":"array","title":"Events"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More"},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["entity_id","events","total","has_more"],"title":"EntityTimelineResponse"},"EntityEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"domain":{"type":"string","title":"Domain"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"event_type":{"type":"string","title":"Event Type"},"event_subtype":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Event Subtype"},"fhir_resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Type"},"fhir_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Id"},"data":{"additionalProperties":true,"type":"object","title":"Data"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","default":"manual"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence","default":1},"produced_by_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Produced By Agent"},"display_name":{"anyOf":[{"$ref":"#/components/schemas/EventDisplayNameString"},{"type":"null"}]},"status":{"anyOf":[{"$ref":"#/components/schemas/EventStatusString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/EventDescriptionString"},{"type":"null"}]},"outcome":{"anyOf":[{"$ref":"#/components/schemas/EventOutcomeString"},{"type":"null"}]},"channel":{"anyOf":[{"$ref":"#/components/schemas/EventChannelString"},{"type":"null"}]},"call_sid":{"anyOf":[{"$ref":"#/components/schemas/EventCallSidString"},{"type":"null"}]},"direction":{"anyOf":[{"$ref":"#/components/schemas/EventDirectionString"},{"type":"null"}]},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds"},"amount":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Amount"},"supersedes":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Supersedes"},"is_current":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Current","default":true},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At"},"synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Synced At"},"sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Error"},"sync_status":{"anyOf":[{"type":"string","enum":["pending","synced","failed","processing","not_applicable"]},{"type":"null"}],"title":"Sync Status"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the event was created"}},"type":"object","required":["id","domain","event_type"],"title":"EntityEventResponse"},"EventDisplayNameString":{"type":"string","maxLength":512},"EventStatusString":{"type":"string","maxLength":128},"EventDescriptionString":{"type":"string","maxLength":4096},"EventOutcomeString":{"type":"string","maxLength":256},"EventChannelString":{"type":"string","maxLength":64},"EventCallSidString":{"type":"string","maxLength":128},"EventDirectionString":{"type":"string","maxLength":64}}}}
```

## The EntityTypeRegistryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityTypeRegistryResponse":{"properties":{"entity_types":{"items":{"$ref":"#/components/schemas/EntityTypeSummary"},"type":"array","title":"Entity Types"},"total_entities":{"type":"integer","title":"Total Entities"}},"type":"object","required":["entity_types","total_entities"],"title":"EntityTypeRegistryResponse"},"EntityTypeSummary":{"properties":{"entity_type":{"type":"string","title":"Entity Type"},"count":{"type":"integer","title":"Count"},"last_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Updated"},"has_projection":{"type":"boolean","title":"Has Projection"}},"type":"object","required":["entity_type","count","last_updated","has_projection"],"title":"EntityTypeSummary"}}}}
```

## The EntityTypeString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityTypeString":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z0-9_]+$"}}}}
```

## The EntityTypeSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EntityTypeSummary":{"properties":{"entity_type":{"type":"string","title":"Entity Type"},"count":{"type":"integer","title":"Count"},"last_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Updated"},"has_projection":{"type":"boolean","title":"Has Projection"}},"type":"object","required":["entity_type","count","last_updated","has_projection"],"title":"EntityTypeSummary"}}}}
```

## The ErrorResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ErrorResponse":{"properties":{"detail":{"type":"string","title":"Detail"}},"type":"object","required":["detail"],"title":"ErrorResponse","description":"The body of an ``HTTPException``: ``{\"detail\": \"<message>\"}``."}}}}
```

## The EscalationDailyStats object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EscalationDailyStats":{"properties":{"requested":{"type":"integer","title":"Requested","default":0},"connected":{"type":"integer","title":"Connected","default":0},"completed":{"type":"integer","title":"Completed","default":0},"avg_wait_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Wait Seconds"},"avg_handle_time_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Handle Time Seconds"}},"type":"object","title":"EscalationDailyStats"}}}}
```

## The EscalationEventListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EscalationEventListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/EscalationEventResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"EscalationEventListResponse"},"EscalationEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"event_type":{"type":"string","title":"Event Type","description":"Event type (e.g. escalation.requested, escalation.connected)"},"data":{"additionalProperties":true,"type":"object","title":"Data","description":"Event payload — shape varies by event_type"},"source":{"type":"string","title":"Source","description":"System that emitted the event"},"confidence":{"type":"number","title":"Confidence","description":"Confidence score 0.0 to 1.0"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At","description":"When the event was ingested"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the event occurred"}},"type":"object","required":["id","workspace_id","event_type","data","source","confidence"],"title":"EscalationEventResponse"}}}}
```

## The EscalationEventResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EscalationEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"event_type":{"type":"string","title":"Event Type","description":"Event type (e.g. escalation.requested, escalation.connected)"},"data":{"additionalProperties":true,"type":"object","title":"Data","description":"Event payload — shape varies by event_type"},"source":{"type":"string","title":"Source","description":"System that emitted the event"},"confidence":{"type":"number","title":"Confidence","description":"Confidence score 0.0 to 1.0"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At","description":"When the event was ingested"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the event occurred"}},"type":"object","required":["id","workspace_id","event_type","data","source","confidence"],"title":"EscalationEventResponse"}}}}
```

## The EscalationState object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EscalationState":{"properties":{"status":{"type":"string","title":"Status","default":"none"},"escalation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Escalation Id"},"requested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"Requested At"},"connected_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"Connected At"},"completed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"Completed At"},"trigger":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger"},"trigger_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger Source"},"concept":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Concept"},"similarity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Similarity"},"agent_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Confidence"},"operator_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Operator Type"},"regulatory_basis":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Regulatory Basis"},"immediate":{"type":"boolean","title":"Immediate","default":false},"risk_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Risk Score"},"operator_entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Operator Entity Id"},"wait_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Wait Seconds"},"handle_time_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Handle Time Seconds"},"human_segment_turn_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Human Segment Turn Count"}},"type":"object","title":"EscalationState"}}}}
```

## The EscalationStatsBucket object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EscalationStatsBucket":{"properties":{"key":{"type":"string","title":"Key"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["key","count"],"title":"EscalationStatsBucket"}}}}
```

## The EscalationStatsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EscalationStatsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"period":{"type":"string","title":"Period"},"group_by":{"type":"string","title":"Group By"},"buckets":{"items":{"$ref":"#/components/schemas/EscalationStatsBucket"},"type":"array","title":"Buckets"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["workspace_id","period","group_by","buckets","total"],"title":"EscalationStatsResponse"},"EscalationStatsBucket":{"properties":{"key":{"type":"string","title":"Key"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["key","count"],"title":"EscalationStatsBucket"}}}}
```

## The EvalKeyQuality object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EvalKeyQuality":{"properties":{"eval_key":{"type":"string","title":"Eval Key","description":"The eval key the verdicts belong to"},"summary":{"$ref":"#/components/schemas/EvalQualitySummary","description":"The eval key's aggregate for the period"},"trend":{"items":{"$ref":"#/components/schemas/EvalQualityTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"The eval key's trend"}},"type":"object","required":["eval_key","summary","trend"],"title":"EvalKeyQuality","description":"One eval key's verdicts: the summary and trend the route returns for ``eval_key`` set to it."},"EvalQualitySummary":{"properties":{"eval_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Eval Key","description":"Eval key for a per-key row; null for the overall summary"},"total_evals":{"type":"integer","title":"Total Evals","description":"Total verdicts recorded (any status, incl. errored)"},"judged":{"type":"integer","title":"Judged","description":"Verdicts with a non-null pass/fail outcome (denominator for pass_rate)"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"Fraction of judged verdicts that passed (0.0-1.0). Null when none were judged, which is not 0.0: judged, and none passed"},"avg_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Score","description":"Mean numeric value of metric verdicts; null when none are numeric"}},"type":"object","required":["total_evals","judged"],"title":"EvalQualitySummary","description":"Aggregate production-eval verdict stats, overall or for one eval_key.\n\nSourced from ``call_eval_results`` (assertion and metric verdicts), which is\nkeyed by ``conversation_id`` and therefore CHANNEL-AGNOSTIC — voice, text,\nSMS, email all contribute equally, unlike the voice-shaped call-quality score."},"EvalQualityTrendPoint":{"properties":{"date":{"type":"string","format":"date","title":"Date","description":"Date of the bucket: the day for a daily bucket, the Monday for a weekly one, and for an hourly bucket the day it falls in, so the buckets of one day share this date"},"total_evals":{"type":"integer","title":"Total Evals","description":"Total verdicts in this bucket"},"judged":{"type":"integer","title":"Judged","description":"Verdicts with a non-null pass/fail outcome in this bucket"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"Fraction of judged verdicts that passed in this bucket. Null when none were judged, which is not 0.0: judged, and none passed"},"avg_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Score","description":"Mean numeric value of metric verdicts in this bucket"}},"type":"object","required":["date","total_evals","judged"],"title":"EvalQualityTrendPoint","description":"Single date-bucket data point in the eval-quality trend series. A bucket with no verdicts has no point."}}}}
```

## The EvalQualityResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EvalQualityResponse":{"properties":{"summary":{"$ref":"#/components/schemas/EvalQualitySummary","description":"Workspace-wide aggregate for the period"},"by_eval_key":{"items":{"$ref":"#/components/schemas/EvalQualitySummary"},"type":"array","maxItems":200,"title":"By Eval Key","description":"Per-eval-key aggregates, most-evaluated first, ties by eval_key. At most 200: a workspace with more lists its most-evaluated keys"},"trend":{"items":{"$ref":"#/components/schemas/EvalQualityTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"Time series of eval pass-rate/score per interval bucket"},"groups":{"anyOf":[{"items":{"$ref":"#/components/schemas/ServiceEvalQuality"},"type":"array"},{"type":"null"}],"title":"Groups","description":"With group_by=service_id, one entry per service with verdicts in the window, ordered by service_id, then a last group with a null service_id for the verdicts saved without a service (workspace-wide checks). The groups' trends hold at most 22,000 points in all; a grouped answer that would hold more is a 422. Null without group_by=service_id."},"eval_key_groups":{"anyOf":[{"items":{"$ref":"#/components/schemas/EvalKeyQuality"},"type":"array","maxItems":200},{"type":"null"}],"title":"Eval Key Groups","description":"With group_by=eval_key, one entry per eval key with verdicts in the window, in the order of by_eval_key: most-evaluated first, ties by eval_key, at most 200. Each entry holds the summary and trend the route returns for that eval_key; with service_id, these are that service's eval keys. The groups' trends hold at most 22,000 points in all; a grouped answer that would hold more is a 422. Null without group_by=eval_key."}},"type":"object","required":["summary","by_eval_key","trend"],"title":"EvalQualityResponse","description":"Production-eval quality: overall pass-rate/score, per-eval-key breakdown, and a trend.\n\nThe channel-agnostic quality surface. Returns zeroed shapes (empty ``by_eval_key``\nand ``trend``, null rates) when no verdicts exist for the workspace/window. The\nconsole renders an empty-state rather than erroring, so this ships safely ahead of\nthe eager-eval trigger being enabled in production.\n\nA verdict belongs to the window and to its trend bucket by ``computed_at``, the UTC time its check last\nran. Evaluating a conversation again replaces its verdict and moves it to the new time; the time the\nconversation took place plays no part."},"EvalQualitySummary":{"properties":{"eval_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Eval Key","description":"Eval key for a per-key row; null for the overall summary"},"total_evals":{"type":"integer","title":"Total Evals","description":"Total verdicts recorded (any status, incl. errored)"},"judged":{"type":"integer","title":"Judged","description":"Verdicts with a non-null pass/fail outcome (denominator for pass_rate)"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"Fraction of judged verdicts that passed (0.0-1.0). Null when none were judged, which is not 0.0: judged, and none passed"},"avg_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Score","description":"Mean numeric value of metric verdicts; null when none are numeric"}},"type":"object","required":["total_evals","judged"],"title":"EvalQualitySummary","description":"Aggregate production-eval verdict stats, overall or for one eval_key.\n\nSourced from ``call_eval_results`` (assertion and metric verdicts), which is\nkeyed by ``conversation_id`` and therefore CHANNEL-AGNOSTIC — voice, text,\nSMS, email all contribute equally, unlike the voice-shaped call-quality score."},"EvalQualityTrendPoint":{"properties":{"date":{"type":"string","format":"date","title":"Date","description":"Date of the bucket: the day for a daily bucket, the Monday for a weekly one, and for an hourly bucket the day it falls in, so the buckets of one day share this date"},"total_evals":{"type":"integer","title":"Total Evals","description":"Total verdicts in this bucket"},"judged":{"type":"integer","title":"Judged","description":"Verdicts with a non-null pass/fail outcome in this bucket"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"Fraction of judged verdicts that passed in this bucket. Null when none were judged, which is not 0.0: judged, and none passed"},"avg_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Score","description":"Mean numeric value of metric verdicts in this bucket"}},"type":"object","required":["date","total_evals","judged"],"title":"EvalQualityTrendPoint","description":"Single date-bucket data point in the eval-quality trend series. A bucket with no verdicts has no point."},"ServiceEvalQuality":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"The service the verdicts are attributed to. Null groups the verdicts saved with no service"},"summary":{"$ref":"#/components/schemas/EvalQualitySummary","description":"The service's aggregate for the period"},"by_eval_key":{"items":{"$ref":"#/components/schemas/EvalQualitySummary"},"type":"array","maxItems":200,"title":"By Eval Key","description":"The service's per-eval-key aggregates, most-evaluated first, ties by eval_key. At most 200: a service with more lists its most-evaluated keys"},"trend":{"items":{"$ref":"#/components/schemas/EvalQualityTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"The service's trend"}},"type":"object","required":["service_id","summary","by_eval_key","trend"],"title":"ServiceEvalQuality","description":"One service's verdicts: what the route returns for ``service_id`` set to it."},"EvalKeyQuality":{"properties":{"eval_key":{"type":"string","title":"Eval Key","description":"The eval key the verdicts belong to"},"summary":{"$ref":"#/components/schemas/EvalQualitySummary","description":"The eval key's aggregate for the period"},"trend":{"items":{"$ref":"#/components/schemas/EvalQualityTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"The eval key's trend"}},"type":"object","required":["eval_key","summary","trend"],"title":"EvalKeyQuality","description":"One eval key's verdicts: the summary and trend the route returns for ``eval_key`` set to it."}}}}
```

## The EvalQualitySummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EvalQualitySummary":{"properties":{"eval_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Eval Key","description":"Eval key for a per-key row; null for the overall summary"},"total_evals":{"type":"integer","title":"Total Evals","description":"Total verdicts recorded (any status, incl. errored)"},"judged":{"type":"integer","title":"Judged","description":"Verdicts with a non-null pass/fail outcome (denominator for pass_rate)"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"Fraction of judged verdicts that passed (0.0-1.0). Null when none were judged, which is not 0.0: judged, and none passed"},"avg_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Score","description":"Mean numeric value of metric verdicts; null when none are numeric"}},"type":"object","required":["total_evals","judged"],"title":"EvalQualitySummary","description":"Aggregate production-eval verdict stats, overall or for one eval_key.\n\nSourced from ``call_eval_results`` (assertion and metric verdicts), which is\nkeyed by ``conversation_id`` and therefore CHANNEL-AGNOSTIC — voice, text,\nSMS, email all contribute equally, unlike the voice-shaped call-quality score."}}}}
```

## The EvalQualityTrendPoint object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EvalQualityTrendPoint":{"properties":{"date":{"type":"string","format":"date","title":"Date","description":"Date of the bucket: the day for a daily bucket, the Monday for a weekly one, and for an hourly bucket the day it falls in, so the buckets of one day share this date"},"total_evals":{"type":"integer","title":"Total Evals","description":"Total verdicts in this bucket"},"judged":{"type":"integer","title":"Judged","description":"Verdicts with a non-null pass/fail outcome in this bucket"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"Fraction of judged verdicts that passed in this bucket. Null when none were judged, which is not 0.0: judged, and none passed"},"avg_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Score","description":"Mean numeric value of metric verdicts in this bucket"}},"type":"object","required":["date","total_evals","judged"],"title":"EvalQualityTrendPoint","description":"Single date-bucket data point in the eval-quality trend series. A bucket with no verdicts has no point."}}}}
```

## The EvaluationResultView object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EvaluationResultView":{"properties":{"source_type":{"type":"string","enum":["metric","assertion"],"title":"Source Type"},"key":{"type":"string","maxLength":128,"title":"Key"},"label":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Label"},"value_type":{"anyOf":[{"type":"string","enum":["numeric","boolean","categorical","text","structured"]},{"type":"null"}],"title":"Value Type"},"evaluation_method":{"anyOf":[{"type":"string","enum":["threshold","equals","contains","regex","tool_called","llm_judge","custom"]},{"type":"null"}],"title":"Evaluation Method"},"grading":{"anyOf":[{"type":"string","enum":["observed_vs_expected","legacy_verdict"]},{"type":"null"}],"title":"Grading","description":"For an LLM-judged assertion: observed_vs_expected (actual is what the judge observed, and the verdict compares it with expected) or legacy_verdict (the judge returned the verdict and observed nothing, so actual is empty). Null otherwise."},"instructions":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Instructions","description":"An llm_boolean assertion's question, with what makes it true or false."},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"expected_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Expected Display"},"actual_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Actual Display"},"verdict":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Verdict"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"rationale":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Rationale"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"run_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"trace_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Trace Id"}},"type":"object","required":["source_type","key","verdict"],"title":"EvaluationResultView","description":"One check as the console renders it, derived from a single eval result.\n\nBoth metric and assertion verdicts normalize to this shape so the frontend\nrenders a check without knowing where the value was stored."}}}}
```

## The EventBreakdownItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventBreakdownItem":{"properties":{"key":{"type":"string","title":"Key","description":"Grouping key (event type or source name)"},"count":{"type":"integer","title":"Count","description":"Number of events for this key"}},"type":"object","required":["key","count"],"title":"EventBreakdownItem","description":"Single row in an event breakdown aggregation."}}}}
```

## The EventBreakdownResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventBreakdownResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace identifier"},"period_start":{"type":"string","format":"date","title":"Period Start","description":"Start of the reporting period"},"period_end":{"type":"string","format":"date","title":"Period End","description":"End of the reporting period"},"by_type":{"items":{"$ref":"#/components/schemas/EventBreakdownItem"},"type":"array","title":"By Type","description":"Event counts grouped by event type"},"by_source":{"items":{"$ref":"#/components/schemas/EventBreakdownItem"},"type":"array","title":"By Source","description":"Event counts grouped by source"},"total_events":{"type":"integer","title":"Total Events","description":"Total number of events in the period"}},"type":"object","required":["workspace_id","period_start","period_end","by_type","by_source","total_events"],"title":"EventBreakdownResponse"},"EventBreakdownItem":{"properties":{"key":{"type":"string","title":"Key","description":"Grouping key (event type or source name)"},"count":{"type":"integer","title":"Count","description":"Number of events for this key"}},"type":"object","required":["key","count"],"title":"EventBreakdownItem","description":"Single row in an event breakdown aggregation."}}}}
```

## The EventCallSidString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventCallSidString":{"type":"string","maxLength":128}}}}
```

## The EventChannelString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventChannelString":{"type":"string","maxLength":64}}}}
```

## The EventDescriptionString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventDescriptionString":{"type":"string","maxLength":4096}}}}
```

## The EventDirectionString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventDirectionString":{"type":"string","maxLength":64}}}}
```

## The EventDisplayNameString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventDisplayNameString":{"type":"string","maxLength":512}}}}
```

## The EventOutcomeString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventOutcomeString":{"type":"string","maxLength":256}}}}
```

## The EventStatusString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventStatusString":{"type":"string","maxLength":128}}}}
```

## The EventTypeRegistryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventTypeRegistryResponse":{"properties":{"event_types":{"items":{"$ref":"#/components/schemas/EventTypeSummary"},"type":"array","title":"Event Types"},"total_events":{"type":"integer","title":"Total Events"}},"type":"object","required":["event_types","total_events"],"title":"EventTypeRegistryResponse"},"EventTypeSummary":{"properties":{"event_type":{"type":"string","title":"Event Type"},"count":{"type":"integer","title":"Count"},"domains":{"items":{"type":"string"},"type":"array","title":"Domains"},"sources":{"items":{"type":"string"},"type":"array","title":"Sources"}},"type":"object","required":["event_type","count","domains","sources"],"title":"EventTypeSummary"}}}}
```

## The EventTypeSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EventTypeSummary":{"properties":{"event_type":{"type":"string","title":"Event Type"},"count":{"type":"integer","title":"Count"},"domains":{"items":{"type":"string"},"type":"array","title":"Domains"},"sources":{"items":{"type":"string"},"type":"array","title":"Sources"}},"type":"object","required":["event_type","count","domains","sources"],"title":"EventTypeSummary"}}}}
```

## The EvidenceColumn object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EvidenceColumn":{"properties":{"index":{"type":"integer","title":"Index"},"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"}},"type":"object","required":["index","name","type"],"title":"EvidenceColumn"}}}}
```

## The ExecutePanelRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExecutePanelRequest":{"properties":{"filter_values":{"additionalProperties":true,"type":"object","title":"Filter Values","description":"Filter values to apply to panel queries"}},"type":"object","title":"ExecutePanelRequest"}}}}
```

## The ExitCondition object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"}}}}
```

## The ExplorationConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExplorationConfig":{"properties":{"coverage_driven_selection":{"type":"boolean","title":"Coverage Driven Selection","default":false},"enable_forking":{"type":"boolean","title":"Enable Forking","default":false},"max_forks_per_scenario":{"type":"integer","maximum":5,"minimum":0,"title":"Max Forks Per Scenario","default":2},"recommend_candidates":{"type":"integer","maximum":10,"minimum":1,"title":"Recommend Candidates","default":3}},"type":"object","title":"ExplorationConfig"}}}}
```

## The ExternalAuthClaim object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalAuthClaim":{"properties":{"namespace":{"type":"string","maxLength":64,"pattern":"^[a-z][a-z0-9_.:-]{0,63}$","title":"Namespace"},"key":{"type":"string","maxLength":64,"pattern":"^[a-z][a-z0-9_.:-]{0,63}$","title":"Key"},"value":{"type":"string","maxLength":256,"minLength":1,"title":"Value"}},"additionalProperties":false,"type":"object","required":["namespace","key","value"],"title":"ExternalAuthClaim","description":"One normalized customer assertion: the exact tuple ``(namespace, key, value)``.\n\n``value`` is preserved byte-for-byte (bounded length only) — Amigo does not\nlowercase, alias, or rewrite it. ``namespace`` and ``key`` are bounded canonical\nidentifiers. Arrays, objects, numbers, booleans, and null are rejected for every\nfield (v1 values are non-empty strings)."}}}}
```

## The ExternalIdentityBindingItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIdentityBindingItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"external_integration_id":{"type":"string","format":"uuid","title":"External Integration Id"},"subject_type":{"type":"string","const":"user","title":"Subject Type"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","deprecated":true},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"status":{"type":"string","enum":["active","revoked"],"title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","external_integration_id","subject_type","entity_id","status","created_at","updated_at"],"title":"ExternalIdentityBindingItem"}}}}
```

## The ExternalIdentityBindingListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIdentityBindingListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ExternalIdentityBindingItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ExternalIdentityBindingListResponse"},"ExternalIdentityBindingItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"external_integration_id":{"type":"string","format":"uuid","title":"External Integration Id"},"subject_type":{"type":"string","const":"user","title":"Subject Type"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","deprecated":true},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"status":{"type":"string","enum":["active","revoked"],"title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","external_integration_id","subject_type","entity_id","status","created_at","updated_at"],"title":"ExternalIdentityBindingItem"}}}}
```

## The ExternalIdentityBindingUpsertResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIdentityBindingUpsertResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"external_integration_id":{"type":"string","format":"uuid","title":"External Integration Id"},"subject_type":{"type":"string","const":"user","title":"Subject Type"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","deprecated":true},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"status":{"type":"string","enum":["active","revoked"],"title":"Status"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"upsert_outcome":{"type":"string","enum":["created","materialized","unchanged"],"title":"Upsert Outcome"}},"type":"object","required":["id","external_integration_id","subject_type","entity_id","status","created_at","updated_at","upsert_outcome"],"title":"ExternalIdentityBindingUpsertResponse"}}}}
```

## The ExternalIntegrationCredentialRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIntegrationCredentialRequest":{"properties":{"service_ids":{"items":{"type":"string","format":"uuid"},"type":"array","maxItems":100,"minItems":1,"title":"Service Ids"},"name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["service_ids"],"title":"ExternalIntegrationCredentialRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ExternalIntegrationCredentialResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIntegrationCredentialResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"integration_id":{"type":"string","format":"uuid","title":"Integration Id"},"client_id":{"type":"string","title":"Client Id"},"service_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Service Ids"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"is_active":{"type":"boolean","title":"Is Active"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"rotated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Rotated At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"}},"type":"object","required":["id","workspace_id","integration_id","client_id","service_ids","is_active"],"title":"ExternalIntegrationCredentialResponse"}}}}
```

## The ExternalIntegrationCredentialSecretResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIntegrationCredentialSecretResponse":{"properties":{"credential":{"$ref":"#/components/schemas/ExternalIntegrationCredentialResponse"},"client_secret":{"type":"string","title":"Client Secret"}},"type":"object","required":["credential","client_secret"],"title":"ExternalIntegrationCredentialSecretResponse"},"ExternalIntegrationCredentialResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"integration_id":{"type":"string","format":"uuid","title":"Integration Id"},"client_id":{"type":"string","title":"Client Id"},"service_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Service Ids"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"is_active":{"type":"boolean","title":"Is Active"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"rotated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Rotated At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"}},"type":"object","required":["id","workspace_id","integration_id","client_id","service_ids","is_active"],"title":"ExternalIntegrationCredentialResponse"}}}}
```

## The ExternalIntegrationListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIntegrationListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ExternalIntegrationResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ExternalIntegrationListResponse"},"ExternalIntegrationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","maxLength":128,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Name"},"display_name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"type":"string","maxLength":4096},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"},"created_by_entity_id":{"type":"string","format":"uuid","title":"Created By Entity Id"},"created_by_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Credential Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","name","display_name","is_active","created_by_entity_id"],"title":"ExternalIntegrationResponse"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ExternalIntegrationRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIntegrationRequest":{"properties":{"name":{"type":"string","maxLength":128,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Name"},"display_name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"type":"string","maxLength":4096},{"type":"null"}],"title":"Description"}},"type":"object","required":["name","display_name"],"title":"ExternalIntegrationRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ExternalIntegrationResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIntegrationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","maxLength":128,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Name"},"display_name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"type":"string","maxLength":4096},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active"},"created_by_entity_id":{"type":"string","format":"uuid","title":"Created By Entity Id"},"created_by_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Credential Id"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","name","display_name","is_active","created_by_entity_id"],"title":"ExternalIntegrationResponse"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ExternalIntegrationUpdateRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalIntegrationUpdateRequest":{"properties":{"name":{"type":"string","maxLength":128,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Name"},"display_name":{"$ref":"#/components/schemas/NameString","title":"Display Name"},"description":{"anyOf":[{"type":"string","maxLength":4096},{"type":"null"}],"title":"Description"}},"type":"object","title":"ExternalIntegrationUpdateRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ExternalRoleAssignmentItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalRoleAssignmentItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"source":{"type":"string","title":"Source"},"external_subject_key":{"type":"string","title":"External Subject Key"},"external_subject_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Subject Id"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"roles":{"items":{"type":"string"},"type":"array","title":"Roles"},"roles_verified":{"type":"boolean","title":"Roles Verified"},"status":{"type":"string","enum":["active","suspended","revoked"],"title":"Status"},"provisioned_via":{"type":"string","enum":["roster_sync","jit"],"title":"Provisioned Via"},"last_verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Verified At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","source","external_subject_key","entity_id","roles","roles_verified","status","provisioned_via","created_at","updated_at"],"title":"ExternalRoleAssignmentItem"}}}}
```

## The ExternalRoleItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalRoleItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"external_name":{"type":"string","title":"External Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","name","external_name","created_at","updated_at"],"title":"ExternalRoleItem","description":"Wire shape for read + create responses."}}}}
```

## The ExternalSystemString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalSystemString":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z0-9_\\-]+$"}}}}
```

## The ExternalValueString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalValueString":{"type":"string","maxLength":256,"minLength":1}}}}
```

## The ExternalWriteProposal object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalWriteProposal":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"connector_type":{"type":"string","title":"Connector Type"},"data_source_id":{"type":"string","format":"uuid","title":"Data Source Id"},"fhir_resource_type":{"type":"string","title":"Fhir Resource Type"},"fhir_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Id"},"proposed_payload":{"additionalProperties":true,"type":"object","title":"Proposed Payload"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence"},"origin_run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Origin Run Id"},"origin_run_kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Origin Run Kind"},"origin_event_id":{"type":"string","format":"uuid","title":"Origin Event Id"},"event_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Event Type"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"status":{"type":"string","enum":["proposed","approved","rejected","pushing","pushed","failed","superseded"],"title":"Status"},"decided_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Decided By"},"decided_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Decided At"},"reject_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reject Reason"},"push_attempt_count":{"type":"integer","title":"Push Attempt Count","default":0},"vendor_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vendor Resource Id"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","connector_type","data_source_id","fhir_resource_type","origin_event_id","status"],"title":"ExternalWriteProposal","description":"A human-review proposal for an external (EHR) write-back — the Review Queue.\n\nStaged by the producer when a `review_required` sink would otherwise\nauto-push (the external write proposals table); a reviewer approves/rejects, and the\negress drain delivers approved ones. ``proposed_payload`` is the full FHIR write\nbody and MAY contain PHI — this surface is workspace-scoped (FORCE-RLS) and\npermission-gated (ReviewQueue); never log it. ``connector_type``/``fhir_*``/\n``status``/``idempotency_key`` are opaque strings; the ids are uuid."}}}}
```

## The ExternalWriteProposalListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ExternalWriteProposalListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ExternalWriteProposal"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ExternalWriteProposalListResponse"},"ExternalWriteProposal":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"connector_type":{"type":"string","title":"Connector Type"},"data_source_id":{"type":"string","format":"uuid","title":"Data Source Id"},"fhir_resource_type":{"type":"string","title":"Fhir Resource Type"},"fhir_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Id"},"proposed_payload":{"additionalProperties":true,"type":"object","title":"Proposed Payload"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence"},"origin_run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Origin Run Id"},"origin_run_kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Origin Run Kind"},"origin_event_id":{"type":"string","format":"uuid","title":"Origin Event Id"},"event_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Event Type"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"status":{"type":"string","enum":["proposed","approved","rejected","pushing","pushed","failed","superseded"],"title":"Status"},"decided_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Decided By"},"decided_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Decided At"},"reject_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reject Reason"},"push_attempt_count":{"type":"integer","title":"Push Attempt Count","default":0},"vendor_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Vendor Resource Id"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","connector_type","data_source_id","fhir_resource_type","origin_event_id","status"],"title":"ExternalWriteProposal","description":"A human-review proposal for an external (EHR) write-back — the Review Queue.\n\nStaged by the producer when a `review_required` sink would otherwise\nauto-push (the external write proposals table); a reviewer approves/rejects, and the\negress drain delivers approved ones. ``proposed_payload`` is the full FHIR write\nbody and MAY contain PHI — this surface is workspace-scoped (FORCE-RLS) and\npermission-gated (ReviewQueue); never log it. ``connector_type``/``fhir_*``/\n``status``/``idempotency_key`` are opaque strings; the ids are uuid."}}}}
```

## The FactId object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FactId":{"type":"string","maxLength":200,"minLength":1}}}}
```

## The FactLabel object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FactLabel":{"type":"string","maxLength":256,"minLength":1}}}}
```

## The FailureClass object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."}}}}
```

## The FailureReason object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FailureReason":{"enum":["refusal","out_of_set","malformed","http_4xx","http_retryable","connection","timeout","breaker_open","options_exceeded"],"type":"string"}}}}
```

## The Family object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Family":{"properties":{"id":{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"],"title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"summary":{"$ref":"#/components/schemas/DescriptionString"},"standing":{"type":"string","enum":["current","to_be_deprecated"],"title":"Standing","description":"current, or to_be_deprecated: the family stays in service and gets fixes and improvements only."},"availability":{"$ref":"#/components/schemas/Availability"},"capabilities":{"$ref":"#/components/schemas/SessionCapabilities"},"config_key":{"anyOf":[{"type":"string","enum":["realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Config Key"},"legacy_keys":{"items":{"type":"string","const":"realtime_voice"},"type":"array","title":"Legacy Keys"},"models":{"items":{"type":"string","maxLength":256},"type":"array","title":"Models"},"voices":{"anyOf":[{"$ref":"#/components/schemas/Voices"},{"type":"null"}]},"options":{"anyOf":[{"additionalProperties":true,"propertyNames":{"maxLength":256},"type":"object"},{"type":"null"}],"title":"Options"},"honored_settings":{"items":{"type":"string","maxLength":64},"type":"array","title":"Honored Settings","description":"The service settings this family reads, as dotted paths from the service (keyterms, voice_config.silence_policy). Saving any other setting is accepted, and the family ignores it."}},"type":"object","required":["id","name","summary","standing","availability","capabilities","config_key","legacy_keys","models","voices","options","honored_settings"],"title":"Family"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"Availability":{"properties":{"available":{"type":"boolean","title":"Available"},"reason":{"anyOf":[{"$ref":"#/components/schemas/AvailabilityReason"},{"type":"null"}]}},"type":"object","required":["available","reason"],"title":"Availability"},"AvailabilityReason":{"properties":{"code":{"type":"string","maxLength":128,"title":"Code"},"message":{"$ref":"#/components/schemas/DescriptionString"}},"type":"object","required":["code","message"],"title":"AvailabilityReason"},"SessionCapabilities":{"properties":{"multi_state":{"type":"boolean","title":"Multi State"},"dynamic_behaviors":{"type":"boolean","title":"Dynamic Behaviors"},"completion_navigation":{"type":"boolean","title":"Completion Navigation"},"channels":{"items":{"type":"string","enum":["app","phone","playground","test_call"]},"type":"array","title":"Channels"},"outbound_calls":{"type":"boolean","title":"Outbound Calls"},"operator_takeover":{"type":"boolean","title":"Operator Takeover"},"end_call":{"type":"boolean","title":"End Call"},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"authored_lines":{"type":"string","enum":["tts","model_checked","clips"],"title":"Authored Lines","default":"clips"},"floor_enforced":{"type":"boolean","title":"Floor Enforced","default":false},"state_carrier":{"anyOf":[{"type":"string","enum":["session_update_and_note","note_only"]},{"type":"null"}],"title":"State Carrier"},"typed_guardrails":{"type":"boolean","title":"Typed Guardrails","default":false}},"type":"object","required":["multi_state","dynamic_behaviors","completion_navigation","channels","outbound_calls","operator_takeover","end_call","warm_transfer","authored_lines","floor_enforced","state_carrier","typed_guardrails"],"title":"SessionCapabilities"},"Voices":{"properties":{"listing":{"type":"string","enum":["static","vendor"],"title":"Listing"},"path":{"type":"string","maxLength":512,"title":"Path"}},"type":"object","required":["listing","path"],"title":"Voices"}}}}
```

## The FamilyDelivery object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FamilyDelivery":{"properties":{"version_set":{"$ref":"#/components/schemas/ReadinessLabel"},"family":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Family"},"source":{"type":"string","enum":["service","agent","engine_default","agent_missing"],"title":"Source"},"capabilities":{"anyOf":[{"$ref":"#/components/schemas/SessionCapabilities"},{"type":"null"}]},"dynamic_behaviors_configured":{"type":"boolean","title":"Dynamic Behaviors Configured"},"ignored_settings":{"items":{"type":"string"},"type":"array","title":"Ignored Settings","description":"The service settings, as dotted paths from the service (keyterms, voice_config.max_buffer_delay_ms), that the service sets to a non-default value and this family does not read. Advisory: the config is valid and saves, and a setting listed here may still be refused (see family_refusals). Empty, and not known, when ignored_settings_known is false."},"ignored_settings_known":{"type":"boolean","title":"Ignored Settings Known","description":"Whether ignored_settings was read: false when the version set's family is unknown or the stored service no longer validates, so an empty list says nothing."},"family_judgement":{"type":"string","enum":["judged","not_judged"],"title":"Family Judgement","description":"judged: family_refusals is every refusal the voice family contract and the family's delivery rules find for this version set, empty when the family runs it as authored. not_judged: the version set could not be judged (family_not_judged says why), so family_refusals may be incomplete and an empty one is never a pass."},"family_refusals":{"items":{"$ref":"#/components/schemas/FamilyRefusal"},"type":"array","title":"Family Refusals","description":"Each reason the family cannot run this version set as stored, with the code, message and fields a save refuses it with: the family's admission for the workspace when the service names the family, its delivery rules held to the whole config, then the contract's rules on the program the set's agent version runs. A client shows each one's code, message and fields and computes none. Messages have every digit redacted; a save plan's problems keep the exact text."},"family_not_judged":{"anyOf":[{"$ref":"#/components/schemas/FamilyNotJudged"},{"type":"null"}],"description":"Why the version set was not judged, when family_judgement is not_judged; null otherwise."},"refusals":{"items":{"$ref":"#/components/schemas/FamilyPolicyRefusal"},"type":"array","title":"Refusals","description":"What the config the save would store asks of the family that it can't deliver (warm transfer,\nservice-written lines), whether or not this save moves the version set. Empty when it delivers it all. Kept as\nit was for a family off the voice family contract; for a family on it, `family_refusals` is the list a client\nshows, which holds these findings with the contract's."}},"type":"object","required":["version_set","family","source","capabilities","dynamic_behaviors_configured","ignored_settings","ignored_settings_known","family_judgement","family_refusals","family_not_judged","refusals"],"title":"FamilyDelivery","description":"The voice family one version set would run, as readiness reads it, and the family's delivery rules held to\nthe whole config."},"ReadinessLabel":{"type":"string"},"SessionCapabilities":{"properties":{"multi_state":{"type":"boolean","title":"Multi State"},"dynamic_behaviors":{"type":"boolean","title":"Dynamic Behaviors"},"completion_navigation":{"type":"boolean","title":"Completion Navigation"},"channels":{"items":{"type":"string","enum":["app","phone","playground","test_call"]},"type":"array","title":"Channels"},"outbound_calls":{"type":"boolean","title":"Outbound Calls"},"operator_takeover":{"type":"boolean","title":"Operator Takeover"},"end_call":{"type":"boolean","title":"End Call"},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"authored_lines":{"type":"string","enum":["tts","model_checked","clips"],"title":"Authored Lines","default":"clips"},"floor_enforced":{"type":"boolean","title":"Floor Enforced","default":false},"state_carrier":{"anyOf":[{"type":"string","enum":["session_update_and_note","note_only"]},{"type":"null"}],"title":"State Carrier"},"typed_guardrails":{"type":"boolean","title":"Typed Guardrails","default":false}},"type":"object","required":["multi_state","dynamic_behaviors","completion_navigation","channels","outbound_calls","operator_takeover","end_call","warm_transfer","authored_lines","floor_enforced","state_carrier","typed_guardrails"],"title":"SessionCapabilities"},"FamilyRefusal":{"properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/FamilyRefusalCode"},{"type":"string","enum":["family_warm_transfer_unsupported","family_cannot_speak_service_lines"]}],"title":"Code"},"message":{"$ref":"#/components/schemas/ReadinessLabel","description":"Names the family and the fix, with every digit redacted."},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"What the author changes, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyRefusal"},"FamilyRefusalCode":{"type":"string","enum":["voice_family_not_served","voice_family_residency","voice_family_agent_version","voice_family_direct_program","voice_family_graph_shape","voice_family_guardrails","voice_family_dynamic_behaviors","voice_family_completion_navigation","voice_family_warm_transfer","voice_family_service_lines","voice_family_outbound","voice_family_settings"]},"FamilyNotJudged":{"properties":{"code":{"$ref":"#/components/schemas/FamilyNotJudgedCode"},"message":{"$ref":"#/components/schemas/ReadinessLabel"},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"Where the author looks, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyNotJudged"},"FamilyNotJudgedCode":{"type":"string","enum":["agent_version_missing","family_not_on_contract","voice_config_unreadable","graph_missing","graph_version_missing","graph_version_unreadable"]},"FamilyPolicyRefusal":{"properties":{"code":{"type":"string","enum":["family_warm_transfer_unsupported","family_cannot_speak_service_lines"],"title":"Code"},"message":{"type":"string","title":"Message"},"fields":{"items":{"type":"string"},"type":"array","title":"Fields"}},"type":"object","required":["code","message","fields"],"title":"FamilyPolicyRefusal"}}}}
```

## The FamilyNotJudged object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FamilyNotJudged":{"properties":{"code":{"$ref":"#/components/schemas/FamilyNotJudgedCode"},"message":{"$ref":"#/components/schemas/ReadinessLabel"},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"Where the author looks, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyNotJudged"},"FamilyNotJudgedCode":{"type":"string","enum":["agent_version_missing","family_not_on_contract","voice_config_unreadable","graph_missing","graph_version_missing","graph_version_unreadable"]},"ReadinessLabel":{"type":"string"}}}}
```

## The FamilyNotJudgedCode object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FamilyNotJudgedCode":{"type":"string","enum":["agent_version_missing","family_not_on_contract","voice_config_unreadable","graph_missing","graph_version_missing","graph_version_unreadable"]}}}}
```

## The FamilyPolicyRefusal object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FamilyPolicyRefusal":{"properties":{"code":{"type":"string","enum":["family_warm_transfer_unsupported","family_cannot_speak_service_lines"],"title":"Code"},"message":{"type":"string","title":"Message"},"fields":{"items":{"type":"string"},"type":"array","title":"Fields"}},"type":"object","required":["code","message","fields"],"title":"FamilyPolicyRefusal"}}}}
```

## The FamilyRefusal object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FamilyRefusal":{"properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/FamilyRefusalCode"},{"type":"string","enum":["family_warm_transfer_unsupported","family_cannot_speak_service_lines"]}],"title":"Code"},"message":{"$ref":"#/components/schemas/ReadinessLabel","description":"Names the family and the fix, with every digit redacted."},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"What the author changes, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyRefusal"},"FamilyRefusalCode":{"type":"string","enum":["voice_family_not_served","voice_family_residency","voice_family_agent_version","voice_family_direct_program","voice_family_graph_shape","voice_family_guardrails","voice_family_dynamic_behaviors","voice_family_completion_navigation","voice_family_warm_transfer","voice_family_service_lines","voice_family_outbound","voice_family_settings"]},"ReadinessLabel":{"type":"string"}}}}
```

## The FamilyRefusalCode object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FamilyRefusalCode":{"type":"string","enum":["voice_family_not_served","voice_family_residency","voice_family_agent_version","voice_family_direct_program","voice_family_graph_shape","voice_family_guardrails","voice_family_dynamic_behaviors","voice_family_completion_navigation","voice_family_warm_transfer","voice_family_service_lines","voice_family_outbound","voice_family_settings"]}}}}
```

## The FhirAppointmentListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirAppointmentListResponse":{"properties":{"appointments":{"items":{"$ref":"#/components/schemas/FhirAppointmentView"},"type":"array","title":"Appointments"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More","default":false},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["appointments","total"],"title":"FhirAppointmentListResponse"},"FhirAppointmentView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"start":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start"},"end":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End"},"patient_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Patient Name"},"practitioner_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Practitioner Name"},"location_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location Name"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"cancel_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cancel Reason"},"appointment_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appointment Type"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"modality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Modality"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirAppointmentView"}}}}
```

## The FhirAppointmentView object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirAppointmentView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"start":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start"},"end":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End"},"patient_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Patient Name"},"practitioner_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Practitioner Name"},"location_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location Name"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"cancel_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cancel Reason"},"appointment_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appointment Type"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"},"modality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Modality"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirAppointmentView"}}}}
```

## The FhirImportRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirImportRequest":{"properties":{"bundle":{"additionalProperties":true,"type":"object","title":"Bundle"},"source":{"type":"string","maxLength":128,"title":"Source","default":"fhir_import"},"source_system":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Source System"},"data_source_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Data Source Id"},"dedup":{"type":"boolean","title":"Dedup","description":"When true, identical re-uploads of the same FHIR resource are skipped via content-hash dedup. Set to false to force emission regardless of content changes.","default":true},"unsupported_resource_policy":{"$ref":"#/components/schemas/FhirUnsupportedResourcePolicy","description":"Controls resources whose resourceType is missing or not projected by platform FHIR APIs. 'error' skips the resource and adds a per-resource error; 'skip' skips it without adding an error. Unsupported resources are never emitted as silent raw world events.","default":"error"}},"type":"object","required":["bundle"],"title":"FhirImportRequest"},"FhirUnsupportedResourcePolicy":{"type":"string","enum":["error","skip"]}}}}
```

## The FhirImportResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirImportResponse":{"properties":{"events_created":{"type":"integer","title":"Events Created"},"events_skipped":{"type":"integer","title":"Events Skipped","default":0},"events_updated":{"type":"integer","title":"Events Updated","default":0},"entities_created":{"type":"integer","title":"Entities Created"},"entities_updated":{"type":"integer","title":"Entities Updated"},"error_count":{"type":"integer","title":"Error Count","default":0},"errors":{"items":{"type":"string"},"type":"array","maxItems":1000,"title":"Errors"},"errors_truncated":{"type":"boolean","title":"Errors Truncated","default":false},"unsupported_resource_count":{"type":"integer","title":"Unsupported Resource Count","default":0},"unsupported_resources":{"items":{"$ref":"#/components/schemas/FhirUnsupportedResourceItem"},"type":"array","maxItems":1000,"title":"Unsupported Resources"},"unsupported_resources_truncated":{"type":"boolean","title":"Unsupported Resources Truncated","default":false},"erased_resource_count":{"type":"integer","title":"Erased Resource Count","description":"Resources dropped because an erasure recorded their source key ({source_system}:{ResourceType}:{id}).","default":0},"upsert_semantics":{"type":"string","const":"same_resource_id_upsert","title":"Upsert Semantics","description":"FHIR import uses workspace + resourceType + id as the natural key. Identical re-uploads can be deduped; changed resources supersede prior current events.","default":"same_resource_id_upsert"},"absence_semantics":{"type":"string","const":"absent_resources_persist","title":"Absence Semantics","description":"Resources omitted from a later bundle are not deleted or archived by import.","default":"absent_resources_persist"}},"type":"object","required":["events_created","entities_created","entities_updated"],"title":"FhirImportResponse"},"FhirUnsupportedResourceItem":{"properties":{"resource_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Resource Type"},"resource_id":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Resource Id"},"location":{"type":"string","maxLength":128,"title":"Location"},"reason":{"type":"string","maxLength":512,"title":"Reason"}},"type":"object","required":["location","reason"],"title":"FhirUnsupportedResourceItem"}}}}
```

## The FhirLocationListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirLocationListResponse":{"properties":{"locations":{"items":{"$ref":"#/components/schemas/FhirLocationView"},"type":"array","title":"Locations"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More","default":false},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["locations","total"],"title":"FhirLocationListResponse"},"FhirLocationView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"address":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Address"},"address_line":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postal Code"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"latitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude"},"longitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"facility_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Facility Id"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Hours"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirLocationView"}}}}
```

## The FhirLocationView object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirLocationView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"address":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Address"},"address_line":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line"},"city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"City"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Postal Code"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country"},"latitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude"},"longitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"facility_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Facility Id"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Hours"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirLocationView"}}}}
```

## The FhirOrganizationListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirOrganizationListResponse":{"properties":{"organizations":{"items":{"$ref":"#/components/schemas/FhirOrganizationView"},"type":"array","title":"Organizations"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More","default":false},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["organizations","total"],"title":"FhirOrganizationListResponse"},"FhirOrganizationView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"address":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Address"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirOrganizationView"}}}}
```

## The FhirOrganizationView object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirOrganizationView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry"},"address":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Address"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirOrganizationView"}}}}
```

## The FhirPatientListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirPatientListResponse":{"properties":{"patients":{"items":{"$ref":"#/components/schemas/FhirPatientView"},"type":"array","title":"Patients"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More","default":false},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["patients","total"],"title":"FhirPatientListResponse"},"FhirPatientView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn"},"address":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Address"},"address_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address State"},"address_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Postal Code"},"address_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address City"},"active_conditions":{"items":{"type":"string"},"type":"array","title":"Active Conditions"},"active_medications":{"items":{"type":"string"},"type":"array","title":"Active Medications"},"allergies":{"items":{"type":"string"},"type":"array","title":"Allergies"},"insurance":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Insurance"},"primary_payer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Payer Name"},"practice_payer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Practice Payer Id"},"member_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Member Id"},"policyholder_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policyholder Name"},"policyholder_relationship":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policyholder Relationship"},"policyholder_dob":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policyholder Dob"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"confidence":{"type":"number","title":"Confidence","default":1},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["entity_id"],"title":"FhirPatientView"}}}}
```

## The FhirPatientView object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirPatientView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn"},"address":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Address"},"address_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address State"},"address_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Postal Code"},"address_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address City"},"active_conditions":{"items":{"type":"string"},"type":"array","title":"Active Conditions"},"active_medications":{"items":{"type":"string"},"type":"array","title":"Active Medications"},"allergies":{"items":{"type":"string"},"type":"array","title":"Allergies"},"insurance":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Insurance"},"primary_payer_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Payer Name"},"practice_payer_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Practice Payer Id"},"member_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Member Id"},"policyholder_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policyholder Name"},"policyholder_relationship":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policyholder Relationship"},"policyholder_dob":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policyholder Dob"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"confidence":{"type":"number","title":"Confidence","default":1},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["entity_id"],"title":"FhirPatientView"}}}}
```

## The FhirPractitionerListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirPractitionerListResponse":{"properties":{"practitioners":{"items":{"$ref":"#/components/schemas/FhirPractitionerView"},"type":"array","title":"Practitioners"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More","default":false},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["practitioners","total"],"title":"FhirPractitionerListResponse"},"FhirPractitionerView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"npi":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Npi"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"member_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Member Id"},"scheduling_eligible":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Scheduling Eligible"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirPractitionerView"}}}}
```

## The FhirPractitionerView object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirPractitionerView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"npi":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Npi"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"member_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Member Id"},"scheduling_eligible":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Scheduling Eligible"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirPractitionerView"}}}}
```

## The FhirResourceHistoryEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirResourceHistoryEntry":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"event_type":{"type":"string","title":"Event Type"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"data_source_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Data Source Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence"},"is_current":{"type":"boolean","title":"Is Current"},"effective_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Effective At"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"fields_affected":{"items":{"type":"string"},"type":"array","title":"Fields Affected"},"data":{"additionalProperties":true,"type":"object","title":"Data"}},"type":"object","required":["event_id","event_type","is_current"],"title":"FhirResourceHistoryEntry"}}}}
```

## The FhirResourceHistoryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirResourceHistoryResponse":{"properties":{"resource_type":{"type":"string","title":"Resource Type"},"resource_id":{"type":"string","title":"Resource Id"},"entries":{"items":{"$ref":"#/components/schemas/FhirResourceHistoryEntry"},"type":"array","title":"Entries"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More","default":false},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["resource_type","resource_id","entries","total"],"title":"FhirResourceHistoryResponse"},"FhirResourceHistoryEntry":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"event_type":{"type":"string","title":"Event Type"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"data_source_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Data Source Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence"},"is_current":{"type":"boolean","title":"Is Current"},"effective_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Effective At"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"fields_affected":{"items":{"type":"string"},"type":"array","title":"Fields Affected"},"data":{"additionalProperties":true,"type":"object","title":"Data"}},"type":"object","required":["event_id","event_type","is_current"],"title":"FhirResourceHistoryEntry"}}}}
```

## The FhirResourceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirResourceResponse":{"properties":{"resource_type":{"type":"string","title":"Resource Type"},"resource_id":{"type":"string","title":"Resource Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"data":{"additionalProperties":true,"type":"object","title":"Data"}},"type":"object","required":["resource_type","resource_id","data"],"title":"FhirResourceResponse"}}}}
```

## The FhirSearchResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirSearchResponse":{"properties":{"resource_type":{"type":"string","title":"Resource Type"},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total"},"entries":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Entries"},"next_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Next Url"}},"type":"object","required":["resource_type","total","entries"],"title":"FhirSearchResponse"}}}}
```

## The FhirSlotListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirSlotListResponse":{"properties":{"slots":{"items":{"$ref":"#/components/schemas/FhirSlotView"},"type":"array","title":"Slots"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More","default":false},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["slots","total"],"title":"FhirSlotListResponse"},"FhirSlotView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"start":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start"},"end":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End"},"schedule_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schedule Ref"},"provider_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider Name"},"provider_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider Id"},"facility_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Facility Id"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"visit_type_ids":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visit Type Ids"},"visit_type_names":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visit Type Names"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirSlotView"}}}}
```

## The FhirSlotView object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirSlotView":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"start":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Start"},"end":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"End"},"schedule_ref":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schedule Ref"},"provider_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider Name"},"provider_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider Id"},"facility_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Facility Id"},"specialty":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Specialty"},"visit_type_ids":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visit Type Ids"},"visit_type_names":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Visit Type Names"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"FhirSlotView"}}}}
```

## The FhirStatusResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirStatusResponse":{"properties":{"configured":{"type":"boolean","title":"Configured"},"connector_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connector Type"},"event_count":{"type":"integer","title":"Event Count"},"entity_count":{"type":"integer","title":"Entity Count"},"entity_type_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Entity Type Counts"},"resource_type_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Resource Type Counts"}},"type":"object","required":["configured","event_count","entity_count"],"title":"FhirStatusResponse"}}}}
```

## The FhirUnsupportedResourceItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirUnsupportedResourceItem":{"properties":{"resource_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Resource Type"},"resource_id":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Resource Id"},"location":{"type":"string","maxLength":128,"title":"Location"},"reason":{"type":"string","maxLength":512,"title":"Reason"}},"type":"object","required":["location","reason"],"title":"FhirUnsupportedResourceItem"}}}}
```

## The FhirUnsupportedResourcePolicy object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirUnsupportedResourcePolicy":{"type":"string","enum":["error","skip"]}}}}
```

## The FhirWriteRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FhirWriteRequest":{"properties":{"data":{"additionalProperties":true,"type":"object","title":"Data"},"data_source_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Data Source Id"}},"type":"object","required":["data"],"title":"FhirWriteRequest"}}}}
```

## The FieldChange object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FieldChange":{"properties":{"path":{"items":{"type":"string"},"type":"array","title":"Path","description":"Where the field is: `name`, or a key of the service's config, then each key under it."},"change":{"type":"string","enum":["added","removed","changed"],"title":"Change"},"before":{"$ref":"#/components/schemas/JsonValue","description":"What is stored. Null for an added field."},"after":{"$ref":"#/components/schemas/JsonValue","description":"What the save would store. Null for a removed field."}},"type":"object","required":["path","change"],"title":"FieldChange","description":"A field the save would change."},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]}}}}
```

## The FieldSaveRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FieldSaveRequest":{"properties":{"value":{"title":"Value","description":"The field value to save"}},"type":"object","required":["value"],"title":"FieldSaveRequest"}}}}
```

## The FieldSuccess object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."}}}}
```

## The FieldType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."}}}}
```

## The FileEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FileEntry":{"properties":{"file_id":{"type":"string","format":"uuid","title":"File Id"},"document_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Document Id"},"version":{"type":"integer","title":"Version"},"source_path":{"type":"string","title":"Source Path"},"file_type":{"type":"string","title":"File Type"},"content_type":{"type":"string","title":"Content Type"},"sha256":{"type":"string","title":"Sha256"},"size_bytes":{"type":"integer","title":"Size Bytes"},"ingested_at":{"type":"string","title":"Ingested At"},"contract_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Contract Id"},"contract_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Version"},"source_file_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source File Id"},"source_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Url"},"source_folder_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Folder Path"},"filename":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filename"}},"type":"object","required":["file_id","version","source_path","file_type","content_type","sha256","size_bytes","ingested_at"],"title":"FileEntry"}}}}
```

## The FireTriggerRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FireTriggerRequest":{"properties":{"input":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input","description":"Optional overrides merged into the trigger's input_template at fire time."}},"type":"object","title":"FireTriggerRequest"}}}}
```

## The FleetStatusResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FleetStatusResponse":{"properties":{"fleet":{"type":"string","title":"Fleet"},"namespace":{"type":"string","title":"Namespace"},"ready":{"type":"integer","title":"Ready"},"allocated":{"type":"integer","title":"Allocated"},"total":{"type":"integer","title":"Total"},"max_replicas":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Replicas"},"headroom":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Headroom"},"by_state":{"additionalProperties":{"type":"integer"},"type":"object","title":"By State"}},"type":"object","required":["fleet","namespace","ready","allocated","total","max_replicas","headroom","by_state"],"title":"FleetStatusResponse","description":"Live Agones fleet capacity (workspace-global).\n\n``headroom`` = remaining isolated-unit slots (``max_replicas - allocated``);\n``max_replicas``/``headroom`` are null when the ceiling isn't configured upstream.\nThe counts span the whole fleet (one fleet serves every workspace) — this is NOT\nper-workspace. ``fleet``/``namespace`` echo which fleet was read."}}}}
```

## The ForecastDrawPoint object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForecastDrawPoint":{"properties":{"draw_id":{"type":"integer","title":"Draw Id"},"t":{"type":"number","title":"T"},"value":{"type":"number","title":"Value"}},"type":"object","required":["draw_id","t","value"],"title":"ForecastDrawPoint"}}}}
```

## The ForecastDrawsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForecastDrawsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/ForecastDrawPoint"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"ForecastDrawsResponse"},"ForecastDrawPoint":{"properties":{"draw_id":{"type":"integer","title":"Draw Id"},"t":{"type":"number","title":"T"},"value":{"type":"number","title":"Value"}},"type":"object","required":["draw_id","t","value"],"title":"ForecastDrawPoint"}}}}
```

## The ForecastFanPointRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForecastFanPointRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"run_id":{"type":"string","title":"Run Id"},"scenario":{"type":"string","enum":["baseline","with_policy","observational"],"title":"Scenario"},"t":{"type":"number","title":"T"},"lower_95":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lower 95"},"upper_95":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Upper 95"},"median":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Median"},"observed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Observed"},"ym":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ym"},"is_historical":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Historical"}},"type":"object","required":["workspace_id","run_id","scenario","t"],"title":"ForecastFanPointRow"}}}}
```

## The ForecastFanResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForecastFanResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/ForecastFanPointRow"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"ForecastFanResponse"},"ForecastFanPointRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"run_id":{"type":"string","title":"Run Id"},"scenario":{"type":"string","enum":["baseline","with_policy","observational"],"title":"Scenario"},"t":{"type":"number","title":"T"},"lower_95":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lower 95"},"upper_95":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Upper 95"},"median":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Median"},"observed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Observed"},"ym":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ym"},"is_historical":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Historical"}},"type":"object","required":["workspace_id","run_id","scenario","t"],"title":"ForecastFanPointRow"}}}}
```

## The ForkAlternative object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForkAlternative":{"properties":{"caller_text":{"type":"string","maxLength":2000,"title":"Caller Text"}},"type":"object","required":["caller_text"],"title":"ForkAlternative"}}}}
```

## The ForkBranch object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForkBranch":{"properties":{"session_id":{"type":"string","title":"Session Id"},"observation":{"anyOf":[{"$ref":"#/components/schemas/ForkObservation"},{"type":"null"}],"description":"The branch's first turn. Null when the branch failed."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the branch failed. Null when it stepped."},"harness_execution":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessExecution"},{"type":"null"}],"description":"What the branch's turn ran on. Null for a failed branch and when the agent runtime reported none."}},"type":"object","required":["session_id"],"title":"ForkBranch"},"ForkObservation":{"properties":{"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"agent_text":{"type":"string","title":"Agent Text"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called","default":[]},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details","default":[]},"selected_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action"},"empathy_tier":{"type":"integer","title":"Empathy Tier","default":0},"has_pause":{"type":"boolean","title":"Has Pause","default":false},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"caller_text":{"type":"string","title":"Caller Text"}},"type":"object","required":["state_before","state_after","state_changed","agent_text","is_terminal","caller_text"],"title":"ForkObservation"},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."},"SimulationHarnessExecution":{"properties":{"service_config_digest":{"type":"string","title":"Service Config Digest","description":"The digest of the configuration the request's engine loaded."},"harness":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessSelection"},{"type":"null"}],"description":"Null when the request resolved no text harness: a voice service's simulation, or a voice note."},"receipts":{"items":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},"type":"array","title":"Receipts","description":"One receipt per round a release answered, each naming this digest and the selected release's wheel. Empty\nwhen no round ran on a release, whatever is selected: a selection alone is not proof of execution."}},"type":"object","required":["service_config_digest","harness","receipts"],"title":"SimulationHarnessExecution","description":"What one simulation request ran on, as the agent runtime reported it. Nothing here is derived by this API."},"SimulationHarnessSelection":{"properties":{"kind":{"type":"string","const":"text","title":"Kind"},"harness":{"type":"string","title":"Harness","description":"The text provider family the request's rounds were routed for."},"release":{"type":"string","title":"Release","description":"The selected release's tag, or `in-tree`."},"source":{"anyOf":[{"$ref":"#/components/schemas/HarnessSource"},{"type":"string","const":"unresolved"}],"title":"Source","description":"Where the selection came from. `unresolved`: the configuration has no entry for the family."},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256","description":"The selected release wheel's sha256. Null for `in-tree`."}},"type":"object","required":["kind","harness","release","source","sha256"],"title":"SimulationHarnessSelection","description":"The text harness the loaded configuration selects for the request's model family."},"HarnessSource":{"type":"string","enum":["pin","workspace_default","harness_default"]}}}}
```

## The ForkObservation object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForkObservation":{"properties":{"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"agent_text":{"type":"string","title":"Agent Text"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called","default":[]},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details","default":[]},"selected_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action"},"empathy_tier":{"type":"integer","title":"Empathy Tier","default":0},"has_pause":{"type":"boolean","title":"Has Pause","default":false},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"caller_text":{"type":"string","title":"Caller Text"}},"type":"object","required":["state_before","state_after","state_changed","agent_text","is_terminal","caller_text"],"title":"ForkObservation"},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."}}}}
```

## The ForkRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForkRequest":{"properties":{"alternatives":{"items":{"$ref":"#/components/schemas/ForkAlternative"},"type":"array","maxItems":20,"minItems":1,"title":"Alternatives"}},"type":"object","required":["alternatives"],"title":"ForkRequest"},"ForkAlternative":{"properties":{"caller_text":{"type":"string","maxLength":2000,"title":"Caller Text"}},"type":"object","required":["caller_text"],"title":"ForkAlternative"}}}}
```

## The FormTemplate-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FormTemplate-Input":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"category":{"type":"string","enum":["intake","update","consent","screening","survey","custom"],"title":"Category","default":"custom"},"patient_type":{"type":"string","enum":["new","returning","any"],"title":"Patient Type","default":"any"},"fields":{"items":{"$ref":"#/components/schemas/FormTemplateField"},"type":"array","maxItems":200,"minItems":1,"title":"Fields"},"sections":{"items":{"$ref":"#/components/schemas/FormTemplateSection"},"type":"array","maxItems":20,"minItems":1,"title":"Sections"},"branding":{"anyOf":[{"$ref":"#/components/schemas/BrandingConfig"},{"type":"null"}]},"completion_title":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"},"active":{"type":"boolean","title":"Active","default":true},"version":{"type":"integer","minimum":1,"title":"Version","default":1}},"type":"object","required":["name","fields","sections"],"title":"FormTemplate","description":"Reusable form template with sections, prefill, branding.\n\nExtends DataTemplate concept. Up to 200 fields, organized in sections.\nStored in workspace settings[\"form_templates\"] JSONB.\n\nExamples:\n- New patient intake (85 fields, 11 sections)\n- Returning patient update (27 fields, 5 sections)\n- Pre-surgery checklist (15 fields, 3 sections)\n- PHQ-9 screening (10 fields, 1 section)"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"FormTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"},"prefill_path":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Prefill Path","description":"Dot-notation path into entity state for prefill (e.g. demographics.date_of_birth)"},"layout_group":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Layout Group","description":"Row grouping hint — fields with same layout_group render side-by-side"}},"type":"object","required":["key","label"],"title":"FormTemplateField","description":"Extended field with prefill_path mapping to entity state.\n\nUnlike SurfaceField (agent-generated, dynamic), FormTemplateField is\na reusable definition that maps to FHIR/EHR data paths for auto-prefill."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"FormTemplateSection":{"properties":{"id":{"type":"string","maxLength":64,"minLength":1,"title":"Id"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":200,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["id","title","field_keys"],"title":"FormTemplateSection","description":"A section in a form template (maps to one wizard step)."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."}}}}
```

## The FormTemplate-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FormTemplate-Output":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"category":{"type":"string","enum":["intake","update","consent","screening","survey","custom"],"title":"Category","default":"custom"},"patient_type":{"type":"string","enum":["new","returning","any"],"title":"Patient Type","default":"any"},"fields":{"items":{"$ref":"#/components/schemas/FormTemplateField"},"type":"array","maxItems":200,"minItems":1,"title":"Fields"},"sections":{"items":{"$ref":"#/components/schemas/FormTemplateSection"},"type":"array","maxItems":20,"minItems":1,"title":"Sections"},"branding":{"anyOf":[{"$ref":"#/components/schemas/BrandingConfig"},{"type":"null"}]},"completion_title":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"},"active":{"type":"boolean","title":"Active","default":true},"version":{"type":"integer","minimum":1,"title":"Version","default":1}},"type":"object","required":["name","fields","sections"],"title":"FormTemplate","description":"Reusable form template with sections, prefill, branding.\n\nExtends DataTemplate concept. Up to 200 fields, organized in sections.\nStored in workspace settings[\"form_templates\"] JSONB.\n\nExamples:\n- New patient intake (85 fields, 11 sections)\n- Returning patient update (27 fields, 5 sections)\n- Pre-surgery checklist (15 fields, 3 sections)\n- PHQ-9 screening (10 fields, 1 section)"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"FormTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"},"prefill_path":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Prefill Path","description":"Dot-notation path into entity state for prefill (e.g. demographics.date_of_birth)"},"layout_group":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Layout Group","description":"Row grouping hint — fields with same layout_group render side-by-side"}},"type":"object","required":["key","label"],"title":"FormTemplateField","description":"Extended field with prefill_path mapping to entity state.\n\nUnlike SurfaceField (agent-generated, dynamic), FormTemplateField is\na reusable definition that maps to FHIR/EHR data paths for auto-prefill."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"FormTemplateSection":{"properties":{"id":{"type":"string","maxLength":64,"minLength":1,"title":"Id"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":200,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["id","title","field_keys"],"title":"FormTemplateSection","description":"A section in a form template (maps to one wizard step)."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."}}}}
```

## The FormTemplateField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FormTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"},"prefill_path":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Prefill Path","description":"Dot-notation path into entity state for prefill (e.g. demographics.date_of_birth)"},"layout_group":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Layout Group","description":"Row grouping hint — fields with same layout_group render side-by-side"}},"type":"object","required":["key","label"],"title":"FormTemplateField","description":"Extended field with prefill_path mapping to entity state.\n\nUnlike SurfaceField (agent-generated, dynamic), FormTemplateField is\na reusable definition that maps to FHIR/EHR data paths for auto-prefill."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The FormTemplateListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FormTemplateListResponse":{"properties":{"templates":{"items":{"$ref":"#/components/schemas/FormTemplate-Output"},"type":"array","title":"Templates"}},"type":"object","required":["templates"],"title":"FormTemplateListResponse","description":"List of form templates for a workspace."},"FormTemplate-Output":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"category":{"type":"string","enum":["intake","update","consent","screening","survey","custom"],"title":"Category","default":"custom"},"patient_type":{"type":"string","enum":["new","returning","any"],"title":"Patient Type","default":"any"},"fields":{"items":{"$ref":"#/components/schemas/FormTemplateField"},"type":"array","maxItems":200,"minItems":1,"title":"Fields"},"sections":{"items":{"$ref":"#/components/schemas/FormTemplateSection"},"type":"array","maxItems":20,"minItems":1,"title":"Sections"},"branding":{"anyOf":[{"$ref":"#/components/schemas/BrandingConfig"},{"type":"null"}]},"completion_title":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"},"active":{"type":"boolean","title":"Active","default":true},"version":{"type":"integer","minimum":1,"title":"Version","default":1}},"type":"object","required":["name","fields","sections"],"title":"FormTemplate","description":"Reusable form template with sections, prefill, branding.\n\nExtends DataTemplate concept. Up to 200 fields, organized in sections.\nStored in workspace settings[\"form_templates\"] JSONB.\n\nExamples:\n- New patient intake (85 fields, 11 sections)\n- Returning patient update (27 fields, 5 sections)\n- Pre-surgery checklist (15 fields, 3 sections)\n- PHQ-9 screening (10 fields, 1 section)"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"FormTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"},"prefill_path":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Prefill Path","description":"Dot-notation path into entity state for prefill (e.g. demographics.date_of_birth)"},"layout_group":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Layout Group","description":"Row grouping hint — fields with same layout_group render side-by-side"}},"type":"object","required":["key","label"],"title":"FormTemplateField","description":"Extended field with prefill_path mapping to entity state.\n\nUnlike SurfaceField (agent-generated, dynamic), FormTemplateField is\na reusable definition that maps to FHIR/EHR data paths for auto-prefill."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"FormTemplateSection":{"properties":{"id":{"type":"string","maxLength":64,"minLength":1,"title":"Id"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":200,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["id","title","field_keys"],"title":"FormTemplateSection","description":"A section in a form template (maps to one wizard step)."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."}}}}
```

## The FormTemplateSection object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FormTemplateSection":{"properties":{"id":{"type":"string","maxLength":64,"minLength":1,"title":"Id"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":200,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["id","title","field_keys"],"title":"FormTemplateSection","description":"A section in a form template (maps to one wizard step)."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The FormTemplateUpdateRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FormTemplateUpdateRequest":{"properties":{"templates":{"items":{"$ref":"#/components/schemas/FormTemplate-Input"},"type":"array","maxItems":50,"title":"Templates"}},"type":"object","required":["templates"],"title":"FormTemplateUpdateRequest","description":"Replace all form templates."},"FormTemplate-Input":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"category":{"type":"string","enum":["intake","update","consent","screening","survey","custom"],"title":"Category","default":"custom"},"patient_type":{"type":"string","enum":["new","returning","any"],"title":"Patient Type","default":"any"},"fields":{"items":{"$ref":"#/components/schemas/FormTemplateField"},"type":"array","maxItems":200,"minItems":1,"title":"Fields"},"sections":{"items":{"$ref":"#/components/schemas/FormTemplateSection"},"type":"array","maxItems":20,"minItems":1,"title":"Sections"},"branding":{"anyOf":[{"$ref":"#/components/schemas/BrandingConfig"},{"type":"null"}]},"completion_title":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"},"active":{"type":"boolean","title":"Active","default":true},"version":{"type":"integer","minimum":1,"title":"Version","default":1}},"type":"object","required":["name","fields","sections"],"title":"FormTemplate","description":"Reusable form template with sections, prefill, branding.\n\nExtends DataTemplate concept. Up to 200 fields, organized in sections.\nStored in workspace settings[\"form_templates\"] JSONB.\n\nExamples:\n- New patient intake (85 fields, 11 sections)\n- Returning patient update (27 fields, 5 sections)\n- Pre-surgery checklist (15 fields, 3 sections)\n- PHQ-9 screening (10 fields, 1 section)"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"FormTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"},"prefill_path":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Prefill Path","description":"Dot-notation path into entity state for prefill (e.g. demographics.date_of_birth)"},"layout_group":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Layout Group","description":"Row grouping hint — fields with same layout_group render side-by-side"}},"type":"object","required":["key","label"],"title":"FormTemplateField","description":"Extended field with prefill_path mapping to entity state.\n\nUnlike SurfaceField (agent-generated, dynamic), FormTemplateField is\na reusable definition that maps to FHIR/EHR data paths for auto-prefill."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"FormTemplateSection":{"properties":{"id":{"type":"string","maxLength":64,"minLength":1,"title":"Id"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":200,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["id","title","field_keys"],"title":"FormTemplateSection","description":"A section in a form template (maps to one wizard step)."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."}}}}
```

## The ForwardingDetails object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForwardingDetails":{"properties":{"forward_to":{"type":"string","title":"Forward To"},"warm_transfer":{"type":"boolean","title":"Warm Transfer"},"forwarded_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Forwarded At"},"after_hours":{"type":"boolean","title":"After Hours","description":"The service's staffed hours sent this transfer to its after-hours line, whichever line was asked for.","default":false},"destination_label":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Destination Label","description":"The service's label for the line this transfer dialed, or ``forward_to`` for a static service's own line."},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason","description":"The key of the service's ``transfer_reasons`` the agent named for this transfer, None for a service that lists\nnone or a transfer the agent didn't make."}},"type":"object","required":["forward_to","warm_transfer"],"title":"ForwardingDetails"}}}}
```

## The FunctionExample object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"FunctionExample":{"properties":{"input":{"additionalProperties":true,"type":"object","title":"Input"},"output":{"title":"Output"},"description":{"type":"string","title":"Description","default":""}},"additionalProperties":false,"type":"object","required":["input","output"],"title":"FunctionExample","description":"One example call. The developer console's tool picker shows it, and the LLM tool spec includes it inline."}}}}
```

## The GetSimulationBenchmarkResultsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"GetSimulationBenchmarkResultsRequest":{"properties":{"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","maxItems":100,"minItems":1,"title":"Run Ids"}},"type":"object","required":["run_ids"],"title":"GetSimulationBenchmarkResultsRequest"}}}}
```

## The GptLiveSessionConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."}}}}
```

## The GraphQLSuccess object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."}}}}
```

## The GrokVoiceSessionConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."}}}}
```

## The Guardrail object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."}}}}
```

## The Guardrails object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Guardrails":{"properties":{"guardrails":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Guardrails","default":[]},"global_boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Global Boundary Constraints","default":[]},"global_action_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Action Guidelines","default":[]}},"type":"object","title":"Guardrails"}}}}
```

## The HTTPValidationError object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## The HarnessContext object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessContext":{"properties":{"context_version":{"type":"integer","title":"Context Version","default":1},"config_fingerprint":{"type":"string","title":"Config Fingerprint","default":""},"source":{"type":"string","title":"Source","default":""},"identity":{"$ref":"#/components/schemas/AgentIdentity"},"world_scope":{"$ref":"#/components/schemas/WorldScope"},"tools":{"$ref":"#/components/schemas/Tools"},"guardrails":{"$ref":"#/components/schemas/Guardrails"},"write_floor":{"$ref":"#/components/schemas/WriteFloor"},"runtime":{"$ref":"#/components/schemas/Runtime"}},"type":"object","required":["identity","world_scope","tools","guardrails","write_floor","runtime"],"title":"HarnessContext","description":"A framework-neutral, retrievable service bootstrap projection."},"AgentIdentity":{"properties":{"entry_actor_name":{"type":"string","title":"Entry Actor Name","default":""},"name":{"type":"string","title":"Name","default":""},"role":{"type":"string","title":"Role","default":""},"developed_by":{"type":"string","title":"Developed By","default":""},"instructions":{"type":"string","title":"Instructions","default":""},"initial_state":{"type":"string","title":"Initial State","default":""}},"type":"object","title":"AgentIdentity","description":"Who the agent is: the service's authored persona and its reference\ninstructions. Named ``AgentIdentity`` (not ``Identity``) to avoid colliding\nwith the existing ``config.models.Identity`` OpenAPI schema (a same-name\ncollision would force-rename that shipped schema, a breaking spec change)."},"WorldScope":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"scoped_entity_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Scoped Entity Ids","default":[]},"allow_create":{"type":"boolean","title":"Allow Create","default":false}},"type":"object","required":["workspace_id"],"title":"WorldScope","description":"The world slice — ids only (the leaf stays I/O-free). This is the\nread/subject scope, NOT the write bound (see ``write_floor``).\n``allow_create`` records context intent and is not an authorization grant."},"Tools":{"properties":{"descriptors":{"items":{"$ref":"#/components/schemas/ToolDescriptor"},"type":"array","title":"Descriptors","default":[]},"read_tool_names":{"items":{"type":"string"},"type":"array","title":"Read Tool Names","default":[]},"write_tool_names":{"items":{"type":"string"},"type":"array","title":"Write Tool Names","default":[]}},"type":"object","title":"Tools","description":"Discovery hint — the neutral descriptors. NOT the enforcement (the MCP\nedge is; a remote agent discovers live schemas from the server too)."},"ToolDescriptor":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description","default":""},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","default":{}}},"type":"object","required":["name"],"title":"ToolDescriptor"},"Guardrails":{"properties":{"guardrails":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Guardrails","default":[]},"global_boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Global Boundary Constraints","default":[]},"global_action_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Action Guidelines","default":[]}},"type":"object","title":"Guardrails"},"WriteFloor":{"properties":{"enforced_at":{"type":"string","title":"Enforced At","default":"mcp-world-tools-edge"},"requires_entity_anchor":{"type":"boolean","title":"Requires Entity Anchor","default":true},"clinical_write_principal":{"type":"string","title":"Clinical Write Principal","default":"provider-only"},"clinical_write_scope":{"type":"string","title":"Clinical Write Scope","default":"any-entity-in-workspace"},"enrichment_write_scope":{"type":"string","title":"Enrichment Write Scope","default":"caller-anchor-only"},"unanchored_or_api_key_writes":{"type":"string","title":"Unanchored Or Api Key Writes","default":"none"},"allow_create":{"type":"boolean","title":"Allow Create","default":false}},"type":"object","title":"WriteFloor","description":"A static summary of the MCP write policy.\n\nThe MCP edge resolves the caller's actual principal and enforces the\nresult. These fields do not grant write access: API-key and unanchored\ncallers get no writes."},"Runtime":{"properties":{"engage_model":{"type":"string","title":"Engage Model","default":""},"channel_kind":{"type":"string","title":"Channel Kind","default":""},"language":{"type":"string","title":"Language","default":""},"caller_context":{"type":"string","title":"Caller Context","default":""}},"type":"object","title":"Runtime"}}}}
```

## The HarnessDefaultListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessDefaultListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/HarnessDefaultResponse"},"type":"array","title":"Items","description":"One per harness, in (kind, harness) order."}},"type":"object","required":["items"],"title":"HarnessDefaultListResponse"},"HarnessDefaultResponse":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo"},"tag":{"type":"string","title":"Tag"},"asset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"updated_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Updated By"},"refusal":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refusal","description":"Why the platform may not run this default's release now (revoked, unregistered, an unsupported contract), so\nevery unpinned service's sessions of this harness fail closed until it is set again. None for ``in-tree`` and for\na release the platform may run."},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"The policy release this default names, the values its harness runs, or None."},"policy_refusal":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policy Refusal","description":"Why the platform may not run this default's policy now (revoked, unregistered, an unsupported contract), so\nevery unpinned service's sessions of this harness fail closed until it is set again. None without a policy and\nfor a policy the platform may run."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","updated_at","updated_by"],"title":"HarnessDefaultResponse"},"HarnessKind":{"type":"string","enum":["voice","text"]},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."}}}}
```

## The HarnessDefaultResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessDefaultResponse":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo"},"tag":{"type":"string","title":"Tag"},"asset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"updated_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Updated By"},"refusal":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refusal","description":"Why the platform may not run this default's release now (revoked, unregistered, an unsupported contract), so\nevery unpinned service's sessions of this harness fail closed until it is set again. None for ``in-tree`` and for\na release the platform may run."},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"The policy release this default names, the values its harness runs, or None."},"policy_refusal":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Policy Refusal","description":"Why the platform may not run this default's policy now (revoked, unregistered, an unsupported contract), so\nevery unpinned service's sessions of this harness fail closed until it is set again. None without a policy and\nfor a policy the platform may run."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","updated_at","updated_by"],"title":"HarnessDefaultResponse"},"HarnessKind":{"type":"string","enum":["voice","text"]},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."}}}}
```

## The HarnessKind object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessKind":{"type":"string","enum":["voice","text"]}}}}
```

## The HarnessPin object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessPin":{"properties":{"repo":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag","description":"A release tag of the harness, e.g. ``grok_voice-v1.2.0`` or ``grok_voice-v1.2.0-hotfix.1``, or ``in-tree``."},"asset":{"anyOf":[{"type":"string","maxLength":256,"minLength":1},{"type":"null"}],"title":"Asset","description":"The wheel's file name on the release."},"sha256":{"anyOf":[{"$ref":"#/components/schemas/Sha256"},{"type":"null"}]},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"A policy release registered in `policy_releases.json`, named exactly by `repo`, `tag`, `asset` and `sha256`:\nthe values the harness runs. Independent of the release, so `in-tree` can name one. Left out, a pin runs the\ndefault's policy, and a default names none. Stored and audited without the key when left out."},"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","maxLength":64,"minLength":1,"title":"Harness","description":"A voice family (``grok_voice``, ``gpt_live``, ...) or a text provider family (``openai``, ``anthropic``, ...)."}},"type":"object","required":["tag","kind","harness"],"title":"HarnessPin"},"Sha256":{"type":"string"},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."},"HarnessKind":{"type":"string","enum":["voice","text"]}}}}
```

## The HarnessReleaseListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessReleaseListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/src__routes__harness_platform__HarnessReleaseListResponse__Item"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"HarnessReleaseListResponse"},"src__routes__harness_platform__HarnessReleaseListResponse__Item":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"type":"string","title":"Repo"},"tag":{"type":"string","title":"Tag"},"asset":{"type":"string","title":"Asset"},"sha256":{"type":"string","title":"Sha256"},"contract_version":{"type":"string","title":"Contract Version"},"harness_version":{"type":"string","title":"Harness Version"},"conformance":{"type":"string","title":"Conformance"},"refusal":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refusal","description":"Why the platform may not run it (revoked, an unsupported contract, conformance not ``pass``), or None when a\npin or a default may name it."},"baked":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Baked","description":"Whether the running agent-engine image carries it, None when agent-engine could not say. A pin or a default\nnaming a release the image does not carry is refused until agent-engine's CD deploys it."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","contract_version","harness_version","conformance","refusal","baked"],"title":"Item"},"HarnessKind":{"type":"string","enum":["voice","text"]}}}}
```

## The HarnessSettingSource object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessSettingSource":{"type":"string","enum":["harness_default","service","policy"]}}}}
```

## The HarnessSettingValue object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessSettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]}}}}
```

## The HarnessSettings object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessSettings":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","maxLength":64,"minLength":1,"title":"Harness"},"settings":{"additionalProperties":{"$ref":"#/components/schemas/ServedHarnessSetting"},"type":"object","maxProperties":200,"title":"Settings"}},"type":"object","required":["kind","harness"],"title":"HarnessSettings","description":"The settings one harness declares, resolved for a service by platform-api: the service's value, else the\nharness default. Only keys the harness declares are served."},"HarnessKind":{"type":"string","enum":["voice","text"]},"ServedHarnessSetting":{"properties":{"value":{"$ref":"#/components/schemas/HarnessSettingValue"},"source":{"$ref":"#/components/schemas/HarnessSettingSource"}},"type":"object","required":["value","source"],"title":"ServedHarnessSetting","description":"One declared setting's value for a service, and the layer it came from."},"HarnessSettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"HarnessSettingSource":{"type":"string","enum":["harness_default","service","policy"]}}}}
```

## The HarnessSettingsSchema object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessSettingsSchema":{"properties":{"kind":{"type":"string","title":"Kind"},"harness":{"type":"string","title":"Harness"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"The release the service runs, or `in-tree`. None when the harness has nothing to run (its effective entry has\nan `error`); it then lists the in-tree schema."},"harness_version":{"type":"string","title":"Harness Version","description":"The schema's version: the release's, or `0.0.0` for `in-tree`."},"settings":{"items":{"$ref":"#/components/schemas/SettingSpec"},"type":"array","title":"Settings"}},"type":"object","required":["kind","harness","tag","harness_version","settings"],"title":"HarnessSettingsSchema","description":"What one harness the service runs declares."},"SettingSpec":{"properties":{"key":{"type":"string","maxLength":100,"minLength":1,"title":"Key"},"area":{"$ref":"#/components/schemas/SettingArea"},"type":{"$ref":"#/components/schemas/SettingType"},"default":{"$ref":"#/components/schemas/SettingValue"},"minimum":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Minimum"},"maximum":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Maximum"},"choices":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":50,"minItems":1},{"type":"null"}],"title":"Choices"},"max_length":{"anyOf":[{"type":"integer","maximum":10000,"minimum":1},{"type":"null"}],"title":"Max Length"},"unit":{"anyOf":[{"$ref":"#/components/schemas/SettingUnit"},{"type":"null"}]},"scopes":{"items":{"$ref":"#/components/schemas/SettingScope"},"type":"array","maxItems":2,"minItems":1,"title":"Scopes"},"description":{"type":"string","maxLength":500,"minLength":1,"title":"Description"}},"additionalProperties":false,"type":"object","required":["key","area","type","default","scopes","description"],"title":"SettingSpec","description":"One setting a harness declares: its type, bounds, choices, default and where a tenant may set it."},"SettingArea":{"type":"string","enum":["timing","turn_taking","tools","call_control","speech","context","flows","greeting","retries","channel","guardrails","safety"]},"SettingType":{"type":"string","enum":["bool","int","float","duration_ms","enum","string","string_list"]},"SettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"SettingUnit":{"type":"string","enum":["ms","s","tokens","count","percent"]},"SettingScope":{"type":"string","enum":["workspace","service"]}}}}
```

## The HarnessSource object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HarnessSource":{"type":"string","enum":["pin","workspace_default","harness_default"]}}}}
```

## The HealFieldRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HealFieldRequest":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"value":{"type":"string","maxLength":2000,"minLength":1,"title":"Value"},"field_type":{"type":"string","maxLength":32,"title":"Field Type"},"label":{"type":"string","maxLength":256,"title":"Label"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"context":{"additionalProperties":true,"type":"object","title":"Context"}},"type":"object","required":["key","value","field_type","label"],"title":"HealFieldRequest"}}}}
```

## The HealFieldResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HealFieldResponse":{"properties":{"corrected_value":{"type":"string","maxLength":4000,"title":"Corrected Value"},"explanation":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Explanation"},"confidence":{"type":"number","maximum":1,"minimum":0,"title":"Confidence"}},"type":"object","required":["corrected_value","confidence"],"title":"HealFieldResponse"}}}}
```

## The HeldTextFloor object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"}}}}
```

## The HipaaReportResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HipaaReportResponse":{"properties":{"generated_at":{"type":"string","title":"Generated At"},"report_period_days":{"type":"integer","title":"Report Period Days"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"audit_summary":{"additionalProperties":true,"type":"object","title":"Audit Summary"},"retention_policy":{"additionalProperties":true,"type":"object","title":"Retention Policy"},"encryption":{"additionalProperties":{"type":"boolean"},"type":"object","title":"Encryption"},"access_controls":{"additionalProperties":true,"type":"object","title":"Access Controls"},"api_key_summary":{"additionalProperties":{"type":"integer"},"type":"object","title":"Api Key Summary"},"compliance_status":{"type":"string","title":"Compliance Status"}},"type":"object","required":["generated_at","report_period_days","workspace_id","audit_summary","retention_policy","encryption","access_controls","api_key_summary","compliance_status"],"title":"HipaaReportResponse"}}}}
```

## The HttpSettings object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HttpSettings":{"properties":{"allowed_origins":{"items":{"type":"string","maxLength":253},"type":"array","maxItems":20,"title":"Allowed Origins","description":"Origins whose web pages may call this workspace's API from a browser, such as `https://app.example.com`.\n\nAt most 20. Each is `https://host` or `https://host:port`, with no path, query, wildcard or credentials.\n`localhost` origins are for local development and are refused in production."}},"type":"object","required":["allowed_origins"],"title":"HttpSettings"}}}}
```

## The HumanSegment object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"HumanSegment":{"properties":{"speaker_role":{"type":"string","title":"Speaker Role"},"transcript":{"type":"string","title":"Transcript"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"}},"type":"object","required":["speaker_role","transcript"],"title":"HumanSegment"}}}}
```

## The IdentifierString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The Identity object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Identity":{"properties":{"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"developed_by":{"type":"string","title":"Developed By"},"default_spoken_language":{"type":"string","title":"Default Spoken Language"},"relationship_to_developer":{"$ref":"#/components/schemas/RelationshipToDeveloper"}},"type":"object","required":["name","role","developed_by","default_spoken_language"],"title":"Identity"},"RelationshipToDeveloper":{"properties":{"ownership":{"type":"string","title":"Ownership"},"type":{"type":"string","title":"Type"},"conversation_visibility":{"type":"string","title":"Conversation Visibility"},"thought_visibility":{"type":"string","title":"Thought Visibility"}},"type":"object","required":["ownership","type","conversation_visibility","thought_visibility"],"title":"RelationshipToDeveloper"}}}}
```

## The IdentityGroupLifecycleActionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IdentityGroupLifecycleActionRequest":{"properties":{"connection_id":{"type":"string","format":"uuid","title":"Connection Id"},"connection_revision":{"type":"string","format":"uuid","title":"Connection Revision"},"configuration_id":{"type":"string","format":"uuid","title":"Configuration Id"},"configuration_revision":{"type":"string","format":"uuid","title":"Configuration Revision"},"mapping_revision":{"type":"string","format":"uuid","title":"Mapping Revision"}},"additionalProperties":false,"type":"object","required":["connection_id","connection_revision","configuration_id","configuration_revision","mapping_revision"],"title":"IdentityGroupLifecycleActionRequest"}}}}
```

## The IdentityGroupLifecycleActionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IdentityGroupLifecycleActionResponse":{"properties":{"connection_id":{"type":"string","format":"uuid","title":"Connection Id"},"connection_revision":{"type":"string","format":"uuid","title":"Connection Revision"},"configuration_id":{"type":"string","format":"uuid","title":"Configuration Id"},"configuration_revision":{"type":"string","format":"uuid","title":"Configuration Revision"},"mapping_revision":{"type":"string","format":"uuid","title":"Mapping Revision"},"action_id":{"type":"string","format":"uuid","title":"Action Id"},"mapping_id":{"type":"string","format":"uuid","title":"Mapping Id"}},"type":"object","required":["connection_id","connection_revision","configuration_id","configuration_revision","mapping_revision","action_id","mapping_id"],"title":"IdentityGroupLifecycleActionResponse"}}}}
```

## The IdentityLifecycleActionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IdentityLifecycleActionRequest":{"properties":{"configuration_id":{"type":"string","format":"uuid","title":"Configuration Id"},"configuration_revision":{"type":"string","format":"uuid","title":"Configuration Revision"}},"additionalProperties":false,"type":"object","required":["configuration_id","configuration_revision"],"title":"IdentityLifecycleActionRequest"}}}}
```

## The IdentityLifecycleActionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IdentityLifecycleActionResponse":{"properties":{"action_id":{"type":"string","format":"uuid","title":"Action Id"},"connection_id":{"type":"string","format":"uuid","title":"Connection Id"},"configuration_id":{"type":"string","format":"uuid","title":"Configuration Id"},"configuration_revision":{"type":"string","format":"uuid","title":"Configuration Revision"}},"type":"object","required":["action_id","connection_id","configuration_id","configuration_revision"],"title":"IdentityLifecycleActionResponse"}}}}
```

## The IdentityMetrics object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IdentityMetrics":{"properties":{"active_api_keys":{"type":"integer","title":"Active Api Keys","default":0},"active_sessions":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Active Sessions"},"failed_auths_1h":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Failed Auths 1H"},"locked_accounts":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Locked Accounts"},"mfa_coverage_pct":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mfa Coverage Pct"}},"type":"object","title":"IdentityMetrics"}}}}
```

## The Index-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Index-Input":{"properties":{"columns":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1,"title":"Columns"}},"type":"object","required":["columns"],"title":"Index"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The Index-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Index-Output":{"properties":{"name":{"type":"string","title":"Name"},"definition":{"type":"string","title":"Definition","description":"``pg_indexes.indexdef`` — the full CREATE INDEX statement."}},"type":"object","required":["name","definition"],"title":"Index"}}}}
```

## The InjectRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InjectRequest":{"properties":{"message":{"type":"string","maxLength":5000,"minLength":1,"title":"Message"},"sender":{"type":"string","maxLength":200,"title":"Sender","default":"System"},"event_type":{"type":"string","enum":["external_event","guidance"],"title":"Event Type","description":"external_event (factual info) or guidance (instructional)","default":"external_event"}},"type":"object","required":["message"],"title":"InjectRequest"}}}}
```

## The InjectResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InjectResponse":{"properties":{"status":{"type":"string","enum":["delivered","queued_no_subscriber"],"title":"Status"},"call_sid":{"type":"string","title":"Call Sid"}},"type":"object","required":["status","call_sid"],"title":"InjectResponse"}}}}
```

## The InsightResultResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InsightResultResponse":{"properties":{"result_id":{"type":"string","format":"uuid","title":"Result Id"},"queried_at":{"type":"string","format":"date-time","title":"Queried At"},"truncated":{"type":"boolean","title":"Truncated"},"sql":{"type":"string","title":"Sql"},"logical_sql":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Logical Sql"},"source":{"anyOf":[{"$ref":"#/components/schemas/DemoSource"},{"type":"null"}]},"columns":{"items":{"$ref":"#/components/schemas/EvidenceColumn"},"type":"array","title":"Columns"},"rows":{"items":{"items":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"array"},"type":"array","title":"Rows"}},"type":"object","required":["result_id","queried_at","truncated","sql","columns","rows"],"title":"InsightResultResponse"},"DemoSource":{"properties":{"kind":{"type":"string","const":"published_demo","title":"Kind","default":"published_demo"},"synthetic":{"type":"boolean","const":true,"title":"Synthetic","default":true},"dataset_version":{"type":"string","pattern":"^r[12]_[0-9]{8}_[a-f0-9]{64}$","title":"Dataset Version"},"as_of_date":{"type":"string","format":"date","title":"As Of Date"},"data_through":{"type":"string","format":"date","title":"Data Through"},"event_window_start":{"type":"string","format":"date-time","title":"Event Window Start"},"event_window_end":{"type":"string","format":"date-time","title":"Event Window End"},"observed_before":{"type":"string","format":"date-time","title":"Observed Before"},"recipe_version":{"type":"string","maxLength":100,"minLength":1,"title":"Recipe Version"},"content_sha256":{"type":"string","pattern":"^[a-f0-9]{64}$","title":"Content Sha256"},"logical_table":{"type":"string","title":"Logical Table"},"snapshot_table":{"type":"string","title":"Snapshot Table"},"definitions":{"additionalProperties":{"type":"string"},"type":"object","title":"Definitions"},"table_map":{"additionalProperties":{"$ref":"#/components/schemas/DemoTable"},"type":"object","title":"Table Map"},"definition_records":{"items":{"$ref":"#/components/schemas/DemoDefinition"},"type":"array","title":"Definition Records","default":[]},"event_window_scope":{"anyOf":[{"type":"string","const":"conversations"},{"type":"null"}],"title":"Event Window Scope"}},"additionalProperties":false,"type":"object","required":["dataset_version","as_of_date","data_through","event_window_start","event_window_end","observed_before","recipe_version","content_sha256","logical_table","snapshot_table","definitions"],"title":"DemoSource","description":"Captured provenance, safe to expose with authorized selected evidence."},"DemoTable":{"properties":{"physical_table":{"type":"string","title":"Physical Table"},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"row_count":{"type":"integer","maximum":5000,"minimum":0,"title":"Row Count"},"description":{"type":"string","maxLength":2048,"title":"Description"}},"additionalProperties":false,"type":"object","required":["physical_table","columns","row_count","description"],"title":"DemoTable"},"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"},"DemoDefinition":{"properties":{"id":{"type":"string","maxLength":80,"minLength":1,"title":"Id"},"description":{"type":"string","maxLength":1024,"minLength":1,"title":"Description"},"population":{"type":"string","maxLength":512,"minLength":1,"title":"Population"},"time_basis":{"type":"string","maxLength":512,"minLength":1,"title":"Time Basis"},"units":{"type":"string","maxLength":128,"minLength":1,"title":"Units"}},"additionalProperties":false,"type":"object","required":["id","description","population","time_basis","units"],"title":"DemoDefinition"},"EvidenceColumn":{"properties":{"index":{"type":"integer","title":"Index"},"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"}},"type":"object","required":["index","name","type"],"title":"EvidenceColumn"}}}}
```

## The InsightSelection object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InsightSelection":{"properties":{"source_session_id":{"type":"string","format":"uuid","title":"Source Session Id"},"presentation_id":{"type":"string","format":"uuid","title":"Presentation Id"},"row_index":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Row Index"},"series_index":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Series Index"}},"additionalProperties":false,"type":"object","required":["source_session_id","presentation_id"],"title":"InsightSelection"}}}}
```

## The InstrumentationScope object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InstrumentationScope":{"properties":{"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"}},"type":"object","required":["name","version"],"title":"InstrumentationScope"}}}}
```

## The IntakeFieldType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IntakeFieldType":{"type":"string","enum":["str","int","float","bool","date","datetime"],"title":"IntakeFieldType","description":"The types a contract's `schema[].type` may declare: `str`, `int`, `float`, `bool`, `date` and `datetime`.\n\nA CSV cell is accepted when it parses as its column's type, ignoring surrounding whitespace. `date` and\n`datetime` cells are in ISO format, and `bool` cells are one of true, false, t, f, yes, no, y, n, 0 or 1, in\nany case. A cell with nothing in it is not checked, except in a primary key column, where it is refused. A\ncell with only spaces is not empty and has to parse. An upload is checked up to its first 200,000 rows."}}}}
```

## The IntakeFileRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IntakeFileRow":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"file_id — used for download."},"filename":{"type":"string","title":"Filename"},"dataset":{"type":"string","title":"Dataset","description":"Schema slug (UI label \"Schema\")."},"schema_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schema Version","description":"The contract version this file validated against (e.g. ``v1``)."},"status":{"$ref":"#/components/schemas/_FileStatus"},"error_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Reason","description":"Null unless rejected/failed."},"size_bytes":{"type":"integer","title":"Size Bytes"},"ingested_at":{"type":"string","title":"Ingested At","description":"ISO-8601 timestamp the file was received."},"document_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Document Id","description":"The document this version belongs to. Null for snapshot and CSV rows; set for documents. The console\ngroups versions by it to show each document's version history."},"version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version","description":"The file's version number (per-document for documents, per-dataset for\nsnapshot). Lets the UI render a document's version history."},"source_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Type","description":"Origin of the document this version belongs to: ``manual`` for console uploads, ``google_shared_drive``\nfor the Drive connector. Null for snapshot and CSV rows."},"source_file_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source File Id","description":"The source's stable external id (e.g. the Google Drive file id) for the\ndocument. Lets the console show provenance and confirm a re-synced file\nbumped the *same* document. Null for manual uploads and snapshot rows."},"source_folder_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Folder Path","description":"Where the file lived within the mapped Drive folder tree, as a relative path with folder names joined by\n``/`` (e.g. ``clinical/notes``), and ``''`` at the mapped root. Lets the console show the original folder\nstructure. Null for manual uploads and snapshot rows."},"doc_metadata":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Doc Metadata","description":"Caller-supplied tags linking the document to a real-world subject, e.g. ``{\"patient_id\": \"…\"}``. Set at upload for the whole document version\nchain. ``{}`` for a document with no tags; null only for snapshot/CSV rows."}},"type":"object","required":["id","filename","dataset","status","size_bytes","ingested_at"],"title":"IntakeFileRow","description":"A file in the Files list."},"_FileStatus":{"type":"string","enum":["received","scanned","processing","curated","rejected","failed","held"]}}}}
```

## The IntakeSourceRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IntakeSourceRow":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"source_id."},"source_type":{"type":"string","title":"Source Type"},"display_name":{"type":"string","title":"Display Name"},"drive_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Drive Id"},"folders":{"items":{"$ref":"#/components/schemas/DriveFolderMapping"},"type":"array","title":"Folders"},"impersonate_subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Impersonate Subject","description":"DWD impersonation subject, if this source authenticates via domain-wide delegation."},"status":{"type":"string","title":"Status"},"created_ts":{"type":"string","title":"Created Ts","description":"ISO-8601 timestamp."}},"type":"object","required":["id","source_type","display_name","folders","status","created_ts"],"title":"IntakeSourceRow","description":"A registered intake source (Sources list)."},"DriveFolderMapping":{"properties":{"folder_id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Folder Id"},"dataset":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Dataset"},"contains_phi":{"type":"boolean","title":"Contains Phi","default":true}},"type":"object","required":["folder_id","dataset"],"title":"DriveFolderMapping","description":"One Google Drive folder ↔ one intake dataset.\n\n``folder_id`` is the Drive folder id (the identity — never the folder name,\nwhich can be renamed/moved). One folder maps to exactly one dataset."}}}}
```

## The IntegrationApprovalResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IntegrationApprovalResponse":{"properties":{"status":{"type":"string","enum":["granted","rejected"],"title":"Status"},"conversation_id":{"type":"string","maxLength":256,"minLength":1,"title":"Conversation Id"}},"type":"object","required":["status","conversation_id"],"title":"IntegrationApprovalResponse","description":"Resolution outcome for a pending integration-write approval."}}}}
```

## The IntegrationRejectRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IntegrationRejectRequest":{"properties":{"reason":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Reason"},"source":{"anyOf":[{"type":"string","const":"playground"},{"type":"null"}],"title":"Source","description":"Set to ``playground`` when the developer console Playground decides the approval. Refused with 403 on a real conversation, one no Playground session or test credential started."}},"type":"object","title":"IntegrationRejectRequest","description":"Reject body — optional free-text reason surfaced to the agent."}}}}
```

## The IntegrationToolRef-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IntegrationToolRef-Input":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string","maxLength":256,"minLength":1},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","maxProperties":50,"title":"Skill Input Bindings","description":"Endpoint parameter -> parent skill input mappings injected at dispatch."}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef","description":"Reference to an integration endpoint by integration + endpoint name."}}}}
```

## The InteractionDynamics object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InteractionDynamics":{"properties":{"turn_taking_quality":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Turn Taking Quality","description":"How well speakers managed turn-taking - interruptions, overlaps, pacing"},"information_density":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Information Density","description":"Whether the agent gave too much or too little information per turn"},"repair_effectiveness":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Repair Effectiveness","description":"How misunderstandings were detected and resolved"},"rapport_trajectory":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Rapport Trajectory","description":"How the interpersonal dynamic evolved across the call"}},"type":"object","title":"InteractionDynamics","description":"System-level analysis of the conversation as a whole."}}}}
```

## The InternalDirectServiceConfigResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InternalDirectServiceConfigResponse":{"properties":{"service":{"$ref":"#/components/schemas/Service"},"agent_version":{"$ref":"#/components/schemas/AgentVersion"},"dynamic_behaviors":{"items":{"$ref":"#/components/schemas/DynamicBehavior"},"type":"array","title":"Dynamic Behaviors","description":"As ``ResolvedServiceConfig.dynamic_behaviors``. None is scoped to graph states: a direct program has none."},"effective_harnesses":{"items":{"$ref":"#/components/schemas/EffectiveHarness"},"type":"array","title":"Effective Harnesses","description":"As ``InternalServiceConfigResponse.effective_harnesses``."},"harness_settings":{"items":{"$ref":"#/components/schemas/HarnessSettings"},"type":"array","title":"Harness Settings","description":"As ``InternalServiceConfigResponse.harness_settings``."}},"type":"object","required":["service","agent_version","dynamic_behaviors","effective_harnesses","harness_settings"],"title":"InternalDirectServiceConfigResponse","description":"Composite response matching DirectServiceConfig shape for voice-agent consumption."},"Service":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"keyterms":{"items":{"type":"string"},"type":"array","title":"Keyterms"},"is_active":{"type":"boolean","title":"Is Active"},"version_sets":{"additionalProperties":{"$ref":"#/components/schemas/VersionSet-Output"},"type":"object","title":"Version Sets"},"tags":{"items":{"$ref":"#/components/schemas/ServiceTag"},"type":"array","title":"Tags"},"tool_capacity":{"type":"integer","title":"Tool Capacity","default":3},"channel_type":{"type":"string","enum":["voice","text"],"title":"Channel Type","default":"voice"},"environment":{"type":"string","enum":["sandbox","production"],"title":"Environment","default":"production"},"demo_mode":{"type":"boolean","title":"Demo Mode","default":false},"platform_caller_verification":{"type":"boolean","title":"Platform Caller Verification","default":true},"caller_verification_endpoint_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Caller Verification Endpoint Id"},"allow_unverified_integration_results":{"type":"boolean","title":"Allow Unverified Integration Results","default":false},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/ServiceVoiceConfig-Output"},{"type":"null"}]},"accepted_context":{"items":{"$ref":"#/components/schemas/ContextKeySpec"},"type":"array","maxItems":100,"title":"Accepted Context"},"crisis_call_911_reply":{"anyOf":[{"$ref":"#/components/schemas/CrisisCall911Reply"},{"type":"null"}]},"contact_lines":{"items":{"$ref":"#/components/schemas/ContactLine"},"type":"array","maxItems":50,"title":"Contact Lines"},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending","default":"stay_on_line"},"output_checks":{"$ref":"#/components/schemas/ServiceOutputChecks"},"emergency_floor":{"$ref":"#/components/schemas/ServiceEmergencyFloor"},"declared_languages":{"anyOf":[{"items":{"type":"string","enum":["en","es","ar","fr","de","pt","zh","ja","ko"]},"type":"array","maxItems":9,"minItems":1},{"type":"null"}],"title":"Declared Languages"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","name","description","agent_id","context_graph_id","keyterms","is_active","version_sets","tags"],"title":"Service","description":"A service links an agent + context graph + version sets."},"VersionSet-Output":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"ServiceTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"ServiceTag"},"ServiceVoiceConfig-Output":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingResponse"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingResponse":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to","warm_transfer","warm_transfer_answer_timeout_s","warm_transfer_on_queue","warm_transfer_on_miss","receiver_classifier","approved_destinations","fallback_to","test_destinations","verification_callers","hours","after_hours_destination","default_destination","transfer_reasons","destination_hours","unsupported_language_destination"],"title":"ServiceForwardingResponse","description":"Forwarding responses always include defaults; the input keeps its existing schema name."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."},"ContextKeySpec":{"properties":{"key":{"$ref":"#/components/schemas/SlugString"},"type":{"type":"string","enum":["string","number"],"title":"Type"},"description":{"$ref":"#/components/schemas/DescriptionString"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["key","type","description","required"],"title":"ContextKeySpec","description":"One key a conversation may supply as start-time context for a service.\n\nThe value is validated against ``type`` at conversation start; a tool can then\nbind the key to one of its parameters (injected, hidden from the model)."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"CrisisCall911Reply":{"properties":{"en":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1},"es":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1}},"additionalProperties":false,"type":"object","required":["en","es"],"title":"CrisisCall911Reply","description":"Per-service wording added when a caller already in crisis asks for emergency dispatch."},"ContactLine":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"type":"string","maxLength":16,"minLength":2,"title":"Number"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLine","description":"A service's declared contact line."},"ServiceOutputChecks":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck"},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck"},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck"},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck"},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck"},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck"},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck"},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck"},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck"}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecks"},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"},"ServiceEmergencyFloor":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor"},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor"},"held_text":{"$ref":"#/components/schemas/HeldTextFloor"}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloor"},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"},"AgentVersion":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"version":{"type":"integer","title":"Version"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"initials":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Initials"},"identity":{"$ref":"#/components/schemas/Identity"},"background":{"type":"string","title":"Background"},"behaviors":{"items":{"type":"string"},"type":"array","title":"Behaviors"},"communication_patterns":{"items":{"type":"string"},"type":"array","title":"Communication Patterns"},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/VoiceConfig"},{"type":"null"}]},"program":{"$ref":"#/components/schemas/AgentProgram-Output"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","agent_id","version","identity","background","behaviors","communication_patterns"],"title":"AgentVersion","description":"A version of an Agent document."},"Identity":{"properties":{"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"developed_by":{"type":"string","title":"Developed By"},"default_spoken_language":{"type":"string","title":"Default Spoken Language"},"relationship_to_developer":{"$ref":"#/components/schemas/RelationshipToDeveloper"}},"type":"object","required":["name","role","developed_by","default_spoken_language"],"title":"Identity"},"RelationshipToDeveloper":{"properties":{"ownership":{"type":"string","title":"Ownership"},"type":{"type":"string","title":"Type"},"conversation_visibility":{"type":"string","title":"Conversation Visibility"},"thought_visibility":{"type":"string","title":"Thought Visibility"}},"type":"object","required":["ownership","type","conversation_visibility","thought_visibility"],"title":"RelationshipToDeveloper"},"VoiceConfig":{"properties":{"voice_id":{"type":"string","title":"Voice Id"},"stability":{"type":"number","title":"Stability","default":0},"similarity_boost":{"type":"number","title":"Similarity Boost","default":0},"style":{"type":"number","title":"Style","default":0},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"}},"type":"object","required":["voice_id"],"title":"VoiceConfig"},"AgentProgram-Output":{"oneOf":[{"$ref":"#/components/schemas/WorkflowProgram"},{"$ref":"#/components/schemas/DirectProgram-Output"}],"discriminator":{"propertyName":"kind","mapping":{"direct":"#/components/schemas/DirectProgram-Output","workflow":"#/components/schemas/WorkflowProgram"}}},"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."},"DirectProgram-Output":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"DynamicBehavior":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Stable across versions: the same behavior keeps its id in every version that carries it. The client\ngenerates it. A resolved behavior carries its library set's id."},"version":{"anyOf":[{"type":"integer","maximum":2147483647,"minimum":1},{"type":"null"}],"title":"Version","description":"The version of the library set this was resolved from. Null on a behavior embedded on a context graph\nversion."},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name","description":"What authors call it. The selector reads it with the condition and examples, and the reply prompt never\ndoes."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled behavior stays on the version and is never offered.","default":true},"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force, and the only text of a behavior that\nreaches the reply prompt. Null: the behavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay.","default":"add"},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one.","default":[]},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on. It ends\nsooner when the selector chooses another behavior with enough confidence, and when a turn is skipped: a\nmedical emergency, a request for a person, an empathy hold, a suspended session, or a state the behavior\ndoes not apply in.","default":1},"tags":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10,"title":"Tags","description":"Labels for authors. They never reach a prompt.","default":[]}},"additionalProperties":false,"type":"object","required":["id","name","condition"],"title":"DynamicBehavior","description":"One authored behavior: embedded on a context graph version, or resolved from a library set version."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"EffectiveHarness":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"The release tag, or ``in-tree``. None when ``error`` is set."},"asset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256"},"source":{"type":"string","enum":["pin","harness_default","invalid_pin"],"title":"Source","description":"``invalid_pin``: the service stores a pin of this harness that no longer validates. The entry names no\nrelease, so the harness has nothing to run until the pin is set again. A ``pin`` or ``harness_default`` with an\n``error`` names a release the platform may no longer run, and names no release either."},"contract_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Version","description":"The contract the release was built on, from the registry. None for ``in-tree`` and when ``error`` is set."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the harness has nothing to run on the service: its stored pin is invalid, or its pin or default names a\nrelease or a policy the platform may no longer run (revoked, unregistered, or off the supported contract range),\nor its pin names a harness the service does not run.\nSet, the entry names no release and no policy, so the harness has nothing to run. None otherwise."},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"The policy release the harness runs the values of: the pin's, else the default's. None when neither names one,\nand when ``error`` is set."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","source","contract_version","error","policy"],"title":"EffectiveHarness","description":"The release one harness runs on a service, and where that came from. ``repo``, ``asset`` and ``sha256`` are\nNone for ``in-tree``. agent-engine loads the wheel it baked at ``/opt/harnesses/<sha256>/``."},"HarnessKind":{"type":"string","enum":["voice","text"]},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."},"HarnessSettings":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","maxLength":64,"minLength":1,"title":"Harness"},"settings":{"additionalProperties":{"$ref":"#/components/schemas/ServedHarnessSetting"},"type":"object","maxProperties":200,"title":"Settings"}},"type":"object","required":["kind","harness"],"title":"HarnessSettings","description":"The settings one harness declares, resolved for a service by platform-api: the service's value, else the\nharness default. Only keys the harness declares are served."},"ServedHarnessSetting":{"properties":{"value":{"$ref":"#/components/schemas/HarnessSettingValue"},"source":{"$ref":"#/components/schemas/HarnessSettingSource"}},"type":"object","required":["value","source"],"title":"ServedHarnessSetting","description":"One declared setting's value for a service, and the layer it came from."},"HarnessSettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"HarnessSettingSource":{"type":"string","enum":["harness_default","service","policy"]}}}}
```

## The InternalServiceConfigResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InternalServiceConfigResponse":{"properties":{"service":{"$ref":"#/components/schemas/Service"},"agent_version":{"$ref":"#/components/schemas/AgentVersion"},"context_graph_version":{"$ref":"#/components/schemas/ContextGraphVersion"},"dynamic_behaviors":{"items":{"$ref":"#/components/schemas/DynamicBehavior"},"type":"array","title":"Dynamic Behaviors","description":"The dynamic behaviors the version set pins, resolved: one per pin in pin order. ``id`` is the library set's id\nand ``version`` the pinned version; ``enabled`` and ``states`` come from the pin, the rest from that version."},"effective_harnesses":{"items":{"$ref":"#/components/schemas/EffectiveHarness"},"type":"array","title":"Effective Harnesses","description":"The release each voice and text harness runs, resolved once here: the service's pin, else the harness default,\nwith the repo, tag, asset and sha256 of a release. agent-engine resolves a session's harness from it at session\nstart and loads the wheel it baked at ``/opt/harnesses/<sha256>/``."},"harness_settings":{"items":{"$ref":"#/components/schemas/HarnessSettings"},"type":"array","title":"Harness Settings","description":"Each harness in ``effective_harnesses``'s declared settings, resolved here: the service's value, else the\nharness default. agent-engine resolves its session's from it once, at session start."}},"type":"object","required":["service","agent_version","context_graph_version","dynamic_behaviors","effective_harnesses","harness_settings"],"title":"InternalServiceConfigResponse","description":"Composite response matching ServiceConfig shape for voice-agent consumption."},"Service":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"keyterms":{"items":{"type":"string"},"type":"array","title":"Keyterms"},"is_active":{"type":"boolean","title":"Is Active"},"version_sets":{"additionalProperties":{"$ref":"#/components/schemas/VersionSet-Output"},"type":"object","title":"Version Sets"},"tags":{"items":{"$ref":"#/components/schemas/ServiceTag"},"type":"array","title":"Tags"},"tool_capacity":{"type":"integer","title":"Tool Capacity","default":3},"channel_type":{"type":"string","enum":["voice","text"],"title":"Channel Type","default":"voice"},"environment":{"type":"string","enum":["sandbox","production"],"title":"Environment","default":"production"},"demo_mode":{"type":"boolean","title":"Demo Mode","default":false},"platform_caller_verification":{"type":"boolean","title":"Platform Caller Verification","default":true},"caller_verification_endpoint_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Caller Verification Endpoint Id"},"allow_unverified_integration_results":{"type":"boolean","title":"Allow Unverified Integration Results","default":false},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/ServiceVoiceConfig-Output"},{"type":"null"}]},"accepted_context":{"items":{"$ref":"#/components/schemas/ContextKeySpec"},"type":"array","maxItems":100,"title":"Accepted Context"},"crisis_call_911_reply":{"anyOf":[{"$ref":"#/components/schemas/CrisisCall911Reply"},{"type":"null"}]},"contact_lines":{"items":{"$ref":"#/components/schemas/ContactLine"},"type":"array","maxItems":50,"title":"Contact Lines"},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending","default":"stay_on_line"},"output_checks":{"$ref":"#/components/schemas/ServiceOutputChecks"},"emergency_floor":{"$ref":"#/components/schemas/ServiceEmergencyFloor"},"declared_languages":{"anyOf":[{"items":{"type":"string","enum":["en","es","ar","fr","de","pt","zh","ja","ko"]},"type":"array","maxItems":9,"minItems":1},{"type":"null"}],"title":"Declared Languages"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","name","description","agent_id","context_graph_id","keyterms","is_active","version_sets","tags"],"title":"Service","description":"A service links an agent + context graph + version sets."},"VersionSet-Output":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"ServiceTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"ServiceTag"},"ServiceVoiceConfig-Output":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingResponse"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingResponse":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to","warm_transfer","warm_transfer_answer_timeout_s","warm_transfer_on_queue","warm_transfer_on_miss","receiver_classifier","approved_destinations","fallback_to","test_destinations","verification_callers","hours","after_hours_destination","default_destination","transfer_reasons","destination_hours","unsupported_language_destination"],"title":"ServiceForwardingResponse","description":"Forwarding responses always include defaults; the input keeps its existing schema name."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."},"ContextKeySpec":{"properties":{"key":{"$ref":"#/components/schemas/SlugString"},"type":{"type":"string","enum":["string","number"],"title":"Type"},"description":{"$ref":"#/components/schemas/DescriptionString"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["key","type","description","required"],"title":"ContextKeySpec","description":"One key a conversation may supply as start-time context for a service.\n\nThe value is validated against ``type`` at conversation start; a tool can then\nbind the key to one of its parameters (injected, hidden from the model)."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"CrisisCall911Reply":{"properties":{"en":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1},"es":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1}},"additionalProperties":false,"type":"object","required":["en","es"],"title":"CrisisCall911Reply","description":"Per-service wording added when a caller already in crisis asks for emergency dispatch."},"ContactLine":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"type":"string","maxLength":16,"minLength":2,"title":"Number"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLine","description":"A service's declared contact line."},"ServiceOutputChecks":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck"},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck"},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck"},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck"},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck"},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck"},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck"},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck"},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck"}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecks"},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"},"ServiceEmergencyFloor":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor"},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor"},"held_text":{"$ref":"#/components/schemas/HeldTextFloor"}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloor"},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"},"AgentVersion":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"version":{"type":"integer","title":"Version"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"initials":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Initials"},"identity":{"$ref":"#/components/schemas/Identity"},"background":{"type":"string","title":"Background"},"behaviors":{"items":{"type":"string"},"type":"array","title":"Behaviors"},"communication_patterns":{"items":{"type":"string"},"type":"array","title":"Communication Patterns"},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/VoiceConfig"},{"type":"null"}]},"program":{"$ref":"#/components/schemas/AgentProgram-Output"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","agent_id","version","identity","background","behaviors","communication_patterns"],"title":"AgentVersion","description":"A version of an Agent document."},"Identity":{"properties":{"name":{"type":"string","title":"Name"},"role":{"type":"string","title":"Role"},"developed_by":{"type":"string","title":"Developed By"},"default_spoken_language":{"type":"string","title":"Default Spoken Language"},"relationship_to_developer":{"$ref":"#/components/schemas/RelationshipToDeveloper"}},"type":"object","required":["name","role","developed_by","default_spoken_language"],"title":"Identity"},"RelationshipToDeveloper":{"properties":{"ownership":{"type":"string","title":"Ownership"},"type":{"type":"string","title":"Type"},"conversation_visibility":{"type":"string","title":"Conversation Visibility"},"thought_visibility":{"type":"string","title":"Thought Visibility"}},"type":"object","required":["ownership","type","conversation_visibility","thought_visibility"],"title":"RelationshipToDeveloper"},"VoiceConfig":{"properties":{"voice_id":{"type":"string","title":"Voice Id"},"stability":{"type":"number","title":"Stability","default":0},"similarity_boost":{"type":"number","title":"Similarity Boost","default":0},"style":{"type":"number","title":"Style","default":0},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"}},"type":"object","required":["voice_id"],"title":"VoiceConfig"},"AgentProgram-Output":{"oneOf":[{"$ref":"#/components/schemas/WorkflowProgram"},{"$ref":"#/components/schemas/DirectProgram-Output"}],"discriminator":{"propertyName":"kind","mapping":{"direct":"#/components/schemas/DirectProgram-Output","workflow":"#/components/schemas/WorkflowProgram"}}},"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."},"DirectProgram-Output":{"properties":{"kind":{"type":"string","const":"direct","title":"Kind"},"instructions":{"type":"string","maxLength":32000,"minLength":1,"title":"Instructions"},"tools":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","maxItems":100,"title":"Tools"}},"additionalProperties":false,"type":"object","required":["kind","instructions"],"title":"DirectProgram","description":"The agent runs on one authored prompt and a fixed set of tools, with no context graph.\n\n``tools`` are the same ``ToolCallSpec`` a workflow state lists, so a tool is granted, bound and held to its\npolicies exactly as in a workflow. A direct program has no state to navigate, so a spec that asks for\nnavigation is refused here instead of being ignored when it runs."},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"ContextGraphVersion":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"context_graph_id":{"type":"string","format":"uuid","title":"Context Graph Id"},"version":{"type":"integer","title":"Version"},"description":{"type":"string","title":"Description"},"states":{"items":{"$ref":"#/components/schemas/ContextGraphState-Output"},"type":"array","title":"States"},"new_user_initial_state":{"type":"string","title":"New User Initial State"},"returning_user_initial_state":{"type":"string","title":"Returning User Initial State"},"terminal_state":{"type":"string","title":"Terminal State","default":""},"global_intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Intra State Navigation Guidelines","default":[]},"global_action_guidelines":{"items":{"type":"string"},"type":"array","title":"Global Action Guidelines","default":[]},"global_boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Global Boundary Constraints","default":[]},"topology_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Topology Description"},"dynamic_behaviors":{"items":{"$ref":"#/components/schemas/DynamicBehavior"},"type":"array","maxItems":254,"title":"Dynamic Behaviors"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","context_graph_id","version","description","states","new_user_initial_state","returning_user_initial_state"],"title":"ContextGraphVersion","description":"A version of a hierarchical state machine (context graph)."},"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"DynamicBehavior":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Stable across versions: the same behavior keeps its id in every version that carries it. The client\ngenerates it. A resolved behavior carries its library set's id."},"version":{"anyOf":[{"type":"integer","maximum":2147483647,"minimum":1},{"type":"null"}],"title":"Version","description":"The version of the library set this was resolved from. Null on a behavior embedded on a context graph\nversion."},"name":{"type":"string","maxLength":120,"minLength":1,"title":"Name","description":"What authors call it. The selector reads it with the condition and examples, and the reply prompt never\ndoes."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled behavior stays on the version and is never offered.","default":true},"condition":{"type":"string","maxLength":1000,"minLength":1,"title":"Condition","description":"When it applies, in terms of what the client wants or says. It describes the behavior to the selector."},"instruction":{"anyOf":[{"type":"string","maxLength":50000,"minLength":1},{"type":"null"}],"title":"Instruction","description":"The guidance the reply follows while the behavior is in force, and the only text of a behavior that\nreaches the reply prompt. Null: the behavior is decided and recorded, and changes no reply."},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode","description":"``add``: the guidance yields to every action guideline. ``replace``: it stands in for the reply's action\nguidelines, while boundary constraints, guardrails and safety rules stay.","default":"add"},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one.","default":[]},"sticky_turns":{"type":"integer","maximum":5,"minimum":1,"title":"Sticky Turns","description":"The fewest caller turns it stays in force once applied, counting the turn it was applied on. It ends\nsooner when the selector chooses another behavior with enough confidence, and when a turn is skipped: a\nmedical emergency, a request for a person, an empathy hold, a suspended session, or a state the behavior\ndoes not apply in.","default":1},"tags":{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10,"title":"Tags","description":"Labels for authors. They never reach a prompt.","default":[]}},"additionalProperties":false,"type":"object","required":["id","name","condition"],"title":"DynamicBehavior","description":"One authored behavior: embedded on a context graph version, or resolved from a library set version."},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"EffectiveHarness":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"The release tag, or ``in-tree``. None when ``error`` is set."},"asset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256"},"source":{"type":"string","enum":["pin","harness_default","invalid_pin"],"title":"Source","description":"``invalid_pin``: the service stores a pin of this harness that no longer validates. The entry names no\nrelease, so the harness has nothing to run until the pin is set again. A ``pin`` or ``harness_default`` with an\n``error`` names a release the platform may no longer run, and names no release either."},"contract_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Version","description":"The contract the release was built on, from the registry. None for ``in-tree`` and when ``error`` is set."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the harness has nothing to run on the service: its stored pin is invalid, or its pin or default names a\nrelease or a policy the platform may no longer run (revoked, unregistered, or off the supported contract range),\nor its pin names a harness the service does not run.\nSet, the entry names no release and no policy, so the harness has nothing to run. None otherwise."},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"The policy release the harness runs the values of: the pin's, else the default's. None when neither names one,\nand when ``error`` is set."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","source","contract_version","error","policy"],"title":"EffectiveHarness","description":"The release one harness runs on a service, and where that came from. ``repo``, ``asset`` and ``sha256`` are\nNone for ``in-tree``. agent-engine loads the wheel it baked at ``/opt/harnesses/<sha256>/``."},"HarnessKind":{"type":"string","enum":["voice","text"]},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."},"HarnessSettings":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","maxLength":64,"minLength":1,"title":"Harness"},"settings":{"additionalProperties":{"$ref":"#/components/schemas/ServedHarnessSetting"},"type":"object","maxProperties":200,"title":"Settings"}},"type":"object","required":["kind","harness"],"title":"HarnessSettings","description":"The settings one harness declares, resolved for a service by platform-api: the service's value, else the\nharness default. Only keys the harness declares are served."},"ServedHarnessSetting":{"properties":{"value":{"$ref":"#/components/schemas/HarnessSettingValue"},"source":{"$ref":"#/components/schemas/HarnessSettingSource"}},"type":"object","required":["value","source"],"title":"ServedHarnessSetting","description":"One declared setting's value for a service, and the layer it came from."},"HarnessSettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"HarnessSettingSource":{"type":"string","enum":["harness_default","service","policy"]}}}}
```

## The InternalSkillResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InternalSkillResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"system_prompt":{"type":"string","title":"System Prompt","default":""},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","default":{}},"result_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result Schema"},"model":{"type":"string","title":"Model","default":"claude-sonnet-5-5"},"max_tokens":{"type":"integer","title":"Max Tokens","default":4096},"max_result_chars":{"type":"integer","title":"Max Result Chars","default":2000},"max_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Input Tokens"},"timeout_s":{"type":"number","title":"Timeout S","default":60},"thinking_effort":{"anyOf":[{"$ref":"#/components/schemas/ThinkingEffort"},{"type":"null"}]},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Top P"},"enable_caching":{"type":"boolean","title":"Enable Caching","default":true},"enable_citations":{"type":"boolean","title":"Enable Citations","default":false},"use_structured_output":{"type":"boolean","title":"Use Structured Output","default":false},"integration_tools":{"items":{"$ref":"#/components/schemas/src__routes__internal_skills__IntegrationToolRef"},"type":"array","title":"Integration Tools","default":[]},"static_tools":{"items":{"$ref":"#/components/schemas/src__routes__internal_skills__StaticToolDef"},"type":"array","title":"Static Tools","default":[]},"enabled":{"type":"boolean","title":"Enabled","default":true},"max_agent_turns":{"type":"integer","title":"Max Agent Turns","default":20},"checkpoint_enabled":{"type":"boolean","title":"Checkpoint Enabled","default":true},"approval_required":{"type":"boolean","title":"Approval Required","default":false},"write_kind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"null"}]}},"type":"object","required":["id","workspace_id","slug","name","description"],"title":"InternalSkillResponse"},"ThinkingEffort":{"type":"string","enum":["low","medium","high"]},"src__routes__internal_skills__IntegrationToolRef":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string"},"type":"object","title":"Skill Input Bindings","default":{}}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef"},"src__routes__internal_skills__StaticToolDef":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef"},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]}}}}
```

## The InternalSkillsListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InternalSkillsListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/InternalSkillResponse"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"InternalSkillsListResponse"},"InternalSkillResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"system_prompt":{"type":"string","title":"System Prompt","default":""},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","default":{}},"result_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result Schema"},"model":{"type":"string","title":"Model","default":"claude-sonnet-5-5"},"max_tokens":{"type":"integer","title":"Max Tokens","default":4096},"max_result_chars":{"type":"integer","title":"Max Result Chars","default":2000},"max_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Input Tokens"},"timeout_s":{"type":"number","title":"Timeout S","default":60},"thinking_effort":{"anyOf":[{"$ref":"#/components/schemas/ThinkingEffort"},{"type":"null"}]},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Top P"},"enable_caching":{"type":"boolean","title":"Enable Caching","default":true},"enable_citations":{"type":"boolean","title":"Enable Citations","default":false},"use_structured_output":{"type":"boolean","title":"Use Structured Output","default":false},"integration_tools":{"items":{"$ref":"#/components/schemas/src__routes__internal_skills__IntegrationToolRef"},"type":"array","title":"Integration Tools","default":[]},"static_tools":{"items":{"$ref":"#/components/schemas/src__routes__internal_skills__StaticToolDef"},"type":"array","title":"Static Tools","default":[]},"enabled":{"type":"boolean","title":"Enabled","default":true},"max_agent_turns":{"type":"integer","title":"Max Agent Turns","default":20},"checkpoint_enabled":{"type":"boolean","title":"Checkpoint Enabled","default":true},"approval_required":{"type":"boolean","title":"Approval Required","default":false},"write_kind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"null"}]}},"type":"object","required":["id","workspace_id","slug","name","description"],"title":"InternalSkillResponse"},"ThinkingEffort":{"type":"string","enum":["low","medium","high"]},"src__routes__internal_skills__IntegrationToolRef":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string"},"type":"object","title":"Skill Input Bindings","default":{}}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef"},"src__routes__internal_skills__StaticToolDef":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef"},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]}}}}
```

## The InvokeOperationGrantRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InvokeOperationGrantRequest":{"properties":{"input":{"additionalProperties":true,"type":"object","maxProperties":32,"title":"Input"}},"additionalProperties":false,"type":"object","title":"InvokeOperationGrantRequest"}}}}
```

## The InvokeOperationGrantResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InvokeOperationGrantResponse":{"properties":{"result":{"title":"Result"},"row_count":{"type":"integer","title":"Row Count"},"duration_ms":{"type":"number","title":"Duration Ms"}},"type":"object","required":["result","row_count","duration_ms"],"title":"InvokeOperationGrantResponse"}}}}
```

## The InvokeRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InvokeRequest":{"properties":{"input":{"additionalProperties":true,"type":"object","title":"Input","description":"Caller arguments matching input_schema."}},"type":"object","title":"InvokeRequest","description":"Invoke a registered function with caller-supplied args."}}}}
```

## The InvokeResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"InvokeResponse":{"properties":{"result":{"title":"Result"},"duration_ms":{"type":"number","title":"Duration Ms","default":0},"row_count":{"type":"integer","title":"Row Count","default":0}},"type":"object","title":"InvokeResponse"}}}}
```

## The JoinCallRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"JoinCallRequest":{"properties":{"call_sid":{"type":"string","maxLength":64,"minLength":1,"title":"Call Sid"},"mode":{"type":"string","enum":["listen","takeover"],"title":"Mode","default":"takeover"}},"type":"object","required":["call_sid"],"title":"JoinCallRequest","description":"Request to join an active call as operator."}}}}
```

## The JoinCallResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"JoinCallResponse":{"properties":{"participant_call_sid":{"type":"string","title":"Participant Call Sid","description":"Twilio participant call SID"},"conference_sid":{"type":"string","title":"Conference Sid","description":"Twilio conference SID"},"mode":{"type":"string","enum":["listen","takeover"],"title":"Mode","description":"Operator mode: listen or takeover"},"operator_entity_id":{"type":"string","format":"uuid","title":"Operator Entity Id","description":"World entity ID of the operator"}},"type":"object","required":["participant_call_sid","conference_sid","mode","operator_entity_id"],"title":"JoinCallResponse","description":"Confirmation of operator joining a call's conference."}}}}
```

## The JsonValue object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]}}}}
```

## The KetamineBlockOverlapParams object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"KetamineBlockOverlapParams":{"properties":{"rule_kind":{"type":"string","const":"ketamine_block_overlap","title":"Rule Kind","default":"ketamine_block_overlap"},"window_days":{"type":"integer","maximum":365,"minimum":1,"title":"Window Days"}},"type":"object","required":["window_days"],"title":"KetamineBlockOverlapParams","description":"How many days after a ketamine session to block follow-up\nappointments (clinical safety window)."}}}}
```

## The KeyMoment object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"KeyMoment":{"properties":{"turn":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turn","description":"Turn index where the moment occurred"},"type":{"type":"string","enum":["latency_spike","silence","barge_in","loop","tool_failure","escalation","safety_flag","high_risk","elevated_risk"],"title":"Type","description":"Category of the moment"},"severity":{"type":"string","enum":["info","warning","error"],"title":"Severity","description":"Severity level","default":"warning"},"description":{"type":"string","title":"Description","description":"Human-readable description"}},"type":"object","required":["type","description"],"title":"KeyMoment","description":"Notable event during the call worth highlighting."}}}}
```

## The KeyValue object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"KeyValue":{"properties":{"key":{"type":"string","title":"Key"},"value":{"$ref":"#/components/schemas/AnyValue"}},"type":"object","required":["key","value"],"title":"KeyValue","description":"OTLP ``KeyValue`` attribute pair."},"AnyValue":{"additionalProperties":true,"type":"object"}}}}
```

## The LLMConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."}}}}
```

## The LLMExperienceControls object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."}}}}
```

## The LanguageProviderEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."}}}}
```

## The LatencySummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LatencySummary":{"properties":{"avg_engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Engine Ms","description":"Average reasoning-engine latency (ms)"},"p50_engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Engine Ms","description":"Median engine latency (ms)"},"p95_engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Engine Ms","description":"95th percentile engine latency (ms)"},"avg_audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Audio Ttfb Ms","description":"Average audio time-to-first-byte (ms)"},"p50_audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Audio Ttfb Ms","description":"Median audio TTFB (ms)"},"p95_audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Audio Ttfb Ms","description":"95th percentile audio TTFB (ms)"},"avg_nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Nav Ms","description":"Average navigation latency (ms)"},"avg_render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Render Ms","description":"Average render latency (ms)"},"turn_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turn Count","description":"Number of turns the latency averages were computed over"},"silence_ratio":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Silence Ratio","description":"Fraction of a voice call in which nobody spoke. Null when it wasn't measured."}},"type":"object","title":"LatencySummary","description":"Audio + engine latency metrics (one entry per turn averaged)."}}}}
```

## The Launch object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Launch":{"properties":{"demo_mode":{"type":"boolean","title":"Demo Mode"},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending"},"output_check_modes":{"$ref":"#/components/schemas/OutputCheckModes"},"test_callers_registered":{"type":"boolean","title":"Test Callers Registered"},"verification_callers_registered":{"type":"boolean","title":"Verification Callers Registered","description":"Every configured verification caller is a registered test caller; false when none are configured."},"human_line_configured":{"type":"boolean","title":"Human Line Configured","description":"A fallback_to or static forward_to is configured for the safe exit; pickup is not verified."},"answer_hours_configured":{"type":"boolean","title":"Answer Hours Configured","description":"The voice config sets answer_hours: outside them the agent takes no call."},"readiness_requires":{"items":{"type":"string","enum":["binding","service_active","residency","fleet","valkey","lakebase","platform_api","outside_answer_hours","openai_realtime","decisions","warehouse"]},"type":"array","title":"Readiness Requires","description":"What the live voice-call readiness check gates this service's phone calls on: the base set every call needs, outside_answer_hours when answer_hours are set, then the voice config's saved readiness_requires."},"effective_voice":{"anyOf":[{"$ref":"#/components/schemas/EffectiveVoice"},{"type":"null"}],"description":"What a gpt_realtime release version set opens its session with once each null model, voice and reasoning_effort resolves to the runtime's default. Null for any other family."}},"type":"object","required":["demo_mode","medical_emergency_ending","output_check_modes","test_callers_registered","verification_callers_registered","human_line_configured","answer_hours_configured","readiness_requires","effective_voice"],"title":"Launch"},"OutputCheckModes":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/ReadinessLabel"}},"type":"object","required":["phi_unverified"],"title":"OutputCheckModes","description":"Mode values follow the library's read model as it adds supported modes."},"ReadinessLabel":{"type":"string"},"EffectiveVoice":{"properties":{"session_provider":{"type":"string","const":"gpt_realtime","title":"Session Provider"},"model":{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"],"title":"Model"},"voice":{"type":"string","maxLength":256,"title":"Voice"},"reasoning_effort":{"type":"string","enum":["minimal","low","medium","high","xhigh"],"title":"Reasoning Effort"}},"type":"object","required":["session_provider","model","voice","reasoning_effort"],"title":"EffectiveVoice"}}}}
```

## The LeaveCallRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LeaveCallRequest":{"properties":{"call_sid":{"type":"string","maxLength":64,"minLength":1,"title":"Call Sid"}},"type":"object","required":["call_sid"],"title":"LeaveCallRequest","description":"Request to remove operator from an active call."}}}}
```

## The LeaveCallResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LeaveCallResponse":{"properties":{"success":{"type":"boolean","title":"Success"}},"type":"object","required":["success"],"title":"LeaveCallResponse"}}}}
```

## The Limits object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Limits":{"properties":{"max_size_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Size Mb"}},"type":"object","title":"Limits"}}}}
```

## The Line object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Line":{"properties":{"kind":{"$ref":"#/components/schemas/LineKind"},"label":{"$ref":"#/components/schemas/ReadinessLabel"},"use_cases":{"items":{"$ref":"#/components/schemas/Dialability"},"type":"array","title":"Use Cases"}},"type":"object","required":["kind","label","use_cases"],"title":"Line"},"LineKind":{"type":"string","enum":["forward_to","approved_destination","fallback_to","after_hours_destination","test_destination"]},"ReadinessLabel":{"type":"string"},"Dialability":{"properties":{"label":{"$ref":"#/components/schemas/ReadinessLabel"},"channel":{"anyOf":[{"$ref":"#/components/schemas/ReadinessLabel"},{"type":"null"}]},"will_dial":{"type":"boolean","title":"Will Dial","description":"Passes the use case's current dial gate when this line is selected."},"reason":{"anyOf":[{"$ref":"#/components/schemas/UseCaseDialability"},{"type":"string","const":"use_case_missing"}],"title":"Reason"}},"type":"object","required":["label","channel","will_dial","reason"],"title":"Dialability"},"UseCaseDialability":{"type":"string","enum":["own_number","listed","not_listed"]}}}}
```

## The LineKind object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LineKind":{"type":"string","enum":["forward_to","approved_destination","fallback_to","after_hours_destination","test_destination"]}}}}
```

## The ListSimulationSuiteRunSummariesResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ListSimulationSuiteRunSummariesResponse":{"properties":{"suite_runs":{"items":{"$ref":"#/components/schemas/SimulationSuiteRunSummary"},"type":"array","title":"Suite Runs","description":"One summary per requested suite run that has runs in the workspace, in request order."}},"type":"object","required":["suite_runs"],"title":"ListSimulationSuiteRunSummariesResponse"},"SimulationSuiteRunSummary":{"properties":{"suite_run_id":{"type":"string","format":"uuid","title":"Suite Run Id"},"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Run Ids"},"total_runs":{"type":"integer","title":"Total Runs"},"expected_case_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Expected Case Count"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"service_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Service Ids","description":"Agents the suite run's runs ran against, each once, in launch order."},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"result_pointer":{"additionalProperties":true,"type":"object","title":"Result Pointer"}},"type":"object","required":["suite_run_id","run_ids","total_runs","status"],"title":"SimulationSuiteRunSummary"}}}}
```

## The ListSimulationSuiteRunsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ListSimulationSuiteRunsResponse":{"properties":{"suite_id":{"type":"string","format":"uuid","title":"Suite Id"},"runs":{"items":{"$ref":"#/components/schemas/SimulationSuiteRunSummary"},"type":"array","title":"Runs"}},"type":"object","required":["suite_id","runs"],"title":"ListSimulationSuiteRunsResponse"},"SimulationSuiteRunSummary":{"properties":{"suite_run_id":{"type":"string","format":"uuid","title":"Suite Run Id"},"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Run Ids"},"total_runs":{"type":"integer","title":"Total Runs"},"expected_case_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Expected Case Count"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"service_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Service Ids","description":"Agents the suite run's runs ran against, each once, in launch order."},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"result_pointer":{"additionalProperties":true,"type":"object","title":"Result Pointer"}},"type":"object","required":["suite_run_id","run_ids","total_runs","status"],"title":"SimulationSuiteRunSummary"}}}}
```

## The ListSimulationSuitesResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ListSimulationSuitesResponse":{"properties":{"suites":{"items":{"$ref":"#/components/schemas/SimulationSuiteResponse"},"type":"array","title":"Suites"}},"type":"object","required":["suites"],"title":"ListSimulationSuitesResponse"},"SimulationSuiteResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":2000,"title":"Description","default":""},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"required_tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Required Tags"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"},"case_count":{"type":"integer","minimum":0,"title":"Case Count"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","name","case_count"],"title":"SimulationSuiteResponse","description":"HTTP response shape for first-class simulation suites."}}}}
```

## The LookupResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LookupResponse":{"properties":{"results":{"items":{"additionalProperties":true,"type":"object"},"type":"array","maxItems":200,"title":"Results"}},"type":"object","title":"LookupResponse","description":"Autocompletion results for a surface lookup field."}}}}
```

## The LoopLatencyPointItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LoopLatencyPointItem":{"properties":{"hour":{"type":"string","format":"date-time","title":"Hour","description":"UTC hour bucket (truncated to the hour)."},"count":{"type":"integer","title":"Count","description":"Sensing→action pairs whose sensing event lands in this hour."},"p50_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Seconds","description":"Median latency for this hour; null if no pairs."}},"type":"object","required":["hour","count"],"title":"LoopLatencyPointItem"}}}}
```

## The LoopLatencyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LoopLatencyResponse":{"properties":{"as_of":{"type":"string","format":"date-time","title":"As Of","description":"Server clock at query time (UTC)."},"window_hours":{"type":"integer","title":"Window Hours"},"overall_count":{"type":"integer","title":"Overall Count","description":"Total pairs across the window."},"overall_p50_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overall P50 Seconds","description":"Median latency across the whole window; null if no pairs."},"sparkline":{"items":{"$ref":"#/components/schemas/LoopLatencyPointItem"},"type":"array","maxItems":168,"title":"Sparkline"},"truncated":{"type":"boolean","title":"Truncated","description":"True when the underlying query hit the row cap; p50 is computed over the truncated sample.","default":false}},"type":"object","required":["as_of","window_hours","overall_count"],"title":"LoopLatencyResponse"},"LoopLatencyPointItem":{"properties":{"hour":{"type":"string","format":"date-time","title":"Hour","description":"UTC hour bucket (truncated to the hour)."},"count":{"type":"integer","title":"Count","description":"Sensing→action pairs whose sensing event lands in this hour."},"p50_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Seconds","description":"Median latency for this hour; null if no pairs."}},"type":"object","required":["hour","count"],"title":"LoopLatencyPointItem"}}}}
```

## The M42CatalogResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"M42CatalogResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/CatalogEntry"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"M42CatalogResponse"},"CatalogEntry":{"properties":{"name":{"type":"string","title":"Name"},"layer":{"type":"string","title":"Layer"},"description":{"type":"string","title":"Description"},"row_count":{"type":"integer","title":"Row Count"},"exists":{"type":"boolean","title":"Exists"}},"type":"object","required":["name","layer","description","row_count","exists"],"title":"CatalogEntry"}}}}
```

## The MappedRole object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MappedRole":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"}},"type":"object","required":["id","name"],"title":"MappedRole"}}}}
```

## The MaterializationRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MaterializationRow":{"properties":{"dataset":{"type":"string","title":"Dataset"},"ingestion_mode":{"type":"string","title":"Ingestion Mode"},"status":{"type":"string","enum":["materialized","not_materialized"],"title":"Status"},"row_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Row Count"},"last_materialized_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Materialized At"}},"type":"object","required":["dataset","ingestion_mode","status"],"title":"MaterializationRow","description":"Per-dataset status of the customer-data destination table\n(``customer_data_<env>.<workspace_id>.<dataset>``)."}}}}
```

## The MaterializeRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MaterializeRequest":{"properties":{"dataset":{"anyOf":[{"$ref":"#/components/schemas/_DatasetSlug"},{"type":"null"}]}},"type":"object","title":"MaterializeRequest"},"_DatasetSlug":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"}}}}
```

## The MaterializeResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MaterializeResponse":{"properties":{"run_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Run Id"}},"type":"object","title":"MaterializeResponse"}}}}
```

## The MergedEntitiesResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MergedEntitiesResponse":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"linked_entities":{"items":{"$ref":"#/components/schemas/EntityResponse"},"type":"array","title":"Linked Entities"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["entity_id","linked_entities","total"],"title":"MergedEntitiesResponse"},"EntityResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"entity_type":{"type":"string","title":"Entity Type"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"canonical_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Canonical Id"},"external_ids":{"additionalProperties":true,"type":"object","title":"External Ids"},"state":{"additionalProperties":true,"type":"object","title":"State","description":"Full JSONB state blob. Prefer typed fields below.","deprecated":true},"has_projection":{"type":"boolean","title":"Has Projection","default":false},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Display name (person, organization)"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"Primary phone number (E.164)"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Primary email address"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date","description":"Date of birth (YYYY-MM-DD)"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender","description":"Gender"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn","description":"Medical record number"},"appointment_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appointment Status","description":"Appointment status (booked, confirmed, cancelled)"},"appointment_start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Appointment Start","description":"Appointment start time (UTC)"},"appointment_end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Appointment End","description":"Appointment end time (UTC)"},"appointment_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Appointment Type","description":"Appointment/visit type"},"domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Domain","description":"Organization domain"},"industry":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Industry","description":"Organization industry"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"Twilio call SID"},"direction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Direction","description":"Call direction (inbound, outbound)"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Call duration in seconds"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Entity status"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Primary data source"},"first_seen_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"First Seen At"},"last_event_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Event At"},"event_count":{"type":"integer","title":"Event Count","default":0},"confidence":{"type":"number","title":"Confidence","default":1},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the entity was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the entity was last updated"}},"type":"object","required":["id","workspace_id","entity_type"],"title":"EntityResponse"}}}}
```

## The MeteringEmitRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MeteringEmitRequest":{"properties":{"event_type":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9._]*$","title":"Event Type"},"metering_quantity":{"type":"number","minimum":0,"title":"Metering Quantity"},"metering_source":{"type":"string","enum":["production","simulation"],"title":"Metering Source","description":"Traffic class — 'production' or 'simulation'."},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At","description":"When the event happened. Defaults to ingest time."},"metering_unit":{"anyOf":[{"type":"string","maxLength":32,"minLength":1},{"type":"null"}],"title":"Metering Unit"},"metering_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metering Metadata"},"event_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Event Id","description":"Optional deterministic row id (typically uuid5(NAMESPACE, '<stable-key>')). Re-emitting with the same value lands on the same metering event instead of double-billing. Use for backfills and retries. Default: server generates a random uuid4."}},"type":"object","required":["event_type","metering_quantity","metering_source"],"title":"MeteringEmitRequest"}}}}
```

## The MeteringEmitResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MeteringEmitResponse":{"properties":{"status":{"type":"string","const":"accepted","title":"Status","description":"Emission outcome. Always 'accepted' on 202."},"event_type":{"type":"string","maxLength":64,"minLength":1,"title":"Event Type","description":"Echo of the emitted event_type."}},"type":"object","required":["status","event_type"],"title":"MeteringEmitResponse"}}}}
```

## The MetricCatalogEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricCatalogEntry":{"properties":{"key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Key","description":"Metric key (lowercase alphanumeric + underscores)"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"metric_type":{"type":"string","enum":["numerical","categorical","boolean"],"title":"Metric Type"},"source":{"type":"string","enum":["call_intelligence","world_events","surface_events","connector_events","zerobus_events","voice_judge_results","custom"],"title":"Source"},"custom_source_key":{"anyOf":[{"type":"string","maxLength":128,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Custom Source Key"},"extraction_mode":{"type":"string","enum":["static","ai_classify","ai_extract","ai_query","sql_expr"],"title":"Extraction Mode","default":"static"},"granularity":{"type":"string","enum":["aggregate","per_entity"],"title":"Granularity","default":"aggregate"},"period_granularity":{"type":"string","enum":["hourly","daily"],"title":"Period Granularity","default":"daily"},"latency_tier":{"type":"string","enum":["streaming","near_realtime","batch"],"title":"Latency Tier","default":"batch"},"model_tier":{"type":"string","enum":["free","fast","balanced","max","custom"],"title":"Model Tier","default":"free"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"has_prompt":{"type":"boolean","title":"Has Prompt","default":false},"builtin":{"type":"boolean","title":"Builtin"}},"type":"object","required":["key","name","metric_type","source","builtin"],"title":"MetricCatalogEntry"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The MetricCatalogResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricCatalogResponse":{"properties":{"metrics":{"items":{"$ref":"#/components/schemas/MetricCatalogEntry"},"type":"array","title":"Metrics"}},"type":"object","required":["metrics"],"title":"MetricCatalogResponse"},"MetricCatalogEntry":{"properties":{"key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Key","description":"Metric key (lowercase alphanumeric + underscores)"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"metric_type":{"type":"string","enum":["numerical","categorical","boolean"],"title":"Metric Type"},"source":{"type":"string","enum":["call_intelligence","world_events","surface_events","connector_events","zerobus_events","voice_judge_results","custom"],"title":"Source"},"custom_source_key":{"anyOf":[{"type":"string","maxLength":128,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Custom Source Key"},"extraction_mode":{"type":"string","enum":["static","ai_classify","ai_extract","ai_query","sql_expr"],"title":"Extraction Mode","default":"static"},"granularity":{"type":"string","enum":["aggregate","per_entity"],"title":"Granularity","default":"aggregate"},"period_granularity":{"type":"string","enum":["hourly","daily"],"title":"Period Granularity","default":"daily"},"latency_tier":{"type":"string","enum":["streaming","near_realtime","batch"],"title":"Latency Tier","default":"batch"},"model_tier":{"type":"string","enum":["free","fast","balanced","max","custom"],"title":"Model Tier","default":"free"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"has_prompt":{"type":"boolean","title":"Has Prompt","default":false},"builtin":{"type":"boolean","title":"Builtin"}},"type":"object","required":["key","name","metric_type","source","builtin"],"title":"MetricCatalogEntry"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The MetricDefinition object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricDefinition":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Key","description":"Lowercase slug used as metric key (e.g. 'voice_quality_score')"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"metric_type":{"type":"string","enum":["numerical","categorical","boolean"],"title":"Metric Type"},"latency_tier":{"type":"string","enum":["streaming","near_realtime","batch"],"title":"Latency Tier","description":"'streaming': seconds of latency, fed continuously as events arrive. 'near_realtime': minutes of latency, refreshed on a trigger. 'batch': refreshed hourly or daily on a schedule (default, cheapest).","default":"batch"},"period_granularity":{"type":"string","enum":["hourly","daily"],"title":"Period Granularity","description":"'hourly' — one row per workspace per hour. Use for near_realtime metrics where shift-level visibility matters (voice quality, latency). 'daily' — one row per workspace per day (default, cheapest).","default":"daily"},"source":{"type":"string","enum":["call_intelligence","world_events","surface_events","connector_events","zerobus_events","voice_judge_results","custom"],"title":"Source","description":"Source key for the producer that supplies this metric. Built-ins include 'call_intelligence', 'world_events', and 'surface_events'. Use 'custom' with custom_source_key for extension producers."},"custom_source_key":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Custom Source Key","description":"Extension source key used only when source='custom'."},"event_types":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Event Types","description":"Event types to scan (e.g. 'call.outcome', 'surface.submitted'). For call_intelligence source, use pseudo-types: 'call_intelligence.row'."},"source_filter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Filter","description":"Optional SQL WHERE fragment for additional filtering (e.g. \"source = 'voice_agent'\"). Applied after event_type filter."},"extraction_mode":{"type":"string","enum":["static","ai_classify","ai_extract","ai_query","sql_expr"],"title":"Extraction Mode","description":"'static' — JSONB path extraction (fast, free). 'ai_classify' — AI classification into user-defined labels (free). 'ai_extract' — AI field extraction from text (free). 'ai_query' — LLM-powered extraction with custom prompt (uses model_tier). 'sql_expr' — Raw SQL expression for computed metrics.","default":"static"},"extract_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extract Path","description":"JSON path for static extraction (e.g. `$.quality_score`, `$.risk_level`). For `call_intelligence` and `world_events`, single-segment paths resolve to typed columns when available and fall back to JSONB extraction otherwise. Used when `extraction_mode='static'`."},"ai_labels":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":500},{"type":"null"}],"title":"Ai Labels","description":"Labels for ai_classify, the allowed answers of a categorical ai_query metric, or field names for ai_extract. Required when extraction_mode='ai_classify' or 'ai_extract'. Examples: ['positive', 'negative', 'neutral'] or ['diagnosis', 'medication']."},"ai_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ai Schema","description":"Extraction schema for ai_extract. Required when extraction_mode='ai_extract'."},"ai_query_endpoint":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Ai Query Endpoint","description":"Model serving endpoint for ai_query. Optional — if omitted, platform resolves from model_tier automatically. Override for custom endpoints."},"ai_query_prompt":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Ai Query Prompt","description":"Prompt template for ai_query. Use {data} placeholder for event data. Example: 'Classify this call transcript into one of: {labels}. Transcript: {data}'. Budgeted at 8KB to hold the full rubric + output spec for standard quality judges (longest authored rubric — conversational_naturalness — is ~5KB)."},"sql_expression":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Sql Expression","description":"Raw SQL expression evaluated in pipeline context. Has access to all columns in the source table. Example: 'CASE WHEN duration_seconds > 120 THEN 1.0 ELSE 0.0 END'. Required when extraction_mode='sql_expr'."},"aggregation":{"type":"string","enum":["count","sum","avg","min","max","count_distinct","ratio","rate"],"title":"Aggregation","description":"How to aggregate extracted values per workspace per period. 'ratio' requires ratio_numerator_event and ratio_denominator_event. 'rate' computes count(true) / count(all) for boolean metrics.","default":"count"},"ratio_numerator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Numerator Event","description":"Event type for numerator when aggregation='ratio'."},"ratio_denominator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Denominator Event","description":"Event type for denominator when aggregation='ratio'."},"valid_range_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Min","description":"Minimum valid value for numerical metrics. Pipeline drops values outside range."},"valid_range_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Max","description":"Maximum valid value for numerical metrics."},"freshness_sla_minutes":{"type":"integer","maximum":1440,"minimum":5,"title":"Freshness Sla Minutes","description":"Max acceptable staleness in minutes before alerting. Default: 60 (1 hour).","default":60},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit","description":"Display unit (e.g. 'score', 'minutes', '%', 'count')."},"categories":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":100},{"type":"null"}],"title":"Categories","description":"Allowed values for categorical metrics. Pipeline drops values not in this list when set. An ai_query metric reads ai_labels instead, and falls back to categories only when ai_labels is empty."},"model_tier":{"type":"string","enum":["free","fast","balanced","max","custom"],"title":"Model Tier","description":"AI model tier for extraction quality/cost tradeoff. 'free' — platform managed models (ai_classify, ai_extract). 'fast' — optimized for simple classification, low latency. 'balanced' — quality scoring, moderate reasoning. 'max' — complex analysis, multi-step reasoning. 'custom' — use ai_query_endpoint directly. When extraction_mode='ai_query' and ai_query_endpoint is not set, platform resolves model_tier to the optimal model automatically.","default":"free"},"channel_scope":{"type":"string","enum":["all","voice","text","surface","inbound","outbound"],"title":"Channel Scope","description":"Business-logic channel filter. 'voice' — voice calls only. 'text' — SMS/text sessions. 'surface' — form submissions. 'inbound'/'outbound' — by direction. 'all' — no channel filter (default). Pipeline translates to appropriate source + event_type filters.","default":"all"},"applies_to_product_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Applies To Product Types","description":"Product types this metric applies to (matches service tags, e.g. 'scheduling', 'outbound', 'coaching', 'intake', 'triage', 'support'). When set, the metric only computes for calls belonging to services whose config.tags include one of these keys. When None (default), the metric applies to every service regardless of product type."},"prompt":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Prompt","description":"Rubric prompt for LLM judge evaluation with {$.path} context variables. Each {$.path} reference is extracted from the entity's projected state and substituted before sending to ai_query. The prompt is both the evaluation criteria and the context specification."},"granularity":{"type":"string","enum":["aggregate","per_entity"],"title":"Granularity","description":"'aggregate' groups by (workspace, period) — one value per time bucket. 'per_entity' keeps entity_id — one value per entity (call, encounter). Judge metrics are typically per_entity. Computed metrics are typically aggregate.","default":"aggregate"},"tags":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":20},{"type":"null"}],"title":"Tags","description":"Up to 20 slugs (lowercase letters, digits, '-' and '_', at most 64 characters each)."},"notes":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Notes","description":"Free-text notes about the definition."},"active":{"type":"boolean","title":"Active","default":true},"builtin":{"type":"boolean","title":"Builtin","description":"True for platform-provided metrics (read-only key).","default":false}},"type":"object","required":["key","name","metric_type","source","event_types"],"title":"MetricDefinition","description":"A metric the platform computes for a workspace: what to extract from events, and how to aggregate it.\n\nBuilt-in metrics ship with every workspace. Custom metrics are defined per workspace through the settings\nAPI, and they extract with AI functions or with static paths into the event data."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The MetricDefinitionItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricDefinitionItem":{"properties":{"definition":{"$ref":"#/components/schemas/MetricDefinition"},"revision":{"type":"integer","title":"Revision","description":"The latest revision of the key; 0 when it has none."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the latest revision was made; null when the key has none."},"transform_kind":{"type":"string","enum":["scalar","non_scalar"],"title":"Transform Kind","description":"Read-only: ``scalar`` for a per-entity metric, ``non_scalar`` for an aggregate one.","readOnly":true}},"type":"object","required":["definition","revision","updated_at","transform_kind"],"title":"MetricDefinitionItem"},"MetricDefinition":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Key","description":"Lowercase slug used as metric key (e.g. 'voice_quality_score')"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"metric_type":{"type":"string","enum":["numerical","categorical","boolean"],"title":"Metric Type"},"latency_tier":{"type":"string","enum":["streaming","near_realtime","batch"],"title":"Latency Tier","description":"'streaming': seconds of latency, fed continuously as events arrive. 'near_realtime': minutes of latency, refreshed on a trigger. 'batch': refreshed hourly or daily on a schedule (default, cheapest).","default":"batch"},"period_granularity":{"type":"string","enum":["hourly","daily"],"title":"Period Granularity","description":"'hourly' — one row per workspace per hour. Use for near_realtime metrics where shift-level visibility matters (voice quality, latency). 'daily' — one row per workspace per day (default, cheapest).","default":"daily"},"source":{"type":"string","enum":["call_intelligence","world_events","surface_events","connector_events","zerobus_events","voice_judge_results","custom"],"title":"Source","description":"Source key for the producer that supplies this metric. Built-ins include 'call_intelligence', 'world_events', and 'surface_events'. Use 'custom' with custom_source_key for extension producers."},"custom_source_key":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Custom Source Key","description":"Extension source key used only when source='custom'."},"event_types":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Event Types","description":"Event types to scan (e.g. 'call.outcome', 'surface.submitted'). For call_intelligence source, use pseudo-types: 'call_intelligence.row'."},"source_filter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Filter","description":"Optional SQL WHERE fragment for additional filtering (e.g. \"source = 'voice_agent'\"). Applied after event_type filter."},"extraction_mode":{"type":"string","enum":["static","ai_classify","ai_extract","ai_query","sql_expr"],"title":"Extraction Mode","description":"'static' — JSONB path extraction (fast, free). 'ai_classify' — AI classification into user-defined labels (free). 'ai_extract' — AI field extraction from text (free). 'ai_query' — LLM-powered extraction with custom prompt (uses model_tier). 'sql_expr' — Raw SQL expression for computed metrics.","default":"static"},"extract_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extract Path","description":"JSON path for static extraction (e.g. `$.quality_score`, `$.risk_level`). For `call_intelligence` and `world_events`, single-segment paths resolve to typed columns when available and fall back to JSONB extraction otherwise. Used when `extraction_mode='static'`."},"ai_labels":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":500},{"type":"null"}],"title":"Ai Labels","description":"Labels for ai_classify, the allowed answers of a categorical ai_query metric, or field names for ai_extract. Required when extraction_mode='ai_classify' or 'ai_extract'. Examples: ['positive', 'negative', 'neutral'] or ['diagnosis', 'medication']."},"ai_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ai Schema","description":"Extraction schema for ai_extract. Required when extraction_mode='ai_extract'."},"ai_query_endpoint":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Ai Query Endpoint","description":"Model serving endpoint for ai_query. Optional — if omitted, platform resolves from model_tier automatically. Override for custom endpoints."},"ai_query_prompt":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Ai Query Prompt","description":"Prompt template for ai_query. Use {data} placeholder for event data. Example: 'Classify this call transcript into one of: {labels}. Transcript: {data}'. Budgeted at 8KB to hold the full rubric + output spec for standard quality judges (longest authored rubric — conversational_naturalness — is ~5KB)."},"sql_expression":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Sql Expression","description":"Raw SQL expression evaluated in pipeline context. Has access to all columns in the source table. Example: 'CASE WHEN duration_seconds > 120 THEN 1.0 ELSE 0.0 END'. Required when extraction_mode='sql_expr'."},"aggregation":{"type":"string","enum":["count","sum","avg","min","max","count_distinct","ratio","rate"],"title":"Aggregation","description":"How to aggregate extracted values per workspace per period. 'ratio' requires ratio_numerator_event and ratio_denominator_event. 'rate' computes count(true) / count(all) for boolean metrics.","default":"count"},"ratio_numerator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Numerator Event","description":"Event type for numerator when aggregation='ratio'."},"ratio_denominator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Denominator Event","description":"Event type for denominator when aggregation='ratio'."},"valid_range_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Min","description":"Minimum valid value for numerical metrics. Pipeline drops values outside range."},"valid_range_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Max","description":"Maximum valid value for numerical metrics."},"freshness_sla_minutes":{"type":"integer","maximum":1440,"minimum":5,"title":"Freshness Sla Minutes","description":"Max acceptable staleness in minutes before alerting. Default: 60 (1 hour).","default":60},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit","description":"Display unit (e.g. 'score', 'minutes', '%', 'count')."},"categories":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":100},{"type":"null"}],"title":"Categories","description":"Allowed values for categorical metrics. Pipeline drops values not in this list when set. An ai_query metric reads ai_labels instead, and falls back to categories only when ai_labels is empty."},"model_tier":{"type":"string","enum":["free","fast","balanced","max","custom"],"title":"Model Tier","description":"AI model tier for extraction quality/cost tradeoff. 'free' — platform managed models (ai_classify, ai_extract). 'fast' — optimized for simple classification, low latency. 'balanced' — quality scoring, moderate reasoning. 'max' — complex analysis, multi-step reasoning. 'custom' — use ai_query_endpoint directly. When extraction_mode='ai_query' and ai_query_endpoint is not set, platform resolves model_tier to the optimal model automatically.","default":"free"},"channel_scope":{"type":"string","enum":["all","voice","text","surface","inbound","outbound"],"title":"Channel Scope","description":"Business-logic channel filter. 'voice' — voice calls only. 'text' — SMS/text sessions. 'surface' — form submissions. 'inbound'/'outbound' — by direction. 'all' — no channel filter (default). Pipeline translates to appropriate source + event_type filters.","default":"all"},"applies_to_product_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Applies To Product Types","description":"Product types this metric applies to (matches service tags, e.g. 'scheduling', 'outbound', 'coaching', 'intake', 'triage', 'support'). When set, the metric only computes for calls belonging to services whose config.tags include one of these keys. When None (default), the metric applies to every service regardless of product type."},"prompt":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Prompt","description":"Rubric prompt for LLM judge evaluation with {$.path} context variables. Each {$.path} reference is extracted from the entity's projected state and substituted before sending to ai_query. The prompt is both the evaluation criteria and the context specification."},"granularity":{"type":"string","enum":["aggregate","per_entity"],"title":"Granularity","description":"'aggregate' groups by (workspace, period) — one value per time bucket. 'per_entity' keeps entity_id — one value per entity (call, encounter). Judge metrics are typically per_entity. Computed metrics are typically aggregate.","default":"aggregate"},"tags":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":20},{"type":"null"}],"title":"Tags","description":"Up to 20 slugs (lowercase letters, digits, '-' and '_', at most 64 characters each)."},"notes":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Notes","description":"Free-text notes about the definition."},"active":{"type":"boolean","title":"Active","default":true},"builtin":{"type":"boolean","title":"Builtin","description":"True for platform-provided metrics (read-only key).","default":false}},"type":"object","required":["key","name","metric_type","source","event_types"],"title":"MetricDefinition","description":"A metric the platform computes for a workspace: what to extract from events, and how to aggregate it.\n\nBuilt-in metrics ship with every workspace. Custom metrics are defined per workspace through the settings\nAPI, and they extract with AI functions or with static paths into the event data."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The MetricDefinitionListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricDefinitionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MetricDefinitionItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"MetricDefinitionListResponse"},"MetricDefinitionItem":{"properties":{"definition":{"$ref":"#/components/schemas/MetricDefinition"},"revision":{"type":"integer","title":"Revision","description":"The latest revision of the key; 0 when it has none."},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the latest revision was made; null when the key has none."},"transform_kind":{"type":"string","enum":["scalar","non_scalar"],"title":"Transform Kind","description":"Read-only: ``scalar`` for a per-entity metric, ``non_scalar`` for an aggregate one.","readOnly":true}},"type":"object","required":["definition","revision","updated_at","transform_kind"],"title":"MetricDefinitionItem"},"MetricDefinition":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Key","description":"Lowercase slug used as metric key (e.g. 'voice_quality_score')"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"metric_type":{"type":"string","enum":["numerical","categorical","boolean"],"title":"Metric Type"},"latency_tier":{"type":"string","enum":["streaming","near_realtime","batch"],"title":"Latency Tier","description":"'streaming': seconds of latency, fed continuously as events arrive. 'near_realtime': minutes of latency, refreshed on a trigger. 'batch': refreshed hourly or daily on a schedule (default, cheapest).","default":"batch"},"period_granularity":{"type":"string","enum":["hourly","daily"],"title":"Period Granularity","description":"'hourly' — one row per workspace per hour. Use for near_realtime metrics where shift-level visibility matters (voice quality, latency). 'daily' — one row per workspace per day (default, cheapest).","default":"daily"},"source":{"type":"string","enum":["call_intelligence","world_events","surface_events","connector_events","zerobus_events","voice_judge_results","custom"],"title":"Source","description":"Source key for the producer that supplies this metric. Built-ins include 'call_intelligence', 'world_events', and 'surface_events'. Use 'custom' with custom_source_key for extension producers."},"custom_source_key":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Custom Source Key","description":"Extension source key used only when source='custom'."},"event_types":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Event Types","description":"Event types to scan (e.g. 'call.outcome', 'surface.submitted'). For call_intelligence source, use pseudo-types: 'call_intelligence.row'."},"source_filter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Filter","description":"Optional SQL WHERE fragment for additional filtering (e.g. \"source = 'voice_agent'\"). Applied after event_type filter."},"extraction_mode":{"type":"string","enum":["static","ai_classify","ai_extract","ai_query","sql_expr"],"title":"Extraction Mode","description":"'static' — JSONB path extraction (fast, free). 'ai_classify' — AI classification into user-defined labels (free). 'ai_extract' — AI field extraction from text (free). 'ai_query' — LLM-powered extraction with custom prompt (uses model_tier). 'sql_expr' — Raw SQL expression for computed metrics.","default":"static"},"extract_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extract Path","description":"JSON path for static extraction (e.g. `$.quality_score`, `$.risk_level`). For `call_intelligence` and `world_events`, single-segment paths resolve to typed columns when available and fall back to JSONB extraction otherwise. Used when `extraction_mode='static'`."},"ai_labels":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":500},{"type":"null"}],"title":"Ai Labels","description":"Labels for ai_classify, the allowed answers of a categorical ai_query metric, or field names for ai_extract. Required when extraction_mode='ai_classify' or 'ai_extract'. Examples: ['positive', 'negative', 'neutral'] or ['diagnosis', 'medication']."},"ai_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ai Schema","description":"Extraction schema for ai_extract. Required when extraction_mode='ai_extract'."},"ai_query_endpoint":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Ai Query Endpoint","description":"Model serving endpoint for ai_query. Optional — if omitted, platform resolves from model_tier automatically. Override for custom endpoints."},"ai_query_prompt":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Ai Query Prompt","description":"Prompt template for ai_query. Use {data} placeholder for event data. Example: 'Classify this call transcript into one of: {labels}. Transcript: {data}'. Budgeted at 8KB to hold the full rubric + output spec for standard quality judges (longest authored rubric — conversational_naturalness — is ~5KB)."},"sql_expression":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Sql Expression","description":"Raw SQL expression evaluated in pipeline context. Has access to all columns in the source table. Example: 'CASE WHEN duration_seconds > 120 THEN 1.0 ELSE 0.0 END'. Required when extraction_mode='sql_expr'."},"aggregation":{"type":"string","enum":["count","sum","avg","min","max","count_distinct","ratio","rate"],"title":"Aggregation","description":"How to aggregate extracted values per workspace per period. 'ratio' requires ratio_numerator_event and ratio_denominator_event. 'rate' computes count(true) / count(all) for boolean metrics.","default":"count"},"ratio_numerator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Numerator Event","description":"Event type for numerator when aggregation='ratio'."},"ratio_denominator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Denominator Event","description":"Event type for denominator when aggregation='ratio'."},"valid_range_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Min","description":"Minimum valid value for numerical metrics. Pipeline drops values outside range."},"valid_range_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Max","description":"Maximum valid value for numerical metrics."},"freshness_sla_minutes":{"type":"integer","maximum":1440,"minimum":5,"title":"Freshness Sla Minutes","description":"Max acceptable staleness in minutes before alerting. Default: 60 (1 hour).","default":60},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit","description":"Display unit (e.g. 'score', 'minutes', '%', 'count')."},"categories":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":100},{"type":"null"}],"title":"Categories","description":"Allowed values for categorical metrics. Pipeline drops values not in this list when set. An ai_query metric reads ai_labels instead, and falls back to categories only when ai_labels is empty."},"model_tier":{"type":"string","enum":["free","fast","balanced","max","custom"],"title":"Model Tier","description":"AI model tier for extraction quality/cost tradeoff. 'free' — platform managed models (ai_classify, ai_extract). 'fast' — optimized for simple classification, low latency. 'balanced' — quality scoring, moderate reasoning. 'max' — complex analysis, multi-step reasoning. 'custom' — use ai_query_endpoint directly. When extraction_mode='ai_query' and ai_query_endpoint is not set, platform resolves model_tier to the optimal model automatically.","default":"free"},"channel_scope":{"type":"string","enum":["all","voice","text","surface","inbound","outbound"],"title":"Channel Scope","description":"Business-logic channel filter. 'voice' — voice calls only. 'text' — SMS/text sessions. 'surface' — form submissions. 'inbound'/'outbound' — by direction. 'all' — no channel filter (default). Pipeline translates to appropriate source + event_type filters.","default":"all"},"applies_to_product_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Applies To Product Types","description":"Product types this metric applies to (matches service tags, e.g. 'scheduling', 'outbound', 'coaching', 'intake', 'triage', 'support'). When set, the metric only computes for calls belonging to services whose config.tags include one of these keys. When None (default), the metric applies to every service regardless of product type."},"prompt":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Prompt","description":"Rubric prompt for LLM judge evaluation with {$.path} context variables. Each {$.path} reference is extracted from the entity's projected state and substituted before sending to ai_query. The prompt is both the evaluation criteria and the context specification."},"granularity":{"type":"string","enum":["aggregate","per_entity"],"title":"Granularity","description":"'aggregate' groups by (workspace, period) — one value per time bucket. 'per_entity' keeps entity_id — one value per entity (call, encounter). Judge metrics are typically per_entity. Computed metrics are typically aggregate.","default":"aggregate"},"tags":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":20},{"type":"null"}],"title":"Tags","description":"Up to 20 slugs (lowercase letters, digits, '-' and '_', at most 64 characters each)."},"notes":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Notes","description":"Free-text notes about the definition."},"active":{"type":"boolean","title":"Active","default":true},"builtin":{"type":"boolean","title":"Builtin","description":"True for platform-provided metrics (read-only key).","default":false}},"type":"object","required":["key","name","metric_type","source","event_types"],"title":"MetricDefinition","description":"A metric the platform computes for a workspace: what to extract from events, and how to aggregate it.\n\nBuilt-in metrics ship with every workspace. Custom metrics are defined per workspace through the settings\nAPI, and they extract with AI functions or with static paths into the event data."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The MetricDefinitionRevision object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricDefinitionRevision":{"properties":{"revision":{"type":"integer","title":"Revision"},"definition_version":{"type":"string","title":"Definition Version"},"change":{"type":"string","enum":["created","updated","deleted"],"title":"Change"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"created_by_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Credential Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["revision","definition_version","change","note","created_by_credential_id","created_at"],"title":"MetricDefinitionRevision"}}}}
```

## The MetricDefinitionRevisionDetail object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricDefinitionRevisionDetail":{"properties":{"revision":{"type":"integer","title":"Revision"},"definition_version":{"type":"string","title":"Definition Version"},"change":{"type":"string","enum":["created","updated","deleted"],"title":"Change"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"created_by_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Credential Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"definition":{"additionalProperties":true,"type":"object","title":"Definition"}},"type":"object","required":["revision","definition_version","change","note","created_by_credential_id","created_at","definition"],"title":"MetricDefinitionRevisionDetail"}}}}
```

## The MetricDefinitionRevisionListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricDefinitionRevisionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MetricDefinitionRevision"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"MetricDefinitionRevisionListResponse"},"MetricDefinitionRevision":{"properties":{"revision":{"type":"integer","title":"Revision"},"definition_version":{"type":"string","title":"Definition Version"},"change":{"type":"string","enum":["created","updated","deleted"],"title":"Change"},"note":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Note"},"created_by_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By Credential Id"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["revision","definition_version","change","note","created_by_credential_id","created_at"],"title":"MetricDefinitionRevision"}}}}
```

## The MetricListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricListResponse":{"properties":{"metrics":{"items":{"oneOf":[{"$ref":"#/components/schemas/NumericalMetricValueResponse"},{"$ref":"#/components/schemas/CategoricalMetricValueResponse"},{"$ref":"#/components/schemas/BooleanMetricValueResponse"}],"discriminator":{"propertyName":"metric_type","mapping":{"boolean":"#/components/schemas/BooleanMetricValueResponse","categorical":"#/components/schemas/CategoricalMetricValueResponse","numerical":"#/components/schemas/NumericalMetricValueResponse"}}},"type":"array","title":"Metrics"}},"type":"object","required":["metrics"],"title":"MetricListResponse"},"NumericalMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"numerical","title":"Metric Type"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"NumericalMetricValueResponse"},"CategoricalMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"categorical","title":"Metric Type"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value","description":"The category this row counts. A list-metrics latest row gives its period's most frequent category."},"distribution":{"items":{"$ref":"#/components/schemas/CategoryCount"},"type":"array","title":"Distribution","description":"Events per category in this row's period, most frequent first. A list-metrics latest row\nlists every category its period saw; any other row lists its own category.","default":[]}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"CategoricalMetricValueResponse"},"CategoryCount":{"properties":{"value":{"type":"string","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["value","count"],"title":"CategoryCount"},"BooleanMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"boolean","title":"Metric Type"},"value":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Value","description":"The value this row counts. A list-metrics latest row gives its period's more frequent value."},"distribution":{"items":{"$ref":"#/components/schemas/BooleanCount"},"type":"array","title":"Distribution","description":"Events per value in this row's period, most frequent first. A list-metrics latest row\nlists both values its period saw; any other row lists its own value.","default":[]}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"BooleanMetricValueResponse"},"BooleanCount":{"properties":{"value":{"type":"boolean","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["value","count"],"title":"BooleanCount"}}}}
```

## The MetricProjectionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricProjectionResponse":{"properties":{"status":{"type":"string","const":"projected","title":"Status"},"accepted":{"type":"integer","title":"Accepted"},"skipped_duplicates":{"type":"integer","title":"Skipped Duplicates"},"queued_jobs":{"type":"integer","title":"Queued Jobs","default":0,"deprecated":true}},"type":"object","required":["status","accepted","skipped_duplicates"],"title":"MetricProjectionResponse"}}}}
```

## The MetricSettingsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricSettingsRequest":{"properties":{"definitions":{"anyOf":[{"items":{"$ref":"#/components/schemas/MetricDefinition"},"type":"array"},{"type":"null"}],"title":"Definitions"}},"type":"object","title":"MetricSettingsRequest","description":"Partial update — only provided fields are changed.\n\nThe definitions list is replaced entirely when provided. A ``null`` resets\nit to the built-in defaults: every custom definition and every change to a\nbuilt-in is dropped.\nBuilt-in metrics can be deactivated (active=false) or have their\nfreshness_sla_minutes changed, but their key cannot be reused\nfor custom metrics."},"MetricDefinition":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Key","description":"Lowercase slug used as metric key (e.g. 'voice_quality_score')"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"metric_type":{"type":"string","enum":["numerical","categorical","boolean"],"title":"Metric Type"},"latency_tier":{"type":"string","enum":["streaming","near_realtime","batch"],"title":"Latency Tier","description":"'streaming': seconds of latency, fed continuously as events arrive. 'near_realtime': minutes of latency, refreshed on a trigger. 'batch': refreshed hourly or daily on a schedule (default, cheapest).","default":"batch"},"period_granularity":{"type":"string","enum":["hourly","daily"],"title":"Period Granularity","description":"'hourly' — one row per workspace per hour. Use for near_realtime metrics where shift-level visibility matters (voice quality, latency). 'daily' — one row per workspace per day (default, cheapest).","default":"daily"},"source":{"type":"string","enum":["call_intelligence","world_events","surface_events","connector_events","zerobus_events","voice_judge_results","custom"],"title":"Source","description":"Source key for the producer that supplies this metric. Built-ins include 'call_intelligence', 'world_events', and 'surface_events'. Use 'custom' with custom_source_key for extension producers."},"custom_source_key":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Custom Source Key","description":"Extension source key used only when source='custom'."},"event_types":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Event Types","description":"Event types to scan (e.g. 'call.outcome', 'surface.submitted'). For call_intelligence source, use pseudo-types: 'call_intelligence.row'."},"source_filter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Filter","description":"Optional SQL WHERE fragment for additional filtering (e.g. \"source = 'voice_agent'\"). Applied after event_type filter."},"extraction_mode":{"type":"string","enum":["static","ai_classify","ai_extract","ai_query","sql_expr"],"title":"Extraction Mode","description":"'static' — JSONB path extraction (fast, free). 'ai_classify' — AI classification into user-defined labels (free). 'ai_extract' — AI field extraction from text (free). 'ai_query' — LLM-powered extraction with custom prompt (uses model_tier). 'sql_expr' — Raw SQL expression for computed metrics.","default":"static"},"extract_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extract Path","description":"JSON path for static extraction (e.g. `$.quality_score`, `$.risk_level`). For `call_intelligence` and `world_events`, single-segment paths resolve to typed columns when available and fall back to JSONB extraction otherwise. Used when `extraction_mode='static'`."},"ai_labels":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":500},{"type":"null"}],"title":"Ai Labels","description":"Labels for ai_classify, the allowed answers of a categorical ai_query metric, or field names for ai_extract. Required when extraction_mode='ai_classify' or 'ai_extract'. Examples: ['positive', 'negative', 'neutral'] or ['diagnosis', 'medication']."},"ai_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ai Schema","description":"Extraction schema for ai_extract. Required when extraction_mode='ai_extract'."},"ai_query_endpoint":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Ai Query Endpoint","description":"Model serving endpoint for ai_query. Optional — if omitted, platform resolves from model_tier automatically. Override for custom endpoints."},"ai_query_prompt":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Ai Query Prompt","description":"Prompt template for ai_query. Use {data} placeholder for event data. Example: 'Classify this call transcript into one of: {labels}. Transcript: {data}'. Budgeted at 8KB to hold the full rubric + output spec for standard quality judges (longest authored rubric — conversational_naturalness — is ~5KB)."},"sql_expression":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Sql Expression","description":"Raw SQL expression evaluated in pipeline context. Has access to all columns in the source table. Example: 'CASE WHEN duration_seconds > 120 THEN 1.0 ELSE 0.0 END'. Required when extraction_mode='sql_expr'."},"aggregation":{"type":"string","enum":["count","sum","avg","min","max","count_distinct","ratio","rate"],"title":"Aggregation","description":"How to aggregate extracted values per workspace per period. 'ratio' requires ratio_numerator_event and ratio_denominator_event. 'rate' computes count(true) / count(all) for boolean metrics.","default":"count"},"ratio_numerator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Numerator Event","description":"Event type for numerator when aggregation='ratio'."},"ratio_denominator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Denominator Event","description":"Event type for denominator when aggregation='ratio'."},"valid_range_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Min","description":"Minimum valid value for numerical metrics. Pipeline drops values outside range."},"valid_range_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Max","description":"Maximum valid value for numerical metrics."},"freshness_sla_minutes":{"type":"integer","maximum":1440,"minimum":5,"title":"Freshness Sla Minutes","description":"Max acceptable staleness in minutes before alerting. Default: 60 (1 hour).","default":60},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit","description":"Display unit (e.g. 'score', 'minutes', '%', 'count')."},"categories":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":100},{"type":"null"}],"title":"Categories","description":"Allowed values for categorical metrics. Pipeline drops values not in this list when set. An ai_query metric reads ai_labels instead, and falls back to categories only when ai_labels is empty."},"model_tier":{"type":"string","enum":["free","fast","balanced","max","custom"],"title":"Model Tier","description":"AI model tier for extraction quality/cost tradeoff. 'free' — platform managed models (ai_classify, ai_extract). 'fast' — optimized for simple classification, low latency. 'balanced' — quality scoring, moderate reasoning. 'max' — complex analysis, multi-step reasoning. 'custom' — use ai_query_endpoint directly. When extraction_mode='ai_query' and ai_query_endpoint is not set, platform resolves model_tier to the optimal model automatically.","default":"free"},"channel_scope":{"type":"string","enum":["all","voice","text","surface","inbound","outbound"],"title":"Channel Scope","description":"Business-logic channel filter. 'voice' — voice calls only. 'text' — SMS/text sessions. 'surface' — form submissions. 'inbound'/'outbound' — by direction. 'all' — no channel filter (default). Pipeline translates to appropriate source + event_type filters.","default":"all"},"applies_to_product_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Applies To Product Types","description":"Product types this metric applies to (matches service tags, e.g. 'scheduling', 'outbound', 'coaching', 'intake', 'triage', 'support'). When set, the metric only computes for calls belonging to services whose config.tags include one of these keys. When None (default), the metric applies to every service regardless of product type."},"prompt":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Prompt","description":"Rubric prompt for LLM judge evaluation with {$.path} context variables. Each {$.path} reference is extracted from the entity's projected state and substituted before sending to ai_query. The prompt is both the evaluation criteria and the context specification."},"granularity":{"type":"string","enum":["aggregate","per_entity"],"title":"Granularity","description":"'aggregate' groups by (workspace, period) — one value per time bucket. 'per_entity' keeps entity_id — one value per entity (call, encounter). Judge metrics are typically per_entity. Computed metrics are typically aggregate.","default":"aggregate"},"tags":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":20},{"type":"null"}],"title":"Tags","description":"Up to 20 slugs (lowercase letters, digits, '-' and '_', at most 64 characters each)."},"notes":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Notes","description":"Free-text notes about the definition."},"active":{"type":"boolean","title":"Active","default":true},"builtin":{"type":"boolean","title":"Builtin","description":"True for platform-provided metrics (read-only key).","default":false}},"type":"object","required":["key","name","metric_type","source","event_types"],"title":"MetricDefinition","description":"A metric the platform computes for a workspace: what to extract from events, and how to aggregate it.\n\nBuilt-in metrics ship with every workspace. Custom metrics are defined per workspace through the settings\nAPI, and they extract with AI functions or with static paths into the event data."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The MetricSettingsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricSettingsResponse":{"properties":{"definitions":{"items":{"$ref":"#/components/schemas/MetricDefinition"},"type":"array","title":"Definitions"}},"type":"object","required":["definitions"],"title":"MetricSettingsResponse"},"MetricDefinition":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Key","description":"Lowercase slug used as metric key (e.g. 'voice_quality_score')"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"metric_type":{"type":"string","enum":["numerical","categorical","boolean"],"title":"Metric Type"},"latency_tier":{"type":"string","enum":["streaming","near_realtime","batch"],"title":"Latency Tier","description":"'streaming': seconds of latency, fed continuously as events arrive. 'near_realtime': minutes of latency, refreshed on a trigger. 'batch': refreshed hourly or daily on a schedule (default, cheapest).","default":"batch"},"period_granularity":{"type":"string","enum":["hourly","daily"],"title":"Period Granularity","description":"'hourly' — one row per workspace per hour. Use for near_realtime metrics where shift-level visibility matters (voice quality, latency). 'daily' — one row per workspace per day (default, cheapest).","default":"daily"},"source":{"type":"string","enum":["call_intelligence","world_events","surface_events","connector_events","zerobus_events","voice_judge_results","custom"],"title":"Source","description":"Source key for the producer that supplies this metric. Built-ins include 'call_intelligence', 'world_events', and 'surface_events'. Use 'custom' with custom_source_key for extension producers."},"custom_source_key":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Custom Source Key","description":"Extension source key used only when source='custom'."},"event_types":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Event Types","description":"Event types to scan (e.g. 'call.outcome', 'surface.submitted'). For call_intelligence source, use pseudo-types: 'call_intelligence.row'."},"source_filter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Filter","description":"Optional SQL WHERE fragment for additional filtering (e.g. \"source = 'voice_agent'\"). Applied after event_type filter."},"extraction_mode":{"type":"string","enum":["static","ai_classify","ai_extract","ai_query","sql_expr"],"title":"Extraction Mode","description":"'static' — JSONB path extraction (fast, free). 'ai_classify' — AI classification into user-defined labels (free). 'ai_extract' — AI field extraction from text (free). 'ai_query' — LLM-powered extraction with custom prompt (uses model_tier). 'sql_expr' — Raw SQL expression for computed metrics.","default":"static"},"extract_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extract Path","description":"JSON path for static extraction (e.g. `$.quality_score`, `$.risk_level`). For `call_intelligence` and `world_events`, single-segment paths resolve to typed columns when available and fall back to JSONB extraction otherwise. Used when `extraction_mode='static'`."},"ai_labels":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":500},{"type":"null"}],"title":"Ai Labels","description":"Labels for ai_classify, the allowed answers of a categorical ai_query metric, or field names for ai_extract. Required when extraction_mode='ai_classify' or 'ai_extract'. Examples: ['positive', 'negative', 'neutral'] or ['diagnosis', 'medication']."},"ai_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ai Schema","description":"Extraction schema for ai_extract. Required when extraction_mode='ai_extract'."},"ai_query_endpoint":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Ai Query Endpoint","description":"Model serving endpoint for ai_query. Optional — if omitted, platform resolves from model_tier automatically. Override for custom endpoints."},"ai_query_prompt":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Ai Query Prompt","description":"Prompt template for ai_query. Use {data} placeholder for event data. Example: 'Classify this call transcript into one of: {labels}. Transcript: {data}'. Budgeted at 8KB to hold the full rubric + output spec for standard quality judges (longest authored rubric — conversational_naturalness — is ~5KB)."},"sql_expression":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Sql Expression","description":"Raw SQL expression evaluated in pipeline context. Has access to all columns in the source table. Example: 'CASE WHEN duration_seconds > 120 THEN 1.0 ELSE 0.0 END'. Required when extraction_mode='sql_expr'."},"aggregation":{"type":"string","enum":["count","sum","avg","min","max","count_distinct","ratio","rate"],"title":"Aggregation","description":"How to aggregate extracted values per workspace per period. 'ratio' requires ratio_numerator_event and ratio_denominator_event. 'rate' computes count(true) / count(all) for boolean metrics.","default":"count"},"ratio_numerator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Numerator Event","description":"Event type for numerator when aggregation='ratio'."},"ratio_denominator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Denominator Event","description":"Event type for denominator when aggregation='ratio'."},"valid_range_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Min","description":"Minimum valid value for numerical metrics. Pipeline drops values outside range."},"valid_range_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Max","description":"Maximum valid value for numerical metrics."},"freshness_sla_minutes":{"type":"integer","maximum":1440,"minimum":5,"title":"Freshness Sla Minutes","description":"Max acceptable staleness in minutes before alerting. Default: 60 (1 hour).","default":60},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit","description":"Display unit (e.g. 'score', 'minutes', '%', 'count')."},"categories":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":100},{"type":"null"}],"title":"Categories","description":"Allowed values for categorical metrics. Pipeline drops values not in this list when set. An ai_query metric reads ai_labels instead, and falls back to categories only when ai_labels is empty."},"model_tier":{"type":"string","enum":["free","fast","balanced","max","custom"],"title":"Model Tier","description":"AI model tier for extraction quality/cost tradeoff. 'free' — platform managed models (ai_classify, ai_extract). 'fast' — optimized for simple classification, low latency. 'balanced' — quality scoring, moderate reasoning. 'max' — complex analysis, multi-step reasoning. 'custom' — use ai_query_endpoint directly. When extraction_mode='ai_query' and ai_query_endpoint is not set, platform resolves model_tier to the optimal model automatically.","default":"free"},"channel_scope":{"type":"string","enum":["all","voice","text","surface","inbound","outbound"],"title":"Channel Scope","description":"Business-logic channel filter. 'voice' — voice calls only. 'text' — SMS/text sessions. 'surface' — form submissions. 'inbound'/'outbound' — by direction. 'all' — no channel filter (default). Pipeline translates to appropriate source + event_type filters.","default":"all"},"applies_to_product_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Applies To Product Types","description":"Product types this metric applies to (matches service tags, e.g. 'scheduling', 'outbound', 'coaching', 'intake', 'triage', 'support'). When set, the metric only computes for calls belonging to services whose config.tags include one of these keys. When None (default), the metric applies to every service regardless of product type."},"prompt":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Prompt","description":"Rubric prompt for LLM judge evaluation with {$.path} context variables. Each {$.path} reference is extracted from the entity's projected state and substituted before sending to ai_query. The prompt is both the evaluation criteria and the context specification."},"granularity":{"type":"string","enum":["aggregate","per_entity"],"title":"Granularity","description":"'aggregate' groups by (workspace, period) — one value per time bucket. 'per_entity' keeps entity_id — one value per entity (call, encounter). Judge metrics are typically per_entity. Computed metrics are typically aggregate.","default":"aggregate"},"tags":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":20},{"type":"null"}],"title":"Tags","description":"Up to 20 slugs (lowercase letters, digits, '-' and '_', at most 64 characters each)."},"notes":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Notes","description":"Free-text notes about the definition."},"active":{"type":"boolean","title":"Active","default":true},"builtin":{"type":"boolean","title":"Builtin","description":"True for platform-provided metrics (read-only key).","default":false}},"type":"object","required":["key","name","metric_type","source","event_types"],"title":"MetricDefinition","description":"A metric the platform computes for a workspace: what to extract from events, and how to aggregate it.\n\nBuilt-in metrics ship with every workspace. Custom metrics are defined per workspace through the settings\nAPI, and they extract with AI functions or with static paths into the event data."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The MetricStoreRunResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricStoreRunResponse":{"properties":{"run_id":{"type":"integer","title":"Run Id"}},"type":"object","required":["run_id"],"title":"MetricStoreRunResponse"}}}}
```

## The MetricStoreRunStatusResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricStoreRunStatusResponse":{"properties":{"run_id":{"type":"integer","title":"Run Id"},"life_cycle_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Life Cycle State"},"result_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Result State"},"state_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Message"}},"type":"object","required":["run_id"],"title":"MetricStoreRunStatusResponse"}}}}
```

## The MetricValueListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MetricValueListResponse":{"properties":{"metrics":{"items":{"oneOf":[{"$ref":"#/components/schemas/NumericalMetricValueResponse"},{"$ref":"#/components/schemas/CategoricalMetricValueResponse"},{"$ref":"#/components/schemas/BooleanMetricValueResponse"}],"discriminator":{"propertyName":"metric_type","mapping":{"boolean":"#/components/schemas/BooleanMetricValueResponse","categorical":"#/components/schemas/CategoricalMetricValueResponse","numerical":"#/components/schemas/NumericalMetricValueResponse"}}},"type":"array","title":"Metrics"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["metrics","has_more"],"title":"MetricValueListResponse"},"NumericalMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"numerical","title":"Metric Type"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"NumericalMetricValueResponse"},"CategoricalMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"categorical","title":"Metric Type"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value","description":"The category this row counts. A list-metrics latest row gives its period's most frequent category."},"distribution":{"items":{"$ref":"#/components/schemas/CategoryCount"},"type":"array","title":"Distribution","description":"Events per category in this row's period, most frequent first. A list-metrics latest row\nlists every category its period saw; any other row lists its own category.","default":[]}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"CategoricalMetricValueResponse"},"CategoryCount":{"properties":{"value":{"type":"string","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["value","count"],"title":"CategoryCount"},"BooleanMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"boolean","title":"Metric Type"},"value":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Value","description":"The value this row counts. A list-metrics latest row gives its period's more frequent value."},"distribution":{"items":{"$ref":"#/components/schemas/BooleanCount"},"type":"array","title":"Distribution","description":"Events per value in this row's period, most frequent first. A list-metrics latest row\nlists both values its period saw; any other row lists its own value.","default":[]}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"BooleanMetricValueResponse"},"BooleanCount":{"properties":{"value":{"type":"boolean","title":"Value"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["value","count"],"title":"BooleanCount"}}}}
```

## The MigrationConversationItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MigrationConversationItem":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"source_conversation_id":{"type":"string","maxLength":128,"minLength":1,"title":"Source Conversation Id"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"ended_at":{"type":"string","format":"date-time","title":"Ended At"},"channel_kind":{"$ref":"#/components/schemas/ChannelKind","default":"web"},"turn_count":{"type":"integer","minimum":0,"title":"Turn Count","default":0}},"type":"object","required":["entity_id","source_conversation_id","started_at","ended_at"],"title":"MigrationConversationItem"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."}}}}
```

## The MigrationConversationsBody object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MigrationConversationsBody":{"properties":{"conversations":{"items":{"$ref":"#/components/schemas/MigrationConversationItem"},"type":"array","maxItems":500,"minItems":1,"title":"Conversations"}},"type":"object","required":["conversations"],"title":"MigrationConversationsBody"},"MigrationConversationItem":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"source_conversation_id":{"type":"string","maxLength":128,"minLength":1,"title":"Source Conversation Id"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"ended_at":{"type":"string","format":"date-time","title":"Ended At"},"channel_kind":{"$ref":"#/components/schemas/ChannelKind","default":"web"},"turn_count":{"type":"integer","minimum":0,"title":"Turn Count","default":0}},"type":"object","required":["entity_id","source_conversation_id","started_at","ended_at"],"title":"MigrationConversationItem"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."}}}}
```

## The MigrationConversationsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MigrationConversationsResponse":{"properties":{"imported":{"type":"integer","title":"Imported"},"created":{"type":"integer","title":"Created"},"updated":{"type":"integer","title":"Updated"}},"type":"object","required":["imported","created","updated"],"title":"MigrationConversationsResponse"}}}}
```

## The MigrationTextThread object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MigrationTextThread":{"properties":{"channel_kind":{"type":"string","const":"sms","title":"Channel Kind"},"recipient":{"$ref":"#/components/schemas/PhoneE164"},"use_case_id":{"type":"string","format":"uuid","title":"Use Case Id"},"source_conversation_id":{"type":"string","maxLength":128,"minLength":1,"title":"Source Conversation Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"type":"object","maxProperties":50,"title":"Context"},"turns":{"items":{"$ref":"#/components/schemas/MigrationTextTurn"},"type":"array","maxItems":500,"minItems":1,"title":"Turns"}},"type":"object","required":["channel_kind","recipient","use_case_id","source_conversation_id","turns"],"title":"MigrationTextThread"},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"MigrationTextTurn":{"properties":{"source_message_id":{"type":"string","maxLength":128,"minLength":1,"title":"Source Message Id"},"role":{"type":"string","enum":["user","agent","external_event"],"title":"Role"},"text":{"type":"string","maxLength":10000,"minLength":1,"title":"Text"},"sent_at":{"type":"string","format":"date-time","title":"Sent At"}},"type":"object","required":["source_message_id","role","text","sent_at"],"title":"MigrationTextTurn"}}}}
```

## The MigrationTextThreadResult object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MigrationTextThreadResult":{"properties":{"source_conversation_id":{"type":"string","title":"Source Conversation Id"},"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id"},"appended":{"type":"integer","title":"Appended"},"skipped_existing":{"type":"integer","title":"Skipped Existing"},"status":{"type":"string","enum":["imported","conflict","out_of_order"],"title":"Status"}},"type":"object","required":["source_conversation_id","conversation_id","appended","skipped_existing","status"],"title":"MigrationTextThreadResult"}}}}
```

## The MigrationTextThreadsBody object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MigrationTextThreadsBody":{"properties":{"threads":{"items":{"$ref":"#/components/schemas/MigrationTextThread"},"type":"array","maxItems":100,"minItems":1,"title":"Threads"}},"type":"object","required":["threads"],"title":"MigrationTextThreadsBody"},"MigrationTextThread":{"properties":{"channel_kind":{"type":"string","const":"sms","title":"Channel Kind"},"recipient":{"$ref":"#/components/schemas/PhoneE164"},"use_case_id":{"type":"string","format":"uuid","title":"Use Case Id"},"source_conversation_id":{"type":"string","maxLength":128,"minLength":1,"title":"Source Conversation Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"type":"object","maxProperties":50,"title":"Context"},"turns":{"items":{"$ref":"#/components/schemas/MigrationTextTurn"},"type":"array","maxItems":500,"minItems":1,"title":"Turns"}},"type":"object","required":["channel_kind","recipient","use_case_id","source_conversation_id","turns"],"title":"MigrationTextThread"},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"MigrationTextTurn":{"properties":{"source_message_id":{"type":"string","maxLength":128,"minLength":1,"title":"Source Message Id"},"role":{"type":"string","enum":["user","agent","external_event"],"title":"Role"},"text":{"type":"string","maxLength":10000,"minLength":1,"title":"Text"},"sent_at":{"type":"string","format":"date-time","title":"Sent At"}},"type":"object","required":["source_message_id","role","text","sent_at"],"title":"MigrationTextTurn"}}}}
```

## The MigrationTextThreadsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MigrationTextThreadsResponse":{"properties":{"threads":{"items":{"$ref":"#/components/schemas/MigrationTextThreadResult"},"type":"array","title":"Threads"}},"type":"object","required":["threads"],"title":"MigrationTextThreadsResponse"},"MigrationTextThreadResult":{"properties":{"source_conversation_id":{"type":"string","title":"Source Conversation Id"},"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id"},"appended":{"type":"integer","title":"Appended"},"skipped_existing":{"type":"integer","title":"Skipped Existing"},"status":{"type":"string","enum":["imported","conflict","out_of_order"],"title":"Status"}},"type":"object","required":["source_conversation_id","conversation_id","appended","skipped_existing","status"],"title":"MigrationTextThreadResult"}}}}
```

## The MigrationTextTurn object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MigrationTextTurn":{"properties":{"source_message_id":{"type":"string","maxLength":128,"minLength":1,"title":"Source Message Id"},"role":{"type":"string","enum":["user","agent","external_event"],"title":"Role"},"text":{"type":"string","maxLength":10000,"minLength":1,"title":"Text"},"sent_at":{"type":"string","format":"date-time","title":"Sent At"}},"type":"object","required":["source_message_id","role","text","sent_at"],"title":"MigrationTextTurn"}}}}
```

## The MisspelledWordCheck object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"}}}}
```

## The ModelCost object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ModelCost":{"properties":{"model_id":{"type":"string","title":"Model Id"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Model priced subtotal rounded to cents; can be partial when is_priced is false. Null if none is priced."},"cost_share":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Share","description":"Model priced subtotal / all model priced subtotals in the selected scope, after any service filter.\nIncludes partial subtotals; null when this model has no priced cost or the denominator is zero."},"is_priced":{"type":"boolean","title":"Is Priced","description":"Whether every contributing usage row for this model is priced; false can coexist with a priced subtotal."},"unpriced_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unpriced Reason","description":"One reason contributing usage could not be priced; null when all usage is priced."},"applied_rates":{"items":{"$ref":"#/components/schemas/AppliedRate"},"type":"array","title":"Applied Rates","description":"Effective-date and context-band rates used for this model."}},"type":"object","required":["model_id","calculated_cost_usd","cost_share","is_priced","unpriced_reason","applied_rates"],"title":"ModelCost","description":"Cost and pricing status for one model."},"AppliedRate":{"properties":{"input_rate_effective_from":{"type":"string","format":"date","title":"Input Rate Effective From","description":"Inclusive first usage date for the input rate."},"input_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Input Rate Effective To","description":"Exclusive end usage date for the input rate; null means no end date."},"output_rate_effective_from":{"type":"string","format":"date","title":"Output Rate Effective From","description":"Inclusive first usage date for the output rate."},"output_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Output Rate Effective To","description":"Exclusive end usage date for the output rate; null means no end date."},"cached_rate_effective_from":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cached Rate Effective From","description":"Inclusive first usage date for the cached-input rate; null if no cached rate applied."},"cached_rate_effective_to":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Cached Rate Effective To","description":"Exclusive end usage date for the cached-input rate; null if unbounded or no cached rate applied."},"min_input_tokens":{"type":"integer","title":"Min Input Tokens","description":"Inclusive lower bound on per-request context input tokens for the input-rate band."},"max_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Input Tokens","description":"Inclusive upper bound on per-request context input tokens; null means unbounded."},"input_per_million":{"type":"string","title":"Input Per Million","description":"USD per million uncached input tokens, as a decimal string."},"cached_input_per_million":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cached Input Per Million","description":"USD per million cached input tokens; null if no cached rate applied."},"output_per_million":{"type":"string","title":"Output Per Million","description":"USD per million output tokens, as a decimal string."}},"type":"object","required":["input_rate_effective_from","input_rate_effective_to","output_rate_effective_from","output_rate_effective_to","cached_rate_effective_from","cached_rate_effective_to","min_input_tokens","max_input_tokens","input_per_million","cached_input_per_million","output_per_million"],"title":"AppliedRate","description":"Rate record applied to this model during the requested period."}}}}
```

## The ModelRegistryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ModelRegistryResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/ModelRegistryRow"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"ModelRegistryResponse"},"ModelRegistryRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"model_id":{"type":"string","title":"Model Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"focus_area":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Focus Area"},"algorithm":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Algorithm"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"trained_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Trained At"},"training_set_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Training Set Size"},"coefficients_json":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coefficients Json"},"metrics_json":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Metrics Json"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},"type":"object","required":["workspace_id","model_id"],"title":"ModelRegistryRow"}}}}
```

## The ModelRegistryRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ModelRegistryRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"model_id":{"type":"string","title":"Model Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"focus_area":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Focus Area"},"algorithm":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Algorithm"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version"},"trained_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Trained At"},"training_set_size":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Training Set Size"},"coefficients_json":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coefficients Json"},"metrics_json":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Metrics Json"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"}},"type":"object","required":["workspace_id","model_id"],"title":"ModelRegistryRow"}}}}
```

## The ModelUsage object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ModelUsage":{"properties":{"model_id":{"type":"string","title":"Model Id"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"request_count":{"type":"integer","title":"Request Count"},"calls_per_conversation":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Calls Per Conversation","description":"This model's linked requests / its distinct linked conversations in the selected scope; null if none."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["model_id","provider","request_count","calls_per_conversation","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ModelUsage","description":"Usage attributed to one model and provider."}}}}
```

## The ModelUse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ModelUse":{"type":"string","enum":["engage","skill"]}}}}
```

## The NameString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The NinetyDayRollingParams object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NinetyDayRollingParams":{"properties":{"rule_kind":{"type":"string","const":"ninety_day_rolling","title":"Rule Kind","default":"ninety_day_rolling"},"days":{"type":"integer","maximum":365,"minimum":1,"title":"Days"}},"type":"object","required":["days"],"title":"NinetyDayRollingParams","description":"Rolling-window cap on appointments per patient (e.g. 90 days\nbetween TMS sessions)."}}}}
```

## The NoPatient object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."}}}}
```

## The NonDesiredState object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NonDesiredState":{"properties":{"state":{"type":"string","maxLength":128,"title":"State"},"mode":{"type":"string","enum":["hard","soft"],"title":"Mode","default":"hard"}},"type":"object","required":["state"],"title":"NonDesiredState"}}}}
```

## The NoteRollupCategoryEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NoteRollupCategoryEntry":{"properties":{"value":{"type":"string","title":"Value"},"n":{"type":"integer","title":"N"},"pct":{"type":"number","title":"Pct"},"mean_risk":{"type":"number","title":"Mean Risk"},"risk_lift":{"type":"number","title":"Risk Lift"}},"type":"object","required":["value","n","pct","mean_risk","risk_lift"],"title":"NoteRollupCategoryEntry"}}}}
```

## The NoteRollupResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NoteRollupResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"total_notes":{"type":"integer","title":"Total Notes"},"cohort_mean_risk":{"type":"number","title":"Cohort Mean Risk"},"sentiment_distribution":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Sentiment Distribution"},"top_symptoms":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Top Symptoms"},"top_concerns":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Top Concerns"},"top_medications":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Top Medications"},"sdoh":{"$ref":"#/components/schemas/NoteRollupSdoh"}},"type":"object","required":["workspace_id","total_notes","cohort_mean_risk","sentiment_distribution","top_symptoms","top_concerns","top_medications","sdoh"],"title":"NoteRollupResponse"},"NoteRollupCategoryEntry":{"properties":{"value":{"type":"string","title":"Value"},"n":{"type":"integer","title":"N"},"pct":{"type":"number","title":"Pct"},"mean_risk":{"type":"number","title":"Mean Risk"},"risk_lift":{"type":"number","title":"Risk Lift"}},"type":"object","required":["value","n","pct","mean_risk","risk_lift"],"title":"NoteRollupCategoryEntry"},"NoteRollupSdoh":{"properties":{"activity":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Activity"},"smoking":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Smoking"},"diet":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Diet"}},"type":"object","required":["activity","smoking","diet"],"title":"NoteRollupSdoh"}}}}
```

## The NoteRollupSdoh object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NoteRollupSdoh":{"properties":{"activity":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Activity"},"smoking":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Smoking"},"diet":{"items":{"$ref":"#/components/schemas/NoteRollupCategoryEntry"},"type":"array","title":"Diet"}},"type":"object","required":["activity","smoking","diet"],"title":"NoteRollupSdoh"},"NoteRollupCategoryEntry":{"properties":{"value":{"type":"string","title":"Value"},"n":{"type":"integer","title":"N"},"pct":{"type":"number","title":"Pct"},"mean_risk":{"type":"number","title":"Mean Risk"},"risk_lift":{"type":"number","title":"Risk Lift"}},"type":"object","required":["value","n","pct","mean_risk","risk_lift"],"title":"NoteRollupCategoryEntry"}}}}
```

## The NumericalMetricValueResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NumericalMetricValueResponse":{"properties":{"metric_key":{"type":"string","title":"Metric Key"},"source":{"type":"string","title":"Source","default":"production"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Id"},"run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Run Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"period_start":{"type":"string","format":"date-time","title":"Period Start"},"period_end":{"type":"string","format":"date-time","title":"Period End"},"event_count":{"type":"integer","title":"Event Count"},"avg_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Confidence"},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"},"metric_type":{"type":"string","const":"numerical","title":"Metric Type"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"}},"type":"object","required":["metric_key","period_start","period_end","event_count","metric_type","value"],"title":"NumericalMetricValueResponse"}}}}
```

## The OAuth2ClientCredentialsAuthDict object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OAuth2ClientCredentialsAuthDict":{"properties":{"type":{"type":"string","const":"oauth2_client_credentials","title":"Type"},"token_url":{"type":"string","title":"Token Url"},"client_id":{"type":"string","title":"Client Id"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"client_auth_method":{"type":"string","enum":["basic","body"],"title":"Client Auth Method"}},"type":"object","required":["type","token_url","client_id","scopes","client_auth_method"],"title":"OAuth2ClientCredentialsAuthDict","description":"OAuth 2.0 Client Credentials Grant — RFC 6749 § 4.4."}}}}
```

## The OAuth2ClientCredentialsAuthRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OAuth2ClientCredentialsAuthRequest":{"properties":{"type":{"type":"string","const":"oauth2_client_credentials","title":"Type","default":"oauth2_client_credentials"},"token_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Token Url"},"client_id":{"type":"string","title":"Client Id"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"client_auth_method":{"type":"string","enum":["basic","body"],"title":"Client Auth Method","description":"RFC 6749 § 2.3.1: ``basic`` sends client_id+secret as HTTP Basic auth; ``body`` sends them in the form body.","default":"basic"}},"type":"object","required":["token_url","client_id"],"title":"OAuth2ClientCredentialsAuthRequest","description":"OAuth 2.0 Client Credentials Grant — RFC 6749 § 4.4.\n\nStrict RFC 6749 § 4.4.2 access token request: ``grant_type`` + optional\n``scope``. Client authentication (RFC 6749 § 2.3.1) is orthogonal —\n``client_auth_method`` picks between HTTP Basic auth and form-body\ncredentials. RFC 8707 ``resource`` and non-standard ``audience`` extensions\nare NOT supported here — add them back when a vendor needs one."}}}}
```

## The OAuth2JwtBearerAuthDict object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OAuth2JwtBearerAuthDict":{"properties":{"type":{"type":"string","const":"oauth2_jwt_bearer","title":"Type"},"token_url":{"type":"string","title":"Token Url"},"assertion_issuer":{"type":"string","title":"Assertion Issuer"},"assertion_audience":{"type":"string","title":"Assertion Audience"},"assertion_subject":{"type":"string","title":"Assertion Subject"},"assertion_lifetime_seconds":{"type":"integer","title":"Assertion Lifetime Seconds"},"include_iat":{"type":"boolean","title":"Include Iat"},"include_jti":{"type":"boolean","title":"Include Jti"},"assertion_algorithm":{"type":"string","enum":["RS256","RS384","RS512","PS256","PS384","PS512","ES256","ES384","ES512"],"title":"Assertion Algorithm"},"assertion_usage":{"type":"string","enum":["authorization_grant","client_authentication"],"title":"Assertion Usage"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"extra_claims":{"additionalProperties":true,"type":"object","title":"Extra Claims"}},"type":"object","required":["type","token_url","assertion_issuer","assertion_audience","assertion_subject","assertion_lifetime_seconds","include_iat","include_jti","assertion_algorithm","assertion_usage","scopes","extra_claims"],"title":"OAuth2JwtBearerAuthDict","description":"OAuth 2.0 JWT Bearer Token — RFC 7523.\n\n``assertion_usage`` selects the flow: § 2.1 (JWT as authorization grant) or\n§ 2.2 (JWT as client authentication / private_key_jwt)."}}}}
```

## The OAuth2JwtBearerAuthRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OAuth2JwtBearerAuthRequest":{"properties":{"type":{"type":"string","const":"oauth2_jwt_bearer","title":"Type","default":"oauth2_jwt_bearer"},"token_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Token Url"},"assertion_issuer":{"type":"string","title":"Assertion Issuer","description":"RFC 7523 ``iss`` claim — typically the service-account email or client_id."},"assertion_audience":{"type":"string","title":"Assertion Audience","description":"RFC 7523 ``aud`` claim — typically the token_url."},"assertion_subject":{"type":"string","title":"Assertion Subject","description":"RFC 7523 § 3 ``sub`` claim — MUST be present. For service-account flows\nwhere the client is its own subject, set to the same value as ``assertion_issuer``.\nUse a different value only for delegation / impersonation grants."},"assertion_lifetime_seconds":{"type":"integer","title":"Assertion Lifetime Seconds","default":3600},"include_iat":{"type":"boolean","title":"Include Iat","description":"RFC 7523 § 3 item 6 — ``iat`` claim set to mint time. Most IdPs (Google, Azure)\nrequire it for anti-replay; leave True unless a specific vendor rejects it.","default":true},"include_jti":{"type":"boolean","title":"Include Jti","description":"When True, generate a fresh ``jti`` (anti-replay) on every mint.","default":true},"assertion_algorithm":{"type":"string","enum":["RS256","RS384","RS512","PS256","PS384","PS512","ES256","ES384","ES512"],"title":"Assertion Algorithm","default":"RS256"},"assertion_usage":{"type":"string","enum":["authorization_grant","client_authentication"],"title":"Assertion Usage","description":"RFC 7523 flow selector — required; the caller must pick a flow.\n``authorization_grant`` (§ 2.1) sends the JWT as ``assertion`` under\n``grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer``.\n``client_authentication`` (§ 2.2, the ``private_key_jwt`` method) sends it as\n``client_assertion`` + ``client_assertion_type`` under ``grant_type=client_credentials``\n— required by Epic / SMART Backend Services."},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes","description":"RFC 7523 § 2.1 ``scope`` form-body parameter. Vendors that put scopes inside\nthe JWT instead (Google service accounts) use ``extra_claims = {\"scope\": \"...\"}``\nand leave this empty."},"extra_claims":{"additionalProperties":true,"type":"object","title":"Extra Claims","description":"RFC 7523 § 3 item 8 — arbitrary additional JWT claims (e.g. Google's\n``scope`` claim, Azure's tenant claim). Merged BEFORE the required claims so\nIdP-specific extensions can't override ``iss`` / ``sub`` / ``aud`` / ``exp`` /\n``iat`` / ``nbf`` / ``jti``.","default":{}}},"type":"object","required":["token_url","assertion_issuer","assertion_audience","assertion_subject","assertion_usage"],"title":"OAuth2JwtBearerAuthRequest","description":"OAuth 2.0 JWT Bearer Token — RFC 7523.\n\n``assertion_usage`` (required) selects the flow: § 2.1 (JWT as authorization\ngrant) or § 2.2 (JWT as client authentication / private_key_jwt)."}}}}
```

## The OcrRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OcrRequest":{"properties":{"image":{"type":"string","maxLength":10000000,"minLength":1,"title":"Image","description":"A PNG, JPEG, WebP or HEIC photo of at most 7 MB, base64-encoded or as a base64 data URL."},"target_fields":{"anyOf":[{"items":{"type":"string","enum":["carrier_name","group_number","member_id","plan_name"]},"type":"array","maxItems":50,"minItems":1},{"type":"null"}],"title":"Target Fields","description":"The card fields to read. Omitted, all four."}},"type":"object","required":["image"],"title":"OcrRequest"}}}}
```

## The OcrResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OcrResponse":{"properties":{"extracted_fields":{"additionalProperties":true,"type":"object","title":"Extracted Fields","description":"Each requested field the photo shows, by key, as the card prints it."},"confidence":{"type":"number","maximum":1,"minimum":0,"title":"Confidence","description":"The model's lowest per-field confidence over extracted_fields; 0 when it read no field."}},"type":"object","required":["confidence"],"title":"OcrResponse","description":"Structured field extraction result for an uploaded image."}}}}
```

## The OpenerFailureResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OpenerFailureResponse":{"properties":{"detail":{"type":"string","title":"Detail","description":"What failed."},"outcome":{"anyOf":[{"type":"string","enum":["delivered","unknown","rejected","not_sent","error"]},{"type":"null"}],"title":"Outcome","description":"What came of the opener's send. ``delivered``: the channel took the message, and a later step failed.\n``unknown``: the send failed after the request may have reached the channel, so the message may have gone\nout. ``rejected``: the channel refused the message, so it did not go out. ``not_sent``: the agent produced\nno message to send. ``error``: the run failed before any send began. Absent when the platform has no report\nof the opener."},"reason":{"anyOf":[{"type":"string","enum":["timeout","connection","http_4xx","http_5xx","error","opted_out","invalid_content","no_opener","llm_timeout","lease_contended","session_init","persist","agent_error","unanswered"]},{"type":"null"}],"title":"Reason","description":"Why the opener ended as it did. A failed send is named by how it failed: ``timeout``, ``connection``,\n``http_4xx``, ``http_5xx`` or ``error``. A refused message is ``opted_out`` (the recipient opted out) or\n``invalid_content``. A run that sent nothing is ``no_opener`` (the agent produced no message),\n``llm_timeout`` (the model did not answer in time) or ``lease_contended`` (another run held the\nconversation). A failure in the run is ``session_init``, ``persist`` or ``agent_error``. ``unanswered``:\nthe agent runtime gave no answer. Null when the send went out and nothing failed after it. Absent when the\nplatform has no report of the opener."},"conversation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Conversation Id","description":"The conversation the opener ran in, or null when none had been created. Absent when the platform has no\nreport of the opener."}},"type":"object","required":["detail"],"title":"OpenerFailureResponse","description":"The body of a failed outbound opener.\n\n``detail`` says what failed. ``outcome``, ``reason`` and ``conversation_id`` say what happened to the\nopener's message and where, when the platform has a report of it; a failure it has none of carries\n``detail`` alone."}}}}
```

## The OperationGrantListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperationGrantListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/OperationGrantResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"OperationGrantListResponse"},"OperationGrantResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"credential_id":{"type":"string","format":"uuid","title":"Credential Id"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"operation_id":{"type":"string","format":"uuid","title":"Operation Id"},"operation_kind":{"type":"string","enum":["data_query","function"],"title":"Operation Kind"},"action":{"type":"string","enum":["read","write","invoke"],"title":"Action"},"definition_sha256":{"type":"string","title":"Definition Sha256"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"}},"type":"object","required":["id","workspace_id","credential_id","entity_id","operation_id","operation_kind","action","definition_sha256","expires_at","revoked_at"],"title":"OperationGrantResponse"}}}}
```

## The OperationGrantResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperationGrantResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"credential_id":{"type":"string","format":"uuid","title":"Credential Id"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"operation_id":{"type":"string","format":"uuid","title":"Operation Id"},"operation_kind":{"type":"string","enum":["data_query","function"],"title":"Operation Kind"},"action":{"type":"string","enum":["read","write","invoke"],"title":"Action"},"definition_sha256":{"type":"string","title":"Definition Sha256"},"expires_at":{"type":"string","format":"date-time","title":"Expires At"},"revoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Revoked At"}},"type":"object","required":["id","workspace_id","credential_id","entity_id","operation_id","operation_kind","action","definition_sha256","expires_at","revoked_at"],"title":"OperationGrantResponse"}}}}
```

## The OperatorIntelligenceSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorIntelligenceSummary":{"properties":{"escalated":{"type":"boolean","title":"Escalated","description":"Whether the call was escalated to a human operator","default":false},"operator_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Operator Active","description":"Whether an operator was active during escalation. True = active; False = escalation occurred but no operator picked up; None = no escalation occurred (do NOT coerce to False)."}},"type":"object","title":"OperatorIntelligenceSummary","description":"Operator intervention summary.\n\nThree-valued semantics on ``operator_active``:\n- ``True``  — escalation occurred and an operator was active.\n- ``False`` — escalation occurred but no operator picked up.\n- ``None``  — no escalation occurred (producer omits the key).\n  Readers must distinguish; do not coerce ``None`` → ``False``."}}}}
```

## The OperatorListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/OperatorResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"OperatorListResponse"},"OperatorResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Display name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The operator's email. It is fixed once registered."},"type":{"anyOf":[{"type":"string","enum":["clinical","administrative","crisis_counselor"]},{"type":"null"}],"title":"Type","description":"Operator specialization"},"skills":{"items":{"type":"string"},"type":"array","title":"Skills","description":"Skill tags for routing"},"connection_method":{"type":"string","enum":["browser","phone"],"title":"Connection Method","description":"How the operator connects to calls"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number","description":"E.164 phone number for phone-based operators"},"role":{"type":"string","enum":["operator","supervisor","admin"],"title":"Role","description":"Permission role"},"status":{"type":"string","enum":["online","busy","offline"],"title":"Status","description":"Current availability"},"last_status_change":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Status Change","description":"ISO-8601 timestamp of last status transition"},"active_call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Active Call Sid","description":"Call SID if currently on a call"},"total_escalations_handled":{"type":"integer","title":"Total Escalations Handled","description":"Lifetime escalation count"},"avg_handle_time_seconds":{"type":"number","title":"Avg Handle Time Seconds","description":"Average escalation handle time in seconds"},"last_call_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Call At","description":"ISO-8601 timestamp of last call"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the operator was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the operator was last updated"}},"type":"object","required":["id","workspace_id","skills","connection_method","role","status","total_escalations_handled","avg_handle_time_seconds"],"title":"OperatorResponse"}}}}
```

## The OperatorPerformanceItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorPerformanceItem":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Display name"},"status":{"type":"string","enum":["online","busy","offline"],"title":"Status","description":"Current availability"},"total_escalations_handled":{"type":"integer","title":"Total Escalations Handled","description":"Lifetime escalation count"},"avg_handle_time_seconds":{"type":"number","title":"Avg Handle Time Seconds","description":"Average handle time in seconds"},"last_call_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Call At","description":"ISO-8601 timestamp of last call"}},"type":"object","required":["operator_id","status","total_escalations_handled","avg_handle_time_seconds"],"title":"OperatorPerformanceItem"}}}}
```

## The OperatorPerformanceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorPerformanceResponse":{"properties":{"summary":{"$ref":"#/components/schemas/OperatorPerformanceSummary","description":"Aggregate operator performance metrics"},"trend":{"items":{"$ref":"#/components/schemas/OperatorPerformanceTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"Time series of escalation counts per interval bucket"}},"type":"object","required":["summary","trend"],"title":"OperatorPerformanceResponse","description":"Operator escalation performance and quality comparison over time."},"OperatorPerformanceSummary":{"properties":{"total_calls":{"type":"integer","title":"Total Calls","description":"Total number of calls in the period"},"escalated_count":{"type":"integer","title":"Escalated Count","description":"Number of calls escalated to an operator"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Fraction of calls that were escalated (0.0-1.0)"},"operator_handled_count":{"type":"integer","title":"Operator Handled Count","description":"Number of calls where an operator was active"},"avg_escalated_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Escalated Duration Seconds","description":"Average duration in seconds of escalated calls"},"avg_escalated_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Escalated Quality Score","description":"Average quality score of escalated calls"},"avg_non_escalated_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Non Escalated Quality Score","description":"Average quality score of non-escalated calls"}},"type":"object","required":["total_calls","escalated_count","escalation_rate","operator_handled_count"],"title":"OperatorPerformanceSummary","description":"Aggregate operator escalation stats for the period."},"OperatorPerformanceTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Bucket start: a date (YYYY-MM-DD) for a daily or weekly bucket, an ISO-8601 timestamp for an hourly one"},"total_calls":{"type":"integer","title":"Total Calls","description":"Total calls in this time bucket"},"escalated_count":{"type":"integer","title":"Escalated Count","description":"Escalated calls in this time bucket"}},"type":"object","required":["date","total_calls","escalated_count"],"title":"OperatorPerformanceTrendPoint","description":"Single time-bucket data point in the operator performance trend series."}}}}
```

## The OperatorPerformanceSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorPerformanceSummary":{"properties":{"total_calls":{"type":"integer","title":"Total Calls","description":"Total number of calls in the period"},"escalated_count":{"type":"integer","title":"Escalated Count","description":"Number of calls escalated to an operator"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Fraction of calls that were escalated (0.0-1.0)"},"operator_handled_count":{"type":"integer","title":"Operator Handled Count","description":"Number of calls where an operator was active"},"avg_escalated_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Escalated Duration Seconds","description":"Average duration in seconds of escalated calls"},"avg_escalated_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Escalated Quality Score","description":"Average quality score of escalated calls"},"avg_non_escalated_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Non Escalated Quality Score","description":"Average quality score of non-escalated calls"}},"type":"object","required":["total_calls","escalated_count","escalation_rate","operator_handled_count"],"title":"OperatorPerformanceSummary","description":"Aggregate operator escalation stats for the period."}}}}
```

## The OperatorPerformanceTrendPoint object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorPerformanceTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Bucket start: a date (YYYY-MM-DD) for a daily or weekly bucket, an ISO-8601 timestamp for an hourly one"},"total_calls":{"type":"integer","title":"Total Calls","description":"Total calls in this time bucket"},"escalated_count":{"type":"integer","title":"Escalated Count","description":"Escalated calls in this time bucket"}},"type":"object","required":["date","total_calls","escalated_count"],"title":"OperatorPerformanceTrendPoint","description":"Single time-bucket data point in the operator performance trend series."}}}}
```

## The OperatorResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Display name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The operator's email. It is fixed once registered."},"type":{"anyOf":[{"type":"string","enum":["clinical","administrative","crisis_counselor"]},{"type":"null"}],"title":"Type","description":"Operator specialization"},"skills":{"items":{"type":"string"},"type":"array","title":"Skills","description":"Skill tags for routing"},"connection_method":{"type":"string","enum":["browser","phone"],"title":"Connection Method","description":"How the operator connects to calls"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number","description":"E.164 phone number for phone-based operators"},"role":{"type":"string","enum":["operator","supervisor","admin"],"title":"Role","description":"Permission role"},"status":{"type":"string","enum":["online","busy","offline"],"title":"Status","description":"Current availability"},"last_status_change":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Status Change","description":"ISO-8601 timestamp of last status transition"},"active_call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Active Call Sid","description":"Call SID if currently on a call"},"total_escalations_handled":{"type":"integer","title":"Total Escalations Handled","description":"Lifetime escalation count"},"avg_handle_time_seconds":{"type":"number","title":"Avg Handle Time Seconds","description":"Average escalation handle time in seconds"},"last_call_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Call At","description":"ISO-8601 timestamp of last call"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the operator was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the operator was last updated"}},"type":"object","required":["id","workspace_id","skills","connection_method","role","status","total_escalations_handled","avg_handle_time_seconds"],"title":"OperatorResponse"}}}}
```

## The OperatorStatusCounts object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorStatusCounts":{"properties":{"total":{"type":"integer","title":"Total"},"online":{"type":"integer","title":"Online"},"busy":{"type":"integer","title":"Busy"},"offline":{"type":"integer","title":"Offline"}},"type":"object","required":["total","online","busy","offline"],"title":"OperatorStatusCounts"}}}}
```

## The OrderedPathway object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OrderedPathway":{"properties":{"id":{"type":"string","maxLength":64,"title":"Id"},"sequence":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"minItems":1,"title":"Sequence"}},"type":"object","required":["id","sequence"],"title":"OrderedPathway"}}}}
```

## The OutboundLogItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OutboundLogItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_id":{"type":"string","format":"uuid","title":"Event Id"},"synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Synced At"},"sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Error"},"attempt_count":{"type":"integer","title":"Attempt Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","event_id","attempt_count","created_at"],"title":"OutboundLogItem"}}}}
```

## The OutboundLogListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OutboundLogListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/OutboundLogItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"OutboundLogListResponse"},"OutboundLogItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_id":{"type":"string","format":"uuid","title":"Event Id"},"synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Synced At"},"sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Error"},"attempt_count":{"type":"integer","title":"Attempt Count"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","event_id","attempt_count","created_at"],"title":"OutboundLogItem"}}}}
```

## The OutboundSinkSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OutboundSinkSummary":{"properties":{"data_source_id":{"type":"string","format":"uuid","title":"Data Source Id"},"data_source_name":{"type":"string","title":"Data Source Name"},"total":{"type":"integer","title":"Total"},"synced":{"type":"integer","title":"Synced"},"failed":{"type":"integer","title":"Failed"},"pending":{"type":"integer","title":"Pending"},"last_synced_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Synced At"}},"type":"object","required":["data_source_id","data_source_name","total","synced","failed","pending"],"title":"OutboundSinkSummary"}}}}
```

## The OutboundSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OutboundSummary":{"properties":{"total":{"type":"integer","title":"Total","default":0},"synced":{"type":"integer","title":"Synced","default":0},"failed":{"type":"integer","title":"Failed","default":0},"pending":{"type":"integer","title":"Pending","default":0},"last_synced_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Synced At"}},"type":"object","title":"OutboundSummary"}}}}
```

## The OutputCheckModes object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OutputCheckModes":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/ReadinessLabel"}},"type":"object","required":["phi_unverified"],"title":"OutputCheckModes","description":"Mode values follow the library's read model as it adds supported modes."},"ReadinessLabel":{"type":"string"}}}}
```

## The OutreachRule object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OutreachRule":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"trigger":{"type":"string","enum":["appointment_window","post_visit","gap_detected","form_intake","manual"],"title":"Trigger","default":"appointment_window"},"trigger_config":{"additionalProperties":true,"type":"object","title":"Trigger Config","description":"Trigger-specific config (hours_before, hours_after, etc.)"},"channel":{"$ref":"#/components/schemas/StoredChannelType","default":"email"},"consent_required":{"type":"boolean","title":"Consent Required","default":true},"quiet_hours":{"$ref":"#/components/schemas/QuietHours"},"review_required":{"type":"boolean","title":"Review Required","default":false},"message_template":{"type":"string","maxLength":1600,"title":"Message Template","default":"Hi {first_name}, please complete your form: {surface_url}"},"data_template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Data Template Id"},"form_template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Form Template Id"},"active":{"type":"boolean","title":"Active","default":true}},"type":"object","required":["name"],"title":"OutreachRule","description":"A single outreach rule — defines WHEN, WHAT, and HOW to reach a patient."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"StoredChannelType":{"type":"string","enum":["email","web","sms"],"title":"StoredChannelType","description":"Channel as stored on a surface row or outreach rule.\n\n``sms`` predates the end of SMS delivery. It stays readable, and an edit may send a stored ``sms`` back\nunchanged, but no surface or rule is ever switched to it or created with it."},"QuietHours":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"start_hour":{"type":"integer","maximum":23,"minimum":0,"title":"Start Hour","default":21},"end_hour":{"type":"integer","maximum":23,"minimum":0,"title":"End Hour","default":8},"timezone":{"type":"string","maxLength":64,"title":"Timezone","default":"America/New_York"}},"type":"object","title":"QuietHours","description":"Quiet hours — no outbound outreach during this window."}}}}
```

## The OutreachSettingsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OutreachSettingsRequest":{"properties":{"rules":{"anyOf":[{"items":{"$ref":"#/components/schemas/OutreachRule"},"type":"array"},{"type":"null"}],"title":"Rules"},"data_templates":{"anyOf":[{"items":{"$ref":"#/components/schemas/DataTemplate-Input"},"type":"array"},{"type":"null"}],"title":"Data Templates"}},"type":"object","title":"OutreachSettingsRequest","description":"Partial update — only provided fields are changed.\n\nRules and data_templates lists are replaced entirely when provided.\nA rule stored with channel ``sms`` may be sent back with it; any other rule with ``sms`` is refused."},"OutreachRule":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"trigger":{"type":"string","enum":["appointment_window","post_visit","gap_detected","form_intake","manual"],"title":"Trigger","default":"appointment_window"},"trigger_config":{"additionalProperties":true,"type":"object","title":"Trigger Config","description":"Trigger-specific config (hours_before, hours_after, etc.)"},"channel":{"$ref":"#/components/schemas/StoredChannelType","default":"email"},"consent_required":{"type":"boolean","title":"Consent Required","default":true},"quiet_hours":{"$ref":"#/components/schemas/QuietHours"},"review_required":{"type":"boolean","title":"Review Required","default":false},"message_template":{"type":"string","maxLength":1600,"title":"Message Template","default":"Hi {first_name}, please complete your form: {surface_url}"},"data_template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Data Template Id"},"form_template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Form Template Id"},"active":{"type":"boolean","title":"Active","default":true}},"type":"object","required":["name"],"title":"OutreachRule","description":"A single outreach rule — defines WHEN, WHAT, and HOW to reach a patient."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"StoredChannelType":{"type":"string","enum":["email","web","sms"],"title":"StoredChannelType","description":"Channel as stored on a surface row or outreach rule.\n\n``sms`` predates the end of SMS delivery. It stays readable, and an edit may send a stored ``sms`` back\nunchanged, but no surface or rule is ever switched to it or created with it."},"QuietHours":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"start_hour":{"type":"integer","maximum":23,"minimum":0,"title":"Start Hour","default":21},"end_hour":{"type":"integer","maximum":23,"minimum":0,"title":"End Hour","default":8},"timezone":{"type":"string","maxLength":64,"title":"Timezone","default":"America/New_York"}},"type":"object","title":"QuietHours","description":"Quiet hours — no outbound outreach during this window."},"DataTemplate-Input":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"fields":{"items":{"$ref":"#/components/schemas/DataTemplateField"},"type":"array","maxItems":50,"minItems":1,"title":"Fields"}},"type":"object","required":["name","fields"],"title":"DataTemplate","description":"Named field template — reusable across multiple outreach rules."},"DataTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"path":{"type":"string","maxLength":256,"minLength":1,"title":"Path","description":"Dot-notation path into entity state (e.g. demographics.date_of_birth)"}},"type":"object","required":["key","label","path"],"title":"DataTemplateField","description":"A field in a data template — maps to entity state path for gap detection."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."}}}}
```

## The OutreachSettingsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OutreachSettingsResponse":{"properties":{"rules":{"items":{"$ref":"#/components/schemas/OutreachRule"},"type":"array","title":"Rules"},"data_templates":{"items":{"$ref":"#/components/schemas/DataTemplate-Output"},"type":"array","title":"Data Templates"}},"type":"object","required":["rules","data_templates"],"title":"OutreachSettingsResponse"},"OutreachRule":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"trigger":{"type":"string","enum":["appointment_window","post_visit","gap_detected","form_intake","manual"],"title":"Trigger","default":"appointment_window"},"trigger_config":{"additionalProperties":true,"type":"object","title":"Trigger Config","description":"Trigger-specific config (hours_before, hours_after, etc.)"},"channel":{"$ref":"#/components/schemas/StoredChannelType","default":"email"},"consent_required":{"type":"boolean","title":"Consent Required","default":true},"quiet_hours":{"$ref":"#/components/schemas/QuietHours"},"review_required":{"type":"boolean","title":"Review Required","default":false},"message_template":{"type":"string","maxLength":1600,"title":"Message Template","default":"Hi {first_name}, please complete your form: {surface_url}"},"data_template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Data Template Id"},"form_template_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Form Template Id"},"active":{"type":"boolean","title":"Active","default":true}},"type":"object","required":["name"],"title":"OutreachRule","description":"A single outreach rule — defines WHEN, WHAT, and HOW to reach a patient."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"StoredChannelType":{"type":"string","enum":["email","web","sms"],"title":"StoredChannelType","description":"Channel as stored on a surface row or outreach rule.\n\n``sms`` predates the end of SMS delivery. It stays readable, and an edit may send a stored ``sms`` back\nunchanged, but no surface or rule is ever switched to it or created with it."},"QuietHours":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"start_hour":{"type":"integer","maximum":23,"minimum":0,"title":"Start Hour","default":21},"end_hour":{"type":"integer","maximum":23,"minimum":0,"title":"End Hour","default":8},"timezone":{"type":"string","maxLength":64,"title":"Timezone","default":"America/New_York"}},"type":"object","title":"QuietHours","description":"Quiet hours — no outbound outreach during this window."},"DataTemplate-Output":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"fields":{"items":{"$ref":"#/components/schemas/DataTemplateField"},"type":"array","maxItems":50,"minItems":1,"title":"Fields"}},"type":"object","required":["name","fields"],"title":"DataTemplate","description":"Named field template — reusable across multiple outreach rules."},"DataTemplateField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType","default":"text"},"required":{"type":"boolean","title":"Required","default":true},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"path":{"type":"string","maxLength":256,"minLength":1,"title":"Path","description":"Dot-notation path into entity state (e.g. demographics.date_of_birth)"}},"type":"object","required":["key","label","path"],"title":"DataTemplateField","description":"A field in a data template — maps to entity state path for gap detection."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."}}}}
```

## The PaginatedResponse\_BatchRow\_ object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PaginatedResponse_BatchRow_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/BatchRow"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Continuation Token"},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total"}},"type":"object","required":["items","has_more"],"title":"PaginatedResponse[BatchRow]"},"BatchRow":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"batch_id."},"source_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Source Id"},"dataset":{"type":"string","title":"Dataset"},"status":{"type":"string","title":"Status","description":"discovered | ready | processing | completed | failed."},"files_found":{"type":"integer","title":"Files Found"},"created_ts":{"type":"string","title":"Created Ts"}},"type":"object","required":["id","dataset","status","files_found","created_ts"],"title":"BatchRow","description":"A source-sync batch (Batches list / detail)."}}}}
```

## The PaginatedResponse\_DatasetRow\_ object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PaginatedResponse_DatasetRow_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/DatasetRow"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Continuation Token"},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total"}},"type":"object","required":["items","has_more"],"title":"PaginatedResponse[DatasetRow]"},"DatasetRow":{"properties":{"name":{"type":"string","title":"Name","description":"Dataset slug (UI label \"Schema\")."},"schema_version":{"type":"string","title":"Schema Version"},"field_count":{"type":"integer","title":"Field Count"},"file_type":{"type":"string","title":"File Type","description":"Primary/representative file type (the first accepted type)."},"accepted_file_types":{"items":{"type":"string"},"type":"array","title":"Accepted File Types","description":"Document datasets: the full accepted-type set. Empty for snapshot\nor legacy single-type documents (the UI falls back to ``file_type``).","default":[]},"ingestion_mode":{"type":"string","title":"Ingestion Mode","description":"`snapshot` (CSV/Excel → CDC) or `document` (PDF/docx → extraction)."},"limits":{"$ref":"#/components/schemas/Limits"}},"type":"object","required":["name","schema_version","field_count","file_type","ingestion_mode","limits"],"title":"DatasetRow","description":"A registered schema in the Schemas list."},"Limits":{"properties":{"max_size_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Size Mb"}},"type":"object","title":"Limits"}}}}
```

## The PaginatedResponse\_IntakeFileRow\_ object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PaginatedResponse_IntakeFileRow_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/IntakeFileRow"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Continuation Token"},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total"}},"type":"object","required":["items","has_more"],"title":"PaginatedResponse[IntakeFileRow]"},"IntakeFileRow":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"file_id — used for download."},"filename":{"type":"string","title":"Filename"},"dataset":{"type":"string","title":"Dataset","description":"Schema slug (UI label \"Schema\")."},"schema_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schema Version","description":"The contract version this file validated against (e.g. ``v1``)."},"status":{"$ref":"#/components/schemas/_FileStatus"},"error_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Reason","description":"Null unless rejected/failed."},"size_bytes":{"type":"integer","title":"Size Bytes"},"ingested_at":{"type":"string","title":"Ingested At","description":"ISO-8601 timestamp the file was received."},"document_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Document Id","description":"The document this version belongs to. Null for snapshot and CSV rows; set for documents. The console\ngroups versions by it to show each document's version history."},"version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Version","description":"The file's version number (per-document for documents, per-dataset for\nsnapshot). Lets the UI render a document's version history."},"source_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Type","description":"Origin of the document this version belongs to: ``manual`` for console uploads, ``google_shared_drive``\nfor the Drive connector. Null for snapshot and CSV rows."},"source_file_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source File Id","description":"The source's stable external id (e.g. the Google Drive file id) for the\ndocument. Lets the console show provenance and confirm a re-synced file\nbumped the *same* document. Null for manual uploads and snapshot rows."},"source_folder_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Folder Path","description":"Where the file lived within the mapped Drive folder tree, as a relative path with folder names joined by\n``/`` (e.g. ``clinical/notes``), and ``''`` at the mapped root. Lets the console show the original folder\nstructure. Null for manual uploads and snapshot rows."},"doc_metadata":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Doc Metadata","description":"Caller-supplied tags linking the document to a real-world subject, e.g. ``{\"patient_id\": \"…\"}``. Set at upload for the whole document version\nchain. ``{}`` for a document with no tags; null only for snapshot/CSV rows."}},"type":"object","required":["id","filename","dataset","status","size_bytes","ingested_at"],"title":"IntakeFileRow","description":"A file in the Files list."},"_FileStatus":{"type":"string","enum":["received","scanned","processing","curated","rejected","failed","held"]}}}}
```

## The PaginatedResponse\_IntakeSourceRow\_ object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PaginatedResponse_IntakeSourceRow_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/IntakeSourceRow"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Continuation Token"},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total"}},"type":"object","required":["items","has_more"],"title":"PaginatedResponse[IntakeSourceRow]"},"IntakeSourceRow":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"source_id."},"source_type":{"type":"string","title":"Source Type"},"display_name":{"type":"string","title":"Display Name"},"drive_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Drive Id"},"folders":{"items":{"$ref":"#/components/schemas/DriveFolderMapping"},"type":"array","title":"Folders"},"impersonate_subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Impersonate Subject","description":"DWD impersonation subject, if this source authenticates via domain-wide delegation."},"status":{"type":"string","title":"Status"},"created_ts":{"type":"string","title":"Created Ts","description":"ISO-8601 timestamp."}},"type":"object","required":["id","source_type","display_name","folders","status","created_ts"],"title":"IntakeSourceRow","description":"A registered intake source (Sources list)."},"DriveFolderMapping":{"properties":{"folder_id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Folder Id"},"dataset":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Dataset"},"contains_phi":{"type":"boolean","title":"Contains Phi","default":true}},"type":"object","required":["folder_id","dataset"],"title":"DriveFolderMapping","description":"One Google Drive folder ↔ one intake dataset.\n\n``folder_id`` is the Drive folder id (the identity — never the folder name,\nwhich can be renamed/moved). One folder maps to exactly one dataset."}}}}
```

## The PaginatedResponse\_MaterializationRow\_ object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PaginatedResponse_MaterializationRow_":{"properties":{"items":{"items":{"$ref":"#/components/schemas/MaterializationRow"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Continuation Token"},"total":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total"}},"type":"object","required":["items","has_more"],"title":"PaginatedResponse[MaterializationRow]"},"MaterializationRow":{"properties":{"dataset":{"type":"string","title":"Dataset"},"ingestion_mode":{"type":"string","title":"Ingestion Mode"},"status":{"type":"string","enum":["materialized","not_materialized"],"title":"Status"},"row_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Row Count"},"last_materialized_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Materialized At"}},"type":"object","required":["dataset","ingestion_mode","status"],"title":"MaterializationRow","description":"Per-dataset status of the customer-data destination table\n(``customer_data_<env>.<workspace_id>.<dataset>``)."}}}}
```

## The PanelResultResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PanelResultResponse":{"properties":{"panel_id":{"type":"string","title":"Panel Id","description":"Panel identifier from the definition"},"columns":{"items":{"type":"string"},"type":"array","title":"Columns","description":"Column names"},"rows":{"items":{"items":{},"type":"array"},"type":"array","title":"Rows","description":"Result rows"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if query failed"}},"type":"object","required":["panel_id","columns","rows"],"title":"PanelResultResponse"}}}}
```

## The ParamValueDict object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ParamValueDict":{"properties":{"param_name":{"type":"string","title":"Param Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["param_name","description"],"title":"ParamValueDict","description":"Routing target for one per-request parameter on the exchange call.\n\nPaired with a wire-name (header / body-field key) on\n``CustomTokenExchangeAuthDict.param_headers`` / ``param_body_fields``."}}}}
```

## The ParamValueRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ParamValueRequest":{"properties":{"param_name":{"type":"string","title":"Param Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["param_name","description"],"title":"ParamValueRequest","description":"Routing target for a single per-request parameter on the exchange call.\n\nPaired with a wire-name (header / body-field key) on\n``CustomTokenExchangeAuthRequest.param_headers`` / ``param_body_fields``."}}}}
```

## The Participant object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Participant":{"properties":{"participant_id":{"type":"string","title":"Participant Id"},"role":{"type":"string","enum":["caller","agent","operator"],"title":"Role"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"joined_at":{"type":"string","format":"date-time","title":"Joined At"},"left_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Left At"}},"type":"object","required":["participant_id","role","joined_at"],"title":"Participant"}}}}
```

## The PatientInParams object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."}}}}
```

## The PatientLabRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientLabRow":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"observation_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Observation Date"},"test_name":{"type":"string","title":"Test Name"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"units":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Units"},"loinc_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Loinc Code"}},"type":"object","required":["patient_id","test_name"],"title":"PatientLabRow"}}}}
```

## The PatientLabsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientLabsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/PatientLabRow"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"PatientLabsResponse"},"PatientLabRow":{"properties":{"patient_id":{"type":"string","title":"Patient Id"},"observation_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Observation Date"},"test_name":{"type":"string","title":"Test Name"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"units":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Units"},"loinc_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Loinc Code"}},"type":"object","required":["patient_id","test_name"],"title":"PatientLabRow"}}}}
```

## The PatientListItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientListItem":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Patient name"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date","description":"Date of birth (YYYY-MM-DD)"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender","description":"Gender"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"Primary phone number"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Primary email address"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn","description":"Medical record number"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"PatientListItem","description":"Typed patient list item."}}}}
```

## The PatientNoteExtractions object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientNoteExtractions":{"properties":{"symptoms":{"items":{"type":"string"},"type":"array","title":"Symptoms"},"concerns":{"items":{"type":"string"},"type":"array","title":"Concerns"},"medications_planned":{"items":{"type":"string"},"type":"array","title":"Medications Planned"},"hba1c_sentiment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hba1C Sentiment"},"activity_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Activity Level"},"smoking_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Smoking Status"},"food_pattern":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Food Pattern"},"n_symptoms":{"type":"integer","title":"N Symptoms","default":0},"n_concerns":{"type":"integer","title":"N Concerns","default":0}},"type":"object","required":["symptoms","concerns","medications_planned"],"title":"PatientNoteExtractions"}}}}
```

## The PatientNoteResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientNoteResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"patient_id":{"type":"string","title":"Patient Id"},"authored_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Authored At"},"author":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Author"},"note_text":{"type":"string","title":"Note Text"},"extractions":{"$ref":"#/components/schemas/PatientNoteExtractions"}},"type":"object","required":["workspace_id","patient_id","note_text","extractions"],"title":"PatientNoteResponse"},"PatientNoteExtractions":{"properties":{"symptoms":{"items":{"type":"string"},"type":"array","title":"Symptoms"},"concerns":{"items":{"type":"string"},"type":"array","title":"Concerns"},"medications_planned":{"items":{"type":"string"},"type":"array","title":"Medications Planned"},"hba1c_sentiment":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Hba1C Sentiment"},"activity_level":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Activity Level"},"smoking_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Smoking Status"},"food_pattern":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Food Pattern"},"n_symptoms":{"type":"integer","title":"N Symptoms","default":0},"n_concerns":{"type":"integer","title":"N Concerns","default":0}},"type":"object","required":["symptoms","concerns","medications_planned"],"title":"PatientNoteExtractions"}}}}
```

## The PatientSearchResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientSearchResponse":{"properties":{"patients":{"items":{"$ref":"#/components/schemas/PatientListItem"},"type":"array","title":"Patients"},"total":{"type":"integer","title":"Total"},"has_more":{"type":"boolean","title":"Has More","default":false},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset"}},"type":"object","required":["patients","total"],"title":"PatientSearchResponse"},"PatientListItem":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Patient name"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date","description":"Date of birth (YYYY-MM-DD)"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender","description":"Gender"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"Primary phone number"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Primary email address"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn","description":"Medical record number"},"event_count":{"type":"integer","title":"Event Count","default":0},"last_event_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Event At"}},"type":"object","required":["entity_id"],"title":"PatientListItem","description":"Typed patient list item."}}}}
```

## The PatientSummaryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientSummaryResponse":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"entity_type":{"type":"string","title":"Entity Type"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"state":{"additionalProperties":true,"type":"object","title":"State","description":"Full JSONB state blob. Prefer typed fields below.","deprecated":true},"event_count":{"type":"integer","title":"Event Count"},"last_event_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Event At"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Patient name"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"Primary phone number (E.164)"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"Primary email address"},"birth_date":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Birth Date","description":"Date of birth (YYYY-MM-DD)"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender","description":"Gender"},"mrn":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Mrn","description":"Medical record number"}},"type":"object","required":["entity_id","entity_type","display_name","event_count","last_event_at"],"title":"PatientSummaryResponse"}}}}
```

## The PatientSurfaceSpec object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientSurfaceSpec":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Description"},"fields":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Fields"},"sections":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sections"},"branding":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Branding"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"},"completion_title":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"context":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Context"}},"type":"object","title":"PatientSurfaceSpec","description":"The patient-facing form a surface renders: its title, description, fields, sections, branding, submit button\ntext, completion text and context.\n\n`fields`, `sections`, `branding` and `context` are passed through as the surface defines them, so their shape\nis not fixed here."}}}}
```

## The PatientTimelineResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientTimelineResponse":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"events":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Events"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["entity_id","events","total"],"title":"PatientTimelineResponse"}}}}
```

## The PatientTopologyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientTopologyResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/PatientTopologyRow"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"PatientTopologyResponse"},"PatientTopologyRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"patient_id":{"type":"string","title":"Patient Id"},"umap_x":{"type":"number","title":"Umap X"},"umap_y":{"type":"number","title":"Umap Y"},"pca_x":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pca X"},"pca_y":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pca Y"},"pca_z":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pca Z"},"cluster_name":{"type":"string","title":"Cluster Name"},"age_bucket":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Age Bucket"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender"},"nationality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Nationality"},"district":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"District"},"charlson_cci":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Charlson Cci"},"bmi_latest":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Bmi Latest"},"hba1c_latest":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hba1C Latest"},"risk_tier":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Risk Tier"},"y_hat_t2d_1yr":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat T2D 1Yr"},"y_hat_htn_1yr":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Htn 1Yr"},"y_hat_chf_90d":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Chf 90D"},"y_hat_asthma_12mo":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Asthma 12Mo"},"y_hat_ckd_1yr":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Ckd 1Yr"},"y_hat_copd_12mo":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Copd 12Mo"},"y_hat_composite":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Composite"},"emergence_month":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Emergence Month"}},"type":"object","required":["workspace_id","patient_id","umap_x","umap_y","cluster_name"],"title":"PatientTopologyRow"}}}}
```

## The PatientTopologyRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientTopologyRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"patient_id":{"type":"string","title":"Patient Id"},"umap_x":{"type":"number","title":"Umap X"},"umap_y":{"type":"number","title":"Umap Y"},"pca_x":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pca X"},"pca_y":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pca Y"},"pca_z":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pca Z"},"cluster_name":{"type":"string","title":"Cluster Name"},"age_bucket":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Age Bucket"},"gender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gender"},"nationality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Nationality"},"district":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"District"},"charlson_cci":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Charlson Cci"},"bmi_latest":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Bmi Latest"},"hba1c_latest":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Hba1C Latest"},"risk_tier":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Risk Tier"},"y_hat_t2d_1yr":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat T2D 1Yr"},"y_hat_htn_1yr":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Htn 1Yr"},"y_hat_chf_90d":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Chf 90D"},"y_hat_asthma_12mo":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Asthma 12Mo"},"y_hat_ckd_1yr":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Ckd 1Yr"},"y_hat_copd_12mo":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Copd 12Mo"},"y_hat_composite":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Y Hat Composite"},"emergence_month":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Emergence Month"}},"type":"object","required":["workspace_id","patient_id","umap_x","umap_y","cluster_name"],"title":"PatientTopologyRow"}}}}
```

## The PatientsInResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."}}}}
```

## The PerformanceSummaryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PerformanceSummaryResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"total_operators":{"type":"integer","title":"Total Operators"},"online":{"type":"integer","title":"Online"},"busy":{"type":"integer","title":"Busy"},"offline":{"type":"integer","title":"Offline"},"total_escalations_handled":{"type":"integer","title":"Total Escalations Handled"},"avg_handle_time_seconds":{"type":"number","title":"Avg Handle Time Seconds"},"operators":{"items":{"$ref":"#/components/schemas/OperatorPerformanceItem"},"type":"array","title":"Operators"}},"type":"object","required":["workspace_id","total_operators","online","busy","offline","total_escalations_handled","avg_handle_time_seconds","operators"],"title":"PerformanceSummaryResponse"},"OperatorPerformanceItem":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Display name"},"status":{"type":"string","enum":["online","busy","offline"],"title":"Status","description":"Current availability"},"total_escalations_handled":{"type":"integer","title":"Total Escalations Handled","description":"Lifetime escalation count"},"avg_handle_time_seconds":{"type":"number","title":"Avg Handle Time Seconds","description":"Average handle time in seconds"},"last_call_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Call At","description":"ISO-8601 timestamp of last call"}},"type":"object","required":["operator_id","status","total_escalations_handled","avg_handle_time_seconds"],"title":"OperatorPerformanceItem"}}}}
```

## The Period object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."}}}}
```

## The PermissionCatalogResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PermissionCatalogResponse":{"properties":{"roles":{"items":{"$ref":"#/components/schemas/RoleEntry"},"type":"array","title":"Roles"},"permissions":{"items":{"$ref":"#/components/schemas/PermissionEntry"},"type":"array","title":"Permissions"}},"type":"object","required":["roles","permissions"],"title":"PermissionCatalogResponse","description":"The authoritative role→permission model for API-key creation.\n\nServes the server-side source of truth (``DEFAULT_ROLE_DEFINITIONS``) so\nclients (console, SDK) stop hand-copying the matrix and drifting out of\nsync — a drift previously shipped `Data:Query` as a viewer default and\nmade the default create flow 422. Human-facing labels/descriptions for\nindividual permissions stay client-side (pure presentation); this payload\nis authorization truth only."},"RoleEntry":{"properties":{"name":{"type":"string","title":"Name"},"priority":{"type":"integer","title":"Priority"},"description":{"type":"string","title":"Description"},"permission_names":{"items":{"type":"string"},"type":"array","title":"Permission Names"}},"type":"object","required":["name","priority","description","permission_names"],"title":"RoleEntry"},"PermissionEntry":{"properties":{"name":{"type":"string","title":"Name"},"namespace":{"type":"string","title":"Namespace"},"action":{"type":"string","title":"Action"}},"type":"object","required":["name","namespace","action"],"title":"PermissionEntry"}}}}
```

## The PermissionEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PermissionEntry":{"properties":{"name":{"type":"string","title":"Name"},"namespace":{"type":"string","title":"Namespace"},"action":{"type":"string","title":"Action"}},"type":"object","required":["name","namespace","action"],"title":"PermissionEntry"}}}}
```

## The PhiUnverifiedCheck object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"}}}}
```

## The PhoneE164 object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PhoneE164":{"type":"string","maxLength":16,"minLength":2}}}}
```

## The PhoneNumberCallVolume object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PhoneNumberCallVolume":{"properties":{"phone_number":{"type":"string","title":"Phone Number","description":"E.164 phone number"},"total_calls":{"type":"integer","title":"Total Calls","description":"Total calls across the period"},"inbound":{"type":"integer","title":"Inbound","description":"Inbound call count"},"outbound":{"type":"integer","title":"Outbound","description":"Outbound call count"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Average call duration"},"by_date":{"items":{"$ref":"#/components/schemas/DailyCallVolume"},"type":"array","title":"By Date","description":"Daily volume breakdown"}},"type":"object","required":["phone_number","total_calls","inbound","outbound"],"title":"PhoneNumberCallVolume"},"DailyCallVolume":{"properties":{"date":{"type":"string","title":"Date","description":"ISO-8601 date (YYYY-MM-DD)"},"count":{"type":"integer","title":"Count","description":"Number of calls on this date"}},"type":"object","required":["date","count"],"title":"DailyCallVolume","description":"Call volume for a single date."}}}}
```

## The PhonicPronunciation object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"}}}}
```

## The PhonicSessionConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"}}}}
```

## The PhonicVadConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."}}}}
```

## The PinEvidence object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PinEvidence":{"properties":{"result_id":{"type":"string","format":"uuid","title":"Result Id"},"queried_at":{"type":"string","format":"date-time","title":"Queried At"},"dataset_source":{"anyOf":[{"$ref":"#/components/schemas/DemoSource"},{"type":"null"}]},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"rows":{"items":{"items":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"array"},"type":"array","title":"Rows"}},"additionalProperties":false,"type":"object","required":["result_id","queried_at","columns","rows"],"title":"PinEvidence"},"DemoSource":{"properties":{"kind":{"type":"string","const":"published_demo","title":"Kind","default":"published_demo"},"synthetic":{"type":"boolean","const":true,"title":"Synthetic","default":true},"dataset_version":{"type":"string","pattern":"^r[12]_[0-9]{8}_[a-f0-9]{64}$","title":"Dataset Version"},"as_of_date":{"type":"string","format":"date","title":"As Of Date"},"data_through":{"type":"string","format":"date","title":"Data Through"},"event_window_start":{"type":"string","format":"date-time","title":"Event Window Start"},"event_window_end":{"type":"string","format":"date-time","title":"Event Window End"},"observed_before":{"type":"string","format":"date-time","title":"Observed Before"},"recipe_version":{"type":"string","maxLength":100,"minLength":1,"title":"Recipe Version"},"content_sha256":{"type":"string","pattern":"^[a-f0-9]{64}$","title":"Content Sha256"},"logical_table":{"type":"string","title":"Logical Table"},"snapshot_table":{"type":"string","title":"Snapshot Table"},"definitions":{"additionalProperties":{"type":"string"},"type":"object","title":"Definitions"},"table_map":{"additionalProperties":{"$ref":"#/components/schemas/DemoTable"},"type":"object","title":"Table Map"},"definition_records":{"items":{"$ref":"#/components/schemas/DemoDefinition"},"type":"array","title":"Definition Records","default":[]},"event_window_scope":{"anyOf":[{"type":"string","const":"conversations"},{"type":"null"}],"title":"Event Window Scope"}},"additionalProperties":false,"type":"object","required":["dataset_version","as_of_date","data_through","event_window_start","event_window_end","observed_before","recipe_version","content_sha256","logical_table","snapshot_table","definitions"],"title":"DemoSource","description":"Captured provenance, safe to expose with authorized selected evidence."},"DemoTable":{"properties":{"physical_table":{"type":"string","title":"Physical Table"},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"row_count":{"type":"integer","maximum":5000,"minimum":0,"title":"Row Count"},"description":{"type":"string","maxLength":2048,"title":"Description"}},"additionalProperties":false,"type":"object","required":["physical_table","columns","row_count","description"],"title":"DemoTable"},"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"},"DemoDefinition":{"properties":{"id":{"type":"string","maxLength":80,"minLength":1,"title":"Id"},"description":{"type":"string","maxLength":1024,"minLength":1,"title":"Description"},"population":{"type":"string","maxLength":512,"minLength":1,"title":"Population"},"time_basis":{"type":"string","maxLength":512,"minLength":1,"title":"Time Basis"},"units":{"type":"string","maxLength":128,"minLength":1,"title":"Units"}},"additionalProperties":false,"type":"object","required":["id","description","population","time_basis","units"],"title":"DemoDefinition"}}}}
```

## The PinListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PinListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SharedPin"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more","continuation_token"],"title":"PinListResponse"},"SharedPin":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"revision":{"type":"integer","title":"Revision"},"question":{"type":"string","title":"Question"},"block":{"additionalProperties":true,"type":"object","title":"Block"},"source":{"$ref":"#/components/schemas/PinEvidence"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"refreshed_at":{"type":"string","format":"date-time","title":"Refreshed At"},"created_by":{"type":"string","format":"uuid","title":"Created By"},"updated_by":{"type":"string","format":"uuid","title":"Updated By"},"refresh_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Error"},"deleted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deleted At"},"undo_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Undo Until"}},"additionalProperties":false,"type":"object","required":["id","revision","question","block","source","created_at","updated_at","refreshed_at","created_by","updated_by","refresh_error","deleted_at","undo_until"],"title":"SharedPin"},"PinEvidence":{"properties":{"result_id":{"type":"string","format":"uuid","title":"Result Id"},"queried_at":{"type":"string","format":"date-time","title":"Queried At"},"dataset_source":{"anyOf":[{"$ref":"#/components/schemas/DemoSource"},{"type":"null"}]},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"rows":{"items":{"items":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"array"},"type":"array","title":"Rows"}},"additionalProperties":false,"type":"object","required":["result_id","queried_at","columns","rows"],"title":"PinEvidence"},"DemoSource":{"properties":{"kind":{"type":"string","const":"published_demo","title":"Kind","default":"published_demo"},"synthetic":{"type":"boolean","const":true,"title":"Synthetic","default":true},"dataset_version":{"type":"string","pattern":"^r[12]_[0-9]{8}_[a-f0-9]{64}$","title":"Dataset Version"},"as_of_date":{"type":"string","format":"date","title":"As Of Date"},"data_through":{"type":"string","format":"date","title":"Data Through"},"event_window_start":{"type":"string","format":"date-time","title":"Event Window Start"},"event_window_end":{"type":"string","format":"date-time","title":"Event Window End"},"observed_before":{"type":"string","format":"date-time","title":"Observed Before"},"recipe_version":{"type":"string","maxLength":100,"minLength":1,"title":"Recipe Version"},"content_sha256":{"type":"string","pattern":"^[a-f0-9]{64}$","title":"Content Sha256"},"logical_table":{"type":"string","title":"Logical Table"},"snapshot_table":{"type":"string","title":"Snapshot Table"},"definitions":{"additionalProperties":{"type":"string"},"type":"object","title":"Definitions"},"table_map":{"additionalProperties":{"$ref":"#/components/schemas/DemoTable"},"type":"object","title":"Table Map"},"definition_records":{"items":{"$ref":"#/components/schemas/DemoDefinition"},"type":"array","title":"Definition Records","default":[]},"event_window_scope":{"anyOf":[{"type":"string","const":"conversations"},{"type":"null"}],"title":"Event Window Scope"}},"additionalProperties":false,"type":"object","required":["dataset_version","as_of_date","data_through","event_window_start","event_window_end","observed_before","recipe_version","content_sha256","logical_table","snapshot_table","definitions"],"title":"DemoSource","description":"Captured provenance, safe to expose with authorized selected evidence."},"DemoTable":{"properties":{"physical_table":{"type":"string","title":"Physical Table"},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"row_count":{"type":"integer","maximum":5000,"minimum":0,"title":"Row Count"},"description":{"type":"string","maxLength":2048,"title":"Description"}},"additionalProperties":false,"type":"object","required":["physical_table","columns","row_count","description"],"title":"DemoTable"},"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"},"DemoDefinition":{"properties":{"id":{"type":"string","maxLength":80,"minLength":1,"title":"Id"},"description":{"type":"string","maxLength":1024,"minLength":1,"title":"Description"},"population":{"type":"string","maxLength":512,"minLength":1,"title":"Population"},"time_basis":{"type":"string","maxLength":512,"minLength":1,"title":"Time Basis"},"units":{"type":"string","maxLength":128,"minLength":1,"title":"Units"}},"additionalProperties":false,"type":"object","required":["id","description","population","time_basis","units"],"title":"DemoDefinition"}}}}
```

## The PinRevisionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PinRevisionRequest":{"properties":{"revision":{"type":"integer","minimum":1,"title":"Revision"}},"additionalProperties":false,"type":"object","required":["revision"],"title":"PinRevisionRequest"}}}}
```

## The PinningService object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PinningService":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"The service's id."},"name":{"type":"string","title":"Name","description":"The service's name."},"version_sets":{"items":{"$ref":"#/components/schemas/PinningVersionSet"},"type":"array","title":"Version Sets"}},"type":"object","required":["id","name","version_sets"],"title":"PinningService"},"PinningVersionSet":{"properties":{"name":{"type":"string","title":"Name","description":"The version set's name."},"version":{"type":"integer","title":"Version","description":"The version of the set it runs."},"enabled":{"type":"boolean","title":"Enabled"},"states":{"items":{"type":"string"},"type":"array","title":"States","description":"The states it applies in. Empty: every one."}},"type":"object","required":["name","version","enabled","states"],"title":"PinningVersionSet"}}}}
```

## The PinningVersionSet object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PinningVersionSet":{"properties":{"name":{"type":"string","title":"Name","description":"The version set's name."},"version":{"type":"integer","title":"Version","description":"The version of the set it runs."},"enabled":{"type":"boolean","title":"Enabled"},"states":{"items":{"type":"string"},"type":"array","title":"States","description":"The states it applies in. Empty: every one."}},"type":"object","required":["name","version","enabled","states"],"title":"PinningVersionSet"}}}}
```

## The PipelineStatusResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PipelineStatusResponse":{"properties":{"total_events":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Events","description":"Read-model event count for the last 7 days. Null means the read model is empty or unavailable; zero means the read model is ready and has no events."},"event_read_model_status":{"type":"string","enum":["ready","empty","unavailable"],"title":"Event Read Model Status","default":"empty"},"event_read_model_synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Event Read Model Synced At"},"total_entities":{"type":"integer","title":"Total Entities","default":0}},"type":"object","title":"PipelineStatusResponse"}}}}
```

## The PlatformRole object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PlatformRole":{"type":"string","enum":["owner","admin","member","operator","viewer"],"title":"PlatformRole"}}}}
```

## The PlaybackTimeline object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PlaybackTimeline":{"properties":{"turns":{"items":{"$ref":"#/components/schemas/TurnTimeline"},"type":"array","title":"Turns"},"segments":{"items":{"$ref":"#/components/schemas/TimelineSegment"},"type":"array","title":"Segments"},"duration_seconds":{"type":"number","title":"Duration Seconds"},"timebase":{"anyOf":[{"$ref":"#/components/schemas/TimelineTimebase"},{"type":"null"}],"description":"Canonical timebase shared by waveform, overlays, seek state, zoom, and scroll transforms."},"lanes":{"items":{"$ref":"#/components/schemas/TimelineLaneDefinition"},"type":"array","title":"Lanes","description":"Canonical actor/system lane model. Every segment lane_id resolves against this collection.","default":[]},"total_user_speech_seconds":{"type":"number","title":"Total User Speech Seconds","default":0},"total_agent_speech_seconds":{"type":"number","title":"Total Agent Speech Seconds","default":0},"total_silence_seconds":{"type":"number","title":"Total Silence Seconds","default":0},"avg_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Processing Gap Ms"},"max_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Max Processing Gap Ms"},"avg_perceived_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Perceived Latency Ms"}},"type":"object","required":["turns","segments","duration_seconds"],"title":"PlaybackTimeline"},"TurnTimeline":{"properties":{"turn_index":{"type":"integer","title":"Turn Index","description":"The turn: its index in the response's ``turns`` on ``GET /conversations/{conversation_id}``,\nthe call-detail row the timeline was built from on ``GET /calls/{call_id}``."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on a turn\nbefore the first exchange."},"seek_to":{"type":"number","title":"Seek To"},"active_start":{"type":"number","title":"Active Start"},"active_end":{"type":"number","title":"Active End"}},"type":"object","required":["turn_index","seek_to","active_start","active_end"],"title":"TurnTimeline"},"TimelineSegment":{"properties":{"type":{"type":"string","enum":["agent_speech","barge_in","caller_speech","filler","filler_hesitation","filler_nav","greeting","interrupted_speech","processing_gap","silence","silence_check","state_transition","tool_call"],"title":"Type"},"lane":{"type":"string","enum":["agent","caller","events","operator","system","tool"],"title":"Lane"},"track":{"anyOf":[{"type":"string","enum":["agent","caller","operator","system","tool"]},{"type":"null"}],"title":"Track","description":"Actor-semantic display track for the segment. Inferred for legacy producers."},"lane_id":{"anyOf":[{"type":"string","maxLength":160,"minLength":1},{"type":"null"}],"title":"Lane Id","description":"Canonical lane id. Must match PlaybackTimeline.lanes[].id after platform normalization."},"order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Order","description":"Canonical event order after platform time/lane normalization."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor responsible for the segment. Inferred for legacy producers."},"start":{"type":"number","title":"Start"},"end":{"type":"number","title":"End"},"label":{"type":"string","title":"Label"},"turn_index":{"type":"integer","title":"Turn Index","description":"The segment's turn: its index in the response's ``turns`` on\n``GET /conversations/{conversation_id}``, the call-detail row the timeline was built from on\n``GET /calls/{call_id}``, or -1 when no turn owns it (a silence, a barge-in)."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the segment's turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on segments no\nexchange owns."},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eot Confidence"},"audio_window_start":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window Start"},"audio_window_end":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window End"},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Render Ms"},"audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Ttfb Ms"},"e2e_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"E2E Ttfb Ms"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"parent_call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Call Id"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"from_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From State"},"to_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"To State"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"}},"type":"object","required":["type","lane","start","end","label","turn_index"],"title":"TimelineSegment"},"TimelineActor":{"properties":{"kind":{"type":"string","enum":["agent","human","operator","system","tool"],"title":"Kind"},"role":{"type":"string","enum":["agent","caller","operator","runtime","state","tool"],"title":"Role"},"label":{"type":"string","title":"Label"},"participant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Id"}},"type":"object","required":["kind","role","label"],"title":"TimelineActor"},"TimelineTimebase":{"properties":{"unit":{"type":"string","const":"seconds","title":"Unit","description":"Timeline offsets are always seconds.","default":"seconds"},"origin":{"type":"string","enum":["media_start","call_start","synthetic"],"title":"Origin","description":"Zero point used for segment start/end offsets.","default":"media_start"},"start":{"type":"number","title":"Start","description":"Visible/canonical timeline range start in seconds.","default":0},"end":{"type":"number","title":"End","description":"Visible/canonical timeline range end in seconds.","default":0}},"type":"object","title":"TimelineTimebase"},"TimelineLaneDefinition":{"properties":{"id":{"type":"string","maxLength":160,"minLength":1,"title":"Id","description":"Stable canonical lane id used by timeline visualizations. Segments attach via TimelineSegment.lane_id; consumers should not re-infer lanes from CSS or pixel positions."},"track":{"type":"string","enum":["agent","caller","operator","system","tool"],"title":"Track","description":"High-level actor-semantic track for styling and grouping."},"label":{"type":"string","title":"Label","description":"Display label for the lane."},"order":{"type":"integer","title":"Order","description":"Stable vertical order within the timeline lane model."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor represented by this lane when applicable."}},"type":"object","required":["id","track","label","order"],"title":"TimelineLaneDefinition"}}}}
```

## The Policies object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Policies":{"properties":{"forward_call_configured":{"type":"boolean","title":"Forward Call Configured"},"warm_transfer":{"type":"boolean","title":"Warm Transfer"},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss"},"hours_configured":{"type":"boolean","title":"Hours Configured"},"default_destination_configured":{"type":"boolean","title":"Default Destination Configured","description":"A dynamic service names the line a transfer dials when the agent names none."},"transfer_reasons":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Transfer Reasons","description":"The keys of the reasons every forward_call names and the call records, empty when none."},"destination_hours_configured":{"type":"boolean","title":"Destination Hours Configured"},"verification_callers_configured":{"type":"boolean","title":"Verification Callers Configured"},"unsupported_language_route":{"type":"boolean","title":"Unsupported Language Route"}},"type":"object","required":["forward_call_configured","warm_transfer","warm_transfer_on_queue","warm_transfer_on_miss","hours_configured","default_destination_configured","transfer_reasons","destination_hours_configured","verification_callers_configured","unsupported_language_route"],"title":"Policies"},"ReadinessLabel":{"type":"string"}}}}
```

## The PolicyRef object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."}}}}
```

## The PriorityQueueItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PriorityQueueItem":{"properties":{"call_sid":{"type":"string","title":"Call Sid","description":"Twilio call SID"},"caller_id":{"type":"string","title":"Caller Id","description":"Caller phone number","default":""},"caller_phone":{"anyOf":[{"type":"string","maxLength":16,"pattern":"^\\+[1-9]\\d{1,14}$"},{"type":"null"}],"title":"Caller Phone","description":"Caller E.164 phone number for console clients"},"service_id":{"type":"string","title":"Service Id","description":"Service ID handling the call","default":""},"service_name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Human-readable service name when available"},"direction":{"type":"string","enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","description":"Call direction","default":"inbound"},"data_quality_flags":{"items":{"type":"string","enum":["invalid_direction","intel_unavailable"]},"type":"array","title":"Data Quality Flags","default":[]},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When the active call started"},"priority_score":{"type":"number","maximum":1,"minimum":0,"title":"Priority Score","description":"Priority score from 0.0 to 1.0; its weights reach 0.85"},"priority_reasons":{"items":{"type":"string","enum":["high_risk","long_wait","safety_concern","looping"]},"type":"array","title":"Priority Reasons","default":[]},"wait_seconds":{"type":"number","title":"Wait Seconds","default":0},"risk_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Risk Score"},"risk_level":{"anyOf":[{"type":"string","enum":["low","medium","high","critical"]},{"type":"null"}],"title":"Risk Level"},"current_state":{"type":"string","title":"Current State","default":""},"turn_count":{"type":"integer","title":"Turn Count","default":0},"escalation_active":{"type":"boolean","title":"Escalation Active","default":false},"entity_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Name"},"brief_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brief Context"}},"type":"object","required":["call_sid","priority_score"],"title":"PriorityQueueItem","description":"An active call ranked by operator priority."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The PriorityQueueResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PriorityQueueResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"queue":{"items":{"$ref":"#/components/schemas/PriorityQueueItem"},"type":"array","title":"Queue"},"total_active":{"type":"integer","title":"Total Active"}},"type":"object","required":["workspace_id","queue","total_active"],"title":"PriorityQueueResponse"},"PriorityQueueItem":{"properties":{"call_sid":{"type":"string","title":"Call Sid","description":"Twilio call SID"},"caller_id":{"type":"string","title":"Caller Id","description":"Caller phone number","default":""},"caller_phone":{"anyOf":[{"type":"string","maxLength":16,"pattern":"^\\+[1-9]\\d{1,14}$"},{"type":"null"}],"title":"Caller Phone","description":"Caller E.164 phone number for console clients"},"service_id":{"type":"string","title":"Service Id","description":"Service ID handling the call","default":""},"service_name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Human-readable service name when available"},"direction":{"type":"string","enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","description":"Call direction","default":"inbound"},"data_quality_flags":{"items":{"type":"string","enum":["invalid_direction","intel_unavailable"]},"type":"array","title":"Data Quality Flags","default":[]},"started_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Started At","description":"When the active call started"},"priority_score":{"type":"number","maximum":1,"minimum":0,"title":"Priority Score","description":"Priority score from 0.0 to 1.0; its weights reach 0.85"},"priority_reasons":{"items":{"type":"string","enum":["high_risk","long_wait","safety_concern","looping"]},"type":"array","title":"Priority Reasons","default":[]},"wait_seconds":{"type":"number","title":"Wait Seconds","default":0},"risk_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Risk Score"},"risk_level":{"anyOf":[{"type":"string","enum":["low","medium","high","critical"]},{"type":"null"}],"title":"Risk Level"},"current_state":{"type":"string","title":"Current State","default":""},"turn_count":{"type":"integer","title":"Turn Count","default":0},"escalation_active":{"type":"boolean","title":"Escalation Active","default":false},"entity_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Name"},"brief_context":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Brief Context"}},"type":"object","required":["call_sid","priority_score"],"title":"PriorityQueueItem","description":"An active call ranked by operator priority."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ProductionEvalDefinition object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ProductionEvalDefinition":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"expected":{"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"active":{"type":"boolean","title":"Active","default":true},"is_default":{"type":"boolean","title":"Is Default","description":"True for a metric's All services default, which the platform creates. It can only be paused or resumed with active, and the post-call evaluation doesn't run it. A standard metric's default can't be deleted; deleting a custom metric's default unassigns the metric.","default":false},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["workspace_id","eval_key","eval_type"],"title":"ProductionEvalDefinition","description":"An eval (assertion or metric-eval) that runs against a workspace's live\ncalls — the production analogue of a sim case's ``evals``. ``service_id``\nNone applies to every service in the workspace. ``expected`` is JSON: a\nphrase string for assertions, or a ``{gte|lte|equals|...}`` threshold for\nmetric-evals."}}}}
```

## The ProductionEvalDefinitionListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ProductionEvalDefinitionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ProductionEvalDefinition"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ProductionEvalDefinitionListResponse"},"ProductionEvalDefinition":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"expected":{"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"active":{"type":"boolean","title":"Active","default":true},"is_default":{"type":"boolean","title":"Is Default","description":"True for a metric's All services default, which the platform creates. It can only be paused or resumed with active, and the post-call evaluation doesn't run it. A standard metric's default can't be deleted; deleting a custom metric's default unassigns the metric.","default":false},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["workspace_id","eval_key","eval_type"],"title":"ProductionEvalDefinition","description":"An eval (assertion or metric-eval) that runs against a workspace's live\ncalls — the production analogue of a sim case's ``evals``. ``service_id``\nNone applies to every service in the workspace. ``expected`` is JSON: a\nphrase string for assertions, or a ``{gte|lte|equals|...}`` threshold for\nmetric-evals."}}}}
```

## The ProductionEvalResultListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ProductionEvalResultListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/src__routes__production_eval_results__ProductionEvalResultListResponse__Item"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ProductionEvalResultListResponse"},"src__routes__production_eval_results__ProductionEvalResultListResponse__Item":{"properties":{"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id","description":"The conversation the verdict is for."},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"The conversation's call SID, when it has one."},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"The service the check is assigned to. Null when the check applies to every service."},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status","description":"How the check graded the conversation: `passed`, `failed`, `skipped` (no pass or fail: the grader found no\nanswer, or the check has no pass rule), `error` (the check could not run) or `pending`."},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed","description":"True for `passed`, false for `failed` and null for every other status. The pass rate counts the verdicts\nwhere this isn't null."},"value":{"title":"Value","description":"What the check observed: the metric's value, a number, a boolean or a label. Null when it observed none, and\nfor the older checks that aren't metrics."},"rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rationale","description":"Why the value passed or failed the check's rule, or why there is no pass or fail."},"justification":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Justification","description":"The grader's explanation of the value. It can quote the conversation."},"cited_turns":{"items":{"type":"integer"},"type":"array","title":"Cited Turns","description":"The turns of the conversation that `justification` cites, by turn number."},"computed_at":{"type":"string","format":"date-time","title":"Computed At","description":"When the verdict was last computed. Evaluating a conversation again replaces its verdict."}},"type":"object","required":["conversation_id","call_sid","service_id","status","passed","value","rationale","justification","cited_turns","computed_at"],"title":"Item","description":"One conversation's verdict on the eval, with the reasoning behind it."}}}}
```

## The ProductionEvalType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ProductionEvalType":{"type":"string","enum":["metric"],"title":"ProductionEvalType"}}}}
```

## The ProgressHint object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."}}}}
```

## The PromoteServiceConfigurationRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PromoteServiceConfigurationRequest":{"properties":{"request_id":{"type":"string","format":"uuid","title":"Request Id","description":"The caller's own id for this promotion. A retry sends the same id with the same request."},"expected_updated_at":{"type":"string","format":"date-time","title":"Expected Updated At","description":"The service's `updated_at` the review was made at, exactly as the service returned it."},"reviewed_base":{"items":{"$ref":"#/components/schemas/ReviewedVersionSet"},"type":"array","maxItems":20,"minItems":1,"title":"Reviewed Base","description":"Every version set the review covered. Each has to be a set the service has, and each digest has to be the one\na session of the set would load when the promotion commits."},"target_version_set":{"type":"string","maxLength":40,"minLength":1,"title":"Target Version Set","description":"The version set the candidate is stored as, `release` for the set sessions run by default."},"version_set":{"$ref":"#/components/schemas/VersionSet-Input","description":"The candidate. It names its agent version, and its context graph version when the service binds a context\ngraph: a set that follows the latest version of either is refused. A service that binds no context graph has no\ngraph version to name."},"harness_pins":{"anyOf":[{"items":{"$ref":"#/components/schemas/HarnessPin"},"type":"array","maxItems":20},{"type":"null"}],"title":"Harness Pins","description":"The service's harness pins, replacing the ones it has. Left out, the pins stay as they are."},"settings":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/SettingValue"},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":200},{"type":"null"}],"title":"Settings","description":"The service's harness settings, replacing the ones it has. Left out, the settings stay as they are."}},"type":"object","required":["request_id","expected_updated_at","reviewed_base","target_version_set","version_set"],"title":"PromoteServiceConfigurationRequest"},"ReviewedVersionSet":{"properties":{"version_set":{"type":"string","maxLength":40,"minLength":1,"title":"Version Set"},"service_config_digest":{"type":"string","maxLength":71,"pattern":"^sha256:[0-9a-f]{64}$","title":"Service Config Digest","description":"The `service_config_digest` `GET .../configuration-identity` answered for the set, which a run of it records."}},"type":"object","required":["version_set","service_config_digest"],"title":"ReviewedVersionSet","description":"One version set the caller reviewed, by the digest of the configuration a session of it loaded."},"VersionSet-Input":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"HarnessPin":{"properties":{"repo":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag","description":"A release tag of the harness, e.g. ``grok_voice-v1.2.0`` or ``grok_voice-v1.2.0-hotfix.1``, or ``in-tree``."},"asset":{"anyOf":[{"type":"string","maxLength":256,"minLength":1},{"type":"null"}],"title":"Asset","description":"The wheel's file name on the release."},"sha256":{"anyOf":[{"$ref":"#/components/schemas/Sha256"},{"type":"null"}]},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"A policy release registered in `policy_releases.json`, named exactly by `repo`, `tag`, `asset` and `sha256`:\nthe values the harness runs. Independent of the release, so `in-tree` can name one. Left out, a pin runs the\ndefault's policy, and a default names none. Stored and audited without the key when left out."},"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","maxLength":64,"minLength":1,"title":"Harness","description":"A voice family (``grok_voice``, ``gpt_live``, ...) or a text provider family (``openai``, ``anthropic``, ...)."}},"type":"object","required":["tag","kind","harness"],"title":"HarnessPin"},"Sha256":{"type":"string"},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."},"HarnessKind":{"type":"string","enum":["voice","text"]},"SettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]}}}}
```

## The PromoteSessionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PromoteSessionResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id","description":"The coverage run the session is now bound to"},"session_id":{"type":"string","title":"Session Id","description":"The promoted session id (unchanged)"},"already_bound":{"type":"boolean","title":"Already Bound","description":"True when the session was already run-scoped; the existing run is returned unchanged"}},"type":"object","required":["run_id","session_id","already_bound"],"title":"PromoteSessionResponse","description":"Result of binding a run-less session to a (newly created) coverage run."}}}}
```

## The PromptLogEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PromptLogEntry":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"prompt_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Type"},"turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turn Index","description":"Counts the prompts one engine instance rendered: every engage render (a user turn, each tool round, a check-in) adds one, and it starts again at 0 when the engine is rebuilt, which on text is every request. It repeats within a conversation and names no turn: join on ``turn_id`` or ``engine_turn_id``."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The user exchange this prompt was rendered for: the same ``turn_id`` the conversation's turns carry (``GET /conversations/{conversation_id}/turns``). Every render in one exchange, tool rounds included, shares it. Null before the conversation's first user message, for a session with no stored turns, and on logs written before this field."},"engine_turn_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Engine Turn Id","description":"The engine turn that rendered this prompt (32 hex characters): the user turn, or one tool round within it, so each tool round's prompt has its own. Null on logs written before this field."},"system_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"System Prompt"},"history":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"History"},"full_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Prompt"},"rendered_prompt_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rendered Prompt Hash"},"prompt_renderer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Renderer"},"llm_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Model"},"llm_response":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Response"},"state_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Name"},"action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"},"tool_names":{"items":{"type":"string"},"type":"array","title":"Tool Names","description":"The tools the agent's state offered when the prompt rendered."},"has_tools":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Tools"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"data_parse_error":{"type":"boolean","title":"Data Parse Error","default":false}},"type":"object","required":["event_id","workspace_id"],"title":"PromptLogEntry","description":"One ``prompt_log`` event projection — full LLM input + output for a turn.\n\nUnbounded string fields (``system_prompt``, ``full_prompt``,\n``llm_response``) reflect the producer's payload as-is — typically\n1-50 KB each, occasionally larger for long histories. SDK consumers\nshould not assume a max length."}}}}
```

## The PromptLogListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PromptLogListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/PromptLogEntry"},"type":"array","title":"Items"},"count":{"type":"integer","minimum":0,"title":"Count"},"has_more":{"type":"boolean","title":"Has More"},"next_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Offset","description":"Pass back as offset to fetch the next page; null when has_more is false"},"applied_time_window_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Applied Time Window Days","description":"Auto-applied time bound (in days) when no call_sid/from_ts/to_ts was passed. Null when the caller supplied an explicit selectivity-bearing filter."},"resolved_call_sid":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Resolved Call Sid","description":"When ``conversation_id`` was supplied, the ``call_sid`` it resolved to: the call SID of a voice call, the conversation's id for a text conversation. Useful for callers that drill into per-call surfaces afterward. Null when the caller filtered by ``call_sid`` directly, did not filter by conversation, or named a voice call with no recorded call SID."},"resolved_conversation_kind":{"anyOf":[{"type":"string","enum":["call","conversation"]},{"type":"null"}],"title":"Resolved Conversation Kind","description":"What ``conversation_id`` named when it was supplied: ``call`` for a voice call, ``conversation`` for a text conversation (web, sms, whatsapp, email). Null otherwise."}},"type":"object","required":["items","count","has_more"],"title":"PromptLogListResponse"},"PromptLogEntry":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"effective_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective At"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"prompt_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Type"},"turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turn Index","description":"Counts the prompts one engine instance rendered: every engage render (a user turn, each tool round, a check-in) adds one, and it starts again at 0 when the engine is rebuilt, which on text is every request. It repeats within a conversation and names no turn: join on ``turn_id`` or ``engine_turn_id``."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The user exchange this prompt was rendered for: the same ``turn_id`` the conversation's turns carry (``GET /conversations/{conversation_id}/turns``). Every render in one exchange, tool rounds included, shares it. Null before the conversation's first user message, for a session with no stored turns, and on logs written before this field."},"engine_turn_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Engine Turn Id","description":"The engine turn that rendered this prompt (32 hex characters): the user turn, or one tool round within it, so each tool round's prompt has its own. Null on logs written before this field."},"system_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"System Prompt"},"history":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"History"},"full_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Full Prompt"},"rendered_prompt_hash":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rendered Prompt Hash"},"prompt_renderer":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Prompt Renderer"},"llm_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Model"},"llm_response":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Llm Response"},"state_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Name"},"action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action"},"tool_names":{"items":{"type":"string"},"type":"array","title":"Tool Names","description":"The tools the agent's state offered when the prompt rendered."},"has_tools":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Tools"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"data_parse_error":{"type":"boolean","title":"Data Parse Error","default":false}},"type":"object","required":["event_id","workspace_id"],"title":"PromptLogEntry","description":"One ``prompt_log`` event projection — full LLM input + output for a turn.\n\nUnbounded string fields (``system_prompt``, ``full_prompt``,\n``llm_response``) reflect the producer's payload as-is — typically\n1-50 KB each, occasionally larger for long histories. SDK consumers\nshould not assume a max length."}}}}
```

## The PromptPreviewContext-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PromptPreviewContext-Input":{"properties":{"state_name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"action":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"language":{"$ref":"#/components/schemas/NameString"},"crisis_resource":{"$ref":"#/components/schemas/DescriptionString"},"has_tools":{"type":"boolean","title":"Has Tools"},"has_write_tools":{"type":"boolean","title":"Has Write Tools"},"transfer_offered":{"type":"boolean","title":"Transfer Offered"},"message_tool":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tools":{"anyOf":[{"items":{"$ref":"#/components/schemas/Tool"},"type":"array","maxItems":100,"minItems":1},{"type":"null"}],"title":"Tools"}},"type":"object","required":["language","crisis_resource","has_tools","has_write_tools","transfer_offered"],"title":"PromptPreviewContext"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"Tool":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"description":{"$ref":"#/components/schemas/DescriptionString"}},"type":"object","required":["name","description"],"title":"Tool"}}}}
```

## The PromptPreviewContext-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PromptPreviewContext-Output":{"properties":{"state_name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"action":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"language":{"$ref":"#/components/schemas/NameString"},"crisis_resource":{"$ref":"#/components/schemas/DescriptionString"},"has_tools":{"type":"boolean","title":"Has Tools"},"has_write_tools":{"type":"boolean","title":"Has Write Tools"},"transfer_offered":{"type":"boolean","title":"Transfer Offered"},"message_tool":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tools":{"anyOf":[{"items":{"$ref":"#/components/schemas/Tool"},"type":"array","maxItems":100,"minItems":1},{"type":"null"}],"title":"Tools"}},"type":"object","required":["language","crisis_resource","has_tools","has_write_tools","transfer_offered"],"title":"PromptPreviewContext"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"Tool":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"description":{"$ref":"#/components/schemas/DescriptionString"}},"type":"object","required":["name","description"],"title":"Tool"}}}}
```

## The PromptPreviewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PromptPreviewResponse":{"properties":{"family":{"type":"string","enum":["cascade","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"],"title":"Family"},"version_set":{"$ref":"#/components/schemas/NameString"},"agent_version":{"type":"integer","title":"Agent Version"},"context_graph_version":{"type":"integer","title":"Context Graph Version"},"state_name":{"$ref":"#/components/schemas/NameString"},"instructions":{"type":"string","title":"Instructions"},"renderer":{"$ref":"#/components/schemas/NameString"},"context":{"$ref":"#/components/schemas/PromptPreviewContext-Output"}},"type":"object","required":["family","version_set","agent_version","context_graph_version","state_name","instructions","renderer","context"],"title":"PromptPreviewResponse"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"PromptPreviewContext-Output":{"properties":{"state_name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"action":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"language":{"$ref":"#/components/schemas/NameString"},"crisis_resource":{"$ref":"#/components/schemas/DescriptionString"},"has_tools":{"type":"boolean","title":"Has Tools"},"has_write_tools":{"type":"boolean","title":"Has Write Tools"},"transfer_offered":{"type":"boolean","title":"Transfer Offered"},"message_tool":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tools":{"anyOf":[{"items":{"$ref":"#/components/schemas/Tool"},"type":"array","maxItems":100,"minItems":1},{"type":"null"}],"title":"Tools"}},"type":"object","required":["language","crisis_resource","has_tools","has_write_tools","transfer_offered"],"title":"PromptPreviewContext"},"DescriptionString":{"type":"string","maxLength":2000},"Tool":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"description":{"$ref":"#/components/schemas/DescriptionString"}},"type":"object","required":["name","description"],"title":"Tool"}}}}
```

## The ProviderFamily object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ProviderFamily":{"type":"string","enum":["anthropic","google","openai","xai"]}}}}
```

## The ProviderType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ProviderType":{"type":"string","enum":["twilio","websocket","ses","sendblue","meta"],"title":"ProviderType","description":"Messaging provider that implements a channel.\n\nMultiple providers may serve the same ChannelKind."}}}}
```

## The ProvisionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ProvisionResponse":{"properties":{"workspace":{"$ref":"#/components/schemas/WorkspaceResponse"}},"type":"object","required":["workspace"],"title":"ProvisionResponse"},"WorkspaceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"backend_org_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Backend Org Id"},"membership_provisioning":{"type":"string","enum":["domain_policies","explicit"],"title":"Membership Provisioning"},"region":{"type":"string","title":"Region"},"connector_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connector Type"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"topic_modeling_enabled":{"type":"boolean","title":"Topic Modeling Enabled"},"delta_sharing_enabled":{"type":"boolean","title":"Delta Sharing Enabled"},"delta_sharing_mode":{"type":"string","enum":["open","databricks"],"title":"Delta Sharing Mode"},"delta_sharing_identifier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delta Sharing Identifier"},"provisioned_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Provisioned At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","slug","name","backend_org_id","membership_provisioning","region","connector_type","timezone","topic_modeling_enabled","delta_sharing_enabled","delta_sharing_mode","delta_sharing_identifier","provisioned_at","created_at","updated_at"],"title":"WorkspaceResponse"}}}}
```

## The PutMetricDefinitionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PutMetricDefinitionRequest":{"properties":{"definition":{"$ref":"#/components/schemas/MetricDefinition"},"expected_revision":{"type":"integer","minimum":0,"title":"Expected Revision","description":"The revision the caller read; 0 for a key with none."},"note":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Note"}},"type":"object","required":["definition","expected_revision"],"title":"PutMetricDefinitionRequest"},"MetricDefinition":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Key","description":"Lowercase slug used as metric key (e.g. 'voice_quality_score')"},"name":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"metric_type":{"type":"string","enum":["numerical","categorical","boolean"],"title":"Metric Type"},"latency_tier":{"type":"string","enum":["streaming","near_realtime","batch"],"title":"Latency Tier","description":"'streaming': seconds of latency, fed continuously as events arrive. 'near_realtime': minutes of latency, refreshed on a trigger. 'batch': refreshed hourly or daily on a schedule (default, cheapest).","default":"batch"},"period_granularity":{"type":"string","enum":["hourly","daily"],"title":"Period Granularity","description":"'hourly' — one row per workspace per hour. Use for near_realtime metrics where shift-level visibility matters (voice quality, latency). 'daily' — one row per workspace per day (default, cheapest).","default":"daily"},"source":{"type":"string","enum":["call_intelligence","world_events","surface_events","connector_events","zerobus_events","voice_judge_results","custom"],"title":"Source","description":"Source key for the producer that supplies this metric. Built-ins include 'call_intelligence', 'world_events', and 'surface_events'. Use 'custom' with custom_source_key for extension producers."},"custom_source_key":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Custom Source Key","description":"Extension source key used only when source='custom'."},"event_types":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Event Types","description":"Event types to scan (e.g. 'call.outcome', 'surface.submitted'). For call_intelligence source, use pseudo-types: 'call_intelligence.row'."},"source_filter":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Filter","description":"Optional SQL WHERE fragment for additional filtering (e.g. \"source = 'voice_agent'\"). Applied after event_type filter."},"extraction_mode":{"type":"string","enum":["static","ai_classify","ai_extract","ai_query","sql_expr"],"title":"Extraction Mode","description":"'static' — JSONB path extraction (fast, free). 'ai_classify' — AI classification into user-defined labels (free). 'ai_extract' — AI field extraction from text (free). 'ai_query' — LLM-powered extraction with custom prompt (uses model_tier). 'sql_expr' — Raw SQL expression for computed metrics.","default":"static"},"extract_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Extract Path","description":"JSON path for static extraction (e.g. `$.quality_score`, `$.risk_level`). For `call_intelligence` and `world_events`, single-segment paths resolve to typed columns when available and fall back to JSONB extraction otherwise. Used when `extraction_mode='static'`."},"ai_labels":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":500},{"type":"null"}],"title":"Ai Labels","description":"Labels for ai_classify, the allowed answers of a categorical ai_query metric, or field names for ai_extract. Required when extraction_mode='ai_classify' or 'ai_extract'. Examples: ['positive', 'negative', 'neutral'] or ['diagnosis', 'medication']."},"ai_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ai Schema","description":"Extraction schema for ai_extract. Required when extraction_mode='ai_extract'."},"ai_query_endpoint":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Ai Query Endpoint","description":"Model serving endpoint for ai_query. Optional — if omitted, platform resolves from model_tier automatically. Override for custom endpoints."},"ai_query_prompt":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Ai Query Prompt","description":"Prompt template for ai_query. Use {data} placeholder for event data. Example: 'Classify this call transcript into one of: {labels}. Transcript: {data}'. Budgeted at 8KB to hold the full rubric + output spec for standard quality judges (longest authored rubric — conversational_naturalness — is ~5KB)."},"sql_expression":{"anyOf":[{"type":"string","maxLength":1000},{"type":"null"}],"title":"Sql Expression","description":"Raw SQL expression evaluated in pipeline context. Has access to all columns in the source table. Example: 'CASE WHEN duration_seconds > 120 THEN 1.0 ELSE 0.0 END'. Required when extraction_mode='sql_expr'."},"aggregation":{"type":"string","enum":["count","sum","avg","min","max","count_distinct","ratio","rate"],"title":"Aggregation","description":"How to aggregate extracted values per workspace per period. 'ratio' requires ratio_numerator_event and ratio_denominator_event. 'rate' computes count(true) / count(all) for boolean metrics.","default":"count"},"ratio_numerator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Numerator Event","description":"Event type for numerator when aggregation='ratio'."},"ratio_denominator_event":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ratio Denominator Event","description":"Event type for denominator when aggregation='ratio'."},"valid_range_min":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Min","description":"Minimum valid value for numerical metrics. Pipeline drops values outside range."},"valid_range_max":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Valid Range Max","description":"Maximum valid value for numerical metrics."},"freshness_sla_minutes":{"type":"integer","maximum":1440,"minimum":5,"title":"Freshness Sla Minutes","description":"Max acceptable staleness in minutes before alerting. Default: 60 (1 hour).","default":60},"unit":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Unit","description":"Display unit (e.g. 'score', 'minutes', '%', 'count')."},"categories":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":100},{"type":"null"}],"title":"Categories","description":"Allowed values for categorical metrics. Pipeline drops values not in this list when set. An ai_query metric reads ai_labels instead, and falls back to categories only when ai_labels is empty."},"model_tier":{"type":"string","enum":["free","fast","balanced","max","custom"],"title":"Model Tier","description":"AI model tier for extraction quality/cost tradeoff. 'free' — platform managed models (ai_classify, ai_extract). 'fast' — optimized for simple classification, low latency. 'balanced' — quality scoring, moderate reasoning. 'max' — complex analysis, multi-step reasoning. 'custom' — use ai_query_endpoint directly. When extraction_mode='ai_query' and ai_query_endpoint is not set, platform resolves model_tier to the optimal model automatically.","default":"free"},"channel_scope":{"type":"string","enum":["all","voice","text","surface","inbound","outbound"],"title":"Channel Scope","description":"Business-logic channel filter. 'voice' — voice calls only. 'text' — SMS/text sessions. 'surface' — form submissions. 'inbound'/'outbound' — by direction. 'all' — no channel filter (default). Pipeline translates to appropriate source + event_type filters.","default":"all"},"applies_to_product_types":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Applies To Product Types","description":"Product types this metric applies to (matches service tags, e.g. 'scheduling', 'outbound', 'coaching', 'intake', 'triage', 'support'). When set, the metric only computes for calls belonging to services whose config.tags include one of these keys. When None (default), the metric applies to every service regardless of product type."},"prompt":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Prompt","description":"Rubric prompt for LLM judge evaluation with {$.path} context variables. Each {$.path} reference is extracted from the entity's projected state and substituted before sending to ai_query. The prompt is both the evaluation criteria and the context specification."},"granularity":{"type":"string","enum":["aggregate","per_entity"],"title":"Granularity","description":"'aggregate' groups by (workspace, period) — one value per time bucket. 'per_entity' keeps entity_id — one value per entity (call, encounter). Judge metrics are typically per_entity. Computed metrics are typically aggregate.","default":"aggregate"},"tags":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":20},{"type":"null"}],"title":"Tags","description":"Up to 20 slugs (lowercase letters, digits, '-' and '_', at most 64 characters each)."},"notes":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Notes","description":"Free-text notes about the definition."},"active":{"type":"boolean","title":"Active","default":true},"builtin":{"type":"boolean","title":"Builtin","description":"True for platform-provided metrics (read-only key).","default":false}},"type":"object","required":["key","name","metric_type","source","event_types"],"title":"MetricDefinition","description":"A metric the platform computes for a workspace: what to extract from events, and how to aggregate it.\n\nBuilt-in metrics ship with every workspace. Custom metrics are defined per workspace through the settings\nAPI, and they extract with AI functions or with static paths into the event data."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The QualityBreakdown object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"QualityBreakdown":{"properties":{"score":{"type":"number","title":"Score"},"components":{"items":{"$ref":"#/components/schemas/QualityComponent"},"type":"array","title":"Components"},"workspace_avg":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Workspace Avg"},"workspace_percentile":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Workspace Percentile"}},"type":"object","required":["score","components"],"title":"QualityBreakdown","description":"Structured breakdown of how quality score was computed."},"QualityComponent":{"properties":{"name":{"type":"string","enum":["latency","silence","barge_ins","loops","escalation","tool_failures"],"title":"Name","description":"Quality dimension"},"penalty":{"type":"number","title":"Penalty","description":"Penalty subtracted from the score"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"Raw measured value"},"threshold":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Threshold","description":"Threshold that was exceeded"},"severity":{"type":"string","enum":["none","minor","major","critical"],"title":"Severity","description":"Severity of the penalty","default":"none"}},"type":"object","required":["name","penalty"],"title":"QualityComponent","description":"Single quality score component with penalty and context."}}}}
```

## The QualityComponent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"QualityComponent":{"properties":{"name":{"type":"string","enum":["latency","silence","barge_ins","loops","escalation","tool_failures"],"title":"Name","description":"Quality dimension"},"penalty":{"type":"number","title":"Penalty","description":"Penalty subtracted from the score"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"Raw measured value"},"threshold":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Threshold","description":"Threshold that was exceeded"},"severity":{"type":"string","enum":["none","minor","major","critical"],"title":"Severity","description":"Severity of the penalty","default":"none"}},"type":"object","required":["name","penalty"],"title":"QualityComponent","description":"Single quality score component with penalty and context."}}}}
```

## The QuietHours object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"QuietHours":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"start_hour":{"type":"integer","maximum":23,"minimum":0,"title":"Start Hour","default":21},"end_hour":{"type":"integer","maximum":23,"minimum":0,"title":"End Hour","default":8},"timezone":{"type":"string","maxLength":64,"title":"Timezone","default":"America/New_York"}},"type":"object","title":"QuietHours","description":"Quiet hours — no outbound outreach during this window."}}}}
```

## The RankedAnomalyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RankedAnomalyResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/RankedAnomalyRow"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"RankedAnomalyResponse"},"RankedAnomalyRow":{"properties":{"indicator":{"type":"string","title":"Indicator","default":"t2d_risk"},"district_name":{"type":"string","title":"District Name"},"lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lat"},"lon":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lon"},"rate_per_1k":{"type":"number","title":"Rate Per 1K","default":0},"territory_mean":{"type":"number","title":"Territory Mean","default":0},"residual":{"type":"number","title":"Residual","default":0},"cohort_size":{"type":"integer","title":"Cohort Size","default":0},"is_anomaly":{"type":"boolean","title":"Is Anomaly","default":true},"alert_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alert Id"},"severity":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Severity"},"priority_score":{"type":"number","title":"Priority Score","default":0},"impact":{"type":"number","title":"Impact","default":0},"narrative":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Narrative"},"decomposition":{"items":{"$ref":"#/components/schemas/DecompositionRow"},"type":"array","title":"Decomposition","default":[]}},"type":"object","required":["district_name"],"title":"RankedAnomalyRow"},"DecompositionRow":{"properties":{"feature_name":{"type":"string","title":"Feature Name"},"beta":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Beta"},"delta_x":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Delta X"},"contribution":{"type":"number","title":"Contribution"},"family":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Family"},"ci_lo":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Ci Lo"},"ci_hi":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Ci Hi"}},"type":"object","required":["feature_name","contribution"],"title":"DecompositionRow"}}}}
```

## The RankedAnomalyRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RankedAnomalyRow":{"properties":{"indicator":{"type":"string","title":"Indicator","default":"t2d_risk"},"district_name":{"type":"string","title":"District Name"},"lat":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lat"},"lon":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Lon"},"rate_per_1k":{"type":"number","title":"Rate Per 1K","default":0},"territory_mean":{"type":"number","title":"Territory Mean","default":0},"residual":{"type":"number","title":"Residual","default":0},"cohort_size":{"type":"integer","title":"Cohort Size","default":0},"is_anomaly":{"type":"boolean","title":"Is Anomaly","default":true},"alert_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Alert Id"},"severity":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Severity"},"priority_score":{"type":"number","title":"Priority Score","default":0},"impact":{"type":"number","title":"Impact","default":0},"narrative":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Narrative"},"decomposition":{"items":{"$ref":"#/components/schemas/DecompositionRow"},"type":"array","title":"Decomposition","default":[]}},"type":"object","required":["district_name"],"title":"RankedAnomalyRow"},"DecompositionRow":{"properties":{"feature_name":{"type":"string","title":"Feature Name"},"beta":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Beta"},"delta_x":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Delta X"},"contribution":{"type":"number","title":"Contribution"},"family":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Family"},"ci_lo":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Ci Lo"},"ci_hi":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Ci Hi"}},"type":"object","required":["feature_name","contribution"],"title":"DecompositionRow"}}}}
```

## The ReadinessLabel object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReadinessLabel":{"type":"string"}}}}
```

## The RealtimeCustomVoice object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."}}}}
```

## The RealtimeSemanticVadConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."}}}}
```

## The RealtimeServerVadConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."}}}}
```

## The RealtimeSessionConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."}}}}
```

## The RealtimeTranscriptionConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."}}}}
```

## The RealtimeTruncationConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."}}}}
```

## The RecommendRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RecommendRequest":{"properties":{"session_id":{"type":"string","maxLength":64,"title":"Session Id"},"n":{"type":"integer","maximum":20,"minimum":1,"title":"N","default":5}},"type":"object","required":["session_id"],"title":"RecommendRequest"}}}}
```

## The RecommendResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RecommendResponse":{"properties":{"suggestions":{"items":{"type":"string"},"type":"array","maxItems":100,"title":"Suggestions","description":"LLM-generated caller message suggestions"}},"type":"object","required":["suggestions"],"title":"RecommendResponse"}}}}
```

## The RecordingUrlsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RecordingUrlsResponse":{"properties":{"call_sid":{"type":"string","title":"Call Sid","description":"Twilio call SID"},"inbound_url":{"type":"string","title":"Inbound Url","description":"Presigned URL for the inbound (caller) WAV"},"outbound_url":{"type":"string","title":"Outbound Url","description":"Presigned URL for the outbound (agent) WAV"},"stereo_url":{"type":"string","title":"Stereo Url","description":"Presigned URL for the merged stereo (caller left / agent right) WAV"}},"type":"object","required":["call_sid","inbound_url","outbound_url","stereo_url"],"title":"RecordingUrlsResponse","description":"Presigned S3 URLs for a call recording's WAV objects."}}}}
```

## The RegisterSchemaRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RegisterSchemaRequest":{"properties":{"name":{"$ref":"#/components/schemas/_DatasetSlug"},"file_type":{"$ref":"#/components/schemas/_FileType"},"accepted_file_types":{"items":{"$ref":"#/components/schemas/_FileType"},"type":"array","maxItems":16,"title":"Accepted File Types","description":"Document only: the set of accepted file types, e.g. ``[\"pdf\",\"docx\",\"md\"]``. Empty means single-type\n(just ``file_type``). ``file_type`` is included as the primary. Mixing in a tabular type (csv, xls or xlsx)\nis rejected; snapshot datasets are single-type.","default":[]},"primary_key":{"items":{"$ref":"#/components/schemas/_FieldName"},"type":"array","maxItems":32,"title":"Primary Key","description":"Snapshot only — the canonical PK column(s). Empty/ignored for documents.","default":[]},"schema":{"items":{"$ref":"#/components/schemas/SchemaFieldSpec"},"type":"array","maxItems":500,"title":"Schema","description":"Snapshot only — canonical field list ``[{name, type}]`` (wire key ``schema``).","default":[]},"document_processing":{"anyOf":[{"$ref":"#/components/schemas/DocumentProcessingSpec"},{"type":"null"}],"description":"Document only — extraction config; defaulted server-side when omitted."},"max_size_mb":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Size Mb"}},"type":"object","required":["name","file_type"],"title":"RegisterSchemaRequest","description":"Create Schema request body.\n\nCallers do not send ``ingestion_mode``. It is inferred from ``file_type``: csv, xls and xlsx make a snapshot\ndataset, and any other type makes a document dataset. Snapshot datasets require ``primary_key`` and\n``schema``. Document datasets take an optional ``document_processing`` config and ignore ``primary_key``\nand ``schema``. The service applies the other defaults itself: ``on_schema_change`` is ``additive``, and\n``schema_version`` is assigned automatically."},"_DatasetSlug":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"_FileType":{"type":"string","maxLength":16,"minLength":1,"pattern":"^[a-z0-9]+$"},"_FieldName":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_]*$"},"SchemaFieldSpec":{"properties":{"name":{"$ref":"#/components/schemas/_FieldName"},"type":{"$ref":"#/components/schemas/IntakeFieldType"}},"type":"object","required":["name","type"],"title":"SchemaFieldSpec"},"IntakeFieldType":{"type":"string","enum":["str","int","float","bool","date","datetime"],"title":"IntakeFieldType","description":"The types a contract's `schema[].type` may declare: `str`, `int`, `float`, `bool`, `date` and `datetime`.\n\nA CSV cell is accepted when it parses as its column's type, ignoring surrounding whitespace. `date` and\n`datetime` cells are in ISO format, and `bool` cells are one of true, false, t, f, yes, no, y, n, 0 or 1, in\nany case. A cell with nothing in it is not checked, except in a primary key column, where it is refused. A\ncell with only spaces is not empty and has to parse. An upload is checked up to its first 200,000 rows."},"DocumentProcessingSpec":{"properties":{"retain_source":{"type":"boolean","title":"Retain Source","default":true},"extraction_mode":{"type":"string","enum":["text_extract","OCR","hybrid"],"title":"Extraction Mode","default":"text_extract"}},"type":"object","title":"DocumentProcessingSpec","description":"Processing config for a document dataset (``ingestion_mode=document``).\n\nDocuments have no schema, primary key or change data capture, so this config is what the contract carries\ninstead."}}}}
```

## The RegisterSourceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RegisterSourceRequest":{"properties":{"display_name":{"type":"string","maxLength":200,"minLength":1,"title":"Display Name"},"drive_id":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Drive Id"},"folders":{"items":{"$ref":"#/components/schemas/DriveFolderMapping"},"type":"array","maxItems":100,"minItems":1,"title":"Folders"},"impersonate_subject":{"anyOf":[{"type":"string","maxLength":320},{"type":"null"}],"title":"Impersonate Subject"}},"type":"object","required":["display_name","folders"],"title":"RegisterSourceRequest","description":"Register a Google Shared Drive intake source.\n\nThe caller supplies no credential, and nothing needs provisioning on the platform side. The source\nauthenticates as the platform's shared intake service account. Grant access on the Drive side: share the\nfolder with that account's email, or set ``impersonate_subject`` to use domain-wide delegation. ``drive_id``\nis optional and is resolved at sync when omitted."},"DriveFolderMapping":{"properties":{"folder_id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Folder Id"},"dataset":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Dataset"},"contains_phi":{"type":"boolean","title":"Contains Phi","default":true}},"type":"object","required":["folder_id","dataset"],"title":"DriveFolderMapping","description":"One Google Drive folder ↔ one intake dataset.\n\n``folder_id`` is the Drive folder id (the identity — never the folder name,\nwhich can be renamed/moved). One folder maps to exactly one dataset."}}}}
```

## The RegisteredFunction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RegisteredFunction":{"properties":{"name":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"description":{"type":"string","maxLength":2048,"minLength":1,"title":"Description"},"when_to_use":{"type":"string","maxLength":2048,"title":"When To Use","default":""},"function_type":{"type":"string","enum":["sql","ai","udtf","python"],"title":"Function Type","default":"sql"},"returns":{"type":"string","enum":["table","scalar"],"title":"Returns","default":"table"},"returns_type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Returns Type","default":"string"},"parameters":{"items":{"$ref":"#/components/schemas/platform_lib__platform_functions__models__Parameter"},"type":"array","maxItems":32,"title":"Parameters"},"returns_columns":{"items":{"$ref":"#/components/schemas/ReturnColumn"},"type":"array","maxItems":32,"title":"Returns Columns"},"body":{"type":"string","maxLength":8192,"minLength":1,"title":"Body"},"timeout_ms":{"type":"integer","maximum":60000,"minimum":100,"title":"Timeout Ms","default":30000}},"additionalProperties":false,"type":"object","required":["name","description","body"],"title":"RegisteredFunction","description":"The authored shape of a platform function.\n\nThe body is the same whether the function is kept as a YAML file in a repository or sent with\n``PUT /v1/{workspace_id}/functions/{function_name}``, which takes this model as its body. The deploy validates\nit and derives the JSON Schema for the LLM tool spec.\nFor python and udtf functions, the deploy also creates the function in Unity Catalog."},"platform_lib__platform_functions__models__Parameter":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","maxLength":512,"minLength":1,"title":"Description"},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Default"},"authorization_binding":{"anyOf":[{"$ref":"#/components/schemas/RoleGrantKeysBinding"},{"type":"null"}]},"authorization_binding_test_value":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Authorization Binding Test Value","description":"Canonical CSV resource keys used only by trusted function-test or playground execution when no live authorization block exists."}},"additionalProperties":false,"type":"object","required":["name","type","description"],"title":"Parameter","description":"Typed declaration of one input parameter.\n\nFor SQL function types, ``name`` becomes the ``:name`` placeholder\nin the SQL template. For Python function types, ``name`` becomes\nthe positional argument name in ``def main(...)`` and the input\ncolumn name on the UC UDF signature.\n\nThe ``description`` propagates into the LLM tool spec (this is\nwhat Databricks' Agent Framework reads, and what Anthropic's\ntool-use spec exposes to the model). Missing descriptions\nsilently break tool selection — the registration layer rejects\nempty strings."},"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."},"ReturnColumn":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","maxLength":512,"title":"Description","default":""}},"additionalProperties":false,"type":"object","required":["name","type"],"title":"ReturnColumn","description":"One column in a UDTF's output schema.\n\nUC ``RETURNS TABLE(<col1> <type1>, <col2> <type2>, ...)`` requires\ndeclaring the schema at deploy time. This list anchors that\nschema for ``function_type=udtf`` rows. ``name`` becomes the\ncolumn name in the result rows; ``type`` maps to a Databricks\nSQL type via the same ``ParameterType`` Literal we use for inputs."}}}}
```

## The RegisteredFunctionListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RegisteredFunctionListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RegisteredFunctionResponse"},"type":"array","title":"Items"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["items","count"],"title":"RegisteredFunctionListResponse"},"RegisteredFunctionResponse":{"properties":{"name":{"type":"string","title":"Name"},"function_type":{"type":"string","title":"Function Type"},"returns_kind":{"type":"string","title":"Returns Kind"},"description":{"type":"string","title":"Description","default":""},"when_to_use":{"type":"string","title":"When To Use","default":""},"parameters":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Parameters"},"sql_template":{"type":"string","title":"Sql Template"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"timeout_ms":{"type":"integer","title":"Timeout Ms","default":30000},"last_test_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Test At"},"last_test_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Test Status"},"last_test_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Test Error"},"last_test_duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Last Test Duration Ms"},"deployed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployed At"},"deployed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployed By"}},"type":"object","required":["name","function_type","returns_kind","sql_template"],"title":"RegisteredFunctionResponse","description":"One registered function, as stored in the workspace."}}}}
```

## The RegisteredFunctionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RegisteredFunctionResponse":{"properties":{"name":{"type":"string","title":"Name"},"function_type":{"type":"string","title":"Function Type"},"returns_kind":{"type":"string","title":"Returns Kind"},"description":{"type":"string","title":"Description","default":""},"when_to_use":{"type":"string","title":"When To Use","default":""},"parameters":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Parameters"},"sql_template":{"type":"string","title":"Sql Template"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"timeout_ms":{"type":"integer","title":"Timeout Ms","default":30000},"last_test_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Test At"},"last_test_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Test Status"},"last_test_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Test Error"},"last_test_duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Last Test Duration Ms"},"deployed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployed At"},"deployed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Deployed By"}},"type":"object","required":["name","function_type","returns_kind","sql_template"],"title":"RegisteredFunctionResponse","description":"One registered function, as stored in the workspace."}}}}
```

## The RejectProposalRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RejectProposalRequest":{"properties":{"reason":{"type":"string","maxLength":1000,"minLength":1,"title":"Reason"}},"type":"object","required":["reason"],"title":"RejectProposalRequest"}}}}
```

## The RejectSurfaceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RejectSurfaceRequest":{"properties":{"reason":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Reason"}},"type":"object","title":"RejectSurfaceRequest"}}}}
```

## The RelationshipToDeveloper object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RelationshipToDeveloper":{"properties":{"ownership":{"type":"string","title":"Ownership"},"type":{"type":"string","title":"Type"},"conversation_visibility":{"type":"string","title":"Conversation Visibility"},"thought_visibility":{"type":"string","title":"Thought Visibility"}},"type":"object","required":["ownership","type","conversation_visibility","thought_visibility"],"title":"RelationshipToDeveloper"}}}}
```

## The ReleaseRef object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReleaseRef":{"properties":{"repo":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag","description":"A release tag of the harness, e.g. ``grok_voice-v1.2.0`` or ``grok_voice-v1.2.0-hotfix.1``, or ``in-tree``."},"asset":{"anyOf":[{"type":"string","maxLength":256,"minLength":1},{"type":"null"}],"title":"Asset","description":"The wheel's file name on the release."},"sha256":{"anyOf":[{"$ref":"#/components/schemas/Sha256"},{"type":"null"}]},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"A policy release registered in `policy_releases.json`, named exactly by `repo`, `tag`, `asset` and `sha256`:\nthe values the harness runs. Independent of the release, so `in-tree` can name one. Left out, a pin runs the\ndefault's policy, and a default names none. Stored and audited without the key when left out."}},"type":"object","required":["tag"],"title":"ReleaseRef","description":"A registered release, named exactly, or ``{tag: \"in-tree\"}``."},"Sha256":{"type":"string"},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."}}}}
```

## The RenameColumnAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RenameColumnAction":{"properties":{"op":{"type":"string","const":"rename_column","title":"Op"},"from":{"$ref":"#/components/schemas/IdentifierString"},"to":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","from","to"],"title":"RenameColumnAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The ReshapeSurfaceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReshapeSurfaceRequest":{"properties":{"conversation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Conversation Id","description":"The text conversation asking for the replacement. Its submission is delivered to that\nconversation's agent. Without one, the replacement belongs to the original's conversation."}},"type":"object","title":"ReshapeSurfaceRequest","description":"Request to replace an abandoned surface with one asking only for what is missing."}}}}
```

## The ResolvePreviewRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ResolvePreviewRequest":{"properties":{"auth_claims":{"items":{"$ref":"#/components/schemas/ExternalAuthClaim"},"type":"array","maxItems":32,"title":"Auth Claims","default":[]}},"additionalProperties":false,"type":"object","title":"ResolvePreviewRequest"},"ExternalAuthClaim":{"properties":{"namespace":{"type":"string","maxLength":64,"pattern":"^[a-z][a-z0-9_.:-]{0,63}$","title":"Namespace"},"key":{"type":"string","maxLength":64,"pattern":"^[a-z][a-z0-9_.:-]{0,63}$","title":"Key"},"value":{"type":"string","maxLength":256,"minLength":1,"title":"Value"}},"additionalProperties":false,"type":"object","required":["namespace","key","value"],"title":"ExternalAuthClaim","description":"One normalized customer assertion: the exact tuple ``(namespace, key, value)``.\n\n``value`` is preserved byte-for-byte (bounded length only) — Amigo does not\nlowercase, alias, or rewrite it. ``namespace`` and ``key`` are bounded canonical\nidentifiers. Arrays, objects, numbers, booleans, and null are rejected for every\nfield (v1 values are non-empty strings)."}}}}
```

## The ResolvePreviewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ResolvePreviewResponse":{"properties":{"roles":{"items":{"$ref":"#/components/schemas/MappedRole"},"type":"array","title":"Roles"},"grants":{"items":{"$ref":"#/components/schemas/EffectiveGrant"},"type":"array","title":"Grants"},"unmapped_claim_count":{"type":"integer","title":"Unmapped Claim Count"}},"type":"object","required":["roles","grants","unmapped_claim_count"],"title":"ResolvePreviewResponse"},"MappedRole":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"}},"type":"object","required":["id","name"],"title":"MappedRole"},"EffectiveGrant":{"properties":{"resource_type":{"$ref":"#/components/schemas/_ResourceType"},"resource_key":{"type":"string","title":"Resource Key"},"access":{"$ref":"#/components/schemas/_Access"}},"type":"object","required":["resource_type","resource_key","access"],"title":"EffectiveGrant"},"_ResourceType":{"type":"string","enum":["integration_endpoint","skill","kb_scope"]},"_Access":{"type":"string","enum":["read","write"]}}}}
```

## The ResolveTemplateRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ResolveTemplateRequest":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"}},"type":"object","required":["entity_id"],"title":"ResolveTemplateRequest","description":"Resolve a form template for a specific entity."}}}}
```

## The ResolveTemplateResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ResolveTemplateResponse":{"properties":{"spec":{"$ref":"#/components/schemas/SurfaceSpec"},"prefilled_count":{"type":"integer","title":"Prefilled Count"},"total_fields":{"type":"integer","title":"Total Fields"}},"type":"object","required":["spec","prefilled_count","total_fields"],"title":"ResolveTemplateResponse","description":"Resolved SurfaceSpec with prefill values."},"SurfaceSpec":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"fields":{"items":{"$ref":"#/components/schemas/SurfaceField"},"type":"array","maxItems":200,"minItems":1,"title":"Fields"},"channel":{"$ref":"#/components/schemas/ChannelType","default":"web"},"expires_in_hours":{"type":"integer","maximum":8760,"minimum":1,"title":"Expires In Hours","default":168},"context":{"additionalProperties":true,"type":"object","title":"Context"},"resource_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Resource Type"},"branding":{"anyOf":[{"$ref":"#/components/schemas/BrandingConfig"},{"type":"null"}]},"sections":{"anyOf":[{"items":{"$ref":"#/components/schemas/SurfaceSection"},"type":"array"},{"type":"null"}],"title":"Sections"},"completion_title":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"}},"type":"object","required":["entity_id","title","fields"],"title":"SurfaceSpec","description":"A complete surface specification generated by an agent.\n\nThe agent reads the HSM (entity state, relationships,\nconfidence gaps) and produces this spec. The spec is stored as a\nworld event and rendered by platform-api into a patient-facing page."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"SurfaceField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"prefill_value":{"anyOf":[{},{"type":"null"}],"title":"Prefill Value"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"}},"type":"object","required":["key","label","field_type"],"title":"SurfaceField","description":"A single data collection field in a surface spec.\n\nGenerated by agents from HSM analysis. Each field maps\nto a specific piece of data the world model needs."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"ChannelType":{"type":"string","enum":["email","web"],"title":"ChannelType","description":"Delivery channels for surfaces."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."},"SurfaceSection":{"properties":{"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["title","field_keys"],"title":"SurfaceSection","description":"A page/step in a multi-page surface form."}}}}
```

## The ResolvedToolItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ResolvedToolItem":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"tool_type":{"type":"string","title":"Tool Type"},"description":{"type":"string","title":"Description","default":""},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"states":{"items":{"type":"string"},"type":"array","title":"States"},"tier":{"type":"string","title":"Tier","default":"world"},"is_write":{"type":"boolean","title":"Is Write","description":"The tool can change something, so a simulation never runs it for real: a world write, an\nendpoint whose HTTP method mutates or that declares a write, or a data query whose stored\ntemplate is not a read-only query.","default":false},"additional_instructions":{"additionalProperties":{"type":"string"},"type":"object","title":"Additional Instructions"},"requires_approval":{"type":"boolean","title":"Requires Approval","description":"The integration's approval policy gates this tool, so a simulation never runs it for real.","default":false},"live_read_eligible":{"type":"boolean","title":"Live Read Eligible","description":"A simulation launch can run this tool for real by naming it in `tool_execution.live_read_tools`.","default":false},"skills":{"items":{"type":"string"},"type":"array","title":"Skills","description":"The companion skills in this service's graph that can call this tool."},"integration_display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Display Name","description":"For an integration endpoint, its integration's display name."},"base_url_host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Base Url Host","description":"For an integration endpoint, the host its calls go to."}},"type":"object","required":["tool_name","tool_type"],"title":"ResolvedToolItem"}}}}
```

## The Resource object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Resource":{"properties":{"attributes":{"items":{"$ref":"#/components/schemas/KeyValue"},"type":"array","title":"Attributes"}},"type":"object","required":["attributes"],"title":"Resource"},"KeyValue":{"properties":{"key":{"type":"string","title":"Key"},"value":{"$ref":"#/components/schemas/AnyValue"}},"type":"object","required":["key","value"],"title":"KeyValue","description":"OTLP ``KeyValue`` attribute pair."},"AnyValue":{"additionalProperties":true,"type":"object"}}}}
```

## The ResourceSpans object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ResourceSpans":{"properties":{"resource":{"$ref":"#/components/schemas/Resource"},"scopeSpans":{"items":{"$ref":"#/components/schemas/ScopeSpans"},"type":"array","title":"Scopespans"}},"type":"object","required":["resource","scopeSpans"],"title":"ResourceSpans"},"Resource":{"properties":{"attributes":{"items":{"$ref":"#/components/schemas/KeyValue"},"type":"array","title":"Attributes"}},"type":"object","required":["attributes"],"title":"Resource"},"KeyValue":{"properties":{"key":{"type":"string","title":"Key"},"value":{"$ref":"#/components/schemas/AnyValue"}},"type":"object","required":["key","value"],"title":"KeyValue","description":"OTLP ``KeyValue`` attribute pair."},"AnyValue":{"additionalProperties":true,"type":"object"},"ScopeSpans":{"properties":{"scope":{"$ref":"#/components/schemas/InstrumentationScope"},"spans":{"items":{"$ref":"#/components/schemas/Span"},"type":"array","title":"Spans"}},"type":"object","required":["scope","spans"],"title":"ScopeSpans"},"InstrumentationScope":{"properties":{"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"}},"type":"object","required":["name","version"],"title":"InstrumentationScope"},"Span":{"properties":{"traceId":{"type":"string","title":"Traceid"},"spanId":{"type":"string","title":"Spanid"},"name":{"type":"string","title":"Name"},"kind":{"type":"integer","title":"Kind"},"startTimeUnixNano":{"type":"string","title":"Starttimeunixnano"},"endTimeUnixNano":{"type":"string","title":"Endtimeunixnano"},"attributes":{"items":{"$ref":"#/components/schemas/KeyValue"},"type":"array","title":"Attributes"},"status":{"$ref":"#/components/schemas/Status"}},"type":"object","required":["traceId","spanId","name","kind","startTimeUnixNano","endTimeUnixNano","attributes","status"],"title":"Span","description":"OTLP ``Span`` in OTLP/JSON encoding (ids hex, timestamps decimal-string)."},"Status":{"properties":{"code":{"type":"integer","title":"Code"}},"type":"object","required":["code"],"title":"Status","description":"OTLP ``Status`` — 0=UNSET, 1=OK, 2=ERROR."}}}}
```

## The RestIntegrationResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RestIntegrationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Integration ID."},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace ID."},"name":{"type":"string","title":"Name","description":"Slug-like identifier, immutable post-create."},"display_name":{"type":"string","title":"Display Name","description":"Human-readable name."},"enabled":{"type":"boolean","title":"Enabled","description":"Whether the integration is active."},"managed":{"type":"boolean","title":"Managed","description":"Whether the integration is system-managed and protected from workspace CRUD.","default":false},"approval_policy":{"type":"string","enum":["none","writes","all"],"title":"Approval Policy","description":"Human-in-the-loop approval gate. ``none`` = no approval required;\n``writes`` = approval required for an endpoint that may write: one that uses\nPOST, PUT, PATCH or DELETE, or declares ``declarations.writes`` of any kind but\n``none``, whatever its method; ``all`` = approval required for every endpoint.","default":"none"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the integration was created."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the integration was last updated."},"kind":{"type":"string","const":"rest","title":"Kind","description":"Discriminator.","default":"rest"},"base_url":{"type":"string","title":"Base Url","description":"Base URL for REST integrations."},"auth":{"anyOf":[{"$ref":"#/components/schemas/StaticHeaderAuthDict"},{"$ref":"#/components/schemas/OAuth2ClientCredentialsAuthDict"},{"$ref":"#/components/schemas/OAuth2JwtBearerAuthDict"},{"$ref":"#/components/schemas/CustomTokenExchangeAuthDict"},{"type":"null"}],"title":"Auth","description":"Authentication configuration (lib TypedDict union)."},"endpoint_count":{"type":"integer","title":"Endpoint Count","description":"Number of configured endpoints. Fetch the full list via GET /endpoints."}},"type":"object","required":["id","workspace_id","name","display_name","enabled","created_at","updated_at","base_url","endpoint_count"],"title":"RestIntegrationResponse","description":"REST variant — base URL, auth config, endpoint count."},"StaticHeaderAuthDict":{"properties":{"type":{"type":"string","const":"static_header","title":"Type"},"header_name":{"type":"string","title":"Header Name"}},"type":"object","required":["type","header_name"],"title":"StaticHeaderAuthDict","description":"Static workspace-level secret used verbatim as a single header value.\n\nBearer is just ``header_name=\"Authorization\"`` with the SSM secret holding\n``\"Bearer <token>\"``."},"OAuth2ClientCredentialsAuthDict":{"properties":{"type":{"type":"string","const":"oauth2_client_credentials","title":"Type"},"token_url":{"type":"string","title":"Token Url"},"client_id":{"type":"string","title":"Client Id"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"client_auth_method":{"type":"string","enum":["basic","body"],"title":"Client Auth Method"}},"type":"object","required":["type","token_url","client_id","scopes","client_auth_method"],"title":"OAuth2ClientCredentialsAuthDict","description":"OAuth 2.0 Client Credentials Grant — RFC 6749 § 4.4."},"OAuth2JwtBearerAuthDict":{"properties":{"type":{"type":"string","const":"oauth2_jwt_bearer","title":"Type"},"token_url":{"type":"string","title":"Token Url"},"assertion_issuer":{"type":"string","title":"Assertion Issuer"},"assertion_audience":{"type":"string","title":"Assertion Audience"},"assertion_subject":{"type":"string","title":"Assertion Subject"},"assertion_lifetime_seconds":{"type":"integer","title":"Assertion Lifetime Seconds"},"include_iat":{"type":"boolean","title":"Include Iat"},"include_jti":{"type":"boolean","title":"Include Jti"},"assertion_algorithm":{"type":"string","enum":["RS256","RS384","RS512","PS256","PS384","PS512","ES256","ES384","ES512"],"title":"Assertion Algorithm"},"assertion_usage":{"type":"string","enum":["authorization_grant","client_authentication"],"title":"Assertion Usage"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"extra_claims":{"additionalProperties":true,"type":"object","title":"Extra Claims"}},"type":"object","required":["type","token_url","assertion_issuer","assertion_audience","assertion_subject","assertion_lifetime_seconds","include_iat","include_jti","assertion_algorithm","assertion_usage","scopes","extra_claims"],"title":"OAuth2JwtBearerAuthDict","description":"OAuth 2.0 JWT Bearer Token — RFC 7523.\n\n``assertion_usage`` selects the flow: § 2.1 (JWT as authorization grant) or\n§ 2.2 (JWT as client authentication / private_key_jwt)."},"CustomTokenExchangeAuthDict":{"properties":{"type":{"type":"string","const":"custom_token_exchange","title":"Type"},"exchange_url":{"type":"string","title":"Exchange Url"},"body_encoding":{"type":"string","enum":["json","form"],"title":"Body Encoding"},"static_headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Headers"},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields"},"param_headers":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueDict"},"type":"object","title":"Param Headers"},"param_body_fields":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueDict"},"type":"object","title":"Param Body Fields"},"response_token_path":{"type":"string","title":"Response Token Path"},"identity_bindings":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Bindings"},"identity_binding_test_values":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Binding Test Values"}},"type":"object","required":["type","exchange_url","body_encoding","static_headers","static_body_fields","param_headers","param_body_fields","response_token_path","identity_bindings"],"title":"CustomTokenExchangeAuthDict","description":"Pre-flight exchange that mints a downstream bearer.\n\nDownstream call always receives ``Authorization: Bearer {token}``. No\nin-process caching — every call mints fresh."},"ParamValueDict":{"properties":{"param_name":{"type":"string","title":"Param Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["param_name","description"],"title":"ParamValueDict","description":"Routing target for one per-request parameter on the exchange call.\n\nPaired with a wire-name (header / body-field key) on\n``CustomTokenExchangeAuthDict.param_headers`` / ``param_body_fields``."}}}}
```

## The RetentionPolicyRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RetentionPolicyRequest":{"properties":{"call_recordings_days":{"type":"integer","maximum":36500,"minimum":365,"title":"Call Recordings Days"},"call_transcripts_days":{"type":"integer","maximum":36500,"minimum":365,"title":"Call Transcripts Days"},"audit_log_days":{"type":"integer","maximum":36500,"minimum":365,"title":"Audit Log Days"},"world_events_days":{"type":"integer","maximum":36500,"minimum":365,"title":"World Events Days"},"phi_data_days":{"type":"integer","maximum":36500,"minimum":365,"title":"Phi Data Days"},"legal_hold":{"type":"boolean","title":"Legal Hold"},"legal_hold_reason":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}],"title":"Legal Hold Reason"}},"type":"object","title":"RetentionPolicyRequest","description":"Change the retention policy. Only the fields sent change, and a field left out keeps its stored value.\n\nA retention period or ``legal_hold`` sent as ``null`` is refused with a 422, so neither is cleared by\naccident. Release a legal hold with ``legal_hold: false``.\n\nA legal hold carries a reason, and a new hold needs its own. A save that turns ``legal_hold`` on must send a\n``legal_hold_reason`` that is not null, empty or blank, since the reason a released hold kept is not the new\nhold's. A save that leaves a hold on may leave the reason out and keeps the stored one, but is refused with a\n422 when the reason it would store is null, empty or blank. A hold that is off needs no reason, and releasing\na hold keeps the stored reason unless the save replaces it: a ``null`` ``legal_hold_reason`` clears the\nreason only while the hold is off."},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The RetentionPolicyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RetentionPolicyResponse":{"properties":{"call_recordings_days":{"type":"integer","title":"Call Recordings Days"},"call_transcripts_days":{"type":"integer","title":"Call Transcripts Days"},"audit_log_days":{"type":"integer","title":"Audit Log Days"},"world_events_days":{"type":"integer","title":"World Events Days"},"phi_data_days":{"type":"integer","title":"Phi Data Days"},"legal_hold":{"type":"boolean","title":"Legal Hold"},"legal_hold_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Legal Hold Reason"}},"type":"object","required":["call_recordings_days","call_transcripts_days","audit_log_days","world_events_days","phi_data_days","legal_hold"],"title":"RetentionPolicyResponse"}}}}
```

## The ReturnColumn object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReturnColumn":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","maxLength":512,"title":"Description","default":""}},"additionalProperties":false,"type":"object","required":["name","type"],"title":"ReturnColumn","description":"One column in a UDTF's output schema.\n\nUC ``RETURNS TABLE(<col1> <type1>, <col2> <type2>, ...)`` requires\ndeclaring the schema at deploy time. This list anchors that\nschema for ``function_type=udtf`` rows. ``name`` becomes the\ncolumn name in the result rows; ``type`` maps to a Databricks\nSQL type via the same ``ParameterType`` Literal we use for inputs."}}}}
```

## The ReviewActionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReviewActionResponse":{"properties":{"surface_id":{"type":"string","format":"uuid","title":"Surface Id"},"status":{"$ref":"#/components/schemas/SurfaceStatus"},"action":{"type":"string","enum":["approved","rejected"],"title":"Action"}},"type":"object","required":["surface_id","status","action"],"title":"ReviewActionResponse"},"SurfaceStatus":{"type":"string","enum":["created","pending_review","delivered","opened","partial","completed","expired","archived"],"title":"SurfaceStatus","description":"Lifecycle status of a surface."}}}}
```

## The ReviewMetrics object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReviewMetrics":{"properties":{"queue_depth":{"type":"integer","title":"Queue Depth"},"pending_by_priority":{"additionalProperties":{"type":"integer"},"type":"object","title":"Pending By Priority"},"approved_7d":{"type":"integer","title":"Approved 7D"},"rejected_7d":{"type":"integer","title":"Rejected 7D"},"avg_review_time_hours":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Review Time Hours"},"total_items":{"type":"integer","title":"Total Items","default":0}},"type":"object","required":["queue_depth","pending_by_priority","approved_7d","rejected_7d"],"title":"ReviewMetrics"}}}}
```

## The ReviewQueueListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReviewQueueListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SurfaceResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ReviewQueueListResponse"},"SurfaceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_id":{"type":"string","format":"uuid","title":"Event Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"$ref":"#/components/schemas/SurfaceStatus"},"channel":{"anyOf":[{"$ref":"#/components/schemas/StoredChannelType"},{"type":"null"}]},"use_case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Use Case Id"},"fields_count":{"type":"integer","title":"Fields Count"},"fields":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Fields","default":[]},"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type"},"context":{"additionalProperties":true,"type":"object","title":"Context","default":{}},"expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expires At"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"delivered_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivered At"},"opened_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Opened At"},"submitted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submitted At"},"submitted_data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Submitted Data"},"delivery_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery Metadata"},"review_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Review Notes"},"reviewed_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewed By"},"reviewed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reviewed At"},"archived_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Archived At"},"archive_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Archive Reason"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"}},"type":"object","required":["id","event_id","status","fields_count"],"title":"SurfaceResponse"},"SurfaceStatus":{"type":"string","enum":["created","pending_review","delivered","opened","partial","completed","expired","archived"],"title":"SurfaceStatus","description":"Lifecycle status of a surface."},"StoredChannelType":{"type":"string","enum":["email","web","sms"],"title":"StoredChannelType","description":"Channel as stored on a surface row or outreach rule.\n\n``sms`` predates the end of SMS delivery. It stays readable, and an edit may send a stored ``sms`` back\nunchanged, but no surface or rule is ever switched to it or created with it."}}}}
```

## The ReviewedVersionSet object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReviewedVersionSet":{"properties":{"version_set":{"type":"string","maxLength":40,"minLength":1,"title":"Version Set"},"service_config_digest":{"type":"string","maxLength":71,"pattern":"^sha256:[0-9a-f]{64}$","title":"Service Config Digest","description":"The `service_config_digest` `GET .../configuration-identity` answered for the set, which a run of it records."}},"type":"object","required":["version_set","service_config_digest"],"title":"ReviewedVersionSet","description":"One version set the caller reviewed, by the digest of the configuration a session of it loaded."}}}}
```

## The RiskSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RiskSummary":{"properties":{"composite_score":{"type":"number","title":"Composite Score","description":"Overall risk score 0.0 to 1.0","default":0},"level":{"type":"string","enum":["low","medium","high","critical"],"title":"Level","description":"Risk level","default":"low"}},"type":"object","title":"RiskSummary","description":"Aggregated risk signals across the call.\n\nFree-form residual on the raw ``risk_summary`` JSONB:\n``signals: list[{name, raw_score, weight, weighted_score, detail}]``\n— the per-signal breakdown that aggregates into ``composite_score``.\nNot exposed via this typed shape; consumers needing per-signal\ndetail read the JSONB endpoint."}}}}
```

## The RoleEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RoleEntry":{"properties":{"name":{"type":"string","title":"Name"},"priority":{"type":"integer","title":"Priority"},"description":{"type":"string","title":"Description"},"permission_names":{"items":{"type":"string"},"type":"array","title":"Permission Names"}},"type":"object","required":["name","priority","description","permission_names"],"title":"RoleEntry"}}}}
```

## The RoleGrantItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RoleGrantItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"role_id":{"type":"string","format":"uuid","title":"Role Id"},"resource_type":{"$ref":"#/components/schemas/_ResourceType"},"resource_key":{"type":"string","title":"Resource Key"},"access":{"$ref":"#/components/schemas/_Access"},"param_binding":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Param Binding"},"status":{"type":"string","enum":["active","superseded"],"title":"Status"},"changed_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Changed By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","role_id","resource_type","resource_key","access","status","created_at"],"title":"RoleGrantItem"},"_ResourceType":{"type":"string","enum":["integration_endpoint","skill","kb_scope"]},"_Access":{"type":"string","enum":["read","write"]}}}}
```

## The RoleGrantKeysBinding object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."}}}}
```

## The RotateApiKeyRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RotateApiKeyRequest":{"properties":{"duration_days":{"type":"integer","maximum":90,"minimum":1,"title":"Duration Days"}},"type":"object","required":["duration_days"],"title":"RotateApiKeyRequest"}}}}
```

## The Run object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Run":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"kind":{"type":"string","enum":["conversation","framework"],"title":"Kind"},"status":{"type":"string","enum":["running","paused","dormant","completed","failed","timed_out"],"title":"Status"},"channel":{"anyOf":[{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"]},{"type":"null"}],"title":"Channel"},"framework":{"anyOf":[{"type":"string","enum":["claude-agent-sdk","openai-agents"]},{"type":"null"}],"title":"Framework"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"ended_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ended At"},"entity_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Name"},"service_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Name"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"direction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Direction"},"turn_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turn Count"},"completion_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completion Reason"},"final_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final State"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider","description":"The voice runtime that handled the run, as its session recorded it at start: ``concurrence``\n(also every text run) or ``gpt_realtime``. Null on a run recorded before the platform kept\nit, on a text conversation before its first session starts, and on a framework run. A live\nin-house call reports it before its row exists."},"manifest":{"anyOf":[{"$ref":"#/components/schemas/RunManifest"},{"type":"null"}],"description":"What the run executed with, as its session recorded it at start, or as it last stood after\na mid-call change. Null on a run recorded before the platform kept it, on a text conversation\nbefore its first session starts, on a framework run, and on a live in-house call until it ends."},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"What started the run's conversation: ``test`` when a test key or the ``test`` marker did, ``playground``\nwhen the developer console Playground did. Null on an ordinary conversation, on a call (its row carries no\nsource), and on a framework run."},"tags":{"items":{"$ref":"#/components/schemas/RunTag"},"type":"array","title":"Tags","description":"The labels an app put on the run's conversation, ordered by key. Empty on a conversation with none,\non a framework run, and on a live call before its row exists."},"source_call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Call Sid"},"source_conversation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Source Conversation Id"},"source_framework_run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Source Framework Run Id"},"takeover":{"$ref":"#/components/schemas/TakeoverEligibility","description":"Channel-neutral takeover eligibility, derived from this run's own fields.\n\nA computed field (not a stored one) so eligibility is derived in ONE place and\ncan never drift across the reader's per-source builders — every ``Run``, however\nconstructed, exposes a consistent ``takeover`` on the wire + in OpenAPI.","readOnly":true}},"type":"object","required":["run_id","workspace_id","kind","status","started_at","takeover"],"title":"Run","description":"One item in the canonical unified Runs read model.\n\n``run_id`` is a dedicated UUID (not an overloaded ``call_sid`` / ``conversation_id``);\nthe originating subsystem's ids are kept as ``source_*`` provenance fields so a\nrun can always be traced back to its channel/framework origin. Conversation runs\ncarry a ``channel`` and no ``framework``; framework runs carry a ``framework`` and\nno ``channel`` — enforced below."},"RunManifest":{"properties":{"agent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Id"},"agent_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version","description":"The agent version number the session loaded."},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version","description":"The context graph version number the session loaded. Null, with ``context_graph_id``, on a run of a direct\nprogram, which loads no graph."},"program_kind":{"anyOf":[{"type":"string","enum":["workflow","direct"]},{"type":"null"}],"title":"Program Kind","description":"What the session ran: ``workflow``, its service's context graph, or ``direct``, its agent version's own\nprompt and tools. Null on a run recorded before programs and on one whose engine failed to load."},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON of the direct program the session ran: its authored prompt as saved and\nits tool specs. Null on a workflow run, which its graph version identifies."},"version_set":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The service version set the session resolved its versions and models through, e.g. ``release``."},"platform_config_fingerprint":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the agent and graph version ids, the LLM model and, when the service pins dynamic\nbehaviors, each pinned set's id and version: one value per config generation."},"service_config_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON (keys sorted, no whitespace, non-ASCII escaped) of the whole service\nconfig the session received: the service, its agent and graph versions and the behaviors its version set\npins. Any edit to that config moves it, where the fingerprint follows only the versions, the model and the\npins, so two runs that record the same digest received the same config. Null when the session loaded none."},"image_sha":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The build the session ran on: the commit the agent-engine image was built from."},"runtime_release_id":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The runtime release of the pod the session ran on."},"llm_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that wrote the agent's replies: the engage model, or the realtime model on gpt_realtime."},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature","description":"The sampling temperature the reply requests set. Null where they set none and the model's own\ndefault applies: every voice call, and a text run on a model family that takes none. On a\nreasoning model it rides only the requests that carry tools."},"engage_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates the reply prompt renders from. Null on gpt_realtime, whose\ninstructions aren't rendered from them."},"rendered_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"SHA256 of the opening rendered instructions, without normalization."},"prompt_renderer":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Renderer that produced the recorded instructions."},"prompt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Model identifier submitted with these instructions; aliases are not resolved snapshots."},"navigation_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that chose each context-graph transition. Null on gpt_realtime, which doesn't navigate."},"navigation_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates each navigation decision renders from. Null on gpt_realtime."},"dynamic_behavior_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the template and fixed text each dynamic behavior decision renders from. Null on\ngpt_realtime, which runs no dynamic behavior, and when the service pins no enabled one."},"decider_kind":{"anyOf":[{"$ref":"#/components/schemas/DeciderKind"},{"type":"null"}],"description":"How the session's region decides: ``decisions``, OpenAI Decisions through the region's gateway.\nNavigation and the reply checks both decide through it."},"stt_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The speech-to-text vendor the call ran on: the one it opened with, or the one it failed over\nto. Null on a text run."},"stt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The vendor that voiced the call's replies. Null on a text run."},"tts_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_language":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The language the call's voice spoke: the one it opened in, or the caller's language once an\nin-house call switched to it. ``multilingual`` on a gpt_realtime call left to answer in the\ncaller's language. Null on a text run."},"emergency_floor_enforced":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Emergency Floor Enforced","description":"Whether the medical-emergency floor acted on what it caught, rather than only counting it."},"effect_shadow":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Effect Shadow","description":"Whether an in-house call also recorded each turn as effects, in shadow. Null off in-house voice."},"cooperative_stop":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cooperative Stop","description":"Whether an in-house call's teardown let its session stop on its own before cancelling it.\nNull off in-house voice."}},"type":"object","title":"RunManifest","description":"The configuration a run executed with: as its session started, and as it stood after\nany change the run made mid-way.\n\nA field is null when the session had nothing to record for it: a text run has no\nspeech models, and a gpt_realtime call whose engine failed to load has no agent or\ngraph version. Nothing here is read back from the service's current configuration."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DeciderKind":{"type":"string","const":"decisions"},"RunTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"RunTag","description":"One of an app's own labels on a conversation: a key and an optional value (null for a bare label)."},"TakeoverEligibility":{"properties":{"eligible":{"type":"boolean","title":"Eligible"},"mode_options":{"items":{"type":"string","enum":["listen","takeover"]},"type":"array","title":"Mode Options","default":[]},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"held_by":{"anyOf":[{"$ref":"#/components/schemas/RunHold"},{"type":"null"}],"description":"The operator who holds the run, since when and until when. Left out of the response while no operator does."}},"type":"object","required":["eligible"],"title":"TakeoverEligibility","description":"Whether an operator can take a run over, and how — the channel-neutral signal the\nconsole keys on instead of a per-channel heuristic.\n\n``eligible`` = an operator may take this run over right now. ``mode_options`` = the\ntakeover modes valid for the run's channel (voice exposes ``listen`` + ``takeover``;\nenumerated asynchronous channels expose authored-turn ``takeover`` only).\n``reason`` = a short, human-facing explanation when NOT eligible (e.g.\n``\"run is not live\"``, ``\"channel not yet supported\"``), so the console can\nrender an honest disabled-state tooltip rather than a bare greyed button.\nServer-computed (see ``Run.takeover``) so eligibility rules live in one place and the\nconsole never re-derives them."},"RunHold":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id","description":"The operator who holds the run."},"since":{"type":"string","format":"date-time","title":"Since","description":"When this hold began. A renewal keeps it."},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the hold ends unless the holder renews it."}},"type":"object","required":["operator_id","since","expires_at"],"title":"RunHold","description":"Who holds a text run, since when, and until when unless it is renewed."}}}}
```

## The RunAuthoredTurnRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunAuthoredTurnRequest":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id"},"text":{"type":"string","maxLength":4000,"minLength":1,"title":"Text"}},"type":"object","required":["operator_id","text"],"title":"RunAuthoredTurnRequest"}}}}
```

## The RunAuthoredTurnResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunAuthoredTurnResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"staged":{"type":"boolean","title":"Staged"},"reply_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reply Id","description":"The staged reply. Read its fate with ``GET .../authored-turn``."},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At","description":"When the staged reply stops waiting to be sent."},"waits_for_person":{"type":"boolean","title":"Waits For Person","description":"True when an external user owns the conversation. No agent is started for them, so the reply is queued and\ngoes out when the person next sends a message or polls. If they do not within ``expires_at`` it expires\nunsent: read ``GET .../authored-turn``.","default":false}},"type":"object","required":["run_id","staged"],"title":"RunAuthoredTurnResponse"}}}}
```

## The RunAuthoredTurnStateResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunAuthoredTurnStateResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"state":{"type":"string","enum":["none","pending","consumed","expired"],"title":"State","description":"``none``: no reply was staged. ``pending``: it is waiting to be sent. ``consumed``: it was taken to be sent.\n``expired``: it ran out of time, or a hand back discarded it."},"reply_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reply Id"},"operator_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Operator Id"},"staged_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Staged At"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"}},"type":"object","required":["run_id","state"],"title":"RunAuthoredTurnStateResponse"}}}}
```

## The RunGuidanceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunGuidanceRequest":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id"},"message":{"type":"string","maxLength":5000,"minLength":1,"title":"Message"}},"type":"object","required":["operator_id","message"],"title":"RunGuidanceRequest","description":"Operator guidance for a live run. `operator_id` is in the body because these routes are not under\n`/operators/{operator_id}`. It must be the caller's own operator identity: the route returns 404 when the\nworkspace has no such operator and 403 when it is someone else's."}}}}
```

## The RunGuidanceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunGuidanceResponse":{"properties":{"status":{"type":"string","enum":["delivered","queued_no_subscriber","deduplicated","failed","unknown"],"title":"Status","description":"Delivery status"},"run_id":{"type":"string","format":"uuid","title":"Run Id","description":"Run the guidance was sent to"}},"type":"object","required":["status","run_id"],"title":"RunGuidanceResponse"}}}}
```

## The RunHandbackRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunHandbackRequest":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id"}},"type":"object","required":["operator_id"],"title":"RunHandbackRequest"}}}}
```

## The RunHandbackResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunHandbackResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"success":{"type":"boolean","title":"Success"}},"type":"object","required":["run_id","success"],"title":"RunHandbackResponse"}}}}
```

## The RunHold object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunHold":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id","description":"The operator who holds the run."},"since":{"type":"string","format":"date-time","title":"Since","description":"When this hold began. A renewal keeps it."},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the hold ends unless the holder renews it."}},"type":"object","required":["operator_id","since","expires_at"],"title":"RunHold","description":"Who holds a text run, since when, and until when unless it is renewed."}}}}
```

## The RunManifest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunManifest":{"properties":{"agent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Id"},"agent_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version","description":"The agent version number the session loaded."},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version","description":"The context graph version number the session loaded. Null, with ``context_graph_id``, on a run of a direct\nprogram, which loads no graph."},"program_kind":{"anyOf":[{"type":"string","enum":["workflow","direct"]},{"type":"null"}],"title":"Program Kind","description":"What the session ran: ``workflow``, its service's context graph, or ``direct``, its agent version's own\nprompt and tools. Null on a run recorded before programs and on one whose engine failed to load."},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON of the direct program the session ran: its authored prompt as saved and\nits tool specs. Null on a workflow run, which its graph version identifies."},"version_set":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The service version set the session resolved its versions and models through, e.g. ``release``."},"platform_config_fingerprint":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the agent and graph version ids, the LLM model and, when the service pins dynamic\nbehaviors, each pinned set's id and version: one value per config generation."},"service_config_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON (keys sorted, no whitespace, non-ASCII escaped) of the whole service\nconfig the session received: the service, its agent and graph versions and the behaviors its version set\npins. Any edit to that config moves it, where the fingerprint follows only the versions, the model and the\npins, so two runs that record the same digest received the same config. Null when the session loaded none."},"image_sha":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The build the session ran on: the commit the agent-engine image was built from."},"runtime_release_id":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The runtime release of the pod the session ran on."},"llm_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that wrote the agent's replies: the engage model, or the realtime model on gpt_realtime."},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature","description":"The sampling temperature the reply requests set. Null where they set none and the model's own\ndefault applies: every voice call, and a text run on a model family that takes none. On a\nreasoning model it rides only the requests that carry tools."},"engage_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates the reply prompt renders from. Null on gpt_realtime, whose\ninstructions aren't rendered from them."},"rendered_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"SHA256 of the opening rendered instructions, without normalization."},"prompt_renderer":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Renderer that produced the recorded instructions."},"prompt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Model identifier submitted with these instructions; aliases are not resolved snapshots."},"navigation_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that chose each context-graph transition. Null on gpt_realtime, which doesn't navigate."},"navigation_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates each navigation decision renders from. Null on gpt_realtime."},"dynamic_behavior_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the template and fixed text each dynamic behavior decision renders from. Null on\ngpt_realtime, which runs no dynamic behavior, and when the service pins no enabled one."},"decider_kind":{"anyOf":[{"$ref":"#/components/schemas/DeciderKind"},{"type":"null"}],"description":"How the session's region decides: ``decisions``, OpenAI Decisions through the region's gateway.\nNavigation and the reply checks both decide through it."},"stt_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The speech-to-text vendor the call ran on: the one it opened with, or the one it failed over\nto. Null on a text run."},"stt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The vendor that voiced the call's replies. Null on a text run."},"tts_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_language":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The language the call's voice spoke: the one it opened in, or the caller's language once an\nin-house call switched to it. ``multilingual`` on a gpt_realtime call left to answer in the\ncaller's language. Null on a text run."},"emergency_floor_enforced":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Emergency Floor Enforced","description":"Whether the medical-emergency floor acted on what it caught, rather than only counting it."},"effect_shadow":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Effect Shadow","description":"Whether an in-house call also recorded each turn as effects, in shadow. Null off in-house voice."},"cooperative_stop":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cooperative Stop","description":"Whether an in-house call's teardown let its session stop on its own before cancelling it.\nNull off in-house voice."}},"type":"object","title":"RunManifest","description":"The configuration a run executed with: as its session started, and as it stood after\nany change the run made mid-way.\n\nA field is null when the session had nothing to record for it: a text run has no\nspeech models, and a gpt_realtime call whose engine failed to load has no agent or\ngraph version. Nothing here is read back from the service's current configuration."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DeciderKind":{"type":"string","const":"decisions"}}}}
```

## The RunRenewRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunRenewRequest":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id"},"hold_token":{"type":"string","maxLength":64,"title":"Hold Token","description":"The ``hold_token`` the takeover returned. It is opaque: send it back exactly as received."}},"type":"object","required":["operator_id","hold_token"],"title":"RunRenewRequest"}}}}
```

## The RunRenewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunRenewResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"held_by":{"$ref":"#/components/schemas/RunHold","description":"The hold with its new expiry."},"lease_seconds":{"type":"integer","title":"Lease Seconds","description":"How long the hold lasts from now unless renewed again."}},"type":"object","required":["run_id","held_by","lease_seconds"],"title":"RunRenewResponse"},"RunHold":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id","description":"The operator who holds the run."},"since":{"type":"string","format":"date-time","title":"Since","description":"When this hold began. A renewal keeps it."},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the hold ends unless the holder renews it."}},"type":"object","required":["operator_id","since","expires_at"],"title":"RunHold","description":"Who holds a text run, since when, and until when unless it is renewed."}}}}
```

## The RunSimulationBenchmarkRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunSimulationBenchmarkRequest":{"properties":{"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"required_tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Required Tags"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"Optional world entity UUID to bind caller context for every selected saved-case run. When omitted, each case falls back to fixtures.case_specific.entity_id if present."},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Optional start context for every selected saved-case run, added to each case's `grounding.context` and winning where both name a key. A case whose service refuses the result (a missing required key, an unknown key or a value of the wrong type) is skipped, with the keys at fault in its reason."},"max_cases":{"type":"integer","maximum":200,"minimum":1,"title":"Max Cases","default":20},"max_turns":{"type":"integer","maximum":40,"minimum":1,"title":"Max Turns","default":20},"concurrency":{"type":"integer","maximum":20,"minimum":1,"title":"Concurrency","default":1},"branch_name":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Branch Name"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Tags"},"exploration":{"anyOf":[{"$ref":"#/components/schemas/ExplorationConfig"},{"type":"null"}]},"tool_execution":{"$ref":"#/components/schemas/SimulationToolExecution","description":"Which tools run for real and which return a configured result, for every case in the\nbatch. A case whose service cannot honor them is skipped with the reason. The default\nsimulates every tool. The response echoes the settings the cases execute with."}},"type":"object","title":"RunSimulationBenchmarkRequest"},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"ExplorationConfig":{"properties":{"coverage_driven_selection":{"type":"boolean","title":"Coverage Driven Selection","default":false},"enable_forking":{"type":"boolean","title":"Enable Forking","default":false},"max_forks_per_scenario":{"type":"integer","maximum":5,"minimum":0,"title":"Max Forks Per Scenario","default":2},"recommend_candidates":{"type":"integer","maximum":10,"minimum":1,"title":"Recommend Candidates","default":3}},"type":"object","title":"ExplorationConfig"},"SimulationToolExecution":{"properties":{"live_read_tools":{"items":{"$ref":"#/components/schemas/SimulationToolName"},"type":"array","maxItems":64,"title":"Live Read Tools","description":"Read tools that run for real. Each must be a tool the service's simulations can call that `GET /services/{service_id}/tools/resolve` reports as `live_read_eligible`, with no entry in `tool_mocks`. Integration endpoints need `Integration:View`; platform functions and data queries need `Workspace:View`; world reads need `Service:Update`, which every launch requires. A case anchored to an external principal (an entity with an active external role assignment) runs its live reads as that principal, so it also needs `Conversation:CreateForPrincipal`."},"tool_mocks":{"additionalProperties":{"$ref":"#/components/schemas/SimulationToolMockValue"},"propertyNames":{"$ref":"#/components/schemas/SimulationToolName"},"type":"object","maxProperties":64,"title":"Tool Mocks","description":"Tool name to the result it returns in place of a call. Each must be a tool the service's simulations can call; a companion skill is mocked through the tools it calls."}},"additionalProperties":false,"type":"object","title":"SimulationToolExecution","description":"Which tools a simulation launch runs for real, and which return a configured result.\n\nEvery other tool is simulated and returns a dry-run placeholder. Writes never run\nfor real. The settings apply to every case, step and fork of the launch, and to a\nre-drive of an interrupted run. Empty, the default, simulates every tool."},"SimulationToolName":{"type":"string","maxLength":128,"minLength":1},"SimulationToolMockValue":{"type":"string","maxLength":16384}}}}
```

## The RunSimulationCaseRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunSimulationCaseRequest":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"Optional world entity UUID to bind caller context for this saved-case run. When omitted, the runner falls back to fixtures.case_specific.entity_id if present."},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Optional start context for this saved-case run, added to the case's `grounding.context` (the key-value pairs a conversation is created with) and winning where both name a key. The result is checked against the service's `accepted_context` before the run starts: a missing required key, an unknown key or a value of the wrong type is a 422."},"max_turns":{"type":"integer","maximum":40,"minimum":1,"title":"Max Turns","default":20},"concurrency":{"type":"integer","maximum":20,"minimum":1,"title":"Concurrency","default":1},"branch_name":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Branch Name"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20,"title":"Tags"},"exploration":{"anyOf":[{"$ref":"#/components/schemas/ExplorationConfig"},{"type":"null"}]},"tool_execution":{"$ref":"#/components/schemas/SimulationToolExecution","description":"Which tools run for real and which return a configured result. The default simulates\nevery tool. The response echoes the settings the run executes with."}},"type":"object","title":"RunSimulationCaseRequest"},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"ExplorationConfig":{"properties":{"coverage_driven_selection":{"type":"boolean","title":"Coverage Driven Selection","default":false},"enable_forking":{"type":"boolean","title":"Enable Forking","default":false},"max_forks_per_scenario":{"type":"integer","maximum":5,"minimum":0,"title":"Max Forks Per Scenario","default":2},"recommend_candidates":{"type":"integer","maximum":10,"minimum":1,"title":"Recommend Candidates","default":3}},"type":"object","title":"ExplorationConfig"},"SimulationToolExecution":{"properties":{"live_read_tools":{"items":{"$ref":"#/components/schemas/SimulationToolName"},"type":"array","maxItems":64,"title":"Live Read Tools","description":"Read tools that run for real. Each must be a tool the service's simulations can call that `GET /services/{service_id}/tools/resolve` reports as `live_read_eligible`, with no entry in `tool_mocks`. Integration endpoints need `Integration:View`; platform functions and data queries need `Workspace:View`; world reads need `Service:Update`, which every launch requires. A case anchored to an external principal (an entity with an active external role assignment) runs its live reads as that principal, so it also needs `Conversation:CreateForPrincipal`."},"tool_mocks":{"additionalProperties":{"$ref":"#/components/schemas/SimulationToolMockValue"},"propertyNames":{"$ref":"#/components/schemas/SimulationToolName"},"type":"object","maxProperties":64,"title":"Tool Mocks","description":"Tool name to the result it returns in place of a call. Each must be a tool the service's simulations can call; a companion skill is mocked through the tools it calls."}},"additionalProperties":false,"type":"object","title":"SimulationToolExecution","description":"Which tools a simulation launch runs for real, and which return a configured result.\n\nEvery other tool is simulated and returns a dry-run placeholder. Writes never run\nfor real. The settings apply to every case, step and fork of the launch, and to a\nre-drive of an interrupted run. Empty, the default, simulates every tool."},"SimulationToolName":{"type":"string","maxLength":128,"minLength":1},"SimulationToolMockValue":{"type":"string","maxLength":16384}}}}
```

## The RunSwitchModeRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunSwitchModeRequest":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id"},"participant_call_sid":{"type":"string","maxLength":64,"title":"Participant Call Sid"},"mode":{"type":"string","enum":["listen","takeover"],"title":"Mode"}},"type":"object","required":["operator_id","participant_call_sid","mode"],"title":"RunSwitchModeRequest"}}}}
```

## The RunSwitchModeResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunSwitchModeResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"mode":{"type":"string","enum":["listen","takeover"],"title":"Mode"}},"type":"object","required":["run_id","mode"],"title":"RunSwitchModeResponse"}}}}
```

## The RunTag object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"RunTag","description":"One of an app's own labels on a conversation: a key and an optional value (null for a bare label)."}}}}
```

## The RunTakeoverRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunTakeoverRequest":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id"},"mode":{"type":"string","enum":["listen","takeover"],"title":"Mode","default":"takeover"}},"type":"object","required":["operator_id"],"title":"RunTakeoverRequest"}}}}
```

## The RunTakeoverResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunTakeoverResponse":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"mode":{"type":"string","enum":["listen","takeover"],"title":"Mode"},"participant_call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Call Sid"},"conference_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Conference Sid"},"held_by":{"anyOf":[{"$ref":"#/components/schemas/RunHold"},{"type":"null"}],"description":"On a text run, the hold the caller now has: who, since when and until when unless renewed."},"hold_token":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Hold Token","description":"On a text run, the token that renews this hold. It is opaque: send it back exactly as received."},"lease_seconds":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Lease Seconds","description":"On a text run, how long a hold lasts after it is taken or renewed."}},"type":"object","required":["run_id","mode"],"title":"RunTakeoverResponse"},"RunHold":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id","description":"The operator who holds the run."},"since":{"type":"string","format":"date-time","title":"Since","description":"When this hold began. A renewal keeps it."},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the hold ends unless the holder renews it."}},"type":"object","required":["operator_id","since","expires_at"],"title":"RunHold","description":"Who holds a text run, since when, and until when unless it is renewed."}}}}
```

## The RunTrajectoryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunTrajectoryResponse":{"properties":{"steps":{"items":{"$ref":"#/components/schemas/TrajectoryStep"},"type":"array","title":"Steps"},"truncated":{"type":"boolean","title":"Truncated"}},"type":"object","required":["steps","truncated"],"title":"RunTrajectoryResponse"},"TrajectoryStep":{"properties":{"seq":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seq"},"kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"},"actor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"tool_input_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Input Summary"},"tool_result_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Result Summary"},"tool_succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tool Succeeded"},"decision_from_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Decision From State"},"decision_to_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Decision To State"},"effective_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Effective At"}},"type":"object","title":"TrajectoryStep","description":"One structural step of a framework run's trajectory. Fields are best-effort\n(only those the step actually carries are present), all optional, and free ``str``\nfor the same read-model resilience the ``Run`` descriptive fields use."}}}}
```

## The RunsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunsResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/Run"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"RunsResponse"},"Run":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"kind":{"type":"string","enum":["conversation","framework"],"title":"Kind"},"status":{"type":"string","enum":["running","paused","dormant","completed","failed","timed_out"],"title":"Status"},"channel":{"anyOf":[{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"]},{"type":"null"}],"title":"Channel"},"framework":{"anyOf":[{"type":"string","enum":["claude-agent-sdk","openai-agents"]},{"type":"null"}],"title":"Framework"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"started_at":{"type":"string","format":"date-time","title":"Started At"},"ended_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ended At"},"entity_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Name"},"service_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Name"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone Number"},"direction":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Direction"},"turn_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Turn Count"},"completion_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completion Reason"},"final_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final State"},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider","description":"The voice runtime that handled the run, as its session recorded it at start: ``concurrence``\n(also every text run) or ``gpt_realtime``. Null on a run recorded before the platform kept\nit, on a text conversation before its first session starts, and on a framework run. A live\nin-house call reports it before its row exists."},"manifest":{"anyOf":[{"$ref":"#/components/schemas/RunManifest"},{"type":"null"}],"description":"What the run executed with, as its session recorded it at start, or as it last stood after\na mid-call change. Null on a run recorded before the platform kept it, on a text conversation\nbefore its first session starts, on a framework run, and on a live in-house call until it ends."},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"What started the run's conversation: ``test`` when a test key or the ``test`` marker did, ``playground``\nwhen the developer console Playground did. Null on an ordinary conversation, on a call (its row carries no\nsource), and on a framework run."},"tags":{"items":{"$ref":"#/components/schemas/RunTag"},"type":"array","title":"Tags","description":"The labels an app put on the run's conversation, ordered by key. Empty on a conversation with none,\non a framework run, and on a live call before its row exists."},"source_call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source Call Sid"},"source_conversation_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Source Conversation Id"},"source_framework_run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Source Framework Run Id"},"takeover":{"$ref":"#/components/schemas/TakeoverEligibility","description":"Channel-neutral takeover eligibility, derived from this run's own fields.\n\nA computed field (not a stored one) so eligibility is derived in ONE place and\ncan never drift across the reader's per-source builders — every ``Run``, however\nconstructed, exposes a consistent ``takeover`` on the wire + in OpenAPI.","readOnly":true}},"type":"object","required":["run_id","workspace_id","kind","status","started_at","takeover"],"title":"Run","description":"One item in the canonical unified Runs read model.\n\n``run_id`` is a dedicated UUID (not an overloaded ``call_sid`` / ``conversation_id``);\nthe originating subsystem's ids are kept as ``source_*`` provenance fields so a\nrun can always be traced back to its channel/framework origin. Conversation runs\ncarry a ``channel`` and no ``framework``; framework runs carry a ``framework`` and\nno ``channel`` — enforced below."},"RunManifest":{"properties":{"agent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Id"},"agent_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version","description":"The agent version number the session loaded."},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version","description":"The context graph version number the session loaded. Null, with ``context_graph_id``, on a run of a direct\nprogram, which loads no graph."},"program_kind":{"anyOf":[{"type":"string","enum":["workflow","direct"]},{"type":"null"}],"title":"Program Kind","description":"What the session ran: ``workflow``, its service's context graph, or ``direct``, its agent version's own\nprompt and tools. Null on a run recorded before programs and on one whose engine failed to load."},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON of the direct program the session ran: its authored prompt as saved and\nits tool specs. Null on a workflow run, which its graph version identifies."},"version_set":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The service version set the session resolved its versions and models through, e.g. ``release``."},"platform_config_fingerprint":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the agent and graph version ids, the LLM model and, when the service pins dynamic\nbehaviors, each pinned set's id and version: one value per config generation."},"service_config_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the canonical JSON (keys sorted, no whitespace, non-ASCII escaped) of the whole service\nconfig the session received: the service, its agent and graph versions and the behaviors its version set\npins. Any edit to that config moves it, where the fingerprint follows only the versions, the model and the\npins, so two runs that record the same digest received the same config. Null when the session loaded none."},"image_sha":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The build the session ran on: the commit the agent-engine image was built from."},"runtime_release_id":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The runtime release of the pod the session ran on."},"llm_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that wrote the agent's replies: the engage model, or the realtime model on gpt_realtime."},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature","description":"The sampling temperature the reply requests set. Null where they set none and the model's own\ndefault applies: every voice call, and a text run on a model family that takes none. On a\nreasoning model it rides only the requests that carry tools."},"engage_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates the reply prompt renders from. Null on gpt_realtime, whose\ninstructions aren't rendered from them."},"rendered_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"SHA256 of the opening rendered instructions, without normalization."},"prompt_renderer":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Renderer that produced the recorded instructions."},"prompt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"Model identifier submitted with these instructions; aliases are not resolved snapshots."},"navigation_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The model that chose each context-graph transition. Null on gpt_realtime, which doesn't navigate."},"navigation_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the templates each navigation decision renders from. Null on gpt_realtime."},"dynamic_behavior_prompt_template_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"``sha256:`` over the template and fixed text each dynamic behavior decision renders from. Null on\ngpt_realtime, which runs no dynamic behavior, and when the service pins no enabled one."},"decider_kind":{"anyOf":[{"$ref":"#/components/schemas/DeciderKind"},{"type":"null"}],"description":"How the session's region decides: ``decisions``, OpenAI Decisions through the region's gateway.\nNavigation and the reply checks both decide through it."},"stt_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The speech-to-text vendor the call ran on: the one it opened with, or the one it failed over\nto. Null on a text run."},"stt_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_provider":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The vendor that voiced the call's replies. Null on a text run."},"tts_model":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"tts_language":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"description":"The language the call's voice spoke: the one it opened in, or the caller's language once an\nin-house call switched to it. ``multilingual`` on a gpt_realtime call left to answer in the\ncaller's language. Null on a text run."},"emergency_floor_enforced":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Emergency Floor Enforced","description":"Whether the medical-emergency floor acted on what it caught, rather than only counting it."},"effect_shadow":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Effect Shadow","description":"Whether an in-house call also recorded each turn as effects, in shadow. Null off in-house voice."},"cooperative_stop":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cooperative Stop","description":"Whether an in-house call's teardown let its session stop on its own before cancelling it.\nNull off in-house voice."}},"type":"object","title":"RunManifest","description":"The configuration a run executed with: as its session started, and as it stood after\nany change the run made mid-way.\n\nA field is null when the session had nothing to record for it: a text run has no\nspeech models, and a gpt_realtime call whose engine failed to load has no agent or\ngraph version. Nothing here is read back from the service's current configuration."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DeciderKind":{"type":"string","const":"decisions"},"RunTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"RunTag","description":"One of an app's own labels on a conversation: a key and an optional value (null for a bare label)."},"TakeoverEligibility":{"properties":{"eligible":{"type":"boolean","title":"Eligible"},"mode_options":{"items":{"type":"string","enum":["listen","takeover"]},"type":"array","title":"Mode Options","default":[]},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"held_by":{"anyOf":[{"$ref":"#/components/schemas/RunHold"},{"type":"null"}],"description":"The operator who holds the run, since when and until when. Left out of the response while no operator does."}},"type":"object","required":["eligible"],"title":"TakeoverEligibility","description":"Whether an operator can take a run over, and how — the channel-neutral signal the\nconsole keys on instead of a per-channel heuristic.\n\n``eligible`` = an operator may take this run over right now. ``mode_options`` = the\ntakeover modes valid for the run's channel (voice exposes ``listen`` + ``takeover``;\nenumerated asynchronous channels expose authored-turn ``takeover`` only).\n``reason`` = a short, human-facing explanation when NOT eligible (e.g.\n``\"run is not live\"``, ``\"channel not yet supported\"``), so the console can\nrender an honest disabled-state tooltip rather than a bare greyed button.\nServer-computed (see ``Run.takeover``) so eligibility rules live in one place and the\nconsole never re-derives them."},"RunHold":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id","description":"The operator who holds the run."},"since":{"type":"string","format":"date-time","title":"Since","description":"When this hold began. A renewal keeps it."},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the hold ends unless the holder renews it."}},"type":"object","required":["operator_id","since","expires_at"],"title":"RunHold","description":"Who holds a text run, since when, and until when unless it is renewed."}}}}
```

## The RunsSummaryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"RunsSummaryResponse":{"properties":{"total":{"type":"integer","title":"Total"},"live":{"type":"integer","title":"Live"},"running":{"type":"integer","title":"Running"},"paused":{"type":"integer","title":"Paused"},"completed":{"type":"integer","title":"Completed"},"failed":{"type":"integer","title":"Failed"},"timed_out":{"type":"integer","title":"Timed Out"},"dormant":{"type":"integer","title":"Dormant"},"by_status":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Status"},"by_kind":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Kind"}},"type":"object","required":["total","live","running","paused","completed","failed","timed_out","dormant","by_status","by_kind"],"title":"RunsSummaryResponse","description":"Aggregate run counts for the Runs page summary strip.\n\nHonest workspace totals the paginated list cannot derive client-side (it only\nholds the loaded page). ``by_status`` carries the full canonical breakdown\n(incl. any status beyond the named convenience fields); ``by_kind`` splits\nframework vs conversation. ``live`` = running + paused. ``dormant`` counts\nopen conversations idle past their channel threshold, which are not live."}}}}
```

## The Runtime object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Runtime":{"properties":{"engage_model":{"type":"string","title":"Engage Model","default":""},"channel_kind":{"type":"string","title":"Channel Kind","default":""},"language":{"type":"string","title":"Language","default":""},"caller_context":{"type":"string","title":"Caller Context","default":""}},"type":"object","title":"Runtime"}}}}
```

## The SafeExitEvidence object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SafeExitEvidence":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger"},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome"},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"Whether the disclosure completed before or during the exit."},"transfer_attempted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Transfer Attempted"}},"type":"object","required":["trigger","outcome","disclosure_heard"],"title":"SafeExitEvidence"}}}}
```

## The SafetySettingsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SafetySettingsRequest":{"properties":{"output_checks":{"anyOf":[{"$ref":"#/components/schemas/ServiceOutputChecksRequest"},{"type":"null"}],"description":"The workspace default reply checks. The block replaces the stored one: a key it names becomes the default for\nevery service that does not set it, and a key it leaves out inherits the platform default. `{}` clears them."},"emergency_floor":{"anyOf":[{"$ref":"#/components/schemas/ServiceEmergencyFloorRequest"},{"type":"null"}],"description":"The workspace default for the floor on text. The block replaces the stored one, as `output_checks` does."}},"additionalProperties":false,"type":"object","title":"SafetySettingsRequest","description":"The workspace defaults to store. A family left out keeps what is stored."},"ServiceOutputChecksRequest":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck","description":"On a voice call, `cut` stops a reply that reads something from a patient's record to a caller who has not\nverified, and the caller hears a correction in its place. `off`, the platform default, does not run the check."},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck","description":"`cut`, the platform default, stops a reply that speaks a number on the platform phone blocklist, and the caller\nhears the no-confirmed-number correction in its place. `off` lets the reply speak it. A listed number is still\nnever dialed and is still refused as a destination."},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck","description":"`cut`, the platform default, stops a reply that spells back, letter by letter, a word close to but not the one\nthe caller just said. `off` lets the spelling play."},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that gives dosing advice or tells the caller to change a medication. `cut` (the platform default)\nreplaces it with a correction, `count` lets it play and counts it, `off` lets it play."},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says what is wrong with the caller, or that a symptom needs no care. `cut`, `count` or `off`."},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says a booking, message or other action is done when no write on the call backs it. `cut`,\n`count` or `off`."},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says emergency help is called, sent or on the way. `cut`, `count` or `off`."},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck","description":"A reply that called no tool and tells the caller the agent is doing something now, on text or a realtime call.\n`retry`, the platform default, gives the agent one more go with a note to act or say what it can't do. `off`\nsends the reply as written."},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck","description":"Text only. A reply that says something was done for the client, such as an escalation, a handoff or a message\npassed to a team, when no tool that succeeded in the turn did it. `off`, the platform default, does not read the\nreply. `log` reads it and counts a claim it finds; the reply goes out as written. `enforce` holds the reply back\nand gives the agent one more go with a note to call the tool first or not claim it; a second reply that still\nclaims it goes out cut before the claim, with the false-confirmation correction in its place."}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecksRequest","description":"The reply checks a service or a workspace sets. A key left out inherits: a service's from the workspace default,\nthe workspace's from the platform default. Every key can be set to `off`."},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"},"ServiceEmergencyFloorRequest":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor","description":"A message that says the person is thinking about harming or killing themselves. `enforce`, the platform default,\nanswers it with the floor's crisis script (the region's crisis line, the service's crisis contacts and the\nemergency number) in place of the agent's reply. `off` leaves it to the agent."},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor","description":"A message that describes a medical emergency, such as chest pain or trouble breathing. `shadow`, the platform\ndefault, detects and counts it and opens the floor's hold, and the agent's reply goes out. `enforce` answers it\nwith the floor's emergency-number script instead. `off` leaves it to the agent."},"held_text":{"$ref":"#/components/schemas/HeldTextFloor","description":"A message on a conversation an operator holds. `enforce`, the platform default, answers it with the floor's\nscript when it names any emergency. `off` leaves every held message to the operator."}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloorRequest","description":"How the medical-emergency and crisis floor acts on text conversations (SMS, email, web chat and the other\nmessaging channels), voice notes and simulations. A key left out inherits: a service's from the workspace default,\nthe workspace's from the platform default, which is today's behavior. Every key can be set to `off`, and then the\nfloor neither replaces nor alters the reply: the agent's own reply and tools run, no hold opens, and the hit is\nonly counted. A voice call's floor is not set here."},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"}}}}
```

## The SafetySettingsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SafetySettingsResponse":{"properties":{"output_checks":{"additionalProperties":{"$ref":"#/components/schemas/SafetyValue"},"propertyNames":{"enum":["phi_unverified","blocklisted_number","misspelled_word","dosing_or_med_change","diagnosis","false_confirmation","dispatch_promise","action_promise","unbacked_action_claims"]},"type":"object","title":"Output Checks","description":"The reply checks a call runs."},"emergency_floor":{"additionalProperties":{"$ref":"#/components/schemas/SafetyValue"},"propertyNames":{"enum":["text_self_harm","text_medical","held_text"]},"type":"object","title":"Emergency Floor","description":"How the medical-emergency and crisis floor acts on text conversations, voice notes and simulations."}},"type":"object","required":["output_checks","emergency_floor"],"title":"SafetySettingsResponse","description":"Each safety key with its effective value and source."},"SafetyValue":{"properties":{"mode":{"type":"string","maxLength":16,"title":"Mode","description":"The mode the check runs in. `off` means the check does not run."},"source":{"$ref":"#/components/schemas/SafetySource","description":"`platform` (the default), `workspace` (the workspace default) or `service` (the service's override)."}},"type":"object","required":["mode","source"],"title":"SafetyValue","description":"One safety key's effective value and the layer it comes from."},"SafetySource":{"type":"string","enum":["platform","workspace","service"]}}}}
```

## The SafetySource object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SafetySource":{"type":"string","enum":["platform","workspace","service"]}}}}
```

## The SafetyState object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SafetyState":{"properties":{"peak_concern_level":{"type":"integer","title":"Peak Concern Level","default":0},"concern_turn_count":{"type":"integer","title":"Concern Turn Count","default":0},"trajectory":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trajectory"},"triage_history":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Triage History","default":[]},"concept_matches":{"items":{"$ref":"#/components/schemas/ConceptMatch"},"type":"array","title":"Concept Matches","default":[]}},"type":"object","title":"SafetyState"},"ConceptMatch":{"properties":{"concept":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Concept"},"similarity":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Similarity"},"agent_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Action"},"agent_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Confidence"},"agent_reasoning":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Reasoning"},"at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"string"},{"type":"null"}],"title":"At"}},"type":"object","title":"ConceptMatch"}}}}
```

## The SafetySummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SafetySummary":{"properties":{"match_count":{"type":"integer","title":"Match Count","description":"Number of safety filter matches","default":0}},"type":"object","title":"SafetySummary","description":"Safety filter results.\n\nFree-form residual on the raw ``safety_summary`` JSONB:\n``actions: dict | list`` — escalation handler actions taken\nwhen ``match_count > 0``. Not exposed via this typed shape."}}}}
```

## The SafetyValue object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SafetyValue":{"properties":{"mode":{"type":"string","maxLength":16,"title":"Mode","description":"The mode the check runs in. `off` means the check does not run."},"source":{"$ref":"#/components/schemas/SafetySource","description":"`platform` (the default), `workspace` (the workspace default) or `service` (the service's override)."}},"type":"object","required":["mode","source"],"title":"SafetyValue","description":"One safety key's effective value and the layer it comes from."},"SafetySource":{"type":"string","enum":["platform","workspace","service"]}}}}
```

## The SaveFieldResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SaveFieldResponse":{"properties":{"status":{"type":"string","const":"saved","title":"Status","default":"saved"}},"type":"object","title":"SaveFieldResponse","description":"Acknowledgement returned when a field is auto-saved."}}}}
```

## The SaveProblem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SaveProblem":{"properties":{"status":{"type":"integer","title":"Status","description":"The HTTP status the save would answer with."},"code":{"type":"string","title":"Code","description":"What is refused, as a stable code: the refusal's own `code`, `error` or `error_code` when it carries one, else\nthe code of the check that refuses."},"message":{"type":"string","title":"Message","description":"What is refused, as the refusal says it."},"where":{"items":{"type":"string"},"type":"array","title":"Where","description":"The fields of the service the refusal is about, as dotted paths. Empty when it is about the save as a whole,\nsuch as who makes it."},"detail":{"$ref":"#/components/schemas/JsonValue","description":"The `detail` the save would answer with, exactly."}},"type":"object","required":["status","code","message","where","detail"],"title":"SaveProblem","description":"One refusal the save would answer with."},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]}}}}
```

## The Scenario object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Scenario":{"properties":{"description":{"type":"string","maxLength":512,"title":"Description"},"temperament":{"type":"string","maxLength":32,"title":"Temperament","default":"neutral"},"initial_message":{"type":"string","maxLength":1000,"title":"Initial Message"},"scenario_instructions":{"type":"string","maxLength":2000,"title":"Scenario Instructions"},"persona":{"$ref":"#/components/schemas/ScenarioPersona"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"}},"type":"object","required":["description","initial_message","scenario_instructions"],"title":"Scenario"},"ScenarioPersona":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name","default":""},"role":{"type":"string","maxLength":64,"title":"Role","default":"patient"},"communication_style":{"type":"string","maxLength":512,"title":"Communication Style","default":""},"default_language":{"type":"string","maxLength":16,"title":"Default Language","default":"en-US"},"background":{"type":"string","maxLength":2000,"title":"Background","default":""}},"type":"object","title":"ScenarioPersona"}}}}
```

## The ScenarioPersona object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ScenarioPersona":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name","default":""},"role":{"type":"string","maxLength":64,"title":"Role","default":"patient"},"communication_style":{"type":"string","maxLength":512,"title":"Communication Style","default":""},"default_language":{"type":"string","maxLength":16,"title":"Default Language","default":"en-US"},"background":{"type":"string","maxLength":2000,"title":"Background","default":""}},"type":"object","title":"ScenarioPersona"}}}}
```

## The SchedulingRuleSetListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SchedulingRuleSetListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SchedulingRuleSetResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"SchedulingRuleSetListResponse"},"SchedulingRuleSetResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"agent_kind":{"type":"string","enum":["tms","ketamine","general"],"title":"Agent Kind"},"rule_kind":{"type":"string","enum":["clinic_open_hours","tms_mapping_release","tms_session_grid","ketamine_block_overlap","ninety_day_rolling","concurrent_start_block"],"title":"Rule Kind"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"is_active":{"type":"boolean","title":"Is Active"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","agent_kind","rule_kind","params","is_active","created_by","created_at","updated_at"],"title":"SchedulingRuleSetResponse","description":"Wire shape for a single rule set. ``params`` stays as ``dict``\nhere (not the discriminated union) so add-a-new-kind doesn't break\nolder clients still on the previous SDK version — the SDK's typed\nhelpers can re-validate into ``RuleParams`` when needed."}}}}
```

## The SchedulingRuleSetResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SchedulingRuleSetResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"agent_kind":{"type":"string","enum":["tms","ketamine","general"],"title":"Agent Kind"},"rule_kind":{"type":"string","enum":["clinic_open_hours","tms_mapping_release","tms_session_grid","ketamine_block_overlap","ninety_day_rolling","concurrent_start_block"],"title":"Rule Kind"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"is_active":{"type":"boolean","title":"Is Active"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","agent_kind","rule_kind","params","is_active","created_by","created_at","updated_at"],"title":"SchedulingRuleSetResponse","description":"Wire shape for a single rule set. ``params`` stays as ``dict``\nhere (not the discriminated union) so add-a-new-kind doesn't break\nolder clients still on the previous SDK version — the SDK's typed\nhelpers can re-validate into ``RuleParams`` when needed."}}}}
```

## The SchemaFieldSpec object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SchemaFieldSpec":{"properties":{"name":{"$ref":"#/components/schemas/_FieldName"},"type":{"$ref":"#/components/schemas/IntakeFieldType"}},"type":"object","required":["name","type"],"title":"SchemaFieldSpec"},"_FieldName":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_]*$"},"IntakeFieldType":{"type":"string","enum":["str","int","float","bool","date","datetime"],"title":"IntakeFieldType","description":"The types a contract's `schema[].type` may declare: `str`, `int`, `float`, `bool`, `date` and `datetime`.\n\nA CSV cell is accepted when it parses as its column's type, ignoring surrounding whitespace. `date` and\n`datetime` cells are in ISO format, and `bool` cells are one of true, false, t, f, yes, no, y, n, 0 or 1, in\nany case. A cell with nothing in it is not checked, except in a primary key column, where it is refused. A\ncell with only spaces is not empty and has to parse. An upload is checked up to its first 200,000 rows."}}}}
```

## The SchemaResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SchemaResponse":{"properties":{"lakebase_tables":{"additionalProperties":{"additionalProperties":{"type":"string"},"type":"object"},"type":"object","title":"Lakebase Tables"},"databricks_catalogs":{"items":{"type":"string"},"type":"array","title":"Databricks Catalogs"},"customer_data_tables":{"additionalProperties":{"additionalProperties":{"type":"string"},"type":"object"},"type":"object","title":"Customer Data Tables","description":"This workspace's customer-data tables and views, by the name to query them by, each mapped to its column types."},"uc_functions":{"items":{"additionalProperties":{"type":"string"},"type":"object"},"type":"array","title":"Uc Functions"},"ai_functions":{"items":{"type":"string"},"type":"array","title":"Ai Functions"}},"type":"object","required":["lakebase_tables","databricks_catalogs","customer_data_tables","uc_functions","ai_functions"],"title":"SchemaResponse"}}}}
```

## The ScopeSpans object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ScopeSpans":{"properties":{"scope":{"$ref":"#/components/schemas/InstrumentationScope"},"spans":{"items":{"$ref":"#/components/schemas/Span"},"type":"array","title":"Spans"}},"type":"object","required":["scope","spans"],"title":"ScopeSpans"},"InstrumentationScope":{"properties":{"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"}},"type":"object","required":["name","version"],"title":"InstrumentationScope"},"Span":{"properties":{"traceId":{"type":"string","title":"Traceid"},"spanId":{"type":"string","title":"Spanid"},"name":{"type":"string","title":"Name"},"kind":{"type":"integer","title":"Kind"},"startTimeUnixNano":{"type":"string","title":"Starttimeunixnano"},"endTimeUnixNano":{"type":"string","title":"Endtimeunixnano"},"attributes":{"items":{"$ref":"#/components/schemas/KeyValue"},"type":"array","title":"Attributes"},"status":{"$ref":"#/components/schemas/Status"}},"type":"object","required":["traceId","spanId","name","kind","startTimeUnixNano","endTimeUnixNano","attributes","status"],"title":"Span","description":"OTLP ``Span`` in OTLP/JSON encoding (ids hex, timestamps decimal-string)."},"KeyValue":{"properties":{"key":{"type":"string","title":"Key"},"value":{"$ref":"#/components/schemas/AnyValue"}},"type":"object","required":["key","value"],"title":"KeyValue","description":"OTLP ``KeyValue`` attribute pair."},"AnyValue":{"additionalProperties":true,"type":"object"},"Status":{"properties":{"code":{"type":"integer","title":"Code"}},"type":"object","required":["code"],"title":"Status","description":"OTLP ``Status`` — 0=UNSET, 1=OK, 2=ERROR."}}}}
```

## The ScoreSessionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ScoreSessionRequest":{"properties":{"score":{"type":"number","maximum":100,"minimum":0,"title":"Score"},"score_rationale":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Score Rationale"}},"type":"object","required":["score"],"title":"ScoreSessionRequest"}}}}
```

## The SearchString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SearchString":{"type":"string","maxLength":200,"minLength":1}}}}
```

## The SendGuidanceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SendGuidanceRequest":{"properties":{"call_sid":{"type":"string","maxLength":64,"minLength":1,"title":"Call Sid"},"message":{"type":"string","maxLength":5000,"minLength":1,"title":"Message"}},"type":"object","required":["call_sid","message"],"title":"SendGuidanceRequest"}}}}
```

## The SendGuidanceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SendGuidanceResponse":{"properties":{"status":{"type":"string","enum":["delivered","queued_no_subscriber","deduplicated","failed","unknown"],"title":"Status","description":"Delivery status"},"call_sid":{"type":"string","title":"Call Sid","description":"Call SID the guidance was sent to"}},"type":"object","required":["status","call_sid"],"title":"SendGuidanceResponse"}}}}
```

## The ServedHarnessSetting object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServedHarnessSetting":{"properties":{"value":{"$ref":"#/components/schemas/HarnessSettingValue"},"source":{"$ref":"#/components/schemas/HarnessSettingSource"}},"type":"object","required":["value","source"],"title":"ServedHarnessSetting","description":"One declared setting's value for a service, and the layer it came from."},"HarnessSettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"HarnessSettingSource":{"type":"string","enum":["harness_default","service","policy"]}}}}
```

## The Service object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Service":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id"},"keyterms":{"items":{"type":"string"},"type":"array","title":"Keyterms"},"is_active":{"type":"boolean","title":"Is Active"},"version_sets":{"additionalProperties":{"$ref":"#/components/schemas/VersionSet-Output"},"type":"object","title":"Version Sets"},"tags":{"items":{"$ref":"#/components/schemas/ServiceTag"},"type":"array","title":"Tags"},"tool_capacity":{"type":"integer","title":"Tool Capacity","default":3},"channel_type":{"type":"string","enum":["voice","text"],"title":"Channel Type","default":"voice"},"environment":{"type":"string","enum":["sandbox","production"],"title":"Environment","default":"production"},"demo_mode":{"type":"boolean","title":"Demo Mode","default":false},"platform_caller_verification":{"type":"boolean","title":"Platform Caller Verification","default":true},"caller_verification_endpoint_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Caller Verification Endpoint Id"},"allow_unverified_integration_results":{"type":"boolean","title":"Allow Unverified Integration Results","default":false},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/ServiceVoiceConfig-Output"},{"type":"null"}]},"accepted_context":{"items":{"$ref":"#/components/schemas/ContextKeySpec"},"type":"array","maxItems":100,"title":"Accepted Context"},"crisis_call_911_reply":{"anyOf":[{"$ref":"#/components/schemas/CrisisCall911Reply"},{"type":"null"}]},"contact_lines":{"items":{"$ref":"#/components/schemas/ContactLine"},"type":"array","maxItems":50,"title":"Contact Lines"},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending","default":"stay_on_line"},"output_checks":{"$ref":"#/components/schemas/ServiceOutputChecks"},"emergency_floor":{"$ref":"#/components/schemas/ServiceEmergencyFloor"},"declared_languages":{"anyOf":[{"items":{"type":"string","enum":["en","es","ar","fr","de","pt","zh","ja","ko"]},"type":"array","maxItems":9,"minItems":1},{"type":"null"}],"title":"Declared Languages"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","name","description","agent_id","context_graph_id","keyterms","is_active","version_sets","tags"],"title":"Service","description":"A service links an agent + context graph + version sets."},"VersionSet-Output":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"ServiceTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"ServiceTag"},"ServiceVoiceConfig-Output":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingResponse"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingResponse":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to","warm_transfer","warm_transfer_answer_timeout_s","warm_transfer_on_queue","warm_transfer_on_miss","receiver_classifier","approved_destinations","fallback_to","test_destinations","verification_callers","hours","after_hours_destination","default_destination","transfer_reasons","destination_hours","unsupported_language_destination"],"title":"ServiceForwardingResponse","description":"Forwarding responses always include defaults; the input keeps its existing schema name."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."},"ContextKeySpec":{"properties":{"key":{"$ref":"#/components/schemas/SlugString"},"type":{"type":"string","enum":["string","number"],"title":"Type"},"description":{"$ref":"#/components/schemas/DescriptionString"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["key","type","description","required"],"title":"ContextKeySpec","description":"One key a conversation may supply as start-time context for a service.\n\nThe value is validated against ``type`` at conversation start; a tool can then\nbind the key to one of its parameters (injected, hidden from the model)."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"CrisisCall911Reply":{"properties":{"en":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1},"es":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1}},"additionalProperties":false,"type":"object","required":["en","es"],"title":"CrisisCall911Reply","description":"Per-service wording added when a caller already in crisis asks for emergency dispatch."},"ContactLine":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"type":"string","maxLength":16,"minLength":2,"title":"Number"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLine","description":"A service's declared contact line."},"ServiceOutputChecks":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck"},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck"},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck"},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck"},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck"},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck"},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck"},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck"},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck"}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecks"},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"},"ServiceEmergencyFloor":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor"},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor"},"held_text":{"$ref":"#/components/schemas/HeldTextFloor"}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloor"},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"}}}}
```

## The ServiceBindingRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceBindingRequest":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"}},"type":"object","required":["service_id"],"title":"ServiceBindingRequest"}}}}
```

## The ServiceBindingResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceBindingResponse":{"properties":{"use_case_id":{"type":"string","format":"uuid","title":"Use Case Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"channel":{"type":"string","enum":["inbound_voice","outbound_voice","email","sms","imessage","whatsapp"],"title":"Channel"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["use_case_id","service_id","workspace_id","channel","created_at","updated_at"],"title":"ServiceBindingResponse"}}}}
```

## The ServiceCallStats object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceCallStats":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id","description":"The service"},"summary":{"$ref":"#/components/schemas/AdvancedCallStatsSummary","description":"The service's calls in the window"},"trend":{"items":{"$ref":"#/components/schemas/AdvancedCallStatsTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"The service's trend"}},"type":"object","required":["service_id","summary","trend"],"title":"ServiceCallStats","description":"One service's summary and trend: what the route returns for ``service_id`` set to it."},"AdvancedCallStatsSummary":{"properties":{"total_calls":{"type":"integer","title":"Total Calls","description":"Production calls in the window"},"completed":{"type":"integer","title":"Completed","description":"Calls not escalated to an operator (total_calls minus escalated)"},"escalated":{"type":"integer","title":"Escalated","description":"Calls escalated to an operator"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Mean call duration in seconds"},"p50_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Duration Seconds","description":"Median call duration in seconds"},"p95_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Duration Seconds","description":"95th-percentile call duration in seconds"},"p99_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P99 Duration Seconds","description":"99th-percentile call duration in seconds"},"avg_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality Score","description":"Mean quality score of scored calls (0-100)"},"p50_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality Score","description":"Median quality score (0-100)"},"p5_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P5 Quality Score","description":"5th-percentile quality score (0-100)"},"p95_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Quality Score","description":"95th-percentile quality score (0-100)"},"p95_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Latency Ms","description":"95th percentile of each call's average audio time-to-first-byte, in ms; /analytics/latency reports the same measure as p95_ttfb_ms but only matches this value when no direction or service scope is applied"}},"type":"object","required":["total_calls","completed","escalated"],"title":"AdvancedCallStatsSummary","description":"Production calls in the window: counts, durations, quality scores and audio latency."},"AdvancedCallStatsTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Bucket start as an ISO-8601 timestamp string (granularity follows `interval`)"},"calls":{"type":"integer","title":"Calls","description":"Production calls in the bucket"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Mean call duration in seconds"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Mean quality score of scored calls (0-100)"},"p50_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality","description":"Median quality score (0-100)"},"p95_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P95 Latency Ms","description":"95th percentile of each call's average audio time-to-first-byte, in ms"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Escalated calls over calls in the bucket (0.0-1.0)"}},"type":"object","required":["date","calls","escalation_rate"],"title":"AdvancedCallStatsTrendPoint","description":"One interval bucket of the advanced call stats."}}}}
```

## The ServiceCalls object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceCalls":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id","description":"The service"},"calls":{"type":"integer","title":"Calls","description":"Production calls"},"avg_quality":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality","description":"Mean quality score of scored calls (0-100)"},"escalation_rate":{"type":"number","title":"Escalation Rate","description":"Escalated calls over calls (0.0-1.0)"}},"type":"object","required":["service_id","calls","escalation_rate"],"title":"ServiceCalls","description":"One service's calls in ``by_service``."}}}}
```

## The ServiceConfigurationIdentityResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceConfigurationIdentityResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"version_set":{"type":"string","title":"Version Set"},"service_config_digest":{"type":"string","title":"Service Config Digest","description":"`sha256:` over the canonical JSON of the whole config a session of `version_set` loads: the service, the\nagent version, context graph version and dynamic behaviors the set pins, and each harness's release and resolved\nsettings. It is the `service_config_digest` a run records."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"The service's `updated_at`: the `expected_updated_at` of a conditional settings, harness pins or version set\nwrite. It is the revision of the service's row only. An agent, a context graph, a harness default or a workspace\ndefault can change the digest without changing it."}},"type":"object","required":["workspace_id","service_id","version_set","service_config_digest","updated_at"],"title":"ServiceConfigurationIdentityResponse","description":"Which configuration a session of one version set of the service loads, without the configuration."}}}}
```

## The ServiceCost object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceCost":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service identifier, or null for cost that could not be attributed."},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"This service's priced subtotal rounded to cents; excludes unpriced usage, null if none can be priced."},"cost_share":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Cost Share","description":"Service priced subtotal / total priced cost in the selected scope, after any service filter.\nNull when the service has no priced cost or the denominator is zero or unavailable."}},"type":"object","required":["service_id","calculated_cost_usd","cost_share"],"title":"ServiceCost","description":"Cost attributed to one service."}}}}
```

## The ServiceEmergencyFloor object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceEmergencyFloor":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor"},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor"},"held_text":{"$ref":"#/components/schemas/HeldTextFloor"}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloor"},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"}}}}
```

## The ServiceEmergencyFloorRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceEmergencyFloorRequest":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor","description":"A message that says the person is thinking about harming or killing themselves. `enforce`, the platform default,\nanswers it with the floor's crisis script (the region's crisis line, the service's crisis contacts and the\nemergency number) in place of the agent's reply. `off` leaves it to the agent."},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor","description":"A message that describes a medical emergency, such as chest pain or trouble breathing. `shadow`, the platform\ndefault, detects and counts it and opens the floor's hold, and the agent's reply goes out. `enforce` answers it\nwith the floor's emergency-number script instead. `off` leaves it to the agent."},"held_text":{"$ref":"#/components/schemas/HeldTextFloor","description":"A message on a conversation an operator holds. `enforce`, the platform default, answers it with the floor's\nscript when it names any emergency. `off` leaves every held message to the operator."}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloorRequest","description":"How the medical-emergency and crisis floor acts on text conversations (SMS, email, web chat and the other\nmessaging channels), voice notes and simulations. A key left out inherits: a service's from the workspace default,\nthe workspace's from the platform default, which is today's behavior. Every key can be set to `off`, and then the\nfloor neither replaces nor alters the reply: the agent's own reply and tools run, no hold opens, and the hit is\nonly counted. A voice call's floor is not set here."},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"}}}}
```

## The ServiceEvalQuality object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceEvalQuality":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"The service the verdicts are attributed to. Null groups the verdicts saved with no service"},"summary":{"$ref":"#/components/schemas/EvalQualitySummary","description":"The service's aggregate for the period"},"by_eval_key":{"items":{"$ref":"#/components/schemas/EvalQualitySummary"},"type":"array","maxItems":200,"title":"By Eval Key","description":"The service's per-eval-key aggregates, most-evaluated first, ties by eval_key. At most 200: a service with more lists its most-evaluated keys"},"trend":{"items":{"$ref":"#/components/schemas/EvalQualityTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"The service's trend"}},"type":"object","required":["service_id","summary","by_eval_key","trend"],"title":"ServiceEvalQuality","description":"One service's verdicts: what the route returns for ``service_id`` set to it."},"EvalQualitySummary":{"properties":{"eval_key":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Eval Key","description":"Eval key for a per-key row; null for the overall summary"},"total_evals":{"type":"integer","title":"Total Evals","description":"Total verdicts recorded (any status, incl. errored)"},"judged":{"type":"integer","title":"Judged","description":"Verdicts with a non-null pass/fail outcome (denominator for pass_rate)"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"Fraction of judged verdicts that passed (0.0-1.0). Null when none were judged, which is not 0.0: judged, and none passed"},"avg_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Score","description":"Mean numeric value of metric verdicts; null when none are numeric"}},"type":"object","required":["total_evals","judged"],"title":"EvalQualitySummary","description":"Aggregate production-eval verdict stats, overall or for one eval_key.\n\nSourced from ``call_eval_results`` (assertion and metric verdicts), which is\nkeyed by ``conversation_id`` and therefore CHANNEL-AGNOSTIC — voice, text,\nSMS, email all contribute equally, unlike the voice-shaped call-quality score."},"EvalQualityTrendPoint":{"properties":{"date":{"type":"string","format":"date","title":"Date","description":"Date of the bucket: the day for a daily bucket, the Monday for a weekly one, and for an hourly bucket the day it falls in, so the buckets of one day share this date"},"total_evals":{"type":"integer","title":"Total Evals","description":"Total verdicts in this bucket"},"judged":{"type":"integer","title":"Judged","description":"Verdicts with a non-null pass/fail outcome in this bucket"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"Fraction of judged verdicts that passed in this bucket. Null when none were judged, which is not 0.0: judged, and none passed"},"avg_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Score","description":"Mean numeric value of metric verdicts in this bucket"}},"type":"object","required":["date","total_evals","judged"],"title":"EvalQualityTrendPoint","description":"Single date-bucket data point in the eval-quality trend series. A bucket with no verdicts has no point."}}}}
```

## The ServiceForwardingConfig-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceForwardingConfig-Input":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to"],"title":"ServiceForwardingConfig","description":"Per-service call-forwarding destination + transfer mechanism.\n\nThis block gates the ``forward_call`` tool: None means the agent cannot\ntransfer at all. When present, ``forward_to`` picks the destination mode,\nand the tool schema follows it — a static service gets an argument-less\ntool, a dynamic one gets a required ``phone_number`` that must be one of\n``approved_destinations`` (none approved means no tool). Nothing cascades:\na service is one mode or the other. ``fallback_to`` is no mode: it is the\nline the safe exit dials, in either, and ``forward_call`` never offers it.\nA call tagged as a test reaches only ``test_destinations``, in either mode, unless\nits caller is one of ``verification_callers``.\n``hours`` is none either: on a dynamic service, a transfer outside its staffed\nhours dials ``after_hours_destination`` whichever approved line was asked for, unless that line keeps\nhours of its own in ``destination_hours``.\nA dynamic service can also name a ``default_destination``, the line a transfer that names none dials. A service\nin either mode can list the ``transfer_reasons`` each of its transfers names and the call records."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."}}}}
```

## The ServiceForwardingConfig-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceForwardingConfig-Output":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to"],"title":"ServiceForwardingConfig","description":"Per-service call-forwarding destination + transfer mechanism.\n\nThis block gates the ``forward_call`` tool: None means the agent cannot\ntransfer at all. When present, ``forward_to`` picks the destination mode,\nand the tool schema follows it — a static service gets an argument-less\ntool, a dynamic one gets a required ``phone_number`` that must be one of\n``approved_destinations`` (none approved means no tool). Nothing cascades:\na service is one mode or the other. ``fallback_to`` is no mode: it is the\nline the safe exit dials, in either, and ``forward_call`` never offers it.\nA call tagged as a test reaches only ``test_destinations``, in either mode, unless\nits caller is one of ``verification_callers``.\n``hours`` is none either: on a dynamic service, a transfer outside its staffed\nhours dials ``after_hours_destination`` whichever approved line was asked for, unless that line keeps\nhours of its own in ``destination_hours``.\nA dynamic service can also name a ``default_destination``, the line a transfer that names none dials. A service\nin either mode can list the ``transfer_reasons`` each of its transfers names and the call records."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."}}}}
```

## The ServiceForwardingResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceForwardingResponse":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to","warm_transfer","warm_transfer_answer_timeout_s","warm_transfer_on_queue","warm_transfer_on_miss","receiver_classifier","approved_destinations","fallback_to","test_destinations","verification_callers","hours","after_hours_destination","default_destination","transfer_reasons","destination_hours","unsupported_language_destination"],"title":"ServiceForwardingResponse","description":"Forwarding responses always include defaults; the input keeps its existing schema name."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."}}}}
```

## The ServiceHarnessesResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceHarnessesResponse":{"properties":{"pins":{"items":{"$ref":"#/components/schemas/HarnessPin"},"type":"array","title":"Pins","description":"The service's own pins that validate. A stored pin that no longer does shows as its harness's\n`invalid_pin` entry in `effective_harnesses`."},"effective_harnesses":{"items":{"$ref":"#/components/schemas/EffectiveHarness"},"type":"array","title":"Effective Harnesses","description":"The release each harness the service runs has on its calls: its pin, else the harness default. The service\nruns a harness of its `channel_type` for each family its version sets run, as a pin write resolves them. A harness\nthat has a platform default, which the service stores a pin of and does not run, has a row too, naming no\nrelease, whose `error` says so."}},"type":"object","required":["pins","effective_harnesses"],"title":"ServiceHarnessesResponse"},"HarnessPin":{"properties":{"repo":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag","description":"A release tag of the harness, e.g. ``grok_voice-v1.2.0`` or ``grok_voice-v1.2.0-hotfix.1``, or ``in-tree``."},"asset":{"anyOf":[{"type":"string","maxLength":256,"minLength":1},{"type":"null"}],"title":"Asset","description":"The wheel's file name on the release."},"sha256":{"anyOf":[{"$ref":"#/components/schemas/Sha256"},{"type":"null"}]},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"A policy release registered in `policy_releases.json`, named exactly by `repo`, `tag`, `asset` and `sha256`:\nthe values the harness runs. Independent of the release, so `in-tree` can name one. Left out, a pin runs the\ndefault's policy, and a default names none. Stored and audited without the key when left out."},"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","maxLength":64,"minLength":1,"title":"Harness","description":"A voice family (``grok_voice``, ``gpt_live``, ...) or a text provider family (``openai``, ``anthropic``, ...)."}},"type":"object","required":["tag","kind","harness"],"title":"HarnessPin"},"Sha256":{"type":"string"},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."},"HarnessKind":{"type":"string","enum":["voice","text"]},"EffectiveHarness":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"The release tag, or ``in-tree``. None when ``error`` is set."},"asset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256"},"source":{"type":"string","enum":["pin","harness_default","invalid_pin"],"title":"Source","description":"``invalid_pin``: the service stores a pin of this harness that no longer validates. The entry names no\nrelease, so the harness has nothing to run until the pin is set again. A ``pin`` or ``harness_default`` with an\n``error`` names a release the platform may no longer run, and names no release either."},"contract_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Version","description":"The contract the release was built on, from the registry. None for ``in-tree`` and when ``error`` is set."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the harness has nothing to run on the service: its stored pin is invalid, or its pin or default names a\nrelease or a policy the platform may no longer run (revoked, unregistered, or off the supported contract range),\nor its pin names a harness the service does not run.\nSet, the entry names no release and no policy, so the harness has nothing to run. None otherwise."},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"The policy release the harness runs the values of: the pin's, else the default's. None when neither names one,\nand when ``error`` is set."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","source","contract_version","error","policy"],"title":"EffectiveHarness","description":"The release one harness runs on a service, and where that came from. ``repo``, ``asset`` and ``sha256`` are\nNone for ``in-tree``. agent-engine loads the wheel it baked at ``/opt/harnesses/<sha256>/``."}}}}
```

## The ServiceListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ServiceResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ServiceListResponse"},"ServiceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id","description":"The context graph the service binds. Null on a service that binds none: it runs direct programs only."},"agent_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Name"},"context_graph_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Context Graph Name"},"keyterms":{"items":{"type":"string"},"type":"array","title":"Keyterms"},"is_active":{"type":"boolean","title":"Is Active"},"version_sets":{"additionalProperties":{"$ref":"#/components/schemas/VersionSet-Output"},"type":"object","title":"Version Sets"},"tags":{"items":{"$ref":"#/components/schemas/ServiceTag"},"type":"array","title":"Tags"},"tool_capacity":{"type":"integer","title":"Tool Capacity"},"channel_type":{"type":"string","enum":["voice","text"],"title":"Channel Type","default":"voice"},"environment":{"type":"string","enum":["sandbox","production"],"title":"Environment","default":"production"},"demo_mode":{"type":"boolean","title":"Demo Mode","description":"Voice calls on this service open with only the recording notice, without the AI disclosure. For demos only,\nnever for a service that takes real callers.","default":false},"platform_caller_verification":{"type":"boolean","title":"Platform Caller Verification","description":"Whether the platform verifies a caller who may match a patient record by full name and date of\nbirth. Off, the agent never asks a caller to verify, and every platform tool that reads a patient\nrecord refuses. The service's integration tools run either way, unless one of them verifies its\ncallers (`caller_verification_endpoint_id`).","default":true},"caller_verification_endpoint_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Caller Verification Endpoint Id","description":"The integration endpoint that verifies this service's callers, or null when none does."},"allow_unverified_integration_results":{"type":"boolean","title":"Allow Unverified Integration Results","description":"A dangerous bypass, off by default. On, results from the service's integration endpoints, reads and\nwrites, never count as a patient record for the output checker's unverified-caller check\n(`output_checks.phi_unverified`, which runs only on a service that sets it to `cut`), so the agent may read\nthem back to any caller, verified or not. Writes are still held to everything else, the platform's own\npatient reads still refuse until the caller verifies, and data queries and skills still count. Never on\nbeside `caller_verification_endpoint_id`. Every change is audited.","default":false},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/ServiceVoiceConfig-Output"},{"type":"null"}]},"accepted_context":{"items":{"$ref":"#/components/schemas/ContextKeySpec"},"type":"array","title":"Accepted Context"},"crisis_call_911_reply":{"anyOf":[{"$ref":"#/components/schemas/CrisisCall911Reply"},{"type":"null"}]},"contact_lines":{"items":{"$ref":"#/components/schemas/ContactLine"},"type":"array","maxItems":50,"title":"Contact Lines","description":"Declared direct contact lines. Public emergency and N11 short codes are refused."},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending","description":"How a voice call ends after a medical emergency's script: ``stay_on_line`` (the default) or\n``end_after_script``, which plays the authored closing line and then ends the call. A self-harm or\ncrisis statement keeps the call open in either.","default":"stay_on_line"},"output_checks":{"$ref":"#/components/schemas/ServiceOutputChecks","description":"The checks the service's calls run: its own block over the workspace defaults. Where each value comes from:\n`GET /v1/{workspace_id}/services/{service_id}/safety`."},"emergency_floor":{"$ref":"#/components/schemas/ServiceEmergencyFloor","description":"How the floor acts on the service's text conversations: its own block over the workspace defaults. Where each\nvalue comes from: `GET /v1/{workspace_id}/services/{service_id}/safety`."},"conversation_audit":{"$ref":"#/components/schemas/ConversationAuditSettings","description":"The post-call transcript quality audit, off unless the service turns it on."},"declared_languages":{"anyOf":[{"items":{"type":"string","enum":["en","es","ar","fr","de","pt","zh","ja","ko"]},"type":"array","maxItems":9,"minItems":1},{"type":"null"}],"title":"Declared Languages","description":"The languages this service serves, as ISO 639-1 codes. None: none declared."},"effective_harnesses":{"anyOf":[{"items":{"$ref":"#/components/schemas/EffectiveHarness"},"type":"array"},{"type":"null"}],"title":"Effective Harnesses","description":"The release each voice and text harness that has a platform default runs on the service's calls: its pin, else\nthe harness default. Set by the single-service GET, left out of lists. `GET .../services/{service_id}/harnesses`\nlists only the harnesses the service runs."},"is_system":{"type":"boolean","title":"Is System","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","description","agent_id","context_graph_id","keyterms","is_active","version_sets","tags","tool_capacity","created_at","updated_at"],"title":"ServiceResponse"},"VersionSet-Output":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"ServiceTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"ServiceTag"},"ServiceVoiceConfig-Output":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingResponse"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingResponse":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to","warm_transfer","warm_transfer_answer_timeout_s","warm_transfer_on_queue","warm_transfer_on_miss","receiver_classifier","approved_destinations","fallback_to","test_destinations","verification_callers","hours","after_hours_destination","default_destination","transfer_reasons","destination_hours","unsupported_language_destination"],"title":"ServiceForwardingResponse","description":"Forwarding responses always include defaults; the input keeps its existing schema name."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."},"ContextKeySpec":{"properties":{"key":{"$ref":"#/components/schemas/SlugString"},"type":{"type":"string","enum":["string","number"],"title":"Type"},"description":{"$ref":"#/components/schemas/DescriptionString"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["key","type","description","required"],"title":"ContextKeySpec","description":"One key a conversation may supply as start-time context for a service.\n\nThe value is validated against ``type`` at conversation start; a tool can then\nbind the key to one of its parameters (injected, hidden from the model)."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"CrisisCall911Reply":{"properties":{"en":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1},"es":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1}},"additionalProperties":false,"type":"object","required":["en","es"],"title":"CrisisCall911Reply","description":"Per-service wording added when a caller already in crisis asks for emergency dispatch."},"ContactLine":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"type":"string","maxLength":16,"minLength":2,"title":"Number"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLine","description":"A service's declared contact line."},"ServiceOutputChecks":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck"},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck"},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck"},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck"},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck"},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck"},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck"},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck"},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck"}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecks"},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"},"ServiceEmergencyFloor":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor"},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor"},"held_text":{"$ref":"#/components/schemas/HeldTextFloor"}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloor"},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"},"ConversationAuditSettings":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"checks":{"items":{"$ref":"#/components/schemas/ConversationAuditCheck"},"type":"array","maxItems":4,"minItems":1,"title":"Checks"},"threshold":{"type":"integer","maximum":100,"minimum":1,"title":"Threshold","default":80}},"additionalProperties":false,"type":"object","title":"ConversationAuditSettings"},"ConversationAuditCheck":{"type":"string","enum":["obvious_errors","missed_escalation","wrong_information","missed_safety_event"]},"EffectiveHarness":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"The release tag, or ``in-tree``. None when ``error`` is set."},"asset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256"},"source":{"type":"string","enum":["pin","harness_default","invalid_pin"],"title":"Source","description":"``invalid_pin``: the service stores a pin of this harness that no longer validates. The entry names no\nrelease, so the harness has nothing to run until the pin is set again. A ``pin`` or ``harness_default`` with an\n``error`` names a release the platform may no longer run, and names no release either."},"contract_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Version","description":"The contract the release was built on, from the registry. None for ``in-tree`` and when ``error`` is set."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the harness has nothing to run on the service: its stored pin is invalid, or its pin or default names a\nrelease or a policy the platform may no longer run (revoked, unregistered, or off the supported contract range),\nor its pin names a harness the service does not run.\nSet, the entry names no release and no policy, so the harness has nothing to run. None otherwise."},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"The policy release the harness runs the values of: the pin's, else the default's. None when neither names one,\nand when ``error`` is set."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","source","contract_version","error","policy"],"title":"EffectiveHarness","description":"The release one harness runs on a service, and where that came from. ``repo``, ``asset`` and ``sha256`` are\nNone for ``in-tree``. agent-engine loads the wheel it baked at ``/opt/harnesses/<sha256>/``."},"HarnessKind":{"type":"string","enum":["voice","text"]},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."}}}}
```

## The ServiceOutputChecks object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceOutputChecks":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck"},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck"},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck"},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck"},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck"},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck"},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck"},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck"},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck"}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecks"},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"}}}}
```

## The ServiceOutputChecksRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceOutputChecksRequest":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck","description":"On a voice call, `cut` stops a reply that reads something from a patient's record to a caller who has not\nverified, and the caller hears a correction in its place. `off`, the platform default, does not run the check."},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck","description":"`cut`, the platform default, stops a reply that speaks a number on the platform phone blocklist, and the caller\nhears the no-confirmed-number correction in its place. `off` lets the reply speak it. A listed number is still\nnever dialed and is still refused as a destination."},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck","description":"`cut`, the platform default, stops a reply that spells back, letter by letter, a word close to but not the one\nthe caller just said. `off` lets the spelling play."},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that gives dosing advice or tells the caller to change a medication. `cut` (the platform default)\nreplaces it with a correction, `count` lets it play and counts it, `off` lets it play."},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says what is wrong with the caller, or that a symptom needs no care. `cut`, `count` or `off`."},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says a booking, message or other action is done when no write on the call backs it. `cut`,\n`count` or `off`."},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says emergency help is called, sent or on the way. `cut`, `count` or `off`."},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck","description":"A reply that called no tool and tells the caller the agent is doing something now, on text or a realtime call.\n`retry`, the platform default, gives the agent one more go with a note to act or say what it can't do. `off`\nsends the reply as written."},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck","description":"Text only. A reply that says something was done for the client, such as an escalation, a handoff or a message\npassed to a team, when no tool that succeeded in the turn did it. `off`, the platform default, does not read the\nreply. `log` reads it and counts a claim it finds; the reply goes out as written. `enforce` holds the reply back\nand gives the agent one more go with a note to call the tool first or not claim it; a second reply that still\nclaims it goes out cut before the claim, with the false-confirmation correction in its place."}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecksRequest","description":"The reply checks a service or a workspace sets. A key left out inherits: a service's from the workspace default,\nthe workspace's from the platform default. Every key can be set to `off`."},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"}}}}
```

## The ServicePlanResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServicePlanResponse":{"properties":{"problems":{"items":{"$ref":"#/components/schemas/SaveProblem"},"type":"array","title":"Problems","description":"Each refusal the save would answer with, in the order it meets them. Empty when every check passes."},"changes":{"anyOf":[{"items":{"$ref":"#/components/schemas/FieldChange"},"type":"array"},{"type":"null"}],"title":"Changes","description":"What the save would change in the stored service, by field. A create's lists every field it would store, and\na save that changes nothing has none. Null when the request does not apply to the stored config, so there is no\nconfig to compare (`readiness_unavailable` is `config_unreadable`)."},"families":{"anyOf":[{"items":{"$ref":"#/components/schemas/FamilyDelivery"},"type":"array"},{"type":"null"}],"title":"Families","description":"Each version set's family, `release` first. Empty for a text service, and null when it can't be read (see\n`readiness_unavailable`)."},"starts":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetStarts"},"type":"array"},{"type":"null"}],"title":"Starts","description":"The starts each version set takes, as `readiness.starts` lists them. Null exactly when `families` is null."},"readiness":{"anyOf":[{"$ref":"#/components/schemas/ServiceReadinessResponse"},{"type":"null"}],"description":"The service's readiness readback (`GET .../readiness`) for the config the save would store. A create's has no\nvoice use case bound. Null when it can't be read (see `readiness_unavailable`)."},"readiness_unavailable":{"anyOf":[{"$ref":"#/components/schemas/Unavailable"},{"type":"null"}],"description":"Why `readiness` is null, and `families` too unless it is `channel_manager_unavailable`: the agent is not in the\nworkspace, a version set pins an agent or context graph version that doesn't exist or that no check cleared, the request does not apply to\nthe stored config, the config the save would store is incompatible with readiness, or channel-manager can't be\nread. Null when it is read."}},"type":"object","required":["problems","changes","families","starts","readiness","readiness_unavailable"],"title":"ServicePlanResponse","description":"What a service save would refuse, change and run. Nothing is written."},"SaveProblem":{"properties":{"status":{"type":"integer","title":"Status","description":"The HTTP status the save would answer with."},"code":{"type":"string","title":"Code","description":"What is refused, as a stable code: the refusal's own `code`, `error` or `error_code` when it carries one, else\nthe code of the check that refuses."},"message":{"type":"string","title":"Message","description":"What is refused, as the refusal says it."},"where":{"items":{"type":"string"},"type":"array","title":"Where","description":"The fields of the service the refusal is about, as dotted paths. Empty when it is about the save as a whole,\nsuch as who makes it."},"detail":{"$ref":"#/components/schemas/JsonValue","description":"The `detail` the save would answer with, exactly."}},"type":"object","required":["status","code","message","where","detail"],"title":"SaveProblem","description":"One refusal the save would answer with."},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]},"FieldChange":{"properties":{"path":{"items":{"type":"string"},"type":"array","title":"Path","description":"Where the field is: `name`, or a key of the service's config, then each key under it."},"change":{"type":"string","enum":["added","removed","changed"],"title":"Change"},"before":{"$ref":"#/components/schemas/JsonValue","description":"What is stored. Null for an added field."},"after":{"$ref":"#/components/schemas/JsonValue","description":"What the save would store. Null for a removed field."}},"type":"object","required":["path","change"],"title":"FieldChange","description":"A field the save would change."},"FamilyDelivery":{"properties":{"version_set":{"$ref":"#/components/schemas/ReadinessLabel"},"family":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Family"},"source":{"type":"string","enum":["service","agent","engine_default","agent_missing"],"title":"Source"},"capabilities":{"anyOf":[{"$ref":"#/components/schemas/SessionCapabilities"},{"type":"null"}]},"dynamic_behaviors_configured":{"type":"boolean","title":"Dynamic Behaviors Configured"},"ignored_settings":{"items":{"type":"string"},"type":"array","title":"Ignored Settings","description":"The service settings, as dotted paths from the service (keyterms, voice_config.max_buffer_delay_ms), that the service sets to a non-default value and this family does not read. Advisory: the config is valid and saves, and a setting listed here may still be refused (see family_refusals). Empty, and not known, when ignored_settings_known is false."},"ignored_settings_known":{"type":"boolean","title":"Ignored Settings Known","description":"Whether ignored_settings was read: false when the version set's family is unknown or the stored service no longer validates, so an empty list says nothing."},"family_judgement":{"type":"string","enum":["judged","not_judged"],"title":"Family Judgement","description":"judged: family_refusals is every refusal the voice family contract and the family's delivery rules find for this version set, empty when the family runs it as authored. not_judged: the version set could not be judged (family_not_judged says why), so family_refusals may be incomplete and an empty one is never a pass."},"family_refusals":{"items":{"$ref":"#/components/schemas/FamilyRefusal"},"type":"array","title":"Family Refusals","description":"Each reason the family cannot run this version set as stored, with the code, message and fields a save refuses it with: the family's admission for the workspace when the service names the family, its delivery rules held to the whole config, then the contract's rules on the program the set's agent version runs. A client shows each one's code, message and fields and computes none. Messages have every digit redacted; a save plan's problems keep the exact text."},"family_not_judged":{"anyOf":[{"$ref":"#/components/schemas/FamilyNotJudged"},{"type":"null"}],"description":"Why the version set was not judged, when family_judgement is not_judged; null otherwise."},"refusals":{"items":{"$ref":"#/components/schemas/FamilyPolicyRefusal"},"type":"array","title":"Refusals","description":"What the config the save would store asks of the family that it can't deliver (warm transfer,\nservice-written lines), whether or not this save moves the version set. Empty when it delivers it all. Kept as\nit was for a family off the voice family contract; for a family on it, `family_refusals` is the list a client\nshows, which holds these findings with the contract's."}},"type":"object","required":["version_set","family","source","capabilities","dynamic_behaviors_configured","ignored_settings","ignored_settings_known","family_judgement","family_refusals","family_not_judged","refusals"],"title":"FamilyDelivery","description":"The voice family one version set would run, as readiness reads it, and the family's delivery rules held to\nthe whole config."},"ReadinessLabel":{"type":"string"},"SessionCapabilities":{"properties":{"multi_state":{"type":"boolean","title":"Multi State"},"dynamic_behaviors":{"type":"boolean","title":"Dynamic Behaviors"},"completion_navigation":{"type":"boolean","title":"Completion Navigation"},"channels":{"items":{"type":"string","enum":["app","phone","playground","test_call"]},"type":"array","title":"Channels"},"outbound_calls":{"type":"boolean","title":"Outbound Calls"},"operator_takeover":{"type":"boolean","title":"Operator Takeover"},"end_call":{"type":"boolean","title":"End Call"},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"authored_lines":{"type":"string","enum":["tts","model_checked","clips"],"title":"Authored Lines","default":"clips"},"floor_enforced":{"type":"boolean","title":"Floor Enforced","default":false},"state_carrier":{"anyOf":[{"type":"string","enum":["session_update_and_note","note_only"]},{"type":"null"}],"title":"State Carrier"},"typed_guardrails":{"type":"boolean","title":"Typed Guardrails","default":false}},"type":"object","required":["multi_state","dynamic_behaviors","completion_navigation","channels","outbound_calls","operator_takeover","end_call","warm_transfer","authored_lines","floor_enforced","state_carrier","typed_guardrails"],"title":"SessionCapabilities"},"FamilyRefusal":{"properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/FamilyRefusalCode"},{"type":"string","enum":["family_warm_transfer_unsupported","family_cannot_speak_service_lines"]}],"title":"Code"},"message":{"$ref":"#/components/schemas/ReadinessLabel","description":"Names the family and the fix, with every digit redacted."},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"What the author changes, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyRefusal"},"FamilyRefusalCode":{"type":"string","enum":["voice_family_not_served","voice_family_residency","voice_family_agent_version","voice_family_direct_program","voice_family_graph_shape","voice_family_guardrails","voice_family_dynamic_behaviors","voice_family_completion_navigation","voice_family_warm_transfer","voice_family_service_lines","voice_family_outbound","voice_family_settings"]},"FamilyNotJudged":{"properties":{"code":{"$ref":"#/components/schemas/FamilyNotJudgedCode"},"message":{"$ref":"#/components/schemas/ReadinessLabel"},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"Where the author looks, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyNotJudged"},"FamilyNotJudgedCode":{"type":"string","enum":["agent_version_missing","family_not_on_contract","voice_config_unreadable","graph_missing","graph_version_missing","graph_version_unreadable"]},"FamilyPolicyRefusal":{"properties":{"code":{"type":"string","enum":["family_warm_transfer_unsupported","family_cannot_speak_service_lines"],"title":"Code"},"message":{"type":"string","title":"Message"},"fields":{"items":{"type":"string"},"type":"array","title":"Fields"}},"type":"object","required":["code","message","fields"],"title":"FamilyPolicyRefusal"},"VersionSetStarts":{"properties":{"version_set":{"$ref":"#/components/schemas/ReadinessLabel"},"kinds":{"items":{"$ref":"#/components/schemas/StartKind"},"type":"array","title":"Kinds"},"kinds_known":{"type":"boolean","title":"Kinds Known","description":"False when the version set's family is unknown (families[].source is agent_missing): kinds is then empty and says nothing; a client offers no start from it and shows why."}},"type":"object","required":["version_set","kinds","kinds_known"],"title":"VersionSetStarts"},"StartKind":{"type":"string","enum":["text","test_call","app_session"]},"ServiceReadinessResponse":{"properties":{"voice_use_cases":{"items":{"$ref":"#/components/schemas/VoiceUseCase"},"type":"array","title":"Voice Use Cases"},"lines":{"items":{"$ref":"#/components/schemas/Line"},"type":"array","title":"Lines"},"families":{"items":{"$ref":"#/components/schemas/BoundFamily"},"type":"array","title":"Families"},"starts":{"items":{"$ref":"#/components/schemas/VersionSetStarts"},"type":"array","title":"Starts","description":"Each version set, release first, with the starts its service takes: a client offers these and no other. A kind listed is one the platform runs for this service's channel and family; it is not a judgement that the start succeeds (families[].family_judgement and family_refusals say that). Every service has an entry per version set, a text one too."},"policies":{"$ref":"#/components/schemas/Policies"},"launch":{"$ref":"#/components/schemas/Launch"}},"type":"object","required":["voice_use_cases","lines","families","starts","policies","launch"],"title":"ServiceReadinessResponse"},"VoiceUseCase":{"properties":{"label":{"$ref":"#/components/schemas/ReadinessLabel"},"channel":{"anyOf":[{"$ref":"#/components/schemas/ReadinessLabel"},{"type":"null"}]},"available":{"type":"boolean","title":"Available"},"fallback_forwarding_number_set":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Fallback Forwarding Number Set","description":"Whether an inbound voice use case has a fallback forwarding number, where inbound calls forward when channel-manager does not answer. Informational: unset does not block a save. Null for an outbound or unavailable use case. The number itself is never returned."}},"type":"object","required":["label","channel","available","fallback_forwarding_number_set"],"title":"VoiceUseCase"},"Line":{"properties":{"kind":{"$ref":"#/components/schemas/LineKind"},"label":{"$ref":"#/components/schemas/ReadinessLabel"},"use_cases":{"items":{"$ref":"#/components/schemas/Dialability"},"type":"array","title":"Use Cases"}},"type":"object","required":["kind","label","use_cases"],"title":"Line"},"LineKind":{"type":"string","enum":["forward_to","approved_destination","fallback_to","after_hours_destination","test_destination"]},"Dialability":{"properties":{"label":{"$ref":"#/components/schemas/ReadinessLabel"},"channel":{"anyOf":[{"$ref":"#/components/schemas/ReadinessLabel"},{"type":"null"}]},"will_dial":{"type":"boolean","title":"Will Dial","description":"Passes the use case's current dial gate when this line is selected."},"reason":{"anyOf":[{"$ref":"#/components/schemas/UseCaseDialability"},{"type":"string","const":"use_case_missing"}],"title":"Reason"}},"type":"object","required":["label","channel","will_dial","reason"],"title":"Dialability"},"UseCaseDialability":{"type":"string","enum":["own_number","listed","not_listed"]},"BoundFamily":{"properties":{"version_set":{"$ref":"#/components/schemas/ReadinessLabel"},"family":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Family"},"source":{"type":"string","enum":["service","agent","engine_default","agent_missing"],"title":"Source"},"capabilities":{"anyOf":[{"$ref":"#/components/schemas/SessionCapabilities"},{"type":"null"}]},"dynamic_behaviors_configured":{"type":"boolean","title":"Dynamic Behaviors Configured"},"ignored_settings":{"items":{"type":"string"},"type":"array","title":"Ignored Settings","description":"The service settings, as dotted paths from the service (keyterms, voice_config.max_buffer_delay_ms), that the service sets to a non-default value and this family does not read. Advisory: the config is valid and saves, and a setting listed here may still be refused (see family_refusals). Empty, and not known, when ignored_settings_known is false."},"ignored_settings_known":{"type":"boolean","title":"Ignored Settings Known","description":"Whether ignored_settings was read: false when the version set's family is unknown or the stored service no longer validates, so an empty list says nothing."},"family_judgement":{"type":"string","enum":["judged","not_judged"],"title":"Family Judgement","description":"judged: family_refusals is every refusal the voice family contract and the family's delivery rules find for this version set, empty when the family runs it as authored. not_judged: the version set could not be judged (family_not_judged says why), so family_refusals may be incomplete and an empty one is never a pass."},"family_refusals":{"items":{"$ref":"#/components/schemas/FamilyRefusal"},"type":"array","title":"Family Refusals","description":"Each reason the family cannot run this version set as stored, with the code, message and fields a save refuses it with: the family's admission for the workspace when the service names the family, its delivery rules held to the whole config, then the contract's rules on the program the set's agent version runs. A client shows each one's code, message and fields and computes none. Messages have every digit redacted; a save plan's problems keep the exact text."},"family_not_judged":{"anyOf":[{"$ref":"#/components/schemas/FamilyNotJudged"},{"type":"null"}],"description":"Why the version set was not judged, when family_judgement is not_judged; null otherwise."}},"type":"object","required":["version_set","family","source","capabilities","dynamic_behaviors_configured","ignored_settings","ignored_settings_known","family_judgement","family_refusals","family_not_judged"],"title":"BoundFamily"},"Policies":{"properties":{"forward_call_configured":{"type":"boolean","title":"Forward Call Configured"},"warm_transfer":{"type":"boolean","title":"Warm Transfer"},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss"},"hours_configured":{"type":"boolean","title":"Hours Configured"},"default_destination_configured":{"type":"boolean","title":"Default Destination Configured","description":"A dynamic service names the line a transfer dials when the agent names none."},"transfer_reasons":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Transfer Reasons","description":"The keys of the reasons every forward_call names and the call records, empty when none."},"destination_hours_configured":{"type":"boolean","title":"Destination Hours Configured"},"verification_callers_configured":{"type":"boolean","title":"Verification Callers Configured"},"unsupported_language_route":{"type":"boolean","title":"Unsupported Language Route"}},"type":"object","required":["forward_call_configured","warm_transfer","warm_transfer_on_queue","warm_transfer_on_miss","hours_configured","default_destination_configured","transfer_reasons","destination_hours_configured","verification_callers_configured","unsupported_language_route"],"title":"Policies"},"Launch":{"properties":{"demo_mode":{"type":"boolean","title":"Demo Mode"},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending"},"output_check_modes":{"$ref":"#/components/schemas/OutputCheckModes"},"test_callers_registered":{"type":"boolean","title":"Test Callers Registered"},"verification_callers_registered":{"type":"boolean","title":"Verification Callers Registered","description":"Every configured verification caller is a registered test caller; false when none are configured."},"human_line_configured":{"type":"boolean","title":"Human Line Configured","description":"A fallback_to or static forward_to is configured for the safe exit; pickup is not verified."},"answer_hours_configured":{"type":"boolean","title":"Answer Hours Configured","description":"The voice config sets answer_hours: outside them the agent takes no call."},"readiness_requires":{"items":{"type":"string","enum":["binding","service_active","residency","fleet","valkey","lakebase","platform_api","outside_answer_hours","openai_realtime","decisions","warehouse"]},"type":"array","title":"Readiness Requires","description":"What the live voice-call readiness check gates this service's phone calls on: the base set every call needs, outside_answer_hours when answer_hours are set, then the voice config's saved readiness_requires."},"effective_voice":{"anyOf":[{"$ref":"#/components/schemas/EffectiveVoice"},{"type":"null"}],"description":"What a gpt_realtime release version set opens its session with once each null model, voice and reasoning_effort resolves to the runtime's default. Null for any other family."}},"type":"object","required":["demo_mode","medical_emergency_ending","output_check_modes","test_callers_registered","verification_callers_registered","human_line_configured","answer_hours_configured","readiness_requires","effective_voice"],"title":"Launch"},"OutputCheckModes":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/ReadinessLabel"}},"type":"object","required":["phi_unverified"],"title":"OutputCheckModes","description":"Mode values follow the library's read model as it adds supported modes."},"EffectiveVoice":{"properties":{"session_provider":{"type":"string","const":"gpt_realtime","title":"Session Provider"},"model":{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"],"title":"Model"},"voice":{"type":"string","maxLength":256,"title":"Voice"},"reasoning_effort":{"type":"string","enum":["minimal","low","medium","high","xhigh"],"title":"Reasoning Effort"}},"type":"object","required":["session_provider","model","voice","reasoning_effort"],"title":"EffectiveVoice"},"Unavailable":{"type":"string","enum":["agent_not_in_workspace","version_not_found","config_unreadable","config_incompatible","channel_manager_unavailable"]}}}}
```

## The ServicePromotionReceipt object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServicePromotionReceipt":{"properties":{"promotion_id":{"type":"string","format":"uuid","title":"Promotion Id"},"request_id":{"type":"string","format":"uuid","title":"Request Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"target_version_set":{"type":"string","title":"Target Version Set"},"request_fingerprint":{"type":"string","title":"Request Fingerprint","description":"`sha256:` over the canonical request. The same `request_id` with another request is refused."},"reviewed_base":{"items":{"$ref":"#/components/schemas/ReviewedVersionSet"},"type":"array","title":"Reviewed Base","description":"The digests the promotion held to, each recomputed in its transaction."},"base_updated_at":{"type":"string","format":"date-time","title":"Base Updated At","description":"The service's `updated_at` the promotion replaced."},"service_config_digest":{"type":"string","title":"Service Config Digest","description":"The `service_config_digest` a session of `target_version_set` loads from the promoted configuration. A run\nbelongs to this promotion when it records this digest."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"The service's `updated_at` after the promotion: the `expected_updated_at` of the next conditional write."},"promoted_at":{"type":"string","format":"date-time","title":"Promoted At"}},"type":"object","required":["promotion_id","request_id","workspace_id","service_id","target_version_set","request_fingerprint","reviewed_base","base_updated_at","service_config_digest","updated_at","promoted_at"],"title":"ServicePromotionReceipt","description":"What one promotion stored, as recorded in the transaction that stored it."},"ReviewedVersionSet":{"properties":{"version_set":{"type":"string","maxLength":40,"minLength":1,"title":"Version Set"},"service_config_digest":{"type":"string","maxLength":71,"pattern":"^sha256:[0-9a-f]{64}$","title":"Service Config Digest","description":"The `service_config_digest` `GET .../configuration-identity` answered for the set, which a run of it records."}},"type":"object","required":["version_set","service_config_digest"],"title":"ReviewedVersionSet","description":"One version set the caller reviewed, by the digest of the configuration a session of it loaded."}}}}
```

## The ServiceReadinessResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceReadinessResponse":{"properties":{"voice_use_cases":{"items":{"$ref":"#/components/schemas/VoiceUseCase"},"type":"array","title":"Voice Use Cases"},"lines":{"items":{"$ref":"#/components/schemas/Line"},"type":"array","title":"Lines"},"families":{"items":{"$ref":"#/components/schemas/BoundFamily"},"type":"array","title":"Families"},"starts":{"items":{"$ref":"#/components/schemas/VersionSetStarts"},"type":"array","title":"Starts","description":"Each version set, release first, with the starts its service takes: a client offers these and no other. A kind listed is one the platform runs for this service's channel and family; it is not a judgement that the start succeeds (families[].family_judgement and family_refusals say that). Every service has an entry per version set, a text one too."},"policies":{"$ref":"#/components/schemas/Policies"},"launch":{"$ref":"#/components/schemas/Launch"}},"type":"object","required":["voice_use_cases","lines","families","starts","policies","launch"],"title":"ServiceReadinessResponse"},"VoiceUseCase":{"properties":{"label":{"$ref":"#/components/schemas/ReadinessLabel"},"channel":{"anyOf":[{"$ref":"#/components/schemas/ReadinessLabel"},{"type":"null"}]},"available":{"type":"boolean","title":"Available"},"fallback_forwarding_number_set":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Fallback Forwarding Number Set","description":"Whether an inbound voice use case has a fallback forwarding number, where inbound calls forward when channel-manager does not answer. Informational: unset does not block a save. Null for an outbound or unavailable use case. The number itself is never returned."}},"type":"object","required":["label","channel","available","fallback_forwarding_number_set"],"title":"VoiceUseCase"},"ReadinessLabel":{"type":"string"},"Line":{"properties":{"kind":{"$ref":"#/components/schemas/LineKind"},"label":{"$ref":"#/components/schemas/ReadinessLabel"},"use_cases":{"items":{"$ref":"#/components/schemas/Dialability"},"type":"array","title":"Use Cases"}},"type":"object","required":["kind","label","use_cases"],"title":"Line"},"LineKind":{"type":"string","enum":["forward_to","approved_destination","fallback_to","after_hours_destination","test_destination"]},"Dialability":{"properties":{"label":{"$ref":"#/components/schemas/ReadinessLabel"},"channel":{"anyOf":[{"$ref":"#/components/schemas/ReadinessLabel"},{"type":"null"}]},"will_dial":{"type":"boolean","title":"Will Dial","description":"Passes the use case's current dial gate when this line is selected."},"reason":{"anyOf":[{"$ref":"#/components/schemas/UseCaseDialability"},{"type":"string","const":"use_case_missing"}],"title":"Reason"}},"type":"object","required":["label","channel","will_dial","reason"],"title":"Dialability"},"UseCaseDialability":{"type":"string","enum":["own_number","listed","not_listed"]},"BoundFamily":{"properties":{"version_set":{"$ref":"#/components/schemas/ReadinessLabel"},"family":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Family"},"source":{"type":"string","enum":["service","agent","engine_default","agent_missing"],"title":"Source"},"capabilities":{"anyOf":[{"$ref":"#/components/schemas/SessionCapabilities"},{"type":"null"}]},"dynamic_behaviors_configured":{"type":"boolean","title":"Dynamic Behaviors Configured"},"ignored_settings":{"items":{"type":"string"},"type":"array","title":"Ignored Settings","description":"The service settings, as dotted paths from the service (keyterms, voice_config.max_buffer_delay_ms), that the service sets to a non-default value and this family does not read. Advisory: the config is valid and saves, and a setting listed here may still be refused (see family_refusals). Empty, and not known, when ignored_settings_known is false."},"ignored_settings_known":{"type":"boolean","title":"Ignored Settings Known","description":"Whether ignored_settings was read: false when the version set's family is unknown or the stored service no longer validates, so an empty list says nothing."},"family_judgement":{"type":"string","enum":["judged","not_judged"],"title":"Family Judgement","description":"judged: family_refusals is every refusal the voice family contract and the family's delivery rules find for this version set, empty when the family runs it as authored. not_judged: the version set could not be judged (family_not_judged says why), so family_refusals may be incomplete and an empty one is never a pass."},"family_refusals":{"items":{"$ref":"#/components/schemas/FamilyRefusal"},"type":"array","title":"Family Refusals","description":"Each reason the family cannot run this version set as stored, with the code, message and fields a save refuses it with: the family's admission for the workspace when the service names the family, its delivery rules held to the whole config, then the contract's rules on the program the set's agent version runs. A client shows each one's code, message and fields and computes none. Messages have every digit redacted; a save plan's problems keep the exact text."},"family_not_judged":{"anyOf":[{"$ref":"#/components/schemas/FamilyNotJudged"},{"type":"null"}],"description":"Why the version set was not judged, when family_judgement is not_judged; null otherwise."}},"type":"object","required":["version_set","family","source","capabilities","dynamic_behaviors_configured","ignored_settings","ignored_settings_known","family_judgement","family_refusals","family_not_judged"],"title":"BoundFamily"},"SessionCapabilities":{"properties":{"multi_state":{"type":"boolean","title":"Multi State"},"dynamic_behaviors":{"type":"boolean","title":"Dynamic Behaviors"},"completion_navigation":{"type":"boolean","title":"Completion Navigation"},"channels":{"items":{"type":"string","enum":["app","phone","playground","test_call"]},"type":"array","title":"Channels"},"outbound_calls":{"type":"boolean","title":"Outbound Calls"},"operator_takeover":{"type":"boolean","title":"Operator Takeover"},"end_call":{"type":"boolean","title":"End Call"},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"authored_lines":{"type":"string","enum":["tts","model_checked","clips"],"title":"Authored Lines","default":"clips"},"floor_enforced":{"type":"boolean","title":"Floor Enforced","default":false},"state_carrier":{"anyOf":[{"type":"string","enum":["session_update_and_note","note_only"]},{"type":"null"}],"title":"State Carrier"},"typed_guardrails":{"type":"boolean","title":"Typed Guardrails","default":false}},"type":"object","required":["multi_state","dynamic_behaviors","completion_navigation","channels","outbound_calls","operator_takeover","end_call","warm_transfer","authored_lines","floor_enforced","state_carrier","typed_guardrails"],"title":"SessionCapabilities"},"FamilyRefusal":{"properties":{"code":{"anyOf":[{"$ref":"#/components/schemas/FamilyRefusalCode"},{"type":"string","enum":["family_warm_transfer_unsupported","family_cannot_speak_service_lines"]}],"title":"Code"},"message":{"$ref":"#/components/schemas/ReadinessLabel","description":"Names the family and the fix, with every digit redacted."},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"What the author changes, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyRefusal"},"FamilyRefusalCode":{"type":"string","enum":["voice_family_not_served","voice_family_residency","voice_family_agent_version","voice_family_direct_program","voice_family_graph_shape","voice_family_guardrails","voice_family_dynamic_behaviors","voice_family_completion_navigation","voice_family_warm_transfer","voice_family_service_lines","voice_family_outbound","voice_family_settings"]},"FamilyNotJudged":{"properties":{"code":{"$ref":"#/components/schemas/FamilyNotJudgedCode"},"message":{"$ref":"#/components/schemas/ReadinessLabel"},"fields":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Fields","description":"Where the author looks, as dotted paths."}},"type":"object","required":["code","message","fields"],"title":"FamilyNotJudged"},"FamilyNotJudgedCode":{"type":"string","enum":["agent_version_missing","family_not_on_contract","voice_config_unreadable","graph_missing","graph_version_missing","graph_version_unreadable"]},"VersionSetStarts":{"properties":{"version_set":{"$ref":"#/components/schemas/ReadinessLabel"},"kinds":{"items":{"$ref":"#/components/schemas/StartKind"},"type":"array","title":"Kinds"},"kinds_known":{"type":"boolean","title":"Kinds Known","description":"False when the version set's family is unknown (families[].source is agent_missing): kinds is then empty and says nothing; a client offers no start from it and shows why."}},"type":"object","required":["version_set","kinds","kinds_known"],"title":"VersionSetStarts"},"StartKind":{"type":"string","enum":["text","test_call","app_session"]},"Policies":{"properties":{"forward_call_configured":{"type":"boolean","title":"Forward Call Configured"},"warm_transfer":{"type":"boolean","title":"Warm Transfer"},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss"},"hours_configured":{"type":"boolean","title":"Hours Configured"},"default_destination_configured":{"type":"boolean","title":"Default Destination Configured","description":"A dynamic service names the line a transfer dials when the agent names none."},"transfer_reasons":{"items":{"$ref":"#/components/schemas/ReadinessLabel"},"type":"array","title":"Transfer Reasons","description":"The keys of the reasons every forward_call names and the call records, empty when none."},"destination_hours_configured":{"type":"boolean","title":"Destination Hours Configured"},"verification_callers_configured":{"type":"boolean","title":"Verification Callers Configured"},"unsupported_language_route":{"type":"boolean","title":"Unsupported Language Route"}},"type":"object","required":["forward_call_configured","warm_transfer","warm_transfer_on_queue","warm_transfer_on_miss","hours_configured","default_destination_configured","transfer_reasons","destination_hours_configured","verification_callers_configured","unsupported_language_route"],"title":"Policies"},"Launch":{"properties":{"demo_mode":{"type":"boolean","title":"Demo Mode"},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending"},"output_check_modes":{"$ref":"#/components/schemas/OutputCheckModes"},"test_callers_registered":{"type":"boolean","title":"Test Callers Registered"},"verification_callers_registered":{"type":"boolean","title":"Verification Callers Registered","description":"Every configured verification caller is a registered test caller; false when none are configured."},"human_line_configured":{"type":"boolean","title":"Human Line Configured","description":"A fallback_to or static forward_to is configured for the safe exit; pickup is not verified."},"answer_hours_configured":{"type":"boolean","title":"Answer Hours Configured","description":"The voice config sets answer_hours: outside them the agent takes no call."},"readiness_requires":{"items":{"type":"string","enum":["binding","service_active","residency","fleet","valkey","lakebase","platform_api","outside_answer_hours","openai_realtime","decisions","warehouse"]},"type":"array","title":"Readiness Requires","description":"What the live voice-call readiness check gates this service's phone calls on: the base set every call needs, outside_answer_hours when answer_hours are set, then the voice config's saved readiness_requires."},"effective_voice":{"anyOf":[{"$ref":"#/components/schemas/EffectiveVoice"},{"type":"null"}],"description":"What a gpt_realtime release version set opens its session with once each null model, voice and reasoning_effort resolves to the runtime's default. Null for any other family."}},"type":"object","required":["demo_mode","medical_emergency_ending","output_check_modes","test_callers_registered","verification_callers_registered","human_line_configured","answer_hours_configured","readiness_requires","effective_voice"],"title":"Launch"},"OutputCheckModes":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/ReadinessLabel"}},"type":"object","required":["phi_unverified"],"title":"OutputCheckModes","description":"Mode values follow the library's read model as it adds supported modes."},"EffectiveVoice":{"properties":{"session_provider":{"type":"string","const":"gpt_realtime","title":"Session Provider"},"model":{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"],"title":"Model"},"voice":{"type":"string","maxLength":256,"title":"Voice"},"reasoning_effort":{"type":"string","enum":["minimal","low","medium","high","xhigh"],"title":"Reasoning Effort"}},"type":"object","required":["session_provider","model","voice","reasoning_effort"],"title":"EffectiveVoice"}}}}
```

## The ServiceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"agent_id":{"type":"string","format":"uuid","title":"Agent Id"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id","description":"The context graph the service binds. Null on a service that binds none: it runs direct programs only."},"agent_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Name"},"context_graph_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Context Graph Name"},"keyterms":{"items":{"type":"string"},"type":"array","title":"Keyterms"},"is_active":{"type":"boolean","title":"Is Active"},"version_sets":{"additionalProperties":{"$ref":"#/components/schemas/VersionSet-Output"},"type":"object","title":"Version Sets"},"tags":{"items":{"$ref":"#/components/schemas/ServiceTag"},"type":"array","title":"Tags"},"tool_capacity":{"type":"integer","title":"Tool Capacity"},"channel_type":{"type":"string","enum":["voice","text"],"title":"Channel Type","default":"voice"},"environment":{"type":"string","enum":["sandbox","production"],"title":"Environment","default":"production"},"demo_mode":{"type":"boolean","title":"Demo Mode","description":"Voice calls on this service open with only the recording notice, without the AI disclosure. For demos only,\nnever for a service that takes real callers.","default":false},"platform_caller_verification":{"type":"boolean","title":"Platform Caller Verification","description":"Whether the platform verifies a caller who may match a patient record by full name and date of\nbirth. Off, the agent never asks a caller to verify, and every platform tool that reads a patient\nrecord refuses. The service's integration tools run either way, unless one of them verifies its\ncallers (`caller_verification_endpoint_id`).","default":true},"caller_verification_endpoint_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Caller Verification Endpoint Id","description":"The integration endpoint that verifies this service's callers, or null when none does."},"allow_unverified_integration_results":{"type":"boolean","title":"Allow Unverified Integration Results","description":"A dangerous bypass, off by default. On, results from the service's integration endpoints, reads and\nwrites, never count as a patient record for the output checker's unverified-caller check\n(`output_checks.phi_unverified`, which runs only on a service that sets it to `cut`), so the agent may read\nthem back to any caller, verified or not. Writes are still held to everything else, the platform's own\npatient reads still refuse until the caller verifies, and data queries and skills still count. Never on\nbeside `caller_verification_endpoint_id`. Every change is audited.","default":false},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/ServiceVoiceConfig-Output"},{"type":"null"}]},"accepted_context":{"items":{"$ref":"#/components/schemas/ContextKeySpec"},"type":"array","title":"Accepted Context"},"crisis_call_911_reply":{"anyOf":[{"$ref":"#/components/schemas/CrisisCall911Reply"},{"type":"null"}]},"contact_lines":{"items":{"$ref":"#/components/schemas/ContactLine"},"type":"array","maxItems":50,"title":"Contact Lines","description":"Declared direct contact lines. Public emergency and N11 short codes are refused."},"medical_emergency_ending":{"type":"string","enum":["stay_on_line","end_after_script"],"title":"Medical Emergency Ending","description":"How a voice call ends after a medical emergency's script: ``stay_on_line`` (the default) or\n``end_after_script``, which plays the authored closing line and then ends the call. A self-harm or\ncrisis statement keeps the call open in either.","default":"stay_on_line"},"output_checks":{"$ref":"#/components/schemas/ServiceOutputChecks","description":"The checks the service's calls run: its own block over the workspace defaults. Where each value comes from:\n`GET /v1/{workspace_id}/services/{service_id}/safety`."},"emergency_floor":{"$ref":"#/components/schemas/ServiceEmergencyFloor","description":"How the floor acts on the service's text conversations: its own block over the workspace defaults. Where each\nvalue comes from: `GET /v1/{workspace_id}/services/{service_id}/safety`."},"conversation_audit":{"$ref":"#/components/schemas/ConversationAuditSettings","description":"The post-call transcript quality audit, off unless the service turns it on."},"declared_languages":{"anyOf":[{"items":{"type":"string","enum":["en","es","ar","fr","de","pt","zh","ja","ko"]},"type":"array","maxItems":9,"minItems":1},{"type":"null"}],"title":"Declared Languages","description":"The languages this service serves, as ISO 639-1 codes. None: none declared."},"effective_harnesses":{"anyOf":[{"items":{"$ref":"#/components/schemas/EffectiveHarness"},"type":"array"},{"type":"null"}],"title":"Effective Harnesses","description":"The release each voice and text harness that has a platform default runs on the service's calls: its pin, else\nthe harness default. Set by the single-service GET, left out of lists. `GET .../services/{service_id}/harnesses`\nlists only the harnesses the service runs."},"is_system":{"type":"boolean","title":"Is System","default":false},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","name","description","agent_id","context_graph_id","keyterms","is_active","version_sets","tags","tool_capacity","created_at","updated_at"],"title":"ServiceResponse"},"VersionSet-Output":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"ServiceTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"ServiceTag"},"ServiceVoiceConfig-Output":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingResponse"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingResponse":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to","warm_transfer","warm_transfer_answer_timeout_s","warm_transfer_on_queue","warm_transfer_on_miss","receiver_classifier","approved_destinations","fallback_to","test_destinations","verification_callers","hours","after_hours_destination","default_destination","transfer_reasons","destination_hours","unsupported_language_destination"],"title":"ServiceForwardingResponse","description":"Forwarding responses always include defaults; the input keeps its existing schema name."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."},"ContextKeySpec":{"properties":{"key":{"$ref":"#/components/schemas/SlugString"},"type":{"type":"string","enum":["string","number"],"title":"Type"},"description":{"$ref":"#/components/schemas/DescriptionString"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["key","type","description","required"],"title":"ContextKeySpec","description":"One key a conversation may supply as start-time context for a service.\n\nThe value is validated against ``type`` at conversation start; a tool can then\nbind the key to one of its parameters (injected, hidden from the model)."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"CrisisCall911Reply":{"properties":{"en":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1},"es":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1}},"additionalProperties":false,"type":"object","required":["en","es"],"title":"CrisisCall911Reply","description":"Per-service wording added when a caller already in crisis asks for emergency dispatch."},"ContactLine":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"type":"string","maxLength":16,"minLength":2,"title":"Number"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLine","description":"A service's declared contact line."},"ServiceOutputChecks":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck"},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck"},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck"},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck"},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck"},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck"},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck"},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck"},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck"}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecks"},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"},"ServiceEmergencyFloor":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor"},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor"},"held_text":{"$ref":"#/components/schemas/HeldTextFloor"}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloor"},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"},"ConversationAuditSettings":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"checks":{"items":{"$ref":"#/components/schemas/ConversationAuditCheck"},"type":"array","maxItems":4,"minItems":1,"title":"Checks"},"threshold":{"type":"integer","maximum":100,"minimum":1,"title":"Threshold","default":80}},"additionalProperties":false,"type":"object","title":"ConversationAuditSettings"},"ConversationAuditCheck":{"type":"string","enum":["obvious_errors","missed_escalation","wrong_information","missed_safety_event"]},"EffectiveHarness":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Repo"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"The release tag, or ``in-tree``. None when ``error`` is set."},"asset":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Asset"},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256"},"source":{"type":"string","enum":["pin","harness_default","invalid_pin"],"title":"Source","description":"``invalid_pin``: the service stores a pin of this harness that no longer validates. The entry names no\nrelease, so the harness has nothing to run until the pin is set again. A ``pin`` or ``harness_default`` with an\n``error`` names a release the platform may no longer run, and names no release either."},"contract_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Contract Version","description":"The contract the release was built on, from the registry. None for ``in-tree`` and when ``error`` is set."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the harness has nothing to run on the service: its stored pin is invalid, or its pin or default names a\nrelease or a policy the platform may no longer run (revoked, unregistered, or off the supported contract range),\nor its pin names a harness the service does not run.\nSet, the entry names no release and no policy, so the harness has nothing to run. None otherwise."},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"The policy release the harness runs the values of: the pin's, else the default's. None when neither names one,\nand when ``error`` is set."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","source","contract_version","error","policy"],"title":"EffectiveHarness","description":"The release one harness runs on a service, and where that came from. ``repo``, ``asset`` and ``sha256`` are\nNone for ``in-tree``. agent-engine loads the wheel it baked at ``/opt/harnesses/<sha256>/``."},"HarnessKind":{"type":"string","enum":["voice","text"]},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."}}}}
```

## The ServiceSettingsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceSettingsResponse":{"properties":{"settings":{"additionalProperties":{"$ref":"#/components/schemas/SettingValue"},"type":"object","title":"Settings","description":"The service's own values, every one stored, including a value only a harness the service does not run\ndeclares."},"harnesses":{"items":{"$ref":"#/components/schemas/HarnessSettings"},"type":"array","title":"Harnesses","description":"Each harness the service runs, its declared settings resolved: the service's value (`source: service`), else\nthe harness default (`source: harness_default`)."}},"type":"object","required":["settings","harnesses"],"title":"ServiceSettingsResponse"},"SettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"HarnessSettings":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","maxLength":64,"minLength":1,"title":"Harness"},"settings":{"additionalProperties":{"$ref":"#/components/schemas/ServedHarnessSetting"},"type":"object","maxProperties":200,"title":"Settings"}},"type":"object","required":["kind","harness"],"title":"HarnessSettings","description":"The settings one harness declares, resolved for a service by platform-api: the service's value, else the\nharness default. Only keys the harness declares are served."},"HarnessKind":{"type":"string","enum":["voice","text"]},"ServedHarnessSetting":{"properties":{"value":{"$ref":"#/components/schemas/HarnessSettingValue"},"source":{"$ref":"#/components/schemas/HarnessSettingSource"}},"type":"object","required":["value","source"],"title":"ServedHarnessSetting","description":"One declared setting's value for a service, and the layer it came from."},"HarnessSettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"HarnessSettingSource":{"type":"string","enum":["harness_default","service","policy"]}}}}
```

## The ServiceSettingsSchemaResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceSettingsSchemaResponse":{"properties":{"harnesses":{"items":{"$ref":"#/components/schemas/HarnessSettingsSchema"},"type":"array","title":"Harnesses","description":"One entry per harness the service runs, in (kind, harness) order: its pin, else the harness default. The\nservice runs a harness of its `channel_type` for each family its version sets run, as a pin write resolves\nthem."}},"type":"object","required":["harnesses"],"title":"ServiceSettingsSchemaResponse"},"HarnessSettingsSchema":{"properties":{"kind":{"type":"string","title":"Kind"},"harness":{"type":"string","title":"Harness"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"The release the service runs, or `in-tree`. None when the harness has nothing to run (its effective entry has\nan `error`); it then lists the in-tree schema."},"harness_version":{"type":"string","title":"Harness Version","description":"The schema's version: the release's, or `0.0.0` for `in-tree`."},"settings":{"items":{"$ref":"#/components/schemas/SettingSpec"},"type":"array","title":"Settings"}},"type":"object","required":["kind","harness","tag","harness_version","settings"],"title":"HarnessSettingsSchema","description":"What one harness the service runs declares."},"SettingSpec":{"properties":{"key":{"type":"string","maxLength":100,"minLength":1,"title":"Key"},"area":{"$ref":"#/components/schemas/SettingArea"},"type":{"$ref":"#/components/schemas/SettingType"},"default":{"$ref":"#/components/schemas/SettingValue"},"minimum":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Minimum"},"maximum":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Maximum"},"choices":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":50,"minItems":1},{"type":"null"}],"title":"Choices"},"max_length":{"anyOf":[{"type":"integer","maximum":10000,"minimum":1},{"type":"null"}],"title":"Max Length"},"unit":{"anyOf":[{"$ref":"#/components/schemas/SettingUnit"},{"type":"null"}]},"scopes":{"items":{"$ref":"#/components/schemas/SettingScope"},"type":"array","maxItems":2,"minItems":1,"title":"Scopes"},"description":{"type":"string","maxLength":500,"minLength":1,"title":"Description"}},"additionalProperties":false,"type":"object","required":["key","area","type","default","scopes","description"],"title":"SettingSpec","description":"One setting a harness declares: its type, bounds, choices, default and where a tenant may set it."},"SettingArea":{"type":"string","enum":["timing","turn_taking","tools","call_control","speech","context","flows","greeting","retries","channel","guardrails","safety"]},"SettingType":{"type":"string","enum":["bool","int","float","duration_ms","enum","string","string_list"]},"SettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"SettingUnit":{"type":"string","enum":["ms","s","tokens","count","percent"]},"SettingScope":{"type":"string","enum":["workspace","service"]}}}}
```

## The ServiceTag object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"ServiceTag"}}}}
```

## The ServiceToolPerformance object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceToolPerformance":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id","description":"The service"},"summary":{"$ref":"#/components/schemas/ToolPerformanceSummary","description":"The service's tool executions in the window"},"trend":{"items":{"$ref":"#/components/schemas/ToolPerformanceTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"The service's trend"}},"type":"object","required":["service_id","summary","trend"],"title":"ServiceToolPerformance","description":"One service's summary and trend: what the route returns for ``service_id`` set to it."},"ToolPerformanceSummary":{"properties":{"total_tool_calls":{"type":"integer","title":"Total Tool Calls","description":"Tool executions"},"total_succeeded":{"type":"integer","title":"Total Succeeded","description":"Tool executions that succeeded"},"total_failed":{"type":"integer","title":"Total Failed","description":"Tool executions that failed"},"overall_failure_rate":{"type":"number","title":"Overall Failure Rate","description":"total_failed over total_tool_calls; 0.0 with no executions"},"avg_failure_rate_per_call":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Failure Rate Per Call","description":"Mean of each call's tool failure rate; null with no tool summaries"}},"type":"object","required":["total_tool_calls","total_succeeded","total_failed","overall_failure_rate"],"title":"ToolPerformanceSummary","description":"Tool executions in the window, over the calls that carry a tool summary."},"ToolPerformanceTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Bucket start as an ISO-8601 timestamp string (granularity follows `interval`)"},"call_count":{"type":"integer","title":"Call Count","description":"Calls in the bucket with a tool summary"},"total_tool_calls":{"type":"integer","title":"Total Tool Calls","description":"Tool executions in the bucket"},"total_failed":{"type":"integer","title":"Total Failed","description":"Tool executions in the bucket that failed"}},"type":"object","required":["date","call_count","total_tool_calls","total_failed"],"title":"ToolPerformanceTrendPoint","description":"One interval bucket of tool performance."}}}}
```

## The ServiceUsage object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceUsage":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service identifier, or null for usage that could not be attributed."},"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["service_id","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ServiceUsage","description":"Usage attributed to one service."}}}}
```

## The ServiceVoiceConfig-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceVoiceConfig-Input":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingConfig-Input"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingConfig-Input":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to"],"title":"ServiceForwardingConfig","description":"Per-service call-forwarding destination + transfer mechanism.\n\nThis block gates the ``forward_call`` tool: None means the agent cannot\ntransfer at all. When present, ``forward_to`` picks the destination mode,\nand the tool schema follows it — a static service gets an argument-less\ntool, a dynamic one gets a required ``phone_number`` that must be one of\n``approved_destinations`` (none approved means no tool). Nothing cascades:\na service is one mode or the other. ``fallback_to`` is no mode: it is the\nline the safe exit dials, in either, and ``forward_call`` never offers it.\nA call tagged as a test reaches only ``test_destinations``, in either mode, unless\nits caller is one of ``verification_callers``.\n``hours`` is none either: on a dynamic service, a transfer outside its staffed\nhours dials ``after_hours_destination`` whichever approved line was asked for, unless that line keeps\nhours of its own in ``destination_hours``.\nA dynamic service can also name a ``default_destination``, the line a transfer that names none dials. A service\nin either mode can list the ``transfer_reasons`` each of its transfers names and the call records."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."}}}}
```

## The ServiceVoiceConfig-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ServiceVoiceConfig-Output":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingResponse"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingResponse":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to","warm_transfer","warm_transfer_answer_timeout_s","warm_transfer_on_queue","warm_transfer_on_miss","receiver_classifier","approved_destinations","fallback_to","test_destinations","verification_callers","hours","after_hours_destination","default_destination","transfer_reasons","destination_hours","unsupported_language_destination"],"title":"ServiceForwardingResponse","description":"Forwarding responses always include defaults; the input keeps its existing schema name."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."}}}}
```

## The SessionCapabilities object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SessionCapabilities":{"properties":{"multi_state":{"type":"boolean","title":"Multi State"},"dynamic_behaviors":{"type":"boolean","title":"Dynamic Behaviors"},"completion_navigation":{"type":"boolean","title":"Completion Navigation"},"channels":{"items":{"type":"string","enum":["app","phone","playground","test_call"]},"type":"array","title":"Channels"},"outbound_calls":{"type":"boolean","title":"Outbound Calls"},"operator_takeover":{"type":"boolean","title":"Operator Takeover"},"end_call":{"type":"boolean","title":"End Call"},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"authored_lines":{"type":"string","enum":["tts","model_checked","clips"],"title":"Authored Lines","default":"clips"},"floor_enforced":{"type":"boolean","title":"Floor Enforced","default":false},"state_carrier":{"anyOf":[{"type":"string","enum":["session_update_and_note","note_only"]},{"type":"null"}],"title":"State Carrier"},"typed_guardrails":{"type":"boolean","title":"Typed Guardrails","default":false}},"type":"object","required":["multi_state","dynamic_behaviors","completion_navigation","channels","outbound_calls","operator_takeover","end_call","warm_transfer","authored_lines","floor_enforced","state_carrier","typed_guardrails"],"title":"SessionCapabilities"}}}}
```

## The SessionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SessionResponse":{"properties":{"id":{"type":"string","title":"Id"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"source":{"anyOf":[{"$ref":"#/components/schemas/DemoSource"},{"type":"null"}]}},"type":"object","required":["id"],"title":"SessionResponse"},"DemoSource":{"properties":{"kind":{"type":"string","const":"published_demo","title":"Kind","default":"published_demo"},"synthetic":{"type":"boolean","const":true,"title":"Synthetic","default":true},"dataset_version":{"type":"string","pattern":"^r[12]_[0-9]{8}_[a-f0-9]{64}$","title":"Dataset Version"},"as_of_date":{"type":"string","format":"date","title":"As Of Date"},"data_through":{"type":"string","format":"date","title":"Data Through"},"event_window_start":{"type":"string","format":"date-time","title":"Event Window Start"},"event_window_end":{"type":"string","format":"date-time","title":"Event Window End"},"observed_before":{"type":"string","format":"date-time","title":"Observed Before"},"recipe_version":{"type":"string","maxLength":100,"minLength":1,"title":"Recipe Version"},"content_sha256":{"type":"string","pattern":"^[a-f0-9]{64}$","title":"Content Sha256"},"logical_table":{"type":"string","title":"Logical Table"},"snapshot_table":{"type":"string","title":"Snapshot Table"},"definitions":{"additionalProperties":{"type":"string"},"type":"object","title":"Definitions"},"table_map":{"additionalProperties":{"$ref":"#/components/schemas/DemoTable"},"type":"object","title":"Table Map"},"definition_records":{"items":{"$ref":"#/components/schemas/DemoDefinition"},"type":"array","title":"Definition Records","default":[]},"event_window_scope":{"anyOf":[{"type":"string","const":"conversations"},{"type":"null"}],"title":"Event Window Scope"}},"additionalProperties":false,"type":"object","required":["dataset_version","as_of_date","data_through","event_window_start","event_window_end","observed_before","recipe_version","content_sha256","logical_table","snapshot_table","definitions"],"title":"DemoSource","description":"Captured provenance, safe to expose with authorized selected evidence."},"DemoTable":{"properties":{"physical_table":{"type":"string","title":"Physical Table"},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"row_count":{"type":"integer","maximum":5000,"minimum":0,"title":"Row Count"},"description":{"type":"string","maxLength":2048,"title":"Description"}},"additionalProperties":false,"type":"object","required":["physical_table","columns","row_count","description"],"title":"DemoTable"},"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"},"DemoDefinition":{"properties":{"id":{"type":"string","maxLength":80,"minLength":1,"title":"Id"},"description":{"type":"string","maxLength":1024,"minLength":1,"title":"Description"},"population":{"type":"string","maxLength":512,"minLength":1,"title":"Population"},"time_basis":{"type":"string","maxLength":512,"minLength":1,"title":"Time Basis"},"units":{"type":"string","maxLength":128,"minLength":1,"title":"Units"}},"additionalProperties":false,"type":"object","required":["id","description","population","time_basis","units"],"title":"DemoDefinition"}}}}
```

## The SetColumnDefaultAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SetColumnDefaultAction":{"properties":{"op":{"type":"string","const":"set_column_default","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"default":{"$ref":"#/components/schemas/Default"}},"type":"object","required":["op","name","default"],"title":"SetColumnDefaultAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"},"Default":{"properties":{"kind":{"type":"string","enum":["literal","uuid_v4","now","current_date"],"title":"Kind"},"value":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value","description":"Only meaningful for ``kind=\"literal\"``. Other kinds ignore it.\nA ``dict`` value is rendered as a JSONB literal — pair it with a\n``jsonb`` column."}},"type":"object","required":["kind"],"title":"Default"}}}}
```

## The SetColumnNullableAction object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SetColumnNullableAction":{"properties":{"op":{"type":"string","const":"set_column_nullable","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"nullable":{"type":"boolean","title":"Nullable"}},"type":"object","required":["op","name","nullable"],"title":"SetColumnNullableAction"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"}}}}
```

## The SetHarnessPinsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SetHarnessPinsRequest":{"properties":{"pins":{"items":{"$ref":"#/components/schemas/HarnessPin"},"type":"array","maxItems":20,"title":"Pins","description":"The service's pins, replacing the ones it has. At most one per harness. A harness left out follows its\ndefault, and `[]` clears every pin."},"drop_orphaned":{"type":"boolean","title":"Drop Orphaned","description":"Delete the service's stored settings that no harness that has a platform default declares on these pins. Left\nfalse, a save that would orphan any is refused with 422 and lists them.","default":false},"expected_updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expected Updated At","description":"The service's `updated_at` these pins were reviewed against, exactly as the service returned it. When the\nservice has changed since, the write is refused with 409 and nothing is stored or dropped, even when the pins\nalready match. Left out, the write is not compared to what the caller last read."}},"type":"object","required":["pins"],"title":"SetHarnessPinsRequest"},"HarnessPin":{"properties":{"repo":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag","description":"A release tag of the harness, e.g. ``grok_voice-v1.2.0`` or ``grok_voice-v1.2.0-hotfix.1``, or ``in-tree``."},"asset":{"anyOf":[{"type":"string","maxLength":256,"minLength":1},{"type":"null"}],"title":"Asset","description":"The wheel's file name on the release."},"sha256":{"anyOf":[{"$ref":"#/components/schemas/Sha256"},{"type":"null"}]},"policy":{"anyOf":[{"$ref":"#/components/schemas/PolicyRef"},{"type":"null"}],"description":"A policy release registered in `policy_releases.json`, named exactly by `repo`, `tag`, `asset` and `sha256`:\nthe values the harness runs. Independent of the release, so `in-tree` can name one. Left out, a pin runs the\ndefault's policy, and a default names none. Stored and audited without the key when left out."},"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","maxLength":64,"minLength":1,"title":"Harness","description":"A voice family (``grok_voice``, ``gpt_live``, ...) or a text provider family (``openai``, ``anthropic``, ...)."}},"type":"object","required":["tag","kind","harness"],"title":"HarnessPin"},"Sha256":{"type":"string"},"PolicyRef":{"properties":{"repo":{"type":"string","maxLength":128,"minLength":1,"title":"Repo"},"tag":{"type":"string","maxLength":128,"minLength":1,"title":"Tag"},"asset":{"type":"string","maxLength":256,"minLength":1,"title":"Asset"},"sha256":{"type":"string","maxLength":64,"minLength":64,"title":"Sha256"}},"type":"object","required":["repo","tag","asset","sha256"],"title":"PolicyRef","description":"A policy release registered in ``policy_releases.json``, named exactly: one family's values for the settings\nCore declares. The image bakes it at ``/opt/harness-policies/<sha256>.json``."},"HarnessKind":{"type":"string","enum":["voice","text"]}}}}
```

## The SetServiceSettingsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SetServiceSettingsRequest":{"properties":{"settings":{"additionalProperties":{"$ref":"#/components/schemas/SettingValue"},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":200,"title":"Settings","description":"The service's values, replacing the ones it has. A key left out runs the harness default, and `{}` clears\nevery value."},"expected_updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expected Updated At","description":"The service's `updated_at` these values were reviewed against, exactly as the service returned it. When the\nservice has changed since, the write is refused with 409 and nothing is stored, even when the values already\nmatch. Left out, the write is not compared to what the caller last read."}},"type":"object","required":["settings"],"title":"SetServiceSettingsRequest"},"SettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]}}}}
```

## The SettingArea object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SettingArea":{"type":"string","enum":["timing","turn_taking","tools","call_control","speech","context","flows","greeting","retries","channel","guardrails","safety"]}}}}
```

## The SettingScope object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SettingScope":{"type":"string","enum":["workspace","service"]}}}}
```

## The SettingSpec object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SettingSpec":{"properties":{"key":{"type":"string","maxLength":100,"minLength":1,"title":"Key"},"area":{"$ref":"#/components/schemas/SettingArea"},"type":{"$ref":"#/components/schemas/SettingType"},"default":{"$ref":"#/components/schemas/SettingValue"},"minimum":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Minimum"},"maximum":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Maximum"},"choices":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":50,"minItems":1},{"type":"null"}],"title":"Choices"},"max_length":{"anyOf":[{"type":"integer","maximum":10000,"minimum":1},{"type":"null"}],"title":"Max Length"},"unit":{"anyOf":[{"$ref":"#/components/schemas/SettingUnit"},{"type":"null"}]},"scopes":{"items":{"$ref":"#/components/schemas/SettingScope"},"type":"array","maxItems":2,"minItems":1,"title":"Scopes"},"description":{"type":"string","maxLength":500,"minLength":1,"title":"Description"}},"additionalProperties":false,"type":"object","required":["key","area","type","default","scopes","description"],"title":"SettingSpec","description":"One setting a harness declares: its type, bounds, choices, default and where a tenant may set it."},"SettingArea":{"type":"string","enum":["timing","turn_taking","tools","call_control","speech","context","flows","greeting","retries","channel","guardrails","safety"]},"SettingType":{"type":"string","enum":["bool","int","float","duration_ms","enum","string","string_list"]},"SettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]},"SettingUnit":{"type":"string","enum":["ms","s","tokens","count","percent"]},"SettingScope":{"type":"string","enum":["workspace","service"]}}}}
```

## The SettingType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SettingType":{"type":"string","enum":["bool","int","float","duration_ms","enum","string","string_list"]}}}}
```

## The SettingUnit object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SettingUnit":{"type":"string","enum":["ms","s","tokens","count","percent"]}}}}
```

## The SettingValue object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SettingValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"type":"string"},"type":"array"}]}}}}
```

## The Sha256 object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Sha256":{"type":"string"}}}}
```

## The SharedPin object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SharedPin":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"revision":{"type":"integer","title":"Revision"},"question":{"type":"string","title":"Question"},"block":{"additionalProperties":true,"type":"object","title":"Block"},"source":{"$ref":"#/components/schemas/PinEvidence"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"},"refreshed_at":{"type":"string","format":"date-time","title":"Refreshed At"},"created_by":{"type":"string","format":"uuid","title":"Created By"},"updated_by":{"type":"string","format":"uuid","title":"Updated By"},"refresh_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Error"},"deleted_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Deleted At"},"undo_until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Undo Until"}},"additionalProperties":false,"type":"object","required":["id","revision","question","block","source","created_at","updated_at","refreshed_at","created_by","updated_by","refresh_error","deleted_at","undo_until"],"title":"SharedPin"},"PinEvidence":{"properties":{"result_id":{"type":"string","format":"uuid","title":"Result Id"},"queried_at":{"type":"string","format":"date-time","title":"Queried At"},"dataset_source":{"anyOf":[{"$ref":"#/components/schemas/DemoSource"},{"type":"null"}]},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"rows":{"items":{"items":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"array"},"type":"array","title":"Rows"}},"additionalProperties":false,"type":"object","required":["result_id","queried_at","columns","rows"],"title":"PinEvidence"},"DemoSource":{"properties":{"kind":{"type":"string","const":"published_demo","title":"Kind","default":"published_demo"},"synthetic":{"type":"boolean","const":true,"title":"Synthetic","default":true},"dataset_version":{"type":"string","pattern":"^r[12]_[0-9]{8}_[a-f0-9]{64}$","title":"Dataset Version"},"as_of_date":{"type":"string","format":"date","title":"As Of Date"},"data_through":{"type":"string","format":"date","title":"Data Through"},"event_window_start":{"type":"string","format":"date-time","title":"Event Window Start"},"event_window_end":{"type":"string","format":"date-time","title":"Event Window End"},"observed_before":{"type":"string","format":"date-time","title":"Observed Before"},"recipe_version":{"type":"string","maxLength":100,"minLength":1,"title":"Recipe Version"},"content_sha256":{"type":"string","pattern":"^[a-f0-9]{64}$","title":"Content Sha256"},"logical_table":{"type":"string","title":"Logical Table"},"snapshot_table":{"type":"string","title":"Snapshot Table"},"definitions":{"additionalProperties":{"type":"string"},"type":"object","title":"Definitions"},"table_map":{"additionalProperties":{"$ref":"#/components/schemas/DemoTable"},"type":"object","title":"Table Map"},"definition_records":{"items":{"$ref":"#/components/schemas/DemoDefinition"},"type":"array","title":"Definition Records","default":[]},"event_window_scope":{"anyOf":[{"type":"string","const":"conversations"},{"type":"null"}],"title":"Event Window Scope"}},"additionalProperties":false,"type":"object","required":["dataset_version","as_of_date","data_through","event_window_start","event_window_end","observed_before","recipe_version","content_sha256","logical_table","snapshot_table","definitions"],"title":"DemoSource","description":"Captured provenance, safe to expose with authorized selected evidence."},"DemoTable":{"properties":{"physical_table":{"type":"string","title":"Physical Table"},"columns":{"items":{"$ref":"#/components/schemas/SqlColumn"},"type":"array","title":"Columns"},"row_count":{"type":"integer","maximum":5000,"minimum":0,"title":"Row Count"},"description":{"type":"string","maxLength":2048,"title":"Description"}},"additionalProperties":false,"type":"object","required":["physical_table","columns","row_count","description"],"title":"DemoTable"},"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"},"DemoDefinition":{"properties":{"id":{"type":"string","maxLength":80,"minLength":1,"title":"Id"},"description":{"type":"string","maxLength":1024,"minLength":1,"title":"Description"},"population":{"type":"string","maxLength":512,"minLength":1,"title":"Population"},"time_basis":{"type":"string","maxLength":512,"minLength":1,"title":"Time Basis"},"units":{"type":"string","maxLength":128,"minLength":1,"title":"Units"}},"additionalProperties":false,"type":"object","required":["id","description","population","time_basis","units"],"title":"DemoDefinition"}}}}
```

## The SignalResponseAlignment object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SignalResponseAlignment":{"properties":{"signal":{"type":"string","maxLength":2000,"minLength":1,"title":"Signal","description":"The signal observed (e.g. caller tone shift, tool result, silence)"},"agent_response":{"type":"string","maxLength":2000,"minLength":1,"title":"Agent Response","description":"What the agent did in response"},"alignment":{"type":"string","enum":["aligned","misaligned","partial"],"title":"Alignment","description":"Whether the response was aligned, misaligned, or partial"},"insight":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Insight","description":"Short insight on why the alignment went the way it did"}},"type":"object","required":["signal","agent_response","alignment"],"title":"SignalResponseAlignment","description":"Whether the agent's response aligned with a salient signal in the call."}}}}
```

## The SilencePolicy object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."}}}}
```

## The SimCaseAssertionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimCaseAssertionResponse":{"properties":{"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"results":{"items":{"$ref":"#/components/schemas/SimulationEvalResultResponse"},"type":"array","title":"Results"},"checks":{"items":{"$ref":"#/components/schemas/EvaluationResultView"},"type":"array","title":"Checks","description":"Normalized per-check view of ``results`` (metric + assertion verdicts),\nso the console renders each drill-down verdict without parsing raw shapes.","readOnly":true}},"type":"object","required":["eval_key","eval_type","checks"],"title":"SimCaseAssertionResponse"},"SimulationEvalResultResponse":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"rationale":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Justification"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"definition":{"additionalProperties":true,"type":"object","title":"Definition"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["eval_key","eval_type","status"],"title":"SimulationEvalResultResponse"},"EvaluationResultView":{"properties":{"source_type":{"type":"string","enum":["metric","assertion"],"title":"Source Type"},"key":{"type":"string","maxLength":128,"title":"Key"},"label":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Label"},"value_type":{"anyOf":[{"type":"string","enum":["numeric","boolean","categorical","text","structured"]},{"type":"null"}],"title":"Value Type"},"evaluation_method":{"anyOf":[{"type":"string","enum":["threshold","equals","contains","regex","tool_called","llm_judge","custom"]},{"type":"null"}],"title":"Evaluation Method"},"grading":{"anyOf":[{"type":"string","enum":["observed_vs_expected","legacy_verdict"]},{"type":"null"}],"title":"Grading","description":"For an LLM-judged assertion: observed_vs_expected (actual is what the judge observed, and the verdict compares it with expected) or legacy_verdict (the judge returned the verdict and observed nothing, so actual is empty). Null otherwise."},"instructions":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Instructions","description":"An llm_boolean assertion's question, with what makes it true or false."},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"expected_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Expected Display"},"actual_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Actual Display"},"verdict":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Verdict"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"rationale":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Rationale"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"run_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"trace_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Trace Id"}},"type":"object","required":["source_type","key","verdict"],"title":"EvaluationResultView","description":"One check as the console renders it, derived from a single eval result.\n\nBoth metric and assertion verdicts normalize to this shape so the frontend\nrenders a check without knowing where the value was stored."}}}}
```

## The SimCasePerfResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimCasePerfResponse":{"properties":{"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"case_name":{"type":"string","maxLength":512,"title":"Case Name"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"measured":{"type":"integer","title":"Measured","description":"passed + failed","default":0},"latest_run_id":{"type":"string","format":"uuid","title":"Latest Run Id"},"latest_run_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Latest Run At"},"assertions":{"items":{"$ref":"#/components/schemas/SimCaseAssertionResponse"},"type":"array","title":"Assertions"}},"type":"object","required":["case_name","latest_run_id"],"title":"SimCasePerfResponse"},"SimCaseAssertionResponse":{"properties":{"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"results":{"items":{"$ref":"#/components/schemas/SimulationEvalResultResponse"},"type":"array","title":"Results"},"checks":{"items":{"$ref":"#/components/schemas/EvaluationResultView"},"type":"array","title":"Checks","description":"Normalized per-check view of ``results`` (metric + assertion verdicts),\nso the console renders each drill-down verdict without parsing raw shapes.","readOnly":true}},"type":"object","required":["eval_key","eval_type","checks"],"title":"SimCaseAssertionResponse"},"SimulationEvalResultResponse":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"rationale":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Justification"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"definition":{"additionalProperties":true,"type":"object","title":"Definition"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["eval_key","eval_type","status"],"title":"SimulationEvalResultResponse"},"EvaluationResultView":{"properties":{"source_type":{"type":"string","enum":["metric","assertion"],"title":"Source Type"},"key":{"type":"string","maxLength":128,"title":"Key"},"label":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Label"},"value_type":{"anyOf":[{"type":"string","enum":["numeric","boolean","categorical","text","structured"]},{"type":"null"}],"title":"Value Type"},"evaluation_method":{"anyOf":[{"type":"string","enum":["threshold","equals","contains","regex","tool_called","llm_judge","custom"]},{"type":"null"}],"title":"Evaluation Method"},"grading":{"anyOf":[{"type":"string","enum":["observed_vs_expected","legacy_verdict"]},{"type":"null"}],"title":"Grading","description":"For an LLM-judged assertion: observed_vs_expected (actual is what the judge observed, and the verdict compares it with expected) or legacy_verdict (the judge returned the verdict and observed nothing, so actual is empty). Null otherwise."},"instructions":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Instructions","description":"An llm_boolean assertion's question, with what makes it true or false."},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"expected_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Expected Display"},"actual_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Actual Display"},"verdict":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Verdict"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"rationale":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Rationale"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"run_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"trace_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Trace Id"}},"type":"object","required":["source_type","key","verdict"],"title":"EvaluationResultView","description":"One check as the console renders it, derived from a single eval result.\n\nBoth metric and assertion verdicts normalize to this shape so the frontend\nrenders a check without knowing where the value was stored."}}}}
```

## The SimMetricPerfResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimMetricPerfResponse":{"properties":{"metric_key":{"type":"string","maxLength":128,"title":"Metric Key"},"label":{"type":"string","maxLength":128,"title":"Label"},"per_run":{"items":{"$ref":"#/components/schemas/SimMetricRunPointResponse"},"type":"array","title":"Per Run"},"results":{"items":{"$ref":"#/components/schemas/SimulationEvalResultResponse"},"type":"array","title":"Results"},"checks":{"items":{"$ref":"#/components/schemas/EvaluationResultView"},"type":"array","title":"Checks","description":"Normalized per-check view of ``results`` (mirrors SimCaseAssertionResponse)\nso the console renders each metric drill-down verdict without parsing raw shapes.","readOnly":true}},"type":"object","required":["metric_key","label","checks"],"title":"SimMetricPerfResponse"},"SimMetricRunPointResponse":{"properties":{"at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"At"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"passed":{"type":"integer","title":"Passed","default":0},"measured":{"type":"integer","title":"Measured","description":"Passed + failed verdicts; error, pending and skipped are excluded","default":0}},"type":"object","title":"SimMetricRunPointResponse","description":"One run's contribution to a metric: the mean value that run (null for\nnon-numeric metrics) plus how many conversations passed / were measured."},"SimulationEvalResultResponse":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"rationale":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Justification"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"definition":{"additionalProperties":true,"type":"object","title":"Definition"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["eval_key","eval_type","status"],"title":"SimulationEvalResultResponse"},"EvaluationResultView":{"properties":{"source_type":{"type":"string","enum":["metric","assertion"],"title":"Source Type"},"key":{"type":"string","maxLength":128,"title":"Key"},"label":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Label"},"value_type":{"anyOf":[{"type":"string","enum":["numeric","boolean","categorical","text","structured"]},{"type":"null"}],"title":"Value Type"},"evaluation_method":{"anyOf":[{"type":"string","enum":["threshold","equals","contains","regex","tool_called","llm_judge","custom"]},{"type":"null"}],"title":"Evaluation Method"},"grading":{"anyOf":[{"type":"string","enum":["observed_vs_expected","legacy_verdict"]},{"type":"null"}],"title":"Grading","description":"For an LLM-judged assertion: observed_vs_expected (actual is what the judge observed, and the verdict compares it with expected) or legacy_verdict (the judge returned the verdict and observed nothing, so actual is empty). Null otherwise."},"instructions":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Instructions","description":"An llm_boolean assertion's question, with what makes it true or false."},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"expected_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Expected Display"},"actual_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Actual Display"},"verdict":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Verdict"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"rationale":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Rationale"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"run_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"trace_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Trace Id"}},"type":"object","required":["source_type","key","verdict"],"title":"EvaluationResultView","description":"One check as the console renders it, derived from a single eval result.\n\nBoth metric and assertion verdicts normalize to this shape so the frontend\nrenders a check without knowing where the value was stored."}}}}
```

## The SimMetricRunPointResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimMetricRunPointResponse":{"properties":{"at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"At"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"passed":{"type":"integer","title":"Passed","default":0},"measured":{"type":"integer","title":"Measured","description":"Passed + failed verdicts; error, pending and skipped are excluded","default":0}},"type":"object","title":"SimMetricRunPointResponse","description":"One run's contribution to a metric: the mean value that run (null for\nnon-numeric metrics) plus how many conversations passed / were measured."}}}}
```

## The SimPerformanceOverviewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimPerformanceOverviewResponse":{"properties":{"overall_pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overall Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"evals_run":{"type":"integer","title":"Evals Run","description":"Passed + failed verdicts: the overall_pass_rate denominator","default":0},"error_count":{"type":"integer","title":"Error Count","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in overall_pass_rate","default":0},"pending_count":{"type":"integer","title":"Pending Count","description":"Verdicts not graded yet; not in overall_pass_rate","default":0},"skipped_count":{"type":"integer","title":"Skipped Count","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in overall_pass_rate","default":0},"needs_attention_count":{"type":"integer","title":"Needs Attention Count","default":0},"runs_analyzed":{"type":"integer","title":"Runs Analyzed","default":0}},"type":"object","title":"SimPerformanceOverviewResponse"}}}}
```

## The SimSuitePerfResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimSuitePerfResponse":{"properties":{"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"suite_name":{"type":"string","maxLength":512,"title":"Suite Name"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"measured":{"type":"integer","title":"Measured","description":"passed + failed","default":0},"latest_run_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Latest Run At"},"cases":{"items":{"$ref":"#/components/schemas/SimCasePerfResponse"},"type":"array","title":"Cases"}},"type":"object","required":["suite_name"],"title":"SimSuitePerfResponse"},"SimCasePerfResponse":{"properties":{"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"case_name":{"type":"string","maxLength":512,"title":"Case Name"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"measured":{"type":"integer","title":"Measured","description":"passed + failed","default":0},"latest_run_id":{"type":"string","format":"uuid","title":"Latest Run Id"},"latest_run_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Latest Run At"},"assertions":{"items":{"$ref":"#/components/schemas/SimCaseAssertionResponse"},"type":"array","title":"Assertions"}},"type":"object","required":["case_name","latest_run_id"],"title":"SimCasePerfResponse"},"SimCaseAssertionResponse":{"properties":{"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"results":{"items":{"$ref":"#/components/schemas/SimulationEvalResultResponse"},"type":"array","title":"Results"},"checks":{"items":{"$ref":"#/components/schemas/EvaluationResultView"},"type":"array","title":"Checks","description":"Normalized per-check view of ``results`` (metric + assertion verdicts),\nso the console renders each drill-down verdict without parsing raw shapes.","readOnly":true}},"type":"object","required":["eval_key","eval_type","checks"],"title":"SimCaseAssertionResponse"},"SimulationEvalResultResponse":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"rationale":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Justification"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"definition":{"additionalProperties":true,"type":"object","title":"Definition"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["eval_key","eval_type","status"],"title":"SimulationEvalResultResponse"},"EvaluationResultView":{"properties":{"source_type":{"type":"string","enum":["metric","assertion"],"title":"Source Type"},"key":{"type":"string","maxLength":128,"title":"Key"},"label":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Label"},"value_type":{"anyOf":[{"type":"string","enum":["numeric","boolean","categorical","text","structured"]},{"type":"null"}],"title":"Value Type"},"evaluation_method":{"anyOf":[{"type":"string","enum":["threshold","equals","contains","regex","tool_called","llm_judge","custom"]},{"type":"null"}],"title":"Evaluation Method"},"grading":{"anyOf":[{"type":"string","enum":["observed_vs_expected","legacy_verdict"]},{"type":"null"}],"title":"Grading","description":"For an LLM-judged assertion: observed_vs_expected (actual is what the judge observed, and the verdict compares it with expected) or legacy_verdict (the judge returned the verdict and observed nothing, so actual is empty). Null otherwise."},"instructions":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Instructions","description":"An llm_boolean assertion's question, with what makes it true or false."},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"expected_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Expected Display"},"actual_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Actual Display"},"verdict":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Verdict"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"rationale":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Rationale"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"run_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"trace_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Trace Id"}},"type":"object","required":["source_type","key","verdict"],"title":"EvaluationResultView","description":"One check as the console renders it, derived from a single eval result.\n\nBoth metric and assertion verdicts normalize to this shape so the frontend\nrenders a check without knowing where the value was stored."}}}}
```

## The SimulationBenchmarkAggregateSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationBenchmarkAggregateSummary":{"properties":{"selected_count":{"type":"integer","title":"Selected Count"},"started_count":{"type":"integer","title":"Started Count"},"skipped_count":{"type":"integer","title":"Skipped Count"},"failed_to_start_count":{"type":"integer","title":"Failed To Start Count"},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"scored_count":{"type":"integer","title":"Scored Count","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"}},"type":"object","required":["selected_count","started_count","skipped_count","failed_to_start_count"],"title":"SimulationBenchmarkAggregateSummary"}}}}
```

## The SimulationBenchmarkBreakdownSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationBenchmarkBreakdownSummary":{"properties":{"run_count":{"type":"integer","title":"Run Count","default":0},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"completed_count":{"type":"integer","title":"Completed Count","default":0},"failed_count":{"type":"integer","title":"Failed Count","default":0},"scored_count":{"type":"integer","title":"Scored Count","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0}},"type":"object","title":"SimulationBenchmarkBreakdownSummary"}}}}
```

## The SimulationBenchmarkCaseResult object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationBenchmarkCaseResult":{"properties":{"case_id":{"type":"string","format":"uuid","title":"Case Id"},"status":{"type":"string","enum":["started","skipped","failed_to_start"],"title":"Status"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"result_pointer":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result Pointer"},"reason":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Reason"}},"type":"object","required":["case_id","status"],"title":"SimulationBenchmarkCaseResult"}}}}
```

## The SimulationBenchmarkPerRunSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationBenchmarkPerRunSummary":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"error":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Error"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"session_ids":{"items":{"type":"string","maxLength":128},"type":"array","title":"Session Ids"},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"terminal_session_count":{"type":"integer","title":"Terminal Session Count","default":0},"scored_session_count":{"type":"integer","title":"Scored Session Count","default":0},"error_session_count":{"type":"integer","title":"Error Session Count","description":"Sessions cut short by the simulator or the platform rather than the agent: the caller LLM,\na step outside the agent's own turn, a turn write or the run's time limit failed. Each has no\nscore and a `score_rationale` of `bridge:error:<end reason>`, so it stays out of `average_score`\nand the pass and fail counts. A session whose agent turn failed (it raised, or ran out of time)\nisn't one of them: it scores 0 with `score_rationale` `bridge:agent_error` or\n`bridge:agent_timeout`, and counts as failed.","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0},"score_rationales":{"items":{"type":"string","maxLength":2000},"type":"array","title":"Score Rationales"},"capability_tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Capability Tags"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"result_pointer":{"additionalProperties":true,"type":"object","title":"Result Pointer"},"immediate_average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Immediate Average Score"},"immediate_passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Immediate Passed"},"immediate_pass_count":{"type":"integer","title":"Immediate Pass Count","default":0},"immediate_fail_count":{"type":"integer","title":"Immediate Fail Count","default":0},"metric_status":{"type":"string","enum":["pending","available","unavailable"],"title":"Metric Status","default":"pending"},"metric_result_count":{"type":"integer","title":"Metric Result Count","default":0},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"}},"type":"object","required":["run_id","service_id","status"],"title":"SimulationBenchmarkPerRunSummary"}}}}
```

## The SimulationBenchmarkResultsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationBenchmarkResultsResponse":{"properties":{"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Run Ids"},"total_runs":{"type":"integer","title":"Total Runs"},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"completed_count":{"type":"integer","title":"Completed Count","default":0},"failed_count":{"type":"integer","title":"Failed Count","default":0},"scored_count":{"type":"integer","title":"Scored Count","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0},"metric_status":{"type":"string","enum":["pending","available","unavailable"],"title":"Metric Status","default":"pending"},"metric_result_count":{"type":"integer","title":"Metric Result Count","default":0},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"capability_breakdown":{"additionalProperties":{"$ref":"#/components/schemas/SimulationBenchmarkBreakdownSummary"},"type":"object","title":"Capability Breakdown"},"missing_run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Missing Run Ids"},"per_run":{"items":{"$ref":"#/components/schemas/SimulationBenchmarkPerRunSummary"},"type":"array","title":"Per Run"}},"type":"object","required":["run_ids","total_runs"],"title":"SimulationBenchmarkResultsResponse"},"SimulationBenchmarkBreakdownSummary":{"properties":{"run_count":{"type":"integer","title":"Run Count","default":0},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"completed_count":{"type":"integer","title":"Completed Count","default":0},"failed_count":{"type":"integer","title":"Failed Count","default":0},"scored_count":{"type":"integer","title":"Scored Count","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0}},"type":"object","title":"SimulationBenchmarkBreakdownSummary"},"SimulationBenchmarkPerRunSummary":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"error":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Error"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"session_ids":{"items":{"type":"string","maxLength":128},"type":"array","title":"Session Ids"},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"terminal_session_count":{"type":"integer","title":"Terminal Session Count","default":0},"scored_session_count":{"type":"integer","title":"Scored Session Count","default":0},"error_session_count":{"type":"integer","title":"Error Session Count","description":"Sessions cut short by the simulator or the platform rather than the agent: the caller LLM,\na step outside the agent's own turn, a turn write or the run's time limit failed. Each has no\nscore and a `score_rationale` of `bridge:error:<end reason>`, so it stays out of `average_score`\nand the pass and fail counts. A session whose agent turn failed (it raised, or ran out of time)\nisn't one of them: it scores 0 with `score_rationale` `bridge:agent_error` or\n`bridge:agent_timeout`, and counts as failed.","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0},"score_rationales":{"items":{"type":"string","maxLength":2000},"type":"array","title":"Score Rationales"},"capability_tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Capability Tags"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"result_pointer":{"additionalProperties":true,"type":"object","title":"Result Pointer"},"immediate_average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Immediate Average Score"},"immediate_passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Immediate Passed"},"immediate_pass_count":{"type":"integer","title":"Immediate Pass Count","default":0},"immediate_fail_count":{"type":"integer","title":"Immediate Fail Count","default":0},"metric_status":{"type":"string","enum":["pending","available","unavailable"],"title":"Metric Status","default":"pending"},"metric_result_count":{"type":"integer","title":"Metric Result Count","default":0},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"}},"type":"object","required":["run_id","service_id","status"],"title":"SimulationBenchmarkPerRunSummary"}}}}
```

## The SimulationBenchmarkRunResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationBenchmarkRunResponse":{"properties":{"batch_id":{"type":"string","format":"uuid","title":"Batch Id"},"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"required_tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Required Tags"},"selected_case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Selected Case Ids"},"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Run Ids"},"cases":{"items":{"$ref":"#/components/schemas/SimulationBenchmarkCaseResult"},"type":"array","title":"Cases"},"skipped_cases":{"items":{"$ref":"#/components/schemas/SimulationBenchmarkCaseResult"},"type":"array","title":"Skipped Cases"},"failed_to_start_cases":{"items":{"$ref":"#/components/schemas/SimulationBenchmarkCaseResult"},"type":"array","title":"Failed To Start Cases"},"aggregate_summary":{"$ref":"#/components/schemas/SimulationBenchmarkAggregateSummary"},"tool_execution":{"$ref":"#/components/schemas/SimulationToolExecution","description":"The tool settings every started case executes with."}},"type":"object","required":["batch_id","required_tags","selected_case_ids","run_ids","cases","skipped_cases","failed_to_start_cases","aggregate_summary","tool_execution"],"title":"SimulationBenchmarkRunResponse"},"SimulationBenchmarkCaseResult":{"properties":{"case_id":{"type":"string","format":"uuid","title":"Case Id"},"status":{"type":"string","enum":["started","skipped","failed_to_start"],"title":"Status"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"result_pointer":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result Pointer"},"reason":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Reason"}},"type":"object","required":["case_id","status"],"title":"SimulationBenchmarkCaseResult"},"SimulationBenchmarkAggregateSummary":{"properties":{"selected_count":{"type":"integer","title":"Selected Count"},"started_count":{"type":"integer","title":"Started Count"},"skipped_count":{"type":"integer","title":"Skipped Count"},"failed_to_start_count":{"type":"integer","title":"Failed To Start Count"},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"scored_count":{"type":"integer","title":"Scored Count","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"}},"type":"object","required":["selected_count","started_count","skipped_count","failed_to_start_count"],"title":"SimulationBenchmarkAggregateSummary"},"SimulationToolExecution":{"properties":{"live_read_tools":{"items":{"$ref":"#/components/schemas/SimulationToolName"},"type":"array","maxItems":64,"title":"Live Read Tools","description":"Read tools that run for real. Each must be a tool the service's simulations can call that `GET /services/{service_id}/tools/resolve` reports as `live_read_eligible`, with no entry in `tool_mocks`. Integration endpoints need `Integration:View`; platform functions and data queries need `Workspace:View`; world reads need `Service:Update`, which every launch requires. A case anchored to an external principal (an entity with an active external role assignment) runs its live reads as that principal, so it also needs `Conversation:CreateForPrincipal`."},"tool_mocks":{"additionalProperties":{"$ref":"#/components/schemas/SimulationToolMockValue"},"propertyNames":{"$ref":"#/components/schemas/SimulationToolName"},"type":"object","maxProperties":64,"title":"Tool Mocks","description":"Tool name to the result it returns in place of a call. Each must be a tool the service's simulations can call; a companion skill is mocked through the tools it calls."}},"additionalProperties":false,"type":"object","title":"SimulationToolExecution","description":"Which tools a simulation launch runs for real, and which return a configured result.\n\nEvery other tool is simulated and returns a dry-run placeholder. Writes never run\nfor real. The settings apply to every case, step and fork of the launch, and to a\nre-drive of an interrupted run. Empty, the default, simulates every tool."},"SimulationToolName":{"type":"string","maxLength":128,"minLength":1},"SimulationToolMockValue":{"type":"string","maxLength":16384}}}}
```

## The SimulationCaseAssertionEval object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."}}}}
```

## The SimulationCaseBooleanAssertionEval object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."}}}}
```

## The SimulationCaseEval object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseEval":{"oneOf":[{"$ref":"#/components/schemas/SimulationCaseMetricEval"},{"$ref":"#/components/schemas/SimulationCaseAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseBooleanAssertionEval"}]},"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"},"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."},"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."}}}}
```

## The SimulationCaseGrounding object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseGrounding":{"properties":{"patient_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Patient Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Start context a run of this case begins with: key-value pairs, each key one the service accepts (`accepted_context`) and each value a string or a number. A tool parameter the service's graph binds to a key is filled from it on every turn and branch. A run is refused, and a suite skips the case, when a required key is missing, a key is not one the service accepts, or a value has the wrong type. A launch's own `context` is added to it and wins where both name a key."}},"type":"object","title":"SimulationCaseGrounding","description":"Optional bindings that start the sim from existing workspace data."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The SimulationCaseLegacyAssertionEval object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseLegacyAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","maxLength":128,"minLength":1,"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"},"grading":{"type":"string","const":"legacy_verdict","title":"Grading","description":"How this assertion is graded: a pass or fail verdict from the legacy judge, with no observed value.","default":"legacy_verdict"}},"type":"object","required":["type","key","assertion_kind","description","expected","params","weight","grading"],"title":"SimulationCaseLegacyAssertionEval","description":"An assertion saved before ``llm_boolean``: ``llm_judge`` or a free-text kind. Returned by reads only.\n\nThe legacy judge grades it with a pass or fail verdict and records no observed\nvalue. Case writes reject this shape, so rewrite it as an ``llm_boolean`` or a\ndeterministic assertion before saving the case's ``evals`` again."}}}}
```

## The SimulationCaseListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SimulationCaseResponse"},"type":"array","title":"Items"},"total":{"type":"integer","minimum":0,"title":"Total","description":"Cases matching the filters and search, across every page."},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","total","has_more"],"title":"SimulationCaseListResponse"},"SimulationCaseResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"description":{"type":"string","maxLength":2000,"title":"Description"},"persona":{"additionalProperties":true,"type":"object","title":"Persona"},"scenario":{"$ref":"#/components/schemas/SimulationCaseScenario"},"grounding":{"$ref":"#/components/schemas/SimulationCaseGrounding"},"evals":{"items":{"$ref":"#/components/schemas/StoredSimulationCaseEval"},"type":"array","title":"Evals"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","description","scenario"],"title":"SimulationCaseResponse","description":"HTTP response shape for durable simulation cases."},"SimulationCaseScenario":{"properties":{"instructions":{"type":"string","maxLength":10000,"minLength":1,"title":"Instructions"},"initial_message":{"type":"string","maxLength":2000,"title":"Initial Message","default":""},"temperament":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Temperament"}},"type":"object","required":["instructions"],"title":"SimulationCaseScenario","description":"Runnable patient-side scenario content for a saved case."},"SimulationCaseGrounding":{"properties":{"patient_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Patient Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Start context a run of this case begins with: key-value pairs, each key one the service accepts (`accepted_context`) and each value a string or a number. A tool parameter the service's graph binds to a key is filled from it on every turn and branch. A run is refused, and a suite skips the case, when a required key is missing, a key is not one the service accepts, or a value has the wrong type. A launch's own `context` is added to it and wins where both name a key."}},"type":"object","title":"SimulationCaseGrounding","description":"Optional bindings that start the sim from existing workspace data."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"StoredSimulationCaseEval":{"oneOf":[{"$ref":"#/components/schemas/SimulationCaseMetricEval"},{"$ref":"#/components/schemas/SimulationCaseAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseBooleanAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseLegacyAssertionEval"}]},"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"},"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."},"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."},"SimulationCaseLegacyAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","maxLength":128,"minLength":1,"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"},"grading":{"type":"string","const":"legacy_verdict","title":"Grading","description":"How this assertion is graded: a pass or fail verdict from the legacy judge, with no observed value.","default":"legacy_verdict"}},"type":"object","required":["type","key","assertion_kind","description","expected","params","weight","grading"],"title":"SimulationCaseLegacyAssertionEval","description":"An assertion saved before ``llm_boolean``: ``llm_judge`` or a free-text kind. Returned by reads only.\n\nThe legacy judge grades it with a pass or fail verdict and records no observed\nvalue. Case writes reject this shape, so rewrite it as an ``llm_boolean`` or a\ndeterministic assertion before saving the case's ``evals`` again."}}}}
```

## The SimulationCaseMetricEval object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"}}}}
```

## The SimulationCaseResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"description":{"type":"string","maxLength":2000,"title":"Description"},"persona":{"additionalProperties":true,"type":"object","title":"Persona"},"scenario":{"$ref":"#/components/schemas/SimulationCaseScenario"},"grounding":{"$ref":"#/components/schemas/SimulationCaseGrounding"},"evals":{"items":{"$ref":"#/components/schemas/StoredSimulationCaseEval"},"type":"array","title":"Evals"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","description","scenario"],"title":"SimulationCaseResponse","description":"HTTP response shape for durable simulation cases."},"SimulationCaseScenario":{"properties":{"instructions":{"type":"string","maxLength":10000,"minLength":1,"title":"Instructions"},"initial_message":{"type":"string","maxLength":2000,"title":"Initial Message","default":""},"temperament":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Temperament"}},"type":"object","required":["instructions"],"title":"SimulationCaseScenario","description":"Runnable patient-side scenario content for a saved case."},"SimulationCaseGrounding":{"properties":{"patient_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Patient Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Start context a run of this case begins with: key-value pairs, each key one the service accepts (`accepted_context`) and each value a string or a number. A tool parameter the service's graph binds to a key is filled from it on every turn and branch. A run is refused, and a suite skips the case, when a required key is missing, a key is not one the service accepts, or a value has the wrong type. A launch's own `context` is added to it and wins where both name a key."}},"type":"object","title":"SimulationCaseGrounding","description":"Optional bindings that start the sim from existing workspace data."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"StoredSimulationCaseEval":{"oneOf":[{"$ref":"#/components/schemas/SimulationCaseMetricEval"},{"$ref":"#/components/schemas/SimulationCaseAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseBooleanAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseLegacyAssertionEval"}]},"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"},"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."},"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."},"SimulationCaseLegacyAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","maxLength":128,"minLength":1,"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"},"grading":{"type":"string","const":"legacy_verdict","title":"Grading","description":"How this assertion is graded: a pass or fail verdict from the legacy judge, with no observed value.","default":"legacy_verdict"}},"type":"object","required":["type","key","assertion_kind","description","expected","params","weight","grading"],"title":"SimulationCaseLegacyAssertionEval","description":"An assertion saved before ``llm_boolean``: ``llm_judge`` or a free-text kind. Returned by reads only.\n\nThe legacy judge grades it with a pass or fail verdict and records no observed\nvalue. Case writes reject this shape, so rewrite it as an ``llm_boolean`` or a\ndeterministic assertion before saving the case's ``evals`` again."}}}}
```

## The SimulationCaseScenario object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCaseScenario":{"properties":{"instructions":{"type":"string","maxLength":10000,"minLength":1,"title":"Instructions"},"initial_message":{"type":"string","maxLength":2000,"title":"Initial Message","default":""},"temperament":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Temperament"}},"type":"object","required":["instructions"],"title":"SimulationCaseScenario","description":"Runnable patient-side scenario content for a saved case."}}}}
```

## The SimulationCoverageGraphResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCoverageGraphResponse":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"total_sessions":{"type":"integer","title":"Total Sessions"},"total_turns":{"type":"integer","title":"Total Turns"},"total_forks":{"type":"integer","title":"Total Forks"},"coverage_percentage":{"type":"number","title":"Coverage Percentage"},"state_nodes":{"items":{"$ref":"#/components/schemas/CoverageStateNode"},"type":"array","title":"State Nodes"},"edges":{"items":{"$ref":"#/components/schemas/CoverageEdge"},"type":"array","title":"Edges"},"tree":{"$ref":"#/components/schemas/CoverageTree"},"sessions":{"items":{"$ref":"#/components/schemas/CoverageSession"},"type":"array","title":"Sessions"},"turns":{"anyOf":[{"items":{"$ref":"#/components/schemas/CoverageTurn"},"type":"array"},{"type":"null"}],"title":"Turns","description":"Every stored turn in order. Set only with include_turns=true."},"metric_status":{"anyOf":[{"type":"string","enum":["pending","available","unavailable"]},{"type":"null"}],"title":"Metric Status","description":"Delayed-metric availability for the run. Set only when the request names a run_id."},"metric_result_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Metric Result Count"},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"}},"type":"object","required":["service_id","run_id","total_sessions","total_turns","total_forks","coverage_percentage","state_nodes","edges","tree","sessions"],"title":"SimulationCoverageGraphResponse","description":"The service's context graph states and transitions, overlaid with the stored turns."},"CoverageStateNode":{"properties":{"id":{"type":"string","title":"Id","description":"The state name."},"type":{"type":"string","title":"Type","description":"The state type in the context graph, or `unknown` for a state seen only in turns."},"theoretical":{"type":"boolean","title":"Theoretical","description":"The state is in the service's context graph."},"observed":{"type":"boolean","title":"Observed","description":"At least one stored turn started in this state."},"turn_count":{"type":"integer","title":"Turn Count"},"session_count":{"type":"integer","title":"Session Count"},"self_loop_count":{"type":"integer","title":"Self Loop Count"},"transition_out_count":{"type":"integer","title":"Transition Out Count"},"pass_count":{"type":"integer","title":"Pass Count"},"fail_count":{"type":"integer","title":"Fail Count"},"unknown_count":{"type":"integer","title":"Unknown Count"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"first_seen_turn":{"type":"integer","title":"First Seen Turn","description":"Index of the first turn that started in this state, or -1."},"tools_used":{"items":{"type":"string"},"type":"array","title":"Tools Used"},"average_empathy_tier":{"type":"number","title":"Average Empathy Tier"},"average_engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Engine Ms"},"average_nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Nav Ms"}},"type":"object","required":["id","type","theoretical","observed","turn_count","session_count","self_loop_count","transition_out_count","pass_count","fail_count","unknown_count","is_terminal","first_seen_turn","tools_used","average_empathy_tier","average_engine_ms","average_nav_ms"],"title":"CoverageStateNode"},"CoverageEdge":{"properties":{"source":{"type":"string","title":"Source"},"target":{"type":"string","title":"Target"},"type":{"type":"string","enum":["transition","self_loop"],"title":"Type"},"theoretical":{"type":"boolean","title":"Theoretical","description":"The transition is an exit condition in the service's context graph."},"observed":{"type":"boolean","title":"Observed"},"frequency":{"type":"integer","title":"Frequency"},"first_seen_turn":{"type":"integer","title":"First Seen Turn","description":"Index of the first turn that took this edge, or -1."}},"type":"object","required":["source","target","type","theoretical","observed","frequency","first_seen_turn"],"title":"CoverageEdge"},"CoverageTree":{"properties":{"root_sessions":{"items":{"type":"string"},"type":"array","title":"Root Sessions"},"forks":{"items":{"$ref":"#/components/schemas/CoverageFork"},"type":"array","title":"Forks"}},"type":"object","required":["root_sessions","forks"],"title":"CoverageTree"},"CoverageFork":{"properties":{"parent_session_id":{"type":"string","title":"Parent Session Id"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index"},"children":{"items":{"type":"string"},"type":"array","title":"Children"}},"type":"object","required":["parent_session_id","fork_turn_index","children"],"title":"CoverageFork"},"CoverageSession":{"properties":{"metric_status":{"anyOf":[{"type":"string","enum":["pending","available","unavailable"]},{"type":"null"}],"title":"Metric Status"},"metric_result_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Metric Result Count"},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"immediate_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Immediate Score","description":"The session's score, the same value as score."},"immediate_score_rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Immediate Score Rationale"},"session_id":{"type":"string","title":"Session Id"},"parent_session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Session Id"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"total_turns":{"type":"integer","title":"Total Turns"},"terminal_reached":{"type":"boolean","title":"Terminal Reached"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["session_id","parent_session_id","fork_turn_index","tags","total_turns","terminal_reached","score","created_at"],"title":"CoverageSession"},"CoverageTurn":{"properties":{"session_id":{"type":"string","title":"Session Id"},"turn_index":{"type":"integer","title":"Turn Index"},"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"caller_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Text"},"agent_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Text"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called"},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details"},"empathy_tier":{"type":"integer","title":"Empathy Tier"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"global_index":{"type":"integer","title":"Global Index"}},"type":"object","required":["session_id","turn_index","state_before","state_after","state_changed","caller_text","agent_text","tools_called","tool_call_details","empathy_tier","is_terminal","created_at","global_index"],"title":"CoverageTurn"},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."}}}}
```

## The SimulationCoveragePathsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationCoveragePathsResponse":{"properties":{"paths":{"items":{"$ref":"#/components/schemas/CoveragePath"},"type":"array","title":"Paths","description":"Most sessions first."}},"type":"object","required":["paths"],"title":"SimulationCoveragePathsResponse"},"CoveragePath":{"properties":{"trajectory":{"items":{"type":"string"},"type":"array","title":"Trajectory","description":"The states the sessions moved through, in order."},"session_count":{"type":"integer","title":"Session Count"},"session_ids":{"items":{"type":"string"},"type":"array","title":"Session Ids"},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"average_turns":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Turns"},"is_complete":{"type":"boolean","title":"Is Complete","description":"At least one session on the path reached a terminal state."}},"type":"object","required":["trajectory","session_count","session_ids","average_score","average_turns","is_complete"],"title":"CoveragePath"}}}}
```

## The SimulationEvalResultResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationEvalResultResponse":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"rationale":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Justification"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"definition":{"additionalProperties":true,"type":"object","title":"Definition"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["eval_key","eval_type","status"],"title":"SimulationEvalResultResponse"}}}}
```

## The SimulationForkResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationForkResponse":{"properties":{"parent_session_id":{"type":"string","title":"Parent Session Id"},"fork_turn_index":{"type":"integer","title":"Fork Turn Index","description":"The parent's turn count when it forked. Each branch's first turn is stored at the next index."},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"branches":{"items":{"$ref":"#/components/schemas/ForkBranch"},"type":"array","title":"Branches"}},"type":"object","required":["parent_session_id","fork_turn_index","service_id","branches"],"title":"SimulationForkResponse","description":"One branch per alternative, in request order."},"ForkBranch":{"properties":{"session_id":{"type":"string","title":"Session Id"},"observation":{"anyOf":[{"$ref":"#/components/schemas/ForkObservation"},{"type":"null"}],"description":"The branch's first turn. Null when the branch failed."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the branch failed. Null when it stepped."},"harness_execution":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessExecution"},{"type":"null"}],"description":"What the branch's turn ran on. Null for a failed branch and when the agent runtime reported none."}},"type":"object","required":["session_id"],"title":"ForkBranch"},"ForkObservation":{"properties":{"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"agent_text":{"type":"string","title":"Agent Text"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called","default":[]},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details","default":[]},"selected_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action"},"empathy_tier":{"type":"integer","title":"Empathy Tier","default":0},"has_pause":{"type":"boolean","title":"Has Pause","default":false},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"caller_text":{"type":"string","title":"Caller Text"}},"type":"object","required":["state_before","state_after","state_changed","agent_text","is_terminal","caller_text"],"title":"ForkObservation"},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."},"SimulationHarnessExecution":{"properties":{"service_config_digest":{"type":"string","title":"Service Config Digest","description":"The digest of the configuration the request's engine loaded."},"harness":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessSelection"},{"type":"null"}],"description":"Null when the request resolved no text harness: a voice service's simulation, or a voice note."},"receipts":{"items":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},"type":"array","title":"Receipts","description":"One receipt per round a release answered, each naming this digest and the selected release's wheel. Empty\nwhen no round ran on a release, whatever is selected: a selection alone is not proof of execution."}},"type":"object","required":["service_config_digest","harness","receipts"],"title":"SimulationHarnessExecution","description":"What one simulation request ran on, as the agent runtime reported it. Nothing here is derived by this API."},"SimulationHarnessSelection":{"properties":{"kind":{"type":"string","const":"text","title":"Kind"},"harness":{"type":"string","title":"Harness","description":"The text provider family the request's rounds were routed for."},"release":{"type":"string","title":"Release","description":"The selected release's tag, or `in-tree`."},"source":{"anyOf":[{"$ref":"#/components/schemas/HarnessSource"},{"type":"string","const":"unresolved"}],"title":"Source","description":"Where the selection came from. `unresolved`: the configuration has no entry for the family."},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256","description":"The selected release wheel's sha256. Null for `in-tree`."}},"type":"object","required":["kind","harness","release","source","sha256"],"title":"SimulationHarnessSelection","description":"The text harness the loaded configuration selects for the request's model family."},"HarnessSource":{"type":"string","enum":["pin","workspace_default","harness_default"]}}}}
```

## The SimulationHarnessExecution object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationHarnessExecution":{"properties":{"service_config_digest":{"type":"string","title":"Service Config Digest","description":"The digest of the configuration the request's engine loaded."},"harness":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessSelection"},{"type":"null"}],"description":"Null when the request resolved no text harness: a voice service's simulation, or a voice note."},"receipts":{"items":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},"type":"array","title":"Receipts","description":"One receipt per round a release answered, each naming this digest and the selected release's wheel. Empty\nwhen no round ran on a release, whatever is selected: a selection alone is not proof of execution."}},"type":"object","required":["service_config_digest","harness","receipts"],"title":"SimulationHarnessExecution","description":"What one simulation request ran on, as the agent runtime reported it. Nothing here is derived by this API."},"SimulationHarnessSelection":{"properties":{"kind":{"type":"string","const":"text","title":"Kind"},"harness":{"type":"string","title":"Harness","description":"The text provider family the request's rounds were routed for."},"release":{"type":"string","title":"Release","description":"The selected release's tag, or `in-tree`."},"source":{"anyOf":[{"$ref":"#/components/schemas/HarnessSource"},{"type":"string","const":"unresolved"}],"title":"Source","description":"Where the selection came from. `unresolved`: the configuration has no entry for the family."},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256","description":"The selected release wheel's sha256. Null for `in-tree`."}},"type":"object","required":["kind","harness","release","source","sha256"],"title":"SimulationHarnessSelection","description":"The text harness the loaded configuration selects for the request's model family."},"HarnessSource":{"type":"string","enum":["pin","workspace_default","harness_default"]}}}}
```

## The SimulationHarnessSelection object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationHarnessSelection":{"properties":{"kind":{"type":"string","const":"text","title":"Kind"},"harness":{"type":"string","title":"Harness","description":"The text provider family the request's rounds were routed for."},"release":{"type":"string","title":"Release","description":"The selected release's tag, or `in-tree`."},"source":{"anyOf":[{"$ref":"#/components/schemas/HarnessSource"},{"type":"string","const":"unresolved"}],"title":"Source","description":"Where the selection came from. `unresolved`: the configuration has no entry for the family."},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256","description":"The selected release wheel's sha256. Null for `in-tree`."}},"type":"object","required":["kind","harness","release","source","sha256"],"title":"SimulationHarnessSelection","description":"The text harness the loaded configuration selects for the request's model family."},"HarnessSource":{"type":"string","enum":["pin","workspace_default","harness_default"]}}}}
```

## The SimulationIntelligenceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationIntelligenceResponse":{"properties":{"session_id":{"type":"string","title":"Session Id"},"intelligence":{"additionalProperties":true,"type":"object","title":"Intelligence"}},"type":"object","required":["session_id","intelligence"],"title":"SimulationIntelligenceResponse"}}}}
```

## The SimulationObservation object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationObservation":{"properties":{"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"agent_text":{"type":"string","title":"Agent Text"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called","default":[]},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details","default":[]},"selected_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action"},"empathy_tier":{"type":"integer","title":"Empathy Tier","default":0},"has_pause":{"type":"boolean","title":"Has Pause","default":false},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"}},"type":"object","required":["state_before","state_after","state_changed","agent_text","is_terminal"],"title":"SimulationObservation"},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."}}}}
```

## The SimulationPerformanceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationPerformanceResponse":{"properties":{"overview":{"$ref":"#/components/schemas/SimPerformanceOverviewResponse"},"metrics":{"items":{"$ref":"#/components/schemas/SimMetricPerfResponse"},"type":"array","title":"Metrics"},"by_case":{"items":{"$ref":"#/components/schemas/SimCasePerfResponse"},"type":"array","title":"By Case"},"by_suite":{"items":{"$ref":"#/components/schemas/SimSuitePerfResponse"},"type":"array","title":"By Suite"}},"type":"object","required":["overview"],"title":"SimulationPerformanceResponse","description":"Aggregated Simulations overview: one request in place of the console's\nformer one-detail-fetch-per-run fan-out."},"SimPerformanceOverviewResponse":{"properties":{"overall_pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overall Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"evals_run":{"type":"integer","title":"Evals Run","description":"Passed + failed verdicts: the overall_pass_rate denominator","default":0},"error_count":{"type":"integer","title":"Error Count","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in overall_pass_rate","default":0},"pending_count":{"type":"integer","title":"Pending Count","description":"Verdicts not graded yet; not in overall_pass_rate","default":0},"skipped_count":{"type":"integer","title":"Skipped Count","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in overall_pass_rate","default":0},"needs_attention_count":{"type":"integer","title":"Needs Attention Count","default":0},"runs_analyzed":{"type":"integer","title":"Runs Analyzed","default":0}},"type":"object","title":"SimPerformanceOverviewResponse"},"SimMetricPerfResponse":{"properties":{"metric_key":{"type":"string","maxLength":128,"title":"Metric Key"},"label":{"type":"string","maxLength":128,"title":"Label"},"per_run":{"items":{"$ref":"#/components/schemas/SimMetricRunPointResponse"},"type":"array","title":"Per Run"},"results":{"items":{"$ref":"#/components/schemas/SimulationEvalResultResponse"},"type":"array","title":"Results"},"checks":{"items":{"$ref":"#/components/schemas/EvaluationResultView"},"type":"array","title":"Checks","description":"Normalized per-check view of ``results`` (mirrors SimCaseAssertionResponse)\nso the console renders each metric drill-down verdict without parsing raw shapes.","readOnly":true}},"type":"object","required":["metric_key","label","checks"],"title":"SimMetricPerfResponse"},"SimMetricRunPointResponse":{"properties":{"at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"At"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"passed":{"type":"integer","title":"Passed","default":0},"measured":{"type":"integer","title":"Measured","description":"Passed + failed verdicts; error, pending and skipped are excluded","default":0}},"type":"object","title":"SimMetricRunPointResponse","description":"One run's contribution to a metric: the mean value that run (null for\nnon-numeric metrics) plus how many conversations passed / were measured."},"SimulationEvalResultResponse":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"rationale":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Justification"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"definition":{"additionalProperties":true,"type":"object","title":"Definition"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["eval_key","eval_type","status"],"title":"SimulationEvalResultResponse"},"EvaluationResultView":{"properties":{"source_type":{"type":"string","enum":["metric","assertion"],"title":"Source Type"},"key":{"type":"string","maxLength":128,"title":"Key"},"label":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Label"},"value_type":{"anyOf":[{"type":"string","enum":["numeric","boolean","categorical","text","structured"]},{"type":"null"}],"title":"Value Type"},"evaluation_method":{"anyOf":[{"type":"string","enum":["threshold","equals","contains","regex","tool_called","llm_judge","custom"]},{"type":"null"}],"title":"Evaluation Method"},"grading":{"anyOf":[{"type":"string","enum":["observed_vs_expected","legacy_verdict"]},{"type":"null"}],"title":"Grading","description":"For an LLM-judged assertion: observed_vs_expected (actual is what the judge observed, and the verdict compares it with expected) or legacy_verdict (the judge returned the verdict and observed nothing, so actual is empty). Null otherwise."},"instructions":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Instructions","description":"An llm_boolean assertion's question, with what makes it true or false."},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"expected_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Expected Display"},"actual_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Actual Display"},"verdict":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Verdict"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"rationale":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Rationale"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"run_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"trace_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Trace Id"}},"type":"object","required":["source_type","key","verdict"],"title":"EvaluationResultView","description":"One check as the console renders it, derived from a single eval result.\n\nBoth metric and assertion verdicts normalize to this shape so the frontend\nrenders a check without knowing where the value was stored."},"SimCasePerfResponse":{"properties":{"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"case_name":{"type":"string","maxLength":512,"title":"Case Name"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"measured":{"type":"integer","title":"Measured","description":"passed + failed","default":0},"latest_run_id":{"type":"string","format":"uuid","title":"Latest Run Id"},"latest_run_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Latest Run At"},"assertions":{"items":{"$ref":"#/components/schemas/SimCaseAssertionResponse"},"type":"array","title":"Assertions"}},"type":"object","required":["case_name","latest_run_id"],"title":"SimCasePerfResponse"},"SimCaseAssertionResponse":{"properties":{"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"results":{"items":{"$ref":"#/components/schemas/SimulationEvalResultResponse"},"type":"array","title":"Results"},"checks":{"items":{"$ref":"#/components/schemas/EvaluationResultView"},"type":"array","title":"Checks","description":"Normalized per-check view of ``results`` (metric + assertion verdicts),\nso the console renders each drill-down verdict without parsing raw shapes.","readOnly":true}},"type":"object","required":["eval_key","eval_type","checks"],"title":"SimCaseAssertionResponse"},"SimSuitePerfResponse":{"properties":{"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"suite_name":{"type":"string","maxLength":512,"title":"Suite Name"},"pass_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pass Rate","description":"passed / (passed + failed); null when there is no passed or failed verdict"},"passed":{"type":"integer","title":"Passed","default":0},"failed":{"type":"integer","title":"Failed","default":0},"error":{"type":"integer","title":"Error","description":"Verdicts where grading broke, or whose conversation the simulation cut short before the agent finished it; not in the pass_rate denominator","default":0},"pending":{"type":"integer","title":"Pending","description":"Verdicts not graded yet; not in the pass_rate denominator","default":0},"skipped":{"type":"integer","title":"Skipped","description":"Verdicts that did not apply, such as on a forked conversation graded through its branches, or that the judge could not answer from the conversation; not in the pass_rate denominator","default":0},"measured":{"type":"integer","title":"Measured","description":"passed + failed","default":0},"latest_run_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Latest Run At"},"cases":{"items":{"$ref":"#/components/schemas/SimCasePerfResponse"},"type":"array","title":"Cases"}},"type":"object","required":["suite_name"],"title":"SimSuitePerfResponse"}}}}
```

## The SimulationProxyErrorResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationProxyErrorResponse":{"properties":{"detail":{"anyOf":[{"type":"string"},{"items":{"additionalProperties":true,"type":"object"},"type":"array"}],"title":"Detail"}},"type":"object","required":["detail"],"title":"SimulationProxyErrorResponse","description":"The error body of the simulation routes that forward to the agent runtime.\n\n`detail` is a string for an error forwarded from the runtime or a configuration error, and a list of\nvalidation error objects for a request that fails validation. Validation and configuration errors return\nHTTP 422, and the routes also declare this body for 404, 502 and 503."}}}}
```

## The SimulationRunEvalCounts object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationRunEvalCounts":{"properties":{"passed":{"type":"integer","minimum":0,"title":"Passed","default":0},"failed":{"type":"integer","minimum":0,"title":"Failed","default":0},"pending":{"type":"integer","minimum":0,"title":"Pending","default":0},"skipped":{"type":"integer","minimum":0,"title":"Skipped","default":0},"error":{"type":"integer","minimum":0,"title":"Error","description":"Verdicts the grader could not produce, plus any whose status is not one of the other four.","default":0}},"type":"object","title":"SimulationRunEvalCounts","description":"A run's evaluation verdicts, counted by status."}}}}
```

## The SimulationRunListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationRunListResponse":{"properties":{"runs":{"items":{"$ref":"#/components/schemas/src__routes__simulations__runs__SimulationRunListResponse__Item"},"type":"array","title":"Runs"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"},"total":{"type":"integer","title":"Total","description":"Runs that match the filters, across every page."}},"type":"object","required":["runs","has_more","total"],"title":"SimulationRunListResponse"},"src__routes__simulations__runs__SimulationRunListResponse__Item":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"branch_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch Name"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"total_sessions":{"type":"integer","title":"Total Sessions"},"total_turns":{"type":"integer","title":"Total Turns"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Failure reason saved by complete-run. Null unless status is failed, and null on\nfailed runs older than the column."},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"}},"type":"object","required":["id","service_id","branch_name","status","tags","total_sessions","total_turns","error","created_at","completed_at"],"title":"Item"}}}}
```

## The SimulationRunParticipant object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationRunParticipant":{"properties":{"binding":{"type":"string","enum":["bound","unbound","unknown"],"title":"Binding","description":"`bound` when the run was started against an entity, `unbound` when it was started\nexplicitly without one, `unknown` when its snapshot does not say."},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"The bound entity. Null unless `binding` is `bound`."},"display_name":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Display Name","description":"The bound entity's display name, else its name. Null when the entity is not in the\nworkspace's world or has neither."},"entity_type":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Entity Type","description":"The bound entity's type, such as `person` or `patient`. Null when the entity is not in\nthe workspace's world."}},"type":"object","required":["binding"],"title":"SimulationRunParticipant","description":"The entity a run simulated, as the run's snapshot and the world record it."}}}}
```

## The SimulationRunResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationRunResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"branch_name":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Branch Name"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"error":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Error"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"objective":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Objective"},"bridge_request":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Bridge Request"},"scenarios":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Scenarios"},"snapshot":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Snapshot"},"total_scenarios_requested":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Scenarios Requested"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"metric_status":{"type":"string","enum":["pending","available","unavailable"],"title":"Metric Status","default":"pending"},"metric_result_count":{"type":"integer","title":"Metric Result Count","default":0},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"eval_results":{"items":{"$ref":"#/components/schemas/SimulationEvalResultResponse"},"type":"array","title":"Eval Results"},"eval_result_count":{"type":"integer","title":"Eval Result Count","default":0},"eval_pass_count":{"type":"integer","title":"Eval Pass Count","default":0},"eval_fail_count":{"type":"integer","title":"Eval Fail Count","default":0},"eval_error_count":{"type":"integer","title":"Eval Error Count","default":0},"checks":{"items":{"$ref":"#/components/schemas/EvaluationResultView"},"type":"array","title":"Checks","description":"Normalized per-check view of ``eval_results``. Raw ``eval_results``\nstay intact; this rides alongside so the console renders checks without\nreverse-engineering actual.latest vs actual.judge vs score.","readOnly":true},"tool_execution":{"anyOf":[{"$ref":"#/components/schemas/SimulationToolExecution"},{"type":"null"}],"description":"The tool settings a saved-case run launched with, as recorded in its snapshot.\n\nNull for a run that recorded none: one that predates the settings, or a `/bridge`\nrun, which simulates every tool.","readOnly":true}},"type":"object","required":["id","service_id","status","checks","tool_execution"],"title":"SimulationRunResponse","description":"Full run payload — used by GET /runs/{run_id} for replay flows."},"SimulationEvalResultResponse":{"properties":{"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Id"},"run_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"eval_key":{"type":"string","maxLength":128,"title":"Eval Key"},"eval_type":{"type":"string","enum":["assertion","metric"],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"rationale":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Rationale"},"justification":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Justification"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"details":{"additionalProperties":true,"type":"object","title":"Details"},"definition":{"additionalProperties":true,"type":"object","title":"Definition"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["eval_key","eval_type","status"],"title":"SimulationEvalResultResponse"},"EvaluationResultView":{"properties":{"source_type":{"type":"string","enum":["metric","assertion"],"title":"Source Type"},"key":{"type":"string","maxLength":128,"title":"Key"},"label":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Label"},"value_type":{"anyOf":[{"type":"string","enum":["numeric","boolean","categorical","text","structured"]},{"type":"null"}],"title":"Value Type"},"evaluation_method":{"anyOf":[{"type":"string","enum":["threshold","equals","contains","regex","tool_called","llm_judge","custom"]},{"type":"null"}],"title":"Evaluation Method"},"grading":{"anyOf":[{"type":"string","enum":["observed_vs_expected","legacy_verdict"]},{"type":"null"}],"title":"Grading","description":"For an LLM-judged assertion: observed_vs_expected (actual is what the judge observed, and the verdict compares it with expected) or legacy_verdict (the judge returned the verdict and observed nothing, so actual is empty). Null otherwise."},"instructions":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Instructions","description":"An llm_boolean assertion's question, with what makes it true or false."},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"actual":{"anyOf":[{},{"type":"null"}],"title":"Actual"},"expected_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Expected Display"},"actual_display":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Actual Display"},"verdict":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Verdict"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"rationale":{"anyOf":[{"type":"string","maxLength":8000},{"type":"null"}],"title":"Rationale"},"references":{"items":{"type":"integer"},"type":"array","maxItems":100,"title":"References"},"run_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Run Id"},"case_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Case Id"},"session_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Session Id"},"trace_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Trace Id"}},"type":"object","required":["source_type","key","verdict"],"title":"EvaluationResultView","description":"One check as the console renders it, derived from a single eval result.\n\nBoth metric and assertion verdicts normalize to this shape so the frontend\nrenders a check without knowing where the value was stored."},"SimulationToolExecution":{"properties":{"live_read_tools":{"items":{"$ref":"#/components/schemas/SimulationToolName"},"type":"array","maxItems":64,"title":"Live Read Tools","description":"Read tools that run for real. Each must be a tool the service's simulations can call that `GET /services/{service_id}/tools/resolve` reports as `live_read_eligible`, with no entry in `tool_mocks`. Integration endpoints need `Integration:View`; platform functions and data queries need `Workspace:View`; world reads need `Service:Update`, which every launch requires. A case anchored to an external principal (an entity with an active external role assignment) runs its live reads as that principal, so it also needs `Conversation:CreateForPrincipal`."},"tool_mocks":{"additionalProperties":{"$ref":"#/components/schemas/SimulationToolMockValue"},"propertyNames":{"$ref":"#/components/schemas/SimulationToolName"},"type":"object","maxProperties":64,"title":"Tool Mocks","description":"Tool name to the result it returns in place of a call. Each must be a tool the service's simulations can call; a companion skill is mocked through the tools it calls."}},"additionalProperties":false,"type":"object","title":"SimulationToolExecution","description":"Which tools a simulation launch runs for real, and which return a configured result.\n\nEvery other tool is simulated and returns a dry-run placeholder. Writes never run\nfor real. The settings apply to every case, step and fork of the launch, and to a\nre-drive of an interrupted run. Empty, the default, simulates every tool."},"SimulationToolName":{"type":"string","maxLength":128,"minLength":1},"SimulationToolMockValue":{"type":"string","maxLength":16384}}}}
```

## The SimulationSessionListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationSessionListResponse":{"properties":{"sessions":{"items":{"$ref":"#/components/schemas/src__routes__simulations__coverage__SimulationSessionListResponse__Item"},"type":"array","title":"Sessions","description":"Newest first."}},"type":"object","required":["sessions"],"title":"SimulationSessionListResponse"},"src__routes__simulations__coverage__SimulationSessionListResponse__Item":{"properties":{"metric_status":{"anyOf":[{"type":"string","enum":["pending","available","unavailable"]},{"type":"null"}],"title":"Metric Status"},"metric_result_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Metric Result Count"},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"immediate_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Immediate Score","description":"The session's score, the same value as score."},"immediate_score_rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Immediate Score Rationale"},"session_id":{"type":"string","title":"Session Id"},"run_id":{"type":"string","format":"uuid","title":"Run Id"},"parent_session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Session Id"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Bridge-written tags, such as `scenario_index:<n>`, `temperament:<x>` and `forked`."},"total_turns":{"type":"integer","title":"Total Turns"},"terminal_reached":{"type":"boolean","title":"Terminal Reached"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"score_rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Score Rationale"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["session_id","run_id","parent_session_id","fork_turn_index","tags","total_turns","terminal_reached","score","score_rationale","created_at"],"title":"Item"}}}}
```

## The SimulationSessionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationSessionResponse":{"properties":{"session_id":{"type":"string","title":"Session Id"},"greeting":{"type":"string","title":"Greeting"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"snapshot":{"$ref":"#/components/schemas/SimulationSnapshotResponse"},"harness_execution":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessExecution"},{"type":"null"}],"description":"What the greeting ran on. Null when the agent runtime reported none."}},"type":"object","required":["session_id","greeting","is_terminal","snapshot"],"title":"SimulationSessionResponse"},"SimulationSnapshotResponse":{"properties":{"current_state":{"$ref":"#/components/schemas/SimulationStateResponse"},"reachable_states":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Reachable States","default":[]},"turn_policy":{"$ref":"#/components/schemas/SimulationTurnPolicyResponse","default":{"barge_in_enabled":true,"greeting_shield_s":0,"context_strategy":"full","block_forward_call":false,"block_forward_call_after_turns":-1}},"conversation_history":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Conversation History","default":[]},"states_visited":{"items":{"type":"string"},"type":"array","title":"States Visited","default":[]},"state_transitions":{"items":{"items":{"type":"string"},"type":"array"},"type":"array","title":"State Transitions","default":[]},"total_turns":{"type":"integer","title":"Total Turns","default":0},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called","default":[]},"terminal_reached":{"type":"boolean","title":"Terminal Reached","default":false},"context_graph_topology":{"items":{"additionalProperties":{"type":"string"},"type":"object"},"type":"array","title":"Context Graph Topology","default":[]},"terminal_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terminal State"}},"additionalProperties":true,"type":"object","required":["current_state"],"title":"SimulationSnapshotResponse"},"SimulationStateResponse":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"},"objective":{"type":"string","title":"Objective","default":""},"actions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Actions","default":[]},"exit_conditions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Exit Conditions","default":[]},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"guardrails":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Guardrails","default":[]},"tools":{"items":{"type":"string"},"type":"array","title":"Tools","default":[]}},"additionalProperties":true,"type":"object","required":["name","type"],"title":"SimulationStateResponse"},"SimulationTurnPolicyResponse":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"greeting_shield_s":{"type":"number","title":"Greeting Shield S","default":0},"context_strategy":{"type":"string","title":"Context Strategy","default":"full"},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","title":"Block Forward Call After Turns","default":-1}},"type":"object","title":"SimulationTurnPolicyResponse"},"SimulationHarnessExecution":{"properties":{"service_config_digest":{"type":"string","title":"Service Config Digest","description":"The digest of the configuration the request's engine loaded."},"harness":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessSelection"},{"type":"null"}],"description":"Null when the request resolved no text harness: a voice service's simulation, or a voice note."},"receipts":{"items":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},"type":"array","title":"Receipts","description":"One receipt per round a release answered, each naming this digest and the selected release's wheel. Empty\nwhen no round ran on a release, whatever is selected: a selection alone is not proof of execution."}},"type":"object","required":["service_config_digest","harness","receipts"],"title":"SimulationHarnessExecution","description":"What one simulation request ran on, as the agent runtime reported it. Nothing here is derived by this API."},"SimulationHarnessSelection":{"properties":{"kind":{"type":"string","const":"text","title":"Kind"},"harness":{"type":"string","title":"Harness","description":"The text provider family the request's rounds were routed for."},"release":{"type":"string","title":"Release","description":"The selected release's tag, or `in-tree`."},"source":{"anyOf":[{"$ref":"#/components/schemas/HarnessSource"},{"type":"string","const":"unresolved"}],"title":"Source","description":"Where the selection came from. `unresolved`: the configuration has no entry for the family."},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256","description":"The selected release wheel's sha256. Null for `in-tree`."}},"type":"object","required":["kind","harness","release","source","sha256"],"title":"SimulationHarnessSelection","description":"The text harness the loaded configuration selects for the request's model family."},"HarnessSource":{"type":"string","enum":["pin","workspace_default","harness_default"]}}}}
```

## The SimulationSessionTurnsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationSessionTurnsResponse":{"properties":{"session_id":{"type":"string","title":"Session Id"},"turns":{"items":{"$ref":"#/components/schemas/SimulationTurnResponse"},"type":"array","title":"Turns","description":"In turn order, at most 200."}},"type":"object","required":["session_id","turns"],"title":"SimulationSessionTurnsResponse"},"SimulationTurnResponse":{"properties":{"session_id":{"type":"string","title":"Session Id"},"turn_index":{"type":"integer","title":"Turn Index"},"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"caller_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Text"},"agent_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Text"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called"},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details"},"empathy_tier":{"type":"integer","title":"Empathy Tier"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"tools_available":{"items":{"type":"string"},"type":"array","title":"Tools Available"}},"type":"object","required":["session_id","turn_index","state_before","state_after","state_changed","caller_text","agent_text","tools_called","tool_call_details","empathy_tier","is_terminal","created_at","tools_available"],"title":"SimulationTurnResponse","description":"One stored turn of a simulation session."},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."}}}}
```

## The SimulationSnapshotResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationSnapshotResponse":{"properties":{"current_state":{"$ref":"#/components/schemas/SimulationStateResponse"},"reachable_states":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Reachable States","default":[]},"turn_policy":{"$ref":"#/components/schemas/SimulationTurnPolicyResponse","default":{"barge_in_enabled":true,"greeting_shield_s":0,"context_strategy":"full","block_forward_call":false,"block_forward_call_after_turns":-1}},"conversation_history":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Conversation History","default":[]},"states_visited":{"items":{"type":"string"},"type":"array","title":"States Visited","default":[]},"state_transitions":{"items":{"items":{"type":"string"},"type":"array"},"type":"array","title":"State Transitions","default":[]},"total_turns":{"type":"integer","title":"Total Turns","default":0},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called","default":[]},"terminal_reached":{"type":"boolean","title":"Terminal Reached","default":false},"context_graph_topology":{"items":{"additionalProperties":{"type":"string"},"type":"object"},"type":"array","title":"Context Graph Topology","default":[]},"terminal_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terminal State"}},"additionalProperties":true,"type":"object","required":["current_state"],"title":"SimulationSnapshotResponse"},"SimulationStateResponse":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"},"objective":{"type":"string","title":"Objective","default":""},"actions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Actions","default":[]},"exit_conditions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Exit Conditions","default":[]},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"guardrails":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Guardrails","default":[]},"tools":{"items":{"type":"string"},"type":"array","title":"Tools","default":[]}},"additionalProperties":true,"type":"object","required":["name","type"],"title":"SimulationStateResponse"},"SimulationTurnPolicyResponse":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"greeting_shield_s":{"type":"number","title":"Greeting Shield S","default":0},"context_strategy":{"type":"string","title":"Context Strategy","default":"full"},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","title":"Block Forward Call After Turns","default":-1}},"type":"object","title":"SimulationTurnPolicyResponse"}}}}
```

## The SimulationStateResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationStateResponse":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"},"objective":{"type":"string","title":"Objective","default":""},"actions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Actions","default":[]},"exit_conditions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Exit Conditions","default":[]},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"guardrails":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Guardrails","default":[]},"tools":{"items":{"type":"string"},"type":"array","title":"Tools","default":[]}},"additionalProperties":true,"type":"object","required":["name","type"],"title":"SimulationStateResponse"}}}}
```

## The SimulationStepResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationStepResponse":{"properties":{"observation":{"$ref":"#/components/schemas/SimulationObservation"},"snapshot":{"$ref":"#/components/schemas/SimulationSnapshotResponse"},"harness_execution":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessExecution"},{"type":"null"}],"description":"What the turn ran on. Null when the agent runtime reported none."}},"type":"object","required":["observation","snapshot"],"title":"SimulationStepResponse"},"SimulationObservation":{"properties":{"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"agent_text":{"type":"string","title":"Agent Text"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called","default":[]},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details","default":[]},"selected_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action"},"empathy_tier":{"type":"integer","title":"Empathy Tier","default":0},"has_pause":{"type":"boolean","title":"Has Pause","default":false},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"}},"type":"object","required":["state_before","state_after","state_changed","agent_text","is_terminal"],"title":"SimulationObservation"},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."},"SimulationSnapshotResponse":{"properties":{"current_state":{"$ref":"#/components/schemas/SimulationStateResponse"},"reachable_states":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Reachable States","default":[]},"turn_policy":{"$ref":"#/components/schemas/SimulationTurnPolicyResponse","default":{"barge_in_enabled":true,"greeting_shield_s":0,"context_strategy":"full","block_forward_call":false,"block_forward_call_after_turns":-1}},"conversation_history":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Conversation History","default":[]},"states_visited":{"items":{"type":"string"},"type":"array","title":"States Visited","default":[]},"state_transitions":{"items":{"items":{"type":"string"},"type":"array"},"type":"array","title":"State Transitions","default":[]},"total_turns":{"type":"integer","title":"Total Turns","default":0},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called","default":[]},"terminal_reached":{"type":"boolean","title":"Terminal Reached","default":false},"context_graph_topology":{"items":{"additionalProperties":{"type":"string"},"type":"object"},"type":"array","title":"Context Graph Topology","default":[]},"terminal_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Terminal State"}},"additionalProperties":true,"type":"object","required":["current_state"],"title":"SimulationSnapshotResponse"},"SimulationStateResponse":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"},"objective":{"type":"string","title":"Objective","default":""},"actions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Actions","default":[]},"exit_conditions":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Exit Conditions","default":[]},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"guardrails":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Guardrails","default":[]},"tools":{"items":{"type":"string"},"type":"array","title":"Tools","default":[]}},"additionalProperties":true,"type":"object","required":["name","type"],"title":"SimulationStateResponse"},"SimulationTurnPolicyResponse":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"greeting_shield_s":{"type":"number","title":"Greeting Shield S","default":0},"context_strategy":{"type":"string","title":"Context Strategy","default":"full"},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","title":"Block Forward Call After Turns","default":-1}},"type":"object","title":"SimulationTurnPolicyResponse"},"SimulationHarnessExecution":{"properties":{"service_config_digest":{"type":"string","title":"Service Config Digest","description":"The digest of the configuration the request's engine loaded."},"harness":{"anyOf":[{"$ref":"#/components/schemas/SimulationHarnessSelection"},{"type":"null"}],"description":"Null when the request resolved no text harness: a voice service's simulation, or a voice note."},"receipts":{"items":{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},"type":"array","title":"Receipts","description":"One receipt per round a release answered, each naming this digest and the selected release's wheel. Empty\nwhen no round ran on a release, whatever is selected: a selection alone is not proof of execution."}},"type":"object","required":["service_config_digest","harness","receipts"],"title":"SimulationHarnessExecution","description":"What one simulation request ran on, as the agent runtime reported it. Nothing here is derived by this API."},"SimulationHarnessSelection":{"properties":{"kind":{"type":"string","const":"text","title":"Kind"},"harness":{"type":"string","title":"Harness","description":"The text provider family the request's rounds were routed for."},"release":{"type":"string","title":"Release","description":"The selected release's tag, or `in-tree`."},"source":{"anyOf":[{"$ref":"#/components/schemas/HarnessSource"},{"type":"string","const":"unresolved"}],"title":"Source","description":"Where the selection came from. `unresolved`: the configuration has no entry for the family."},"sha256":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sha256","description":"The selected release wheel's sha256. Null for `in-tree`."}},"type":"object","required":["kind","harness","release","source","sha256"],"title":"SimulationHarnessSelection","description":"The text harness the loaded configuration selects for the request's model family."},"HarnessSource":{"type":"string","enum":["pin","workspace_default","harness_default"]}}}}
```

## The SimulationSuiteResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationSuiteResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":2000,"title":"Description","default":""},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"required_tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Required Tags"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"metadata":{"additionalProperties":true,"type":"object","title":"Metadata"},"case_count":{"type":"integer","minimum":0,"title":"Case Count"},"created_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Created By"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id","workspace_id","name","case_count"],"title":"SimulationSuiteResponse","description":"HTTP response shape for first-class simulation suites."}}}}
```

## The SimulationSuiteRunPerRunSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationSuiteRunPerRunSummary":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"error":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Error"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"session_ids":{"items":{"type":"string","maxLength":128},"type":"array","title":"Session Ids"},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"terminal_session_count":{"type":"integer","title":"Terminal Session Count","default":0},"scored_session_count":{"type":"integer","title":"Scored Session Count","default":0},"error_session_count":{"type":"integer","title":"Error Session Count","description":"Sessions cut short by the simulator or the platform rather than the agent: the caller LLM,\na step outside the agent's own turn, a turn write or the run's time limit failed. Each has no\nscore and a `score_rationale` of `bridge:error:<end reason>`, so it stays out of `average_score`\nand the pass and fail counts. A session whose agent turn failed (it raised, or ran out of time)\nisn't one of them: it scores 0 with `score_rationale` `bridge:agent_error` or\n`bridge:agent_timeout`, and counts as failed.","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0},"score_rationales":{"items":{"type":"string","maxLength":2000},"type":"array","title":"Score Rationales"},"capability_tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Capability Tags"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"result_pointer":{"additionalProperties":true,"type":"object","title":"Result Pointer"},"immediate_average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Immediate Average Score"},"immediate_passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Immediate Passed"},"immediate_pass_count":{"type":"integer","title":"Immediate Pass Count","default":0},"immediate_fail_count":{"type":"integer","title":"Immediate Fail Count","default":0},"metric_status":{"type":"string","enum":["pending","available","unavailable"],"title":"Metric Status","default":"pending"},"metric_result_count":{"type":"integer","title":"Metric Result Count","default":0},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"eval_counts":{"anyOf":[{"$ref":"#/components/schemas/SimulationRunEvalCounts"},{"type":"null"}],"description":"How the run's evaluation verdicts came out, counted by status across its sessions and the run\nas a whole. All zero for a run that has not completed."},"evaluations_configured":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Evaluations Configured","description":"False when the run's snapshot records no evaluation definitions, so a run with no verdicts\nwas never going to get any."},"case_name":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Case Name","description":"The run's case description, else its name. Null when the snapshot has neither."},"participant":{"anyOf":[{"$ref":"#/components/schemas/SimulationRunParticipant"},{"type":"null"}],"description":"The entity the run simulated and how its snapshot binds it."}},"type":"object","required":["run_id","service_id","status"],"title":"SimulationSuiteRunPerRunSummary"},"SimulationRunEvalCounts":{"properties":{"passed":{"type":"integer","minimum":0,"title":"Passed","default":0},"failed":{"type":"integer","minimum":0,"title":"Failed","default":0},"pending":{"type":"integer","minimum":0,"title":"Pending","default":0},"skipped":{"type":"integer","minimum":0,"title":"Skipped","default":0},"error":{"type":"integer","minimum":0,"title":"Error","description":"Verdicts the grader could not produce, plus any whose status is not one of the other four.","default":0}},"type":"object","title":"SimulationRunEvalCounts","description":"A run's evaluation verdicts, counted by status."},"SimulationRunParticipant":{"properties":{"binding":{"type":"string","enum":["bound","unbound","unknown"],"title":"Binding","description":"`bound` when the run was started against an entity, `unbound` when it was started\nexplicitly without one, `unknown` when its snapshot does not say."},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"The bound entity. Null unless `binding` is `bound`."},"display_name":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Display Name","description":"The bound entity's display name, else its name. Null when the entity is not in the\nworkspace's world or has neither."},"entity_type":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Entity Type","description":"The bound entity's type, such as `person` or `patient`. Null when the entity is not in\nthe workspace's world."}},"type":"object","required":["binding"],"title":"SimulationRunParticipant","description":"The entity a run simulated, as the run's snapshot and the world record it."}}}}
```

## The SimulationSuiteRunResultsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationSuiteRunResultsResponse":{"properties":{"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Run Ids"},"total_runs":{"type":"integer","title":"Total Runs"},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"completed_count":{"type":"integer","title":"Completed Count","default":0},"failed_count":{"type":"integer","title":"Failed Count","default":0},"scored_count":{"type":"integer","title":"Scored Count","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0},"metric_status":{"type":"string","enum":["pending","available","unavailable"],"title":"Metric Status","default":"pending"},"metric_result_count":{"type":"integer","title":"Metric Result Count","default":0},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"capability_breakdown":{"additionalProperties":{"$ref":"#/components/schemas/SimulationBenchmarkBreakdownSummary"},"type":"object","title":"Capability Breakdown"},"missing_run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Missing Run Ids"},"per_run":{"items":{"$ref":"#/components/schemas/SimulationSuiteRunPerRunSummary"},"type":"array","title":"Per Run"},"suite_run_id":{"type":"string","format":"uuid","title":"Suite Run Id"},"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"summary":{"$ref":"#/components/schemas/SimulationSuiteRunSummary"}},"type":"object","required":["run_ids","total_runs","suite_run_id","summary"],"title":"SimulationSuiteRunResultsResponse"},"SimulationBenchmarkBreakdownSummary":{"properties":{"run_count":{"type":"integer","title":"Run Count","default":0},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"completed_count":{"type":"integer","title":"Completed Count","default":0},"failed_count":{"type":"integer","title":"Failed Count","default":0},"scored_count":{"type":"integer","title":"Scored Count","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0}},"type":"object","title":"SimulationBenchmarkBreakdownSummary"},"SimulationSuiteRunPerRunSummary":{"properties":{"run_id":{"type":"string","format":"uuid","title":"Run Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"error":{"anyOf":[{"type":"string","maxLength":500},{"type":"null"}],"title":"Error"},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"session_ids":{"items":{"type":"string","maxLength":128},"type":"array","title":"Session Ids"},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"terminal_session_count":{"type":"integer","title":"Terminal Session Count","default":0},"scored_session_count":{"type":"integer","title":"Scored Session Count","default":0},"error_session_count":{"type":"integer","title":"Error Session Count","description":"Sessions cut short by the simulator or the platform rather than the agent: the caller LLM,\na step outside the agent's own turn, a turn write or the run's time limit failed. Each has no\nscore and a `score_rationale` of `bridge:error:<end reason>`, so it stays out of `average_score`\nand the pass and fail counts. A session whose agent turn failed (it raised, or ran out of time)\nisn't one of them: it scores 0 with `score_rationale` `bridge:agent_error` or\n`bridge:agent_timeout`, and counts as failed.","default":0},"average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Average Score"},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed"},"pass_count":{"type":"integer","title":"Pass Count","default":0},"fail_count":{"type":"integer","title":"Fail Count","default":0},"score_rationales":{"items":{"type":"string","maxLength":2000},"type":"array","title":"Score Rationales"},"capability_tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Capability Tags"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"result_pointer":{"additionalProperties":true,"type":"object","title":"Result Pointer"},"immediate_average_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Immediate Average Score"},"immediate_passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Immediate Passed"},"immediate_pass_count":{"type":"integer","title":"Immediate Pass Count","default":0},"immediate_fail_count":{"type":"integer","title":"Immediate Fail Count","default":0},"metric_status":{"type":"string","enum":["pending","available","unavailable"],"title":"Metric Status","default":"pending"},"metric_result_count":{"type":"integer","title":"Metric Result Count","default":0},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"eval_counts":{"anyOf":[{"$ref":"#/components/schemas/SimulationRunEvalCounts"},{"type":"null"}],"description":"How the run's evaluation verdicts came out, counted by status across its sessions and the run\nas a whole. All zero for a run that has not completed."},"evaluations_configured":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Evaluations Configured","description":"False when the run's snapshot records no evaluation definitions, so a run with no verdicts\nwas never going to get any."},"case_name":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Case Name","description":"The run's case description, else its name. Null when the snapshot has neither."},"participant":{"anyOf":[{"$ref":"#/components/schemas/SimulationRunParticipant"},{"type":"null"}],"description":"The entity the run simulated and how its snapshot binds it."}},"type":"object","required":["run_id","service_id","status"],"title":"SimulationSuiteRunPerRunSummary"},"SimulationRunEvalCounts":{"properties":{"passed":{"type":"integer","minimum":0,"title":"Passed","default":0},"failed":{"type":"integer","minimum":0,"title":"Failed","default":0},"pending":{"type":"integer","minimum":0,"title":"Pending","default":0},"skipped":{"type":"integer","minimum":0,"title":"Skipped","default":0},"error":{"type":"integer","minimum":0,"title":"Error","description":"Verdicts the grader could not produce, plus any whose status is not one of the other four.","default":0}},"type":"object","title":"SimulationRunEvalCounts","description":"A run's evaluation verdicts, counted by status."},"SimulationRunParticipant":{"properties":{"binding":{"type":"string","enum":["bound","unbound","unknown"],"title":"Binding","description":"`bound` when the run was started against an entity, `unbound` when it was started\nexplicitly without one, `unknown` when its snapshot does not say."},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"The bound entity. Null unless `binding` is `bound`."},"display_name":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Display Name","description":"The bound entity's display name, else its name. Null when the entity is not in the\nworkspace's world or has neither."},"entity_type":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Entity Type","description":"The bound entity's type, such as `person` or `patient`. Null when the entity is not in\nthe workspace's world."}},"type":"object","required":["binding"],"title":"SimulationRunParticipant","description":"The entity a run simulated, as the run's snapshot and the world record it."},"SimulationSuiteRunSummary":{"properties":{"suite_run_id":{"type":"string","format":"uuid","title":"Suite Run Id"},"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Run Ids"},"total_runs":{"type":"integer","title":"Total Runs"},"expected_case_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Expected Case Count"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"service_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Service Ids","description":"Agents the suite run's runs ran against, each once, in launch order."},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"result_pointer":{"additionalProperties":true,"type":"object","title":"Result Pointer"}},"type":"object","required":["suite_run_id","run_ids","total_runs","status"],"title":"SimulationSuiteRunSummary"}}}}
```

## The SimulationSuiteRunSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationSuiteRunSummary":{"properties":{"suite_run_id":{"type":"string","format":"uuid","title":"Suite Run Id"},"suite_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Suite Id"},"run_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Run Ids"},"total_runs":{"type":"integer","title":"Total Runs"},"expected_case_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Expected Case Count"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"status_counts":{"additionalProperties":{"type":"integer"},"type":"object","title":"Status Counts"},"case_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Case Ids"},"service_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Service Ids","description":"Agents the suite run's runs ran against, each once, in launch order."},"total_sessions":{"type":"integer","title":"Total Sessions","default":0},"total_turns":{"type":"integer","title":"Total Turns","default":0},"tags":{"items":{"type":"string","maxLength":128},"type":"array","title":"Tags"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"},"result_pointer":{"additionalProperties":true,"type":"object","title":"Result Pointer"}},"type":"object","required":["suite_run_id","run_ids","total_runs","status"],"title":"SimulationSuiteRunSummary"}}}}
```

## The SimulationToolExecution object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationToolExecution":{"properties":{"live_read_tools":{"items":{"$ref":"#/components/schemas/SimulationToolName"},"type":"array","maxItems":64,"title":"Live Read Tools","description":"Read tools that run for real. Each must be a tool the service's simulations can call that `GET /services/{service_id}/tools/resolve` reports as `live_read_eligible`, with no entry in `tool_mocks`. Integration endpoints need `Integration:View`; platform functions and data queries need `Workspace:View`; world reads need `Service:Update`, which every launch requires. A case anchored to an external principal (an entity with an active external role assignment) runs its live reads as that principal, so it also needs `Conversation:CreateForPrincipal`."},"tool_mocks":{"additionalProperties":{"$ref":"#/components/schemas/SimulationToolMockValue"},"propertyNames":{"$ref":"#/components/schemas/SimulationToolName"},"type":"object","maxProperties":64,"title":"Tool Mocks","description":"Tool name to the result it returns in place of a call. Each must be a tool the service's simulations can call; a companion skill is mocked through the tools it calls."}},"additionalProperties":false,"type":"object","title":"SimulationToolExecution","description":"Which tools a simulation launch runs for real, and which return a configured result.\n\nEvery other tool is simulated and returns a dry-run placeholder. Writes never run\nfor real. The settings apply to every case, step and fork of the launch, and to a\nre-drive of an interrupted run. Empty, the default, simulates every tool."},"SimulationToolName":{"type":"string","maxLength":128,"minLength":1},"SimulationToolMockValue":{"type":"string","maxLength":16384}}}}
```

## The SimulationToolMockValue object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationToolMockValue":{"type":"string","maxLength":16384}}}}
```

## The SimulationToolName object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationToolName":{"type":"string","maxLength":128,"minLength":1}}}}
```

## The SimulationTurnPolicyResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationTurnPolicyResponse":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"greeting_shield_s":{"type":"number","title":"Greeting Shield S","default":0},"context_strategy":{"type":"string","title":"Context Strategy","default":"full"},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","title":"Block Forward Call After Turns","default":-1}},"type":"object","title":"SimulationTurnPolicyResponse"}}}}
```

## The SimulationTurnQueryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationTurnQueryResponse":{"properties":{"turns":{"items":{"$ref":"#/components/schemas/SimulationTurnResponse"},"type":"array","title":"Turns","description":"Newest first."}},"type":"object","required":["turns"],"title":"SimulationTurnQueryResponse"},"SimulationTurnResponse":{"properties":{"session_id":{"type":"string","title":"Session Id"},"turn_index":{"type":"integer","title":"Turn Index"},"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"caller_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Text"},"agent_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Text"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called"},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details"},"empathy_tier":{"type":"integer","title":"Empathy Tier"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"tools_available":{"items":{"type":"string"},"type":"array","title":"Tools Available"}},"type":"object","required":["session_id","turn_index","state_before","state_after","state_changed","caller_text","agent_text","tools_called","tool_call_details","empathy_tier","is_terminal","created_at","tools_available"],"title":"SimulationTurnResponse","description":"One stored turn of a simulation session."},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."}}}}
```

## The SimulationTurnResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationTurnResponse":{"properties":{"session_id":{"type":"string","title":"Session Id"},"turn_index":{"type":"integer","title":"Turn Index"},"state_before":{"type":"string","title":"State Before"},"state_after":{"type":"string","title":"State After"},"state_changed":{"type":"boolean","title":"State Changed"},"caller_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Caller Text"},"agent_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Text"},"tools_called":{"items":{"type":"string"},"type":"array","title":"Tools Called"},"tool_call_details":{"items":{"$ref":"#/components/schemas/ToolCallDetail"},"type":"array","title":"Tool Call Details"},"empathy_tier":{"type":"integer","title":"Empathy Tier"},"is_terminal":{"type":"boolean","title":"Is Terminal"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"tools_available":{"items":{"type":"string"},"type":"array","title":"Tools Available"}},"type":"object","required":["session_id","turn_index","state_before","state_after","state_changed","caller_text","agent_text","tools_called","tool_call_details","empathy_tier","is_terminal","created_at","tools_available"],"title":"SimulationTurnResponse","description":"One stored turn of a simulation session."},"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."}}}}
```

## The SkillContextGraphReference object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SkillContextGraphReference":{"properties":{"context_graph_id":{"type":"string","format":"uuid","title":"Context Graph Id"},"context_graph_name":{"type":"string","title":"Context Graph Name"},"version":{"type":"integer","title":"Version"},"states":{"items":{"$ref":"#/components/schemas/SkillStateReference"},"type":"array","title":"States"}},"type":"object","required":["context_graph_id","context_graph_name","version","states"],"title":"SkillContextGraphReference"},"SkillStateReference":{"properties":{"state_name":{"type":"string","title":"State Name"},"tool_spec_category":{"type":"string","title":"Tool Spec Category"}},"type":"object","required":["state_name","tool_spec_category"],"title":"SkillStateReference"}}}}
```

## The SkillListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SkillListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SkillResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"SkillListResponse"},"SkillResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"system_prompt":{"type":"string","title":"System Prompt"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"result_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result Schema"},"model":{"type":"string","title":"Model"},"max_tokens":{"type":"integer","title":"Max Tokens"},"max_result_chars":{"type":"integer","title":"Max Result Chars"},"max_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Input Tokens"},"timeout_s":{"type":"number","title":"Timeout S"},"thinking_effort":{"anyOf":[{"$ref":"#/components/schemas/ThinkingEffort"},{"type":"null"}]},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Top P"},"enable_caching":{"type":"boolean","title":"Enable Caching"},"enable_citations":{"type":"boolean","title":"Enable Citations"},"use_structured_output":{"type":"boolean","title":"Use Structured Output"},"integration_tools":{"items":{"$ref":"#/components/schemas/src__models__IntegrationToolRef"},"type":"array","title":"Integration Tools"},"static_tools":{"items":{"$ref":"#/components/schemas/src__models__StaticToolDef"},"type":"array","title":"Static Tools"},"enabled":{"type":"boolean","title":"Enabled"},"max_agent_turns":{"type":"integer","title":"Max Agent Turns"},"checkpoint_enabled":{"type":"boolean","title":"Checkpoint Enabled"},"approval_required":{"type":"boolean","title":"Approval Required"},"write_kind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"null"}],"description":"What this skill's writes do through an endpoint whose kind ``varies``. Null when undeclared."},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","slug","name","description","system_prompt","input_schema","result_schema","model","max_tokens","max_result_chars","max_input_tokens","timeout_s","thinking_effort","temperature","top_p","enable_caching","enable_citations","use_structured_output","integration_tools","static_tools","enabled","max_agent_turns","checkpoint_enabled","approval_required","write_kind","created_at","updated_at"],"title":"SkillResponse"},"ThinkingEffort":{"type":"string","enum":["low","medium","high"]},"src__models__IntegrationToolRef":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string","maxLength":256,"minLength":1},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","maxProperties":50,"title":"Skill Input Bindings","description":"Endpoint parameter -> parent skill input mappings injected at dispatch."}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef","description":"Reference to an integration endpoint by integration + endpoint name."},"src__models__StaticToolDef":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef","description":"A built-in tool available to companion agents."},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]}}}}
```

## The SkillReferencesResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SkillReferencesResponse":{"properties":{"skill_id":{"type":"string","format":"uuid","title":"Skill Id"},"skill_slug":{"type":"string","title":"Skill Slug"},"context_graph_references":{"items":{"$ref":"#/components/schemas/SkillContextGraphReference"},"type":"array","title":"Context Graph References"},"service_references":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Service References"}},"type":"object","required":["skill_id","skill_slug","context_graph_references","service_references"],"title":"SkillReferencesResponse"},"SkillContextGraphReference":{"properties":{"context_graph_id":{"type":"string","format":"uuid","title":"Context Graph Id"},"context_graph_name":{"type":"string","title":"Context Graph Name"},"version":{"type":"integer","title":"Version"},"states":{"items":{"$ref":"#/components/schemas/SkillStateReference"},"type":"array","title":"States"}},"type":"object","required":["context_graph_id","context_graph_name","version","states"],"title":"SkillContextGraphReference"},"SkillStateReference":{"properties":{"state_name":{"type":"string","title":"State Name"},"tool_spec_category":{"type":"string","title":"Tool Spec Category"}},"type":"object","required":["state_name","tool_spec_category"],"title":"SkillStateReference"}}}}
```

## The SkillResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SkillResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"system_prompt":{"type":"string","title":"System Prompt"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"result_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result Schema"},"model":{"type":"string","title":"Model"},"max_tokens":{"type":"integer","title":"Max Tokens"},"max_result_chars":{"type":"integer","title":"Max Result Chars"},"max_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Input Tokens"},"timeout_s":{"type":"number","title":"Timeout S"},"thinking_effort":{"anyOf":[{"$ref":"#/components/schemas/ThinkingEffort"},{"type":"null"}]},"temperature":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Top P"},"enable_caching":{"type":"boolean","title":"Enable Caching"},"enable_citations":{"type":"boolean","title":"Enable Citations"},"use_structured_output":{"type":"boolean","title":"Use Structured Output"},"integration_tools":{"items":{"$ref":"#/components/schemas/src__models__IntegrationToolRef"},"type":"array","title":"Integration Tools"},"static_tools":{"items":{"$ref":"#/components/schemas/src__models__StaticToolDef"},"type":"array","title":"Static Tools"},"enabled":{"type":"boolean","title":"Enabled"},"max_agent_turns":{"type":"integer","title":"Max Agent Turns"},"checkpoint_enabled":{"type":"boolean","title":"Checkpoint Enabled"},"approval_required":{"type":"boolean","title":"Approval Required"},"write_kind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"null"}],"description":"What this skill's writes do through an endpoint whose kind ``varies``. Null when undeclared."},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","workspace_id","slug","name","description","system_prompt","input_schema","result_schema","model","max_tokens","max_result_chars","max_input_tokens","timeout_s","thinking_effort","temperature","top_p","enable_caching","enable_citations","use_structured_output","integration_tools","static_tools","enabled","max_agent_turns","checkpoint_enabled","approval_required","write_kind","created_at","updated_at"],"title":"SkillResponse"},"ThinkingEffort":{"type":"string","enum":["low","medium","high"]},"src__models__IntegrationToolRef":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string","maxLength":256,"minLength":1},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","maxProperties":50,"title":"Skill Input Bindings","description":"Endpoint parameter -> parent skill input mappings injected at dispatch."}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef","description":"Reference to an integration endpoint by integration + endpoint name."},"src__models__StaticToolDef":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef","description":"A built-in tool available to companion agents."},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]}}}}
```

## The SkillStateReference object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SkillStateReference":{"properties":{"state_name":{"type":"string","title":"State Name"},"tool_spec_category":{"type":"string","title":"Tool Spec Category"}},"type":"object","required":["state_name","tool_spec_category"],"title":"SkillStateReference"}}}}
```

## The SlugString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SortField":{"type":"string","enum":["key","updated_at"]}}}}
```

## The SourceBreakdownItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceBreakdownItem":{"properties":{"source_system":{"type":"string","title":"Source System"},"entity_type":{"type":"string","title":"Entity Type"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["source_system","entity_type","count"],"title":"SourceBreakdownItem"}}}}
```

## The SourceBreakdownResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceBreakdownResponse":{"properties":{"breakdown":{"items":{"$ref":"#/components/schemas/SourceBreakdownItem"},"type":"array","title":"Breakdown"},"total":{"type":"integer","title":"Total"}},"type":"object","required":["breakdown","total"],"title":"SourceBreakdownResponse"},"SourceBreakdownItem":{"properties":{"source_system":{"type":"string","title":"Source System"},"entity_type":{"type":"string","title":"Entity Type"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["source_system","entity_type","count"],"title":"SourceBreakdownItem"}}}}
```

## The SourceEventItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceEventItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_type":{"type":"string","title":"Event Type"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"source":{"type":"string","title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"confidence":{"type":"number","title":"Confidence"},"ingested_at":{"type":"string","format":"date-time","title":"Ingested At"}},"type":"object","required":["id","event_type","source","confidence","ingested_at"],"title":"SourceEventItem"}}}}
```

## The SourceEventListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceEventListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SourceEventItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"SourceEventListResponse"},"SourceEventItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_type":{"type":"string","title":"Event Type"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Entity Type"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"source":{"type":"string","title":"Source"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"confidence":{"type":"number","title":"Confidence"},"ingested_at":{"type":"string","format":"date-time","title":"Ingested At"}},"type":"object","required":["id","event_type","source","confidence","ingested_at"],"title":"SourceEventItem"}}}}
```

## The SourceFailureItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceFailureItem":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"event_type":{"type":"string","title":"Event Type"},"fhir_resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Type"},"sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Error"},"ingested_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ingested At"}},"type":"object","required":["event_id","event_type"],"title":"SourceFailureItem"}}}}
```

## The SourceHistoryItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceHistoryItem":{"properties":{"bucket":{"type":"string","title":"Bucket"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"event_count":{"type":"integer","title":"Event Count"}},"type":"object","required":["bucket","event_count"],"title":"SourceHistoryItem"}}}}
```

## The SourceListItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceListItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"source_type":{"type":"string","enum":["ehr","fhir_store","snowflake"],"title":"Source Type"},"is_active":{"type":"boolean","title":"Is Active"},"health_status":{"type":"string","enum":["unknown","healthy","degraded"],"title":"Health Status"},"event_count":{"type":"integer","title":"Event Count","default":0}},"type":"object","required":["id","name","source_type","is_active","health_status"],"title":"SourceListItem"}}}}
```

## The SourceOverviewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceOverviewResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"source_type":{"type":"string","enum":["ehr","fhir_store","snowflake"],"title":"Source Type"},"is_active":{"type":"boolean","title":"Is Active"},"health_status":{"type":"string","enum":["unknown","healthy","degraded"],"title":"Health Status"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"event_count":{"type":"integer","title":"Event Count","default":0},"entity_count":{"type":"integer","title":"Entity Count","default":0},"recent_failures":{"items":{"$ref":"#/components/schemas/SourceFailureItem"},"type":"array","title":"Recent Failures","default":[]},"outbound":{"$ref":"#/components/schemas/OutboundSummary","default":{"total":0,"synced":0,"failed":0,"pending":0}}},"type":"object","required":["id","name","source_type","is_active","health_status"],"title":"SourceOverviewResponse"},"SourceFailureItem":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"event_type":{"type":"string","title":"Event Type"},"fhir_resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Type"},"sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Error"},"ingested_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ingested At"}},"type":"object","required":["event_id","event_type"],"title":"SourceFailureItem"},"OutboundSummary":{"properties":{"total":{"type":"integer","title":"Total","default":0},"synced":{"type":"integer","title":"Synced","default":0},"failed":{"type":"integer","title":"Failed","default":0},"pending":{"type":"integer","title":"Pending","default":0},"last_synced_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Synced At"}},"type":"object","title":"OutboundSummary"}}}}
```

## The SourceSyncResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SourceSyncResponse":{"properties":{"batches":{"items":{"$ref":"#/components/schemas/SyncBatchRow"},"type":"array","title":"Batches"}},"type":"object","required":["batches"],"title":"SourceSyncResponse"},"SyncBatchRow":{"properties":{"batch_id":{"type":"string","format":"uuid","title":"Batch Id"},"dataset":{"type":"string","title":"Dataset"},"files_found":{"type":"integer","title":"Files Found"},"status":{"type":"string","title":"Status"}},"type":"object","required":["batch_id","dataset","files_found","status"],"title":"SyncBatchRow","description":"One batch produced by a source sync (one per mapped folder/dataset)."}}}}
```

## The Span object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Span":{"properties":{"traceId":{"type":"string","title":"Traceid"},"spanId":{"type":"string","title":"Spanid"},"name":{"type":"string","title":"Name"},"kind":{"type":"integer","title":"Kind"},"startTimeUnixNano":{"type":"string","title":"Starttimeunixnano"},"endTimeUnixNano":{"type":"string","title":"Endtimeunixnano"},"attributes":{"items":{"$ref":"#/components/schemas/KeyValue"},"type":"array","title":"Attributes"},"status":{"$ref":"#/components/schemas/Status"}},"type":"object","required":["traceId","spanId","name","kind","startTimeUnixNano","endTimeUnixNano","attributes","status"],"title":"Span","description":"OTLP ``Span`` in OTLP/JSON encoding (ids hex, timestamps decimal-string)."},"KeyValue":{"properties":{"key":{"type":"string","title":"Key"},"value":{"$ref":"#/components/schemas/AnyValue"}},"type":"object","required":["key","value"],"title":"KeyValue","description":"OTLP ``KeyValue`` attribute pair."},"AnyValue":{"additionalProperties":true,"type":"object"},"Status":{"properties":{"code":{"type":"integer","title":"Code"}},"type":"object","required":["code"],"title":"Status","description":"OTLP ``Status`` — 0=UNSET, 1=OK, 2=ERROR."}}}}
```

## The SqlColumn object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SqlColumn":{"properties":{"name":{"type":"string","title":"Name"},"type_name":{"type":"string","title":"Type Name"},"type_text":{"type":"string","title":"Type Text"}},"type":"object","required":["name","type_name","type_text"],"title":"SqlColumn"}}}}
```

## The SqlQueryRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SqlQueryRequest":{"properties":{"sql":{"type":"string","maxLength":50000,"minLength":1,"title":"Sql","description":"Read-only SQL query against Databricks."}},"type":"object","required":["sql"],"title":"SqlQueryRequest"}}}}
```

## The SqlQueryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SqlQueryResponse":{"properties":{"results":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Results"},"count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Count"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","title":"SqlQueryResponse"}}}}
```

## The StaffedHours object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."}}}}
```

## The StaffedWindow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."}}}}
```

## The StartKind object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StartKind":{"type":"string","enum":["text","test_call","app_session"]}}}}
```

## The StartSessionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StartSessionRequest":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"World model entity UUID. Provide either entity_id or canonical_id."},"canonical_id":{"anyOf":[{"$ref":"#/components/schemas/CanonicalIdString"},{"type":"null"}],"description":"World model canonical_id of the form 'source:resource_type:id' (e.g. 'charmhealth:Patient:67890'). The structural regex on CanonicalIdString blocks spaces, names, DOBs, and similar regulated content. Resolved against the SDP-projected entity table; a freshly-created entity may not be visible yet if the projection is lagging. Provide either entity_id or canonical_id, not both."},"channel_kind":{"type":"string","const":"web","title":"Channel Kind"},"greeting":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Greeting","description":"Custom greeting. Agent auto-greets if omitted."},"source":{"anyOf":[{"type":"string","const":"playground"},{"type":"null"}],"title":"Source","description":"Set to ``playground`` when the developer console Playground starts the session. It gets its own conversation for the entity and service, never a real client's, and every turn on it runs as a test turn: its tools run in simulation mode, and it stays out of EHR sync and billing."},"tags":{"items":{"$ref":"#/components/schemas/ConversationTag"},"type":"array","maxItems":20,"title":"Tags","description":"Labels to set on the conversation, at most 20, each a key and an optional value. When the session resumes a conversation (``already_active``), they merge into its tags as updates, and a merge that would pass 20 is refused with 422."}},"type":"object","required":["service_id","channel_kind"],"title":"StartSessionRequest"},"CanonicalIdString":{"type":"string","maxLength":256,"minLength":3,"pattern":"^[A-Za-z0-9._-]+:[A-Za-z0-9._-]+:[A-Za-z0-9._-]+$"},"ConversationTag":{"properties":{"key":{"type":"string","maxLength":64,"minLength":1,"title":"Key"},"value":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Value","description":"Null for a bare label."}},"type":"object","required":["key"],"title":"ConversationTag"}}}}
```

## The StartSessionResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StartSessionResponse":{"properties":{"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id"},"session_status":{"type":"string","enum":["created","already_active"],"title":"Session Status"},"channel_kind":{"type":"string","const":"web","title":"Channel Kind"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"created_at":{"type":"string","title":"Created At"}},"type":"object","required":["conversation_id","session_status","channel_kind","entity_id","service_id","created_at"],"title":"StartSessionResponse"}}}}
```

## The StateTransition object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StateTransition":{"properties":{"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"},"previous_state":{"type":"string","title":"Previous State","default":""},"next_state":{"type":"string","title":"Next State","default":""},"annotation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Annotation"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"from_state":{"type":"string","title":"From State","readOnly":true},"to_state":{"type":"string","title":"To State","readOnly":true}},"type":"object","required":["from_state","to_state"],"title":"StateTransition"}}}}
```

## The StateVisit object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StateVisit":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"previous_state":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Previous State"},"state":{"type":"string","maxLength":512,"title":"State"}},"type":"object","required":["state"],"title":"StateVisit"}}}}
```

## The StaticHeaderAuthDict object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StaticHeaderAuthDict":{"properties":{"type":{"type":"string","const":"static_header","title":"Type"},"header_name":{"type":"string","title":"Header Name"}},"type":"object","required":["type","header_name"],"title":"StaticHeaderAuthDict","description":"Static workspace-level secret used verbatim as a single header value.\n\nBearer is just ``header_name=\"Authorization\"`` with the SSM secret holding\n``\"Bearer <token>\"``."}}}}
```

## The StaticHeaderAuthRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StaticHeaderAuthRequest":{"properties":{"type":{"type":"string","const":"static_header","title":"Type","default":"static_header"},"header_name":{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$","title":"Header Name","description":"Outbound header name (RFC 7230 tchar)."}},"type":"object","required":["header_name"],"title":"StaticHeaderAuthRequest","description":"Static workspace-level secret used verbatim as a single header value."}}}}
```

## The StaticToolDef-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StaticToolDef-Input":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef","description":"A built-in tool available to companion agents."}}}}
```

## The Status object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Status":{"properties":{"code":{"type":"integer","title":"Code"}},"type":"object","required":["code"],"title":"Status","description":"OTLP ``Status`` — 0=UNSET, 1=OK, 2=ERROR."}}}}
```

## The StatusSuccess object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."}}}}
```

## The StatusWriteBackRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StatusWriteBackRequest":{"properties":{"status":{"$ref":"#/components/schemas/_FileStatus"},"error_reason":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Error Reason"},"curated_path":{"anyOf":[{"$ref":"#/components/schemas/_VolumePath"},{"type":"null"}]},"cdc_path":{"anyOf":[{"$ref":"#/components/schemas/_VolumePath"},{"type":"null"}]}},"type":"object","required":["status"],"title":"StatusWriteBackRequest","description":"Status advance written by the async CDC job (P4).\n\nThe job posts the terminal verdict after conform/validate/diff. ``error_reason``\nmust be PHI-safe (the engine reports column + type + counts only — never cell\nvalues). ``curated_path``/``cdc_path`` are set only on a clean verdict."},"_FileStatus":{"type":"string","enum":["received","scanned","processing","curated","rejected","failed","held"]},"_VolumePath":{"type":"string","maxLength":1024,"minLength":1,"pattern":"^[A-Za-z0-9/._-]+$"}}}}
```

## The StepRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StepRequest":{"properties":{"session_id":{"type":"string","maxLength":64,"title":"Session Id"},"caller_text":{"type":"string","maxLength":2000,"title":"Caller Text"}},"type":"object","required":["session_id","caller_text"],"title":"StepRequest"}}}}
```

## The StepSessionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StepSessionRequest":{"properties":{"caller_text":{"type":"string","maxLength":2000,"title":"Caller Text"},"session_id":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Session Id","description":"Leave unset: the path names the session. A value that differs from the path returns 422."}},"type":"object","required":["caller_text"],"title":"StepSessionRequest","description":"One caller turn for the session named in the path."}}}}
```

## The StoredChannelType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StoredChannelType":{"type":"string","enum":["email","web","sms"],"title":"StoredChannelType","description":"Channel as stored on a surface row or outreach rule.\n\n``sms`` predates the end of SMS delivery. It stays readable, and an edit may send a stored ``sms`` back\nunchanged, but no surface or rule is ever switched to it or created with it."}}}}
```

## The StoredParameter object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StoredParameter":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","title":"Description"},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Default"},"authorization_binding":{"anyOf":[{"$ref":"#/components/schemas/RoleGrantKeysBinding"},{"type":"null"}]},"authorization_binding_test_value":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Authorization Binding Test Value","description":"Canonical CSV resource keys used only by trusted playground execution when no live authorization block exists."}},"additionalProperties":false,"type":"object","required":["name","type","description"],"title":"StoredParameter","description":"One typed input parameter of a workspace data query.\n\nA null `default` marks the parameter as required: a call that omits it is refused, unless the parameter is\nbound by `authorization_binding`. Otherwise an omitted argument takes the default."},"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."}}}}
```

## The StoredSimulationCaseEval object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StoredSimulationCaseEval":{"oneOf":[{"$ref":"#/components/schemas/SimulationCaseMetricEval"},{"$ref":"#/components/schemas/SimulationCaseAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseBooleanAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseLegacyAssertionEval"}]},"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"},"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."},"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."},"SimulationCaseLegacyAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","maxLength":128,"minLength":1,"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"},"grading":{"type":"string","const":"legacy_verdict","title":"Grading","description":"How this assertion is graded: a pass or fail verdict from the legacy judge, with no observed value.","default":"legacy_verdict"}},"type":"object","required":["type","key","assertion_kind","description","expected","params","weight","grading"],"title":"SimulationCaseLegacyAssertionEval","description":"An assertion saved before ``llm_boolean``: ``llm_judge`` or a free-text kind. Returned by reads only.\n\nThe legacy judge grades it with a pass or fail verdict and records no observed\nvalue. Case writes reject this shape, so rewrite it as an ``llm_boolean`` or a\ndeterministic assertion before saving the case's ``evals`` again."}}}}
```

## The StratifiedFitRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StratifiedFitRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"outcome_key":{"type":"string","title":"Outcome Key"},"outcome_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome Name"},"cohort":{"type":"string","title":"Cohort"},"region":{"type":"string","title":"Region"},"n":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"N"},"base_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Base Rate"},"auroc":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Auroc"},"intercept":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Intercept"},"coefficients_json":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coefficients Json"},"is_pooled_fallback":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Pooled Fallback"}},"type":"object","required":["workspace_id","outcome_key","cohort","region"],"title":"StratifiedFitRow"}}}}
```

## The StratifiedFitsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StratifiedFitsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"count":{"type":"integer","title":"Count"},"items":{"items":{"$ref":"#/components/schemas/StratifiedFitRow"},"type":"array","title":"Items"}},"type":"object","required":["workspace_id","count","items"],"title":"StratifiedFitsResponse"},"StratifiedFitRow":{"properties":{"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string","const":"labs"}],"title":"Workspace Id"},"outcome_key":{"type":"string","title":"Outcome Key"},"outcome_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Outcome Name"},"cohort":{"type":"string","title":"Cohort"},"region":{"type":"string","title":"Region"},"n":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"N"},"base_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Base Rate"},"auroc":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Auroc"},"intercept":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Intercept"},"coefficients_json":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Coefficients Json"},"is_pooled_fallback":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Pooled Fallback"}},"type":"object","required":["workspace_id","outcome_key","cohort","region"],"title":"StratifiedFitRow"}}}}
```

## The StrippedNonemptyString object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StrippedNonemptyString":{"type":"string","minLength":1}}}}
```

## The SubToolLog object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SubToolLog":{"properties":{"tool_name":{"type":"string","title":"Tool Name","description":"Name of the tool that was invoked"},"input":{"additionalProperties":true,"type":"object","title":"Input","description":"Input parameters passed to the tool"},"output":{"type":"string","title":"Output","description":"Raw output returned by the tool"},"duration_ms":{"type":"number","title":"Duration Ms","description":"Execution time in milliseconds"},"succeeded":{"type":"boolean","title":"Succeeded","description":"Whether the tool invocation succeeded"},"round":{"type":"integer","title":"Round","description":"Agent reasoning round in which the tool was called"}},"type":"object","required":["tool_name","input","output","duration_ms","succeeded","round"],"title":"SubToolLog"}}}}
```

## The SubToolLogItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SubToolLogItem":{"properties":{"tool_name":{"type":"string","title":"Tool Name","default":""},"input":{"additionalProperties":true,"type":"object","title":"Input"},"output":{"type":"string","title":"Output","default":""},"duration_ms":{"type":"number","title":"Duration Ms","default":0},"succeeded":{"type":"boolean","title":"Succeeded","default":true}},"type":"object","title":"SubToolLogItem"}}}}
```

## The SuggestionsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SuggestionsResponse":{"properties":{"suggestions":{"items":{"type":"string"},"type":"array","title":"Suggestions"}},"type":"object","required":["suggestions"],"title":"SuggestionsResponse"}}}}
```

## The SurfaceErrorResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceErrorResponse":{"properties":{"error_code":{"type":"string","maxLength":64,"title":"Error Code","description":"Machine-readable error code."},"message":{"anyOf":[{"type":"string","maxLength":1024},{"type":"null"}],"title":"Message","description":"Human-readable error message. Omitted for token-validator errors that only carry ``reason``."},"reason":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Reason","description":"Debug detail from the token validator (e.g. ``token expired``)."},"details":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Details","description":"Optional structured validation details for 422 responses."}},"type":"object","required":["error_code"],"title":"SurfaceErrorResponse","description":"Error envelope returned by patient-facing surface JSON endpoints.\n\nFrontend (forms-app) reads ``error_code`` for branching and ``message``\nfor user-visible copy. ``reason`` is a debug-only field set by the token\nvalidator. ``details`` is set when a request body fails server-side\nvalidation."}}}}
```

## The SurfaceField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"prefill_value":{"anyOf":[{},{"type":"null"}],"title":"Prefill Value"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"}},"type":"object","required":["key","label","field_type"],"title":"SurfaceField","description":"A single data collection field in a surface spec.\n\nGenerated by agents from HSM analysis. Each field maps\nto a specific piece of data the world model needs."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The SurfaceListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/SurfaceResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"SurfaceListResponse"},"SurfaceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_id":{"type":"string","format":"uuid","title":"Event Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"$ref":"#/components/schemas/SurfaceStatus"},"channel":{"anyOf":[{"$ref":"#/components/schemas/StoredChannelType"},{"type":"null"}]},"use_case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Use Case Id"},"fields_count":{"type":"integer","title":"Fields Count"},"fields":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Fields","default":[]},"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type"},"context":{"additionalProperties":true,"type":"object","title":"Context","default":{}},"expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expires At"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"delivered_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivered At"},"opened_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Opened At"},"submitted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submitted At"},"submitted_data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Submitted Data"},"delivery_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery Metadata"},"review_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Review Notes"},"reviewed_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewed By"},"reviewed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reviewed At"},"archived_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Archived At"},"archive_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Archive Reason"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"}},"type":"object","required":["id","event_id","status","fields_count"],"title":"SurfaceResponse"},"SurfaceStatus":{"type":"string","enum":["created","pending_review","delivered","opened","partial","completed","expired","archived"],"title":"SurfaceStatus","description":"Lifecycle status of a surface."},"StoredChannelType":{"type":"string","enum":["email","web","sms"],"title":"StoredChannelType","description":"Channel as stored on a surface row or outreach rule.\n\n``sms`` predates the end of SMS delivery. It stays readable, and an edit may send a stored ``sms`` back\nunchanged, but no surface or rule is ever switched to it or created with it."}}}}
```

## The SurfaceProgressResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceProgressResponse":{"properties":{"surface_id":{"type":"string","format":"uuid","title":"Surface Id"},"total_fields":{"type":"integer","title":"Total Fields"},"filled_count":{"type":"integer","title":"Filled Count"},"empty_count":{"type":"integer","title":"Empty Count"},"filled_keys":{"items":{"type":"string"},"type":"array","title":"Filled Keys"},"empty_keys":{"items":{"type":"string"},"type":"array","title":"Empty Keys"},"required_empty_keys":{"items":{"type":"string"},"type":"array","title":"Required Empty Keys"}},"type":"object","required":["surface_id","total_fields","filled_count","empty_count","filled_keys","empty_keys","required_empty_keys"],"title":"SurfaceProgressResponse"}}}}
```

## The SurfaceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"event_id":{"type":"string","format":"uuid","title":"Event Id"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"status":{"$ref":"#/components/schemas/SurfaceStatus"},"channel":{"anyOf":[{"$ref":"#/components/schemas/StoredChannelType"},{"type":"null"}]},"use_case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Use Case Id"},"fields_count":{"type":"integer","title":"Fields Count"},"fields":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Fields","default":[]},"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type"},"context":{"additionalProperties":true,"type":"object","title":"Context","default":{}},"expires_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Expires At"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"delivered_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delivered At"},"opened_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Opened At"},"submitted_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Submitted At"},"submitted_data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Submitted Data"},"delivery_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Delivery Metadata"},"review_notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Review Notes"},"reviewed_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Reviewed By"},"reviewed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reviewed At"},"archived_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Archived At"},"archive_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Archive Reason"},"url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Url"}},"type":"object","required":["id","event_id","status","fields_count"],"title":"SurfaceResponse"},"SurfaceStatus":{"type":"string","enum":["created","pending_review","delivered","opened","partial","completed","expired","archived"],"title":"SurfaceStatus","description":"Lifecycle status of a surface."},"StoredChannelType":{"type":"string","enum":["email","web","sms"],"title":"StoredChannelType","description":"Channel as stored on a surface row or outreach rule.\n\n``sms`` predates the end of SMS delivery. It stays readable, and an edit may send a stored ``sms`` back\nunchanged, but no surface or rule is ever switched to it or created with it."}}}}
```

## The SurfaceSection object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceSection":{"properties":{"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["title","field_keys"],"title":"SurfaceSection","description":"A page/step in a multi-page surface form."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The SurfaceSpec object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceSpec":{"properties":{"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"fields":{"items":{"$ref":"#/components/schemas/SurfaceField"},"type":"array","maxItems":200,"minItems":1,"title":"Fields"},"channel":{"$ref":"#/components/schemas/ChannelType","default":"web"},"expires_in_hours":{"type":"integer","maximum":8760,"minimum":1,"title":"Expires In Hours","default":168},"context":{"additionalProperties":true,"type":"object","title":"Context"},"resource_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Resource Type"},"branding":{"anyOf":[{"$ref":"#/components/schemas/BrandingConfig"},{"type":"null"}]},"sections":{"anyOf":[{"items":{"$ref":"#/components/schemas/SurfaceSection"},"type":"array"},{"type":"null"}],"title":"Sections"},"completion_title":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"}},"type":"object","required":["entity_id","title","fields"],"title":"SurfaceSpec","description":"A complete surface specification generated by an agent.\n\nThe agent reads the HSM (entity state, relationships,\nconfidence gaps) and produces this spec. The spec is stored as a\nworld event and rendered by platform-api into a patient-facing page."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"SurfaceField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"prefill_value":{"anyOf":[{},{"type":"null"}],"title":"Prefill Value"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"}},"type":"object","required":["key","label","field_type"],"title":"SurfaceField","description":"A single data collection field in a surface spec.\n\nGenerated by agents from HSM analysis. Each field maps\nto a specific piece of data the world model needs."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"ChannelType":{"type":"string","enum":["email","web"],"title":"ChannelType","description":"Delivery channels for surfaces."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."},"SurfaceSection":{"properties":{"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["title","field_keys"],"title":"SurfaceSection","description":"A page/step in a multi-page surface form."}}}}
```

## The SurfaceSpecResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceSpecResponse":{"properties":{"surface_id":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Surface Id"},"entity_id":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Entity Id"},"status":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Status"},"spec":{"$ref":"#/components/schemas/PatientSurfaceSpec"},"saved_values":{"additionalProperties":true,"type":"object","title":"Saved Values"}},"type":"object","required":["spec"],"title":"SurfaceSpecResponse","description":"Surface render bundle returned to forms-app SSR."},"PatientSurfaceSpec":{"properties":{"title":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Title"},"description":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Description"},"fields":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Fields"},"sections":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Sections"},"branding":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Branding"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"},"completion_title":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":4000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"context":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Context"}},"type":"object","title":"PatientSurfaceSpec","description":"The patient-facing form a surface renders: its title, description, fields, sections, branding, submit button\ntext, completion text and context.\n\n`fields`, `sections`, `branding` and `context` are passed through as the surface defines them, so their shape\nis not fixed here."}}}}
```

## The SurfaceStatus object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceStatus":{"type":"string","enum":["created","pending_review","delivered","opened","partial","completed","expired","archived"],"title":"SurfaceStatus","description":"Lifecycle status of a surface."}}}}
```

## The SwitchChannelRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SwitchChannelRequest":{"properties":{"channel":{"$ref":"#/components/schemas/ChannelKind","description":"Target channel to move the conversation to (sms or imessage)."},"recipient":{"anyOf":[{"$ref":"#/components/schemas/PhoneE164"},{"type":"null"}],"description":"Recipient address on the new channel (E.164). Required for sms/imessage."},"use_case_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Use Case Id","description":"The use case for the new channel, which resolves the sender. Required for sms/imessage."},"reason":{"$ref":"#/components/schemas/NameString","description":"Why the conversation is being moved (e.g. escalation, customer_request)."},"dispatch_opener":{"type":"boolean","title":"Dispatch Opener","description":"If true, immediately drive one agent turn on the new channel (e.g. 'I'll text you now').","default":false},"instruction":{"anyOf":[{"$ref":"#/components/schemas/BackgroundString"},{"type":"null"}],"description":"Optional context steering the opener when dispatch_opener=true."},"source":{"anyOf":[{"type":"string","const":"playground"},{"type":"null"}],"title":"Source","description":"Set to ``playground`` when the developer console Playground switches the conversation. Refused with 403 on a real conversation, one no Playground session or test credential started."}},"type":"object","required":["channel","reason"],"title":"SwitchChannelRequest"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"BackgroundString":{"type":"string","maxLength":10000}}}}
```

## The SwitchModeRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SwitchModeRequest":{"properties":{"call_sid":{"type":"string","maxLength":64,"minLength":1,"title":"Call Sid"},"participant_call_sid":{"type":"string","maxLength":64,"title":"Participant Call Sid","default":""},"mode":{"type":"string","enum":["listen","takeover"],"title":"Mode"}},"type":"object","required":["call_sid","mode"],"title":"SwitchModeRequest","description":"Request to toggle operator mode on an active call."}}}}
```

## The SwitchModeResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SwitchModeResponse":{"properties":{"mode":{"type":"string","enum":["listen","takeover"],"title":"Mode","description":"New operator mode"}},"type":"object","required":["mode"],"title":"SwitchModeResponse"}}}}
```

## The SyncBatchRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SyncBatchRow":{"properties":{"batch_id":{"type":"string","format":"uuid","title":"Batch Id"},"dataset":{"type":"string","title":"Dataset"},"files_found":{"type":"integer","title":"Files Found"},"status":{"type":"string","title":"Status"}},"type":"object","required":["batch_id","dataset","files_found","status"],"title":"SyncBatchRow","description":"One batch produced by a source sync (one per mapped folder/dataset)."}}}}
```

## The SyncFailureEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SyncFailureEntry":{"properties":{"event_id":{"type":"string","format":"uuid","title":"Event Id"},"event_type":{"type":"string","title":"Event Type"},"fhir_resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Type"},"fhir_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Resource Id"},"sync_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sync Error"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["event_id","event_type","fhir_resource_type","fhir_resource_id","sync_error","created_at"],"title":"SyncFailureEntry"}}}}
```

## The SyncHistoryEntry object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SyncHistoryEntry":{"properties":{"date":{"type":"string","title":"Date"},"event_count":{"type":"integer","title":"Event Count"},"synced_count":{"type":"integer","title":"Synced Count"},"failed_count":{"type":"integer","title":"Failed Count"}},"type":"object","required":["date","event_count","synced_count","failed_count"],"title":"SyncHistoryEntry"}}}}
```

## The TMSMappingReleaseParams object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TMSMappingReleaseParams":{"properties":{"rule_kind":{"type":"string","const":"tms_mapping_release","title":"Rule Kind","default":"tms_mapping_release"},"reservation_window_hours":{"type":"integer","maximum":720,"minimum":0,"title":"Reservation Window Hours"},"weekend_skip":{"type":"boolean","title":"Weekend Skip","default":true}},"type":"object","required":["reservation_window_hours"],"title":"TMSMappingReleaseParams","description":"How long before a TMS mapping appointment its slot is released\nback to the pool. ``weekend_skip=True`` adds Saturday + Sunday days\nto the wall-clock countdown (clinic doesn't release on weekends)."}}}}
```

## The TMSSessionGridParams object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TMSSessionGridParams":{"properties":{"rule_kind":{"type":"string","const":"tms_session_grid","title":"Rule Kind","default":"tms_session_grid"},"interval_minutes":{"type":"integer","maximum":120,"minimum":5,"title":"Interval Minutes"},"boundary_minutes":{"items":{"type":"integer"},"type":"array","maxItems":60,"minItems":1,"title":"Boundary Minutes"}},"type":"object","required":["interval_minutes","boundary_minutes"],"title":"TMSSessionGridParams","description":"TMS sessions only start at fixed minute-of-hour boundaries\n(e.g. ``:00`` and ``:30``) so the technician can run them\nback-to-back without gaps."}}}}
```

## The TakeoverEligibility object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TakeoverEligibility":{"properties":{"eligible":{"type":"boolean","title":"Eligible"},"mode_options":{"items":{"type":"string","enum":["listen","takeover"]},"type":"array","title":"Mode Options","default":[]},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Reason"},"held_by":{"anyOf":[{"$ref":"#/components/schemas/RunHold"},{"type":"null"}],"description":"The operator who holds the run, since when and until when. Left out of the response while no operator does."}},"type":"object","required":["eligible"],"title":"TakeoverEligibility","description":"Whether an operator can take a run over, and how — the channel-neutral signal the\nconsole keys on instead of a per-channel heuristic.\n\n``eligible`` = an operator may take this run over right now. ``mode_options`` = the\ntakeover modes valid for the run's channel (voice exposes ``listen`` + ``takeover``;\nenumerated asynchronous channels expose authored-turn ``takeover`` only).\n``reason`` = a short, human-facing explanation when NOT eligible (e.g.\n``\"run is not live\"``, ``\"channel not yet supported\"``), so the console can\nrender an honest disabled-state tooltip rather than a bare greyed button.\nServer-computed (see ``Run.takeover``) so eligibility rules live in one place and the\nconsole never re-derives them."},"RunHold":{"properties":{"operator_id":{"type":"string","format":"uuid","title":"Operator Id","description":"The operator who holds the run."},"since":{"type":"string","format":"date-time","title":"Since","description":"When this hold began. A renewal keeps it."},"expires_at":{"type":"string","format":"date-time","title":"Expires At","description":"When the hold ends unless the holder renews it."}},"type":"object","required":["operator_id","since","expires_at"],"title":"RunHold","description":"Who holds a text run, since when, and until when unless it is renewed."}}}}
```

## The TargetSpec object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TargetSpec":{"properties":{"desired_states":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"Desired States"},"non_desired_states":{"items":{"$ref":"#/components/schemas/NonDesiredState"},"type":"array","maxItems":50,"title":"Non Desired States"},"ordered_pathways":{"items":{"$ref":"#/components/schemas/OrderedPathway"},"type":"array","maxItems":20,"title":"Ordered Pathways"},"completion_criteria":{"$ref":"#/components/schemas/CompletionCriteria"}},"type":"object","title":"TargetSpec"},"NonDesiredState":{"properties":{"state":{"type":"string","maxLength":128,"title":"State"},"mode":{"type":"string","enum":["hard","soft"],"title":"Mode","default":"hard"}},"type":"object","required":["state"],"title":"NonDesiredState"},"OrderedPathway":{"properties":{"id":{"type":"string","maxLength":64,"title":"Id"},"sequence":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"minItems":1,"title":"Sequence"}},"type":"object","required":["id","sequence"],"title":"OrderedPathway"},"CompletionCriteria":{"properties":{"state_based":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"State Based"},"tool_based":{"items":{"type":"string","maxLength":128},"type":"array","maxItems":50,"title":"Tool Based"}},"type":"object","title":"CompletionCriteria"}}}}
```

## The TestCallerNumbersRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TestCallerNumbersRequest":{"properties":{"numbers":{"items":{"type":"string"},"type":"array","maxItems":100,"title":"Numbers"}},"type":"object","required":["numbers"],"title":"TestCallerNumbersRequest"}}}}
```

## The TestCallerNumbersResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TestCallerNumbersResponse":{"properties":{"numbers":{"items":{"type":"string"},"type":"array","title":"Numbers"}},"type":"object","required":["numbers"],"title":"TestCallerNumbersResponse"}}}}
```

## The TestCredentialIdsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TestCredentialIdsRequest":{"properties":{"credential_ids":{"items":{"type":"string","format":"uuid"},"type":"array","maxItems":100,"title":"Credential Ids"}},"type":"object","required":["credential_ids"],"title":"TestCredentialIdsRequest"}}}}
```

## The TestCredentialIdsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TestCredentialIdsResponse":{"properties":{"credential_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Credential Ids"}},"type":"object","required":["credential_ids"],"title":"TestCredentialIdsResponse"}}}}
```

## The TestInvokeResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TestInvokeResponse":{"properties":{"result":{"title":"Result"},"duration_ms":{"type":"number","title":"Duration Ms","default":0},"row_count":{"type":"integer","title":"Row Count","default":0},"status":{"type":"string","title":"Status","default":"pass"},"error":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Error"},"test_duration_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Test Duration Ms"}},"type":"object","title":"TestInvokeResponse","description":"The result of testing a function with `POST /v1/{workspace_id}/functions/{function_name}/test`.\n\nIt has the fields of an invoke response, plus `status`, `error` and `test_duration_ms`. A run the executor\nrefuses (422, such as arguments that do not fit or a stored body that is refused) or that fails in\nexecution (5xx) still returns 200, with `status` set to `fail` and the reason in `error`, so the caller can\nshow the message. Any other 4xx, such as a missing function, is returned as that error. `error` is never\nempty when `status` is `fail`."}}}}
```

## The TestSkillFailureClass object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TestSkillFailureClass":{"type":"string","enum":["model_rejected","rounds_exhausted","generic"]}}}}
```

## The TestSkillRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TestSkillRequest":{"properties":{"input":{"additionalProperties":true,"type":"object","title":"Input","description":"Input parameters to pass to the skill executor."},"static_tool_mocks":{"additionalProperties":{"$ref":"#/components/schemas/_ToolMockValue"},"propertyNames":{"$ref":"#/components/schemas/_ToolMockKey"},"type":"object","maxProperties":64,"title":"Static Tool Mocks","description":"Map of static tool name (max 128 chars) to mocked output string (max 16 KB). Up to 64 entries."}},"type":"object","required":["input"],"title":"TestSkillRequest"},"_ToolMockValue":{"type":"string","maxLength":16384},"_ToolMockKey":{"type":"string","maxLength":128,"minLength":1}}}}
```

## The TestSkillResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TestSkillResponse":{"properties":{"result":{"type":"string","title":"Result","description":"Final result text produced by the skill"},"duration_ms":{"type":"number","title":"Duration Ms","description":"Total execution time in milliseconds"},"input_tokens":{"type":"integer","title":"Input Tokens","description":"Number of input tokens consumed"},"output_tokens":{"type":"integer","title":"Output Tokens","description":"Number of output tokens generated"},"cached_tokens":{"type":"integer","title":"Cached Tokens","description":"Number of tokens served from cache"},"rounds":{"type":"integer","title":"Rounds","description":"Number of agent reasoning rounds executed"},"sub_tool_logs":{"items":{"$ref":"#/components/schemas/SubToolLog"},"type":"array","title":"Sub Tool Logs","description":"Chronological log of tool invocations"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Why the run failed, in the platform's own words; null when it succeeded."},"failure_class":{"anyOf":[{"$ref":"#/components/schemas/TestSkillFailureClass"},{"type":"null"}],"description":"Why the run failed; null when it succeeded. model_rejected: the model provider refused a request the run sent (HTTP 400, 413 or 422), which points at the skill's tools, schemas, prompt or model settings. rounds_exhausted: the run spent its tool-round budget. generic: anything else, including a provider error on the platform's side (credentials, a missing endpoint, a rate limit, an outage) and a tool call the model narrated as text instead of making."}},"type":"object","required":["result","duration_ms","input_tokens","output_tokens","cached_tokens","rounds","sub_tool_logs"],"title":"TestSkillResponse"},"SubToolLog":{"properties":{"tool_name":{"type":"string","title":"Tool Name","description":"Name of the tool that was invoked"},"input":{"additionalProperties":true,"type":"object","title":"Input","description":"Input parameters passed to the tool"},"output":{"type":"string","title":"Output","description":"Raw output returned by the tool"},"duration_ms":{"type":"number","title":"Duration Ms","description":"Execution time in milliseconds"},"succeeded":{"type":"boolean","title":"Succeeded","description":"Whether the tool invocation succeeded"},"round":{"type":"integer","title":"Round","description":"Agent reasoning round in which the tool was called"}},"type":"object","required":["tool_name","input","output","duration_ms","succeeded","round"],"title":"SubToolLog"},"TestSkillFailureClass":{"type":"string","enum":["model_rejected","rounds_exhausted","generic"]}}}}
```

## The TextMedicalFloor object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"}}}}
```

## The TextSelfHarmFloor object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"}}}}
```

## The ThinkingEffort object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ThinkingEffort":{"type":"string","enum":["low","medium","high"]}}}}
```

## The ThroughputBucket object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ThroughputBucket":{"properties":{"bucket":{"type":"string","title":"Bucket"},"source_system":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source System"},"event_count":{"type":"integer","title":"Event Count"}},"type":"object","required":["bucket","event_count"],"title":"ThroughputBucket"}}}}
```

## The TimelineActor object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TimelineActor":{"properties":{"kind":{"type":"string","enum":["agent","human","operator","system","tool"],"title":"Kind"},"role":{"type":"string","enum":["agent","caller","operator","runtime","state","tool"],"title":"Role"},"label":{"type":"string","title":"Label"},"participant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Id"}},"type":"object","required":["kind","role","label"],"title":"TimelineActor"}}}}
```

## The TimelineLaneDefinition object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TimelineLaneDefinition":{"properties":{"id":{"type":"string","maxLength":160,"minLength":1,"title":"Id","description":"Stable canonical lane id used by timeline visualizations. Segments attach via TimelineSegment.lane_id; consumers should not re-infer lanes from CSS or pixel positions."},"track":{"type":"string","enum":["agent","caller","operator","system","tool"],"title":"Track","description":"High-level actor-semantic track for styling and grouping."},"label":{"type":"string","title":"Label","description":"Display label for the lane."},"order":{"type":"integer","title":"Order","description":"Stable vertical order within the timeline lane model."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor represented by this lane when applicable."}},"type":"object","required":["id","track","label","order"],"title":"TimelineLaneDefinition"},"TimelineActor":{"properties":{"kind":{"type":"string","enum":["agent","human","operator","system","tool"],"title":"Kind"},"role":{"type":"string","enum":["agent","caller","operator","runtime","state","tool"],"title":"Role"},"label":{"type":"string","title":"Label"},"participant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Id"}},"type":"object","required":["kind","role","label"],"title":"TimelineActor"}}}}
```

## The TimelineSegment object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TimelineSegment":{"properties":{"type":{"type":"string","enum":["agent_speech","barge_in","caller_speech","filler","filler_hesitation","filler_nav","greeting","interrupted_speech","processing_gap","silence","silence_check","state_transition","tool_call"],"title":"Type"},"lane":{"type":"string","enum":["agent","caller","events","operator","system","tool"],"title":"Lane"},"track":{"anyOf":[{"type":"string","enum":["agent","caller","operator","system","tool"]},{"type":"null"}],"title":"Track","description":"Actor-semantic display track for the segment. Inferred for legacy producers."},"lane_id":{"anyOf":[{"type":"string","maxLength":160,"minLength":1},{"type":"null"}],"title":"Lane Id","description":"Canonical lane id. Must match PlaybackTimeline.lanes[].id after platform normalization."},"order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Order","description":"Canonical event order after platform time/lane normalization."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor responsible for the segment. Inferred for legacy producers."},"start":{"type":"number","title":"Start"},"end":{"type":"number","title":"End"},"label":{"type":"string","title":"Label"},"turn_index":{"type":"integer","title":"Turn Index","description":"The segment's turn: its index in the response's ``turns`` on\n``GET /conversations/{conversation_id}``, the call-detail row the timeline was built from on\n``GET /calls/{call_id}``, or -1 when no turn owns it (a silence, a barge-in)."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the segment's turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on segments no\nexchange owns."},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eot Confidence"},"audio_window_start":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window Start"},"audio_window_end":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window End"},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Render Ms"},"audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Ttfb Ms"},"e2e_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"E2E Ttfb Ms"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"parent_call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Call Id"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"from_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From State"},"to_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"To State"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"}},"type":"object","required":["type","lane","start","end","label","turn_index"],"title":"TimelineSegment"},"TimelineActor":{"properties":{"kind":{"type":"string","enum":["agent","human","operator","system","tool"],"title":"Kind"},"role":{"type":"string","enum":["agent","caller","operator","runtime","state","tool"],"title":"Role"},"label":{"type":"string","title":"Label"},"participant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Id"}},"type":"object","required":["kind","role","label"],"title":"TimelineActor"}}}}
```

## The TimelineTimebase object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TimelineTimebase":{"properties":{"unit":{"type":"string","const":"seconds","title":"Unit","description":"Timeline offsets are always seconds.","default":"seconds"},"origin":{"type":"string","enum":["media_start","call_start","synthetic"],"title":"Origin","description":"Zero point used for segment start/end offsets.","default":"media_start"},"start":{"type":"number","title":"Start","description":"Visible/canonical timeline range start in seconds.","default":0},"end":{"type":"number","title":"End","description":"Visible/canonical timeline range end in seconds.","default":0}},"type":"object","title":"TimelineTimebase"}}}}
```

## The Tool object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Tool":{"properties":{"name":{"$ref":"#/components/schemas/NameString"},"description":{"$ref":"#/components/schemas/DescriptionString"}},"type":"object","required":["name","description"],"title":"Tool"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The ToolCall object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolCall":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"input":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input"},"output":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output"},"output_truncated":{"type":"boolean","title":"Output Truncated","default":false},"output_original_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Output Original Length"},"output_truncated_to":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Output Truncated To"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"executed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Executed"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"}},"type":"object","required":["tool_name"],"title":"ToolCall"}}}}
```

## The ToolCallDetail object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"input":{"type":"string","title":"Input","default":""},"result":{"type":"string","title":"Result","default":""},"call_id":{"type":"string","title":"Call Id","default":""},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"execution":{"anyOf":[{"type":"string","enum":["live","mocked","dry_run"]},{"type":"null"}],"title":"Execution","description":"How the call ran: `live` for real, `mocked` against the run's `tool_mocks` entry, or `dry_run`\n(it returned a placeholder). A companion skill carries its most simulated tool's label, and none\nwhen no tool it can call was simulated: its output is its own text, never a system's response.\nNull then, on a record that predates the label, and for a name that was not a session tool."},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["tool_name"],"title":"ToolCallDetail","description":"Rich tool call data from a simulation step."}}}}
```

## The ToolCallSpec object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"}}}}
```

## The ToolCatalogResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolCatalogResponse":{"properties":{"tools":{"items":{"$ref":"#/components/schemas/ResolvedToolItem"},"type":"array","title":"Tools"}},"type":"object","required":["tools"],"title":"ToolCatalogResponse"},"ResolvedToolItem":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"tool_type":{"type":"string","title":"Tool Type"},"description":{"type":"string","title":"Description","default":""},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"states":{"items":{"type":"string"},"type":"array","title":"States"},"tier":{"type":"string","title":"Tier","default":"world"},"is_write":{"type":"boolean","title":"Is Write","description":"The tool can change something, so a simulation never runs it for real: a world write, an\nendpoint whose HTTP method mutates or that declares a write, or a data query whose stored\ntemplate is not a read-only query.","default":false},"additional_instructions":{"additionalProperties":{"type":"string"},"type":"object","title":"Additional Instructions"},"requires_approval":{"type":"boolean","title":"Requires Approval","description":"The integration's approval policy gates this tool, so a simulation never runs it for real.","default":false},"live_read_eligible":{"type":"boolean","title":"Live Read Eligible","description":"A simulation launch can run this tool for real by naming it in `tool_execution.live_read_tools`.","default":false},"skills":{"items":{"type":"string"},"type":"array","title":"Skills","description":"The companion skills in this service's graph that can call this tool."},"integration_display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Display Name","description":"For an integration endpoint, its integration's display name."},"base_url_host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Base Url Host","description":"For an integration endpoint, the host its calls go to."}},"type":"object","required":["tool_name","tool_type"],"title":"ResolvedToolItem"}}}}
```

## The ToolDescriptor object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolDescriptor":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description","default":""},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","default":{}}},"type":"object","required":["name"],"title":"ToolDescriptor"}}}}
```

## The ToolExecuteRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolExecuteRequest":{"properties":{"tool_type":{"type":"string","maxLength":64,"title":"Tool Type","description":"world_tool — other tool families use their dedicated endpoints"},"tool_name":{"$ref":"#/components/schemas/NameString","description":"Fully qualified tool name"},"service_id":{"type":"string","format":"uuid","title":"Service Id","description":"Service ID that owns the HSM"},"input_params":{"additionalProperties":true,"type":"object","title":"Input Params","description":"Parameters to pass to the tool handler"},"entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Entity Id","description":"Optional entity ID for context"},"dry_run":{"type":"boolean","title":"Dry Run","description":"If true, write tools are simulated without persistence","default":false}},"type":"object","required":["tool_type","tool_name","service_id"],"title":"ToolExecuteRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The ToolExecuteResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolExecuteResponse":{"properties":{"result":{"title":"Result"},"duration_ms":{"type":"number","title":"Duration Ms","default":0},"dry_run":{"type":"boolean","title":"Dry Run","default":false},"source":{"type":"string","title":"Source","default":"tool_test"},"tool_type":{"type":"string","title":"Tool Type","default":""},"tier":{"type":"string","title":"Tier","default":"world"},"is_write":{"type":"boolean","title":"Is Write","default":false},"sub_tool_logs":{"items":{"$ref":"#/components/schemas/SubToolLogItem"},"type":"array","title":"Sub Tool Logs"},"blocked_side_effects":{"items":{"type":"string"},"type":"array","title":"Blocked Side Effects"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error"}},"type":"object","title":"ToolExecuteResponse"},"SubToolLogItem":{"properties":{"tool_name":{"type":"string","title":"Tool Name","default":""},"input":{"additionalProperties":true,"type":"object","title":"Input"},"output":{"type":"string","title":"Output","default":""},"duration_ms":{"type":"number","title":"Duration Ms","default":0},"succeeded":{"type":"boolean","title":"Succeeded","default":true}},"type":"object","title":"SubToolLogItem"}}}}
```

## The ToolOutcome object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolOutcome":{"properties":{"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"name":{"type":"string","maxLength":512,"title":"Name"},"call_id":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Call Id"},"outcome":{"type":"string","enum":["succeeded","failed","not_executed","unknown"],"title":"Outcome"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"}},"type":"object","required":["name","outcome"],"title":"ToolOutcome"}}}}
```

## The ToolPerformanceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolPerformanceResponse":{"properties":{"summary":{"$ref":"#/components/schemas/ToolPerformanceSummary","description":"Tool executions in the window"},"trend":{"items":{"$ref":"#/components/schemas/ToolPerformanceTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"One point per bucket with a tool summary"},"groups":{"anyOf":[{"items":{"$ref":"#/components/schemas/ServiceToolPerformance"},"type":"array"},{"type":"null"}],"title":"Groups","description":"With group_by=service_id, one entry per service with calls in the window, ordered by service_id. A grouped answer holds at most 22,000 points in all (trend points, groups' trend points and breakdown rows); one that would hold more is a 422. Null without group_by."}},"type":"object","required":["summary","trend"],"title":"ToolPerformanceResponse","description":"Tool execution totals and a trend, over the calls that carry a tool summary."},"ToolPerformanceSummary":{"properties":{"total_tool_calls":{"type":"integer","title":"Total Tool Calls","description":"Tool executions"},"total_succeeded":{"type":"integer","title":"Total Succeeded","description":"Tool executions that succeeded"},"total_failed":{"type":"integer","title":"Total Failed","description":"Tool executions that failed"},"overall_failure_rate":{"type":"number","title":"Overall Failure Rate","description":"total_failed over total_tool_calls; 0.0 with no executions"},"avg_failure_rate_per_call":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Failure Rate Per Call","description":"Mean of each call's tool failure rate; null with no tool summaries"}},"type":"object","required":["total_tool_calls","total_succeeded","total_failed","overall_failure_rate"],"title":"ToolPerformanceSummary","description":"Tool executions in the window, over the calls that carry a tool summary."},"ToolPerformanceTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Bucket start as an ISO-8601 timestamp string (granularity follows `interval`)"},"call_count":{"type":"integer","title":"Call Count","description":"Calls in the bucket with a tool summary"},"total_tool_calls":{"type":"integer","title":"Total Tool Calls","description":"Tool executions in the bucket"},"total_failed":{"type":"integer","title":"Total Failed","description":"Tool executions in the bucket that failed"}},"type":"object","required":["date","call_count","total_tool_calls","total_failed"],"title":"ToolPerformanceTrendPoint","description":"One interval bucket of tool performance."},"ServiceToolPerformance":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id","description":"The service"},"summary":{"$ref":"#/components/schemas/ToolPerformanceSummary","description":"The service's tool executions in the window"},"trend":{"items":{"$ref":"#/components/schemas/ToolPerformanceTrendPoint"},"type":"array","maxItems":2200,"title":"Trend","description":"The service's trend"}},"type":"object","required":["service_id","summary","trend"],"title":"ServiceToolPerformance","description":"One service's summary and trend: what the route returns for ``service_id`` set to it."}}}}
```

## The ToolPerformanceSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolPerformanceSummary":{"properties":{"total_tool_calls":{"type":"integer","title":"Total Tool Calls","description":"Tool executions"},"total_succeeded":{"type":"integer","title":"Total Succeeded","description":"Tool executions that succeeded"},"total_failed":{"type":"integer","title":"Total Failed","description":"Tool executions that failed"},"overall_failure_rate":{"type":"number","title":"Overall Failure Rate","description":"total_failed over total_tool_calls; 0.0 with no executions"},"avg_failure_rate_per_call":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Failure Rate Per Call","description":"Mean of each call's tool failure rate; null with no tool summaries"}},"type":"object","required":["total_tool_calls","total_succeeded","total_failed","overall_failure_rate"],"title":"ToolPerformanceSummary","description":"Tool executions in the window, over the calls that carry a tool summary."}}}}
```

## The ToolPerformanceTrendPoint object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolPerformanceTrendPoint":{"properties":{"date":{"type":"string","title":"Date","description":"Bucket start as an ISO-8601 timestamp string (granularity follows `interval`)"},"call_count":{"type":"integer","title":"Call Count","description":"Calls in the bucket with a tool summary"},"total_tool_calls":{"type":"integer","title":"Total Tool Calls","description":"Tool executions in the bucket"},"total_failed":{"type":"integer","title":"Total Failed","description":"Tool executions in the bucket that failed"}},"type":"object","required":["date","call_count","total_tool_calls","total_failed"],"title":"ToolPerformanceTrendPoint","description":"One interval bucket of tool performance."}}}}
```

## The ToolResolveResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolResolveResponse":{"properties":{"tools":{"items":{"$ref":"#/components/schemas/ResolvedToolItem"},"type":"array","title":"Tools"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"}},"type":"object","required":["tools","service_id","workspace_id"],"title":"ToolResolveResponse"},"ResolvedToolItem":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"tool_type":{"type":"string","title":"Tool Type"},"description":{"type":"string","title":"Description","default":""},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"states":{"items":{"type":"string"},"type":"array","title":"States"},"tier":{"type":"string","title":"Tier","default":"world"},"is_write":{"type":"boolean","title":"Is Write","description":"The tool can change something, so a simulation never runs it for real: a world write, an\nendpoint whose HTTP method mutates or that declares a write, or a data query whose stored\ntemplate is not a read-only query.","default":false},"additional_instructions":{"additionalProperties":{"type":"string"},"type":"object","title":"Additional Instructions"},"requires_approval":{"type":"boolean","title":"Requires Approval","description":"The integration's approval policy gates this tool, so a simulation never runs it for real.","default":false},"live_read_eligible":{"type":"boolean","title":"Live Read Eligible","description":"A simulation launch can run this tool for real by naming it in `tool_execution.live_read_tools`.","default":false},"skills":{"items":{"type":"string"},"type":"array","title":"Skills","description":"The companion skills in this service's graph that can call this tool."},"integration_display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Display Name","description":"For an integration endpoint, its integration's display name."},"base_url_host":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Base Url Host","description":"For an integration endpoint, the host its calls go to."}},"type":"object","required":["tool_name","tool_type"],"title":"ResolvedToolItem"}}}}
```

## The ToolSummary object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolSummary":{"properties":{"total_calls":{"type":"integer","title":"Total Calls","description":"Total tool invocations","default":0},"succeeded":{"type":"integer","title":"Succeeded","description":"Successful tool invocations","default":0},"failed":{"type":"integer","title":"Failed","description":"Failed tool invocations","default":0},"failure_rate":{"type":"number","title":"Failure Rate","description":"Tool failure rate 0.0 to 1.0","default":0}},"type":"object","title":"ToolSummary","description":"Tool usage statistics.\n\nFree-form residual on the raw ``tool_summary`` JSONB:\n``by_tool: list[{name, calls, succeeded, failed, avg_duration_ms}]``\n— per-tool breakdown. Not exposed via this typed shape."}}}}
```

## The Tools object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Tools":{"properties":{"descriptors":{"items":{"$ref":"#/components/schemas/ToolDescriptor"},"type":"array","title":"Descriptors","default":[]},"read_tool_names":{"items":{"type":"string"},"type":"array","title":"Read Tool Names","default":[]},"write_tool_names":{"items":{"type":"string"},"type":"array","title":"Write Tool Names","default":[]}},"type":"object","title":"Tools","description":"Discovery hint — the neutral descriptors. NOT the enforcement (the MCP\nedge is; a remote agent discovers live schemas from the server too)."},"ToolDescriptor":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description","default":""},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","default":{}}},"type":"object","required":["name"],"title":"ToolDescriptor"}}}}
```

## The TraceAnalysisListItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TraceAnalysisListItem":{"properties":{"call_sid":{"type":"string","maxLength":128,"minLength":1,"title":"Call Sid","description":"Call identifier"},"call_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Call Entity Id","description":"Associated call entity row UUID"},"outcome":{"anyOf":[{"type":"string","enum":["succeeded","partially","failed","abandoned"]},{"type":"null"}],"title":"Outcome","description":"Overall call outcome"},"summary":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Summary","description":"Short call summary"},"emotional_arc":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Emotional Arc","description":"Caller emotional trajectory string"},"key_moment_count":{"type":"integer","minimum":0,"title":"Key Moment Count","description":"Number of key moments identified","default":0},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At","description":"When the analysis was produced"}},"type":"object","required":["call_sid"],"title":"TraceAnalysisListItem","description":"Compact summary of a trace analysis row for list views."}}}}
```

## The TraceAnalysisListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TraceAnalysisListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TraceAnalysisListItem"},"type":"array","title":"Items","description":"Trace analysis summaries"},"has_more":{"type":"boolean","title":"Has More","description":"Whether more rows are available beyond this page","default":false},"continuation_token":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Continuation Token","description":"Token to pass as ``continuation_token`` for the next page (None when exhausted)"}},"type":"object","title":"TraceAnalysisListResponse","description":"Paginated list response for trace analyses."},"TraceAnalysisListItem":{"properties":{"call_sid":{"type":"string","maxLength":128,"minLength":1,"title":"Call Sid","description":"Call identifier"},"call_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Call Entity Id","description":"Associated call entity row UUID"},"outcome":{"anyOf":[{"type":"string","enum":["succeeded","partially","failed","abandoned"]},{"type":"null"}],"title":"Outcome","description":"Overall call outcome"},"summary":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Summary","description":"Short call summary"},"emotional_arc":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Emotional Arc","description":"Caller emotional trajectory string"},"key_moment_count":{"type":"integer","minimum":0,"title":"Key Moment Count","description":"Number of key moments identified","default":0},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At","description":"When the analysis was produced"}},"type":"object","required":["call_sid"],"title":"TraceAnalysisListItem","description":"Compact summary of a trace analysis row for list views."}}}}
```

## The TraceAnalysisResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TraceAnalysisResponse":{"properties":{"call_sid":{"type":"string","maxLength":128,"minLength":1,"title":"Call Sid","description":"Call identifier (Twilio call SID or direct session ID)"},"status":{"type":"string","enum":["ready","pending","unavailable"],"title":"Status","description":"ready: analysis complete. pending: call completed, analysis processing. unavailable: analysis not possible for this call.","default":"ready"},"summary":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Summary","description":"2-3 sentence narrative of the call - the emotional story, not just what happened"},"outcome":{"anyOf":[{"type":"string","enum":["succeeded","partially","failed","abandoned"]},{"type":"null"}],"title":"Outcome","description":"Overall call outcome"},"key_moment_count":{"type":"integer","minimum":0,"title":"Key Moment Count","description":"Number of key decision moments identified (typically 3-8)","default":0},"key_moments":{"items":{"$ref":"#/components/schemas/TraceKeyMoment"},"type":"array","maxItems":100,"title":"Key Moments","description":"Key decision points with causal attribution to audio inputs"},"emotional_arc":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Emotional Arc","description":"Caller emotional trajectory as a readable sequence (e.g. 'curious -> confused -> frustrated -> relieved')"},"emotional_shifts":{"items":{"$ref":"#/components/schemas/EmotionalShift"},"type":"array","maxItems":100,"title":"Emotional Shifts","description":"Critical emotional state changes detected in the caller's voice"},"interaction_dynamics":{"anyOf":[{"$ref":"#/components/schemas/InteractionDynamics"},{"type":"null"}],"description":"System-level conversation flow analysis"},"coaching":{"items":{"$ref":"#/components/schemas/CoachingItem"},"type":"array","maxItems":50,"title":"Coaching","description":"Specific, actionable agent improvements tied to exact moments in this call"},"counterfactuals":{"items":{"$ref":"#/components/schemas/Counterfactual"},"type":"array","maxItems":50,"title":"Counterfactuals","description":"Alternative actions that would have meaningfully changed the outcome"},"deep_understanding":{"anyOf":[{"type":"string","maxLength":10000,"minLength":1},{"type":"null"}],"title":"Deep Understanding","description":"Synthesis of why this call went the way it did - combining audio perception with execution data"},"signal_response_alignment":{"items":{"$ref":"#/components/schemas/SignalResponseAlignment"},"type":"array","maxItems":50,"title":"Signal Response Alignment","description":"Per-signal alignment analysis: whether the agent's response matched each salient signal"},"missed_opportunities":{"items":{"type":"string","maxLength":2000,"minLength":1},"type":"array","maxItems":50,"title":"Missed Opportunities","description":"Moments where the agent could have taken a better action"},"emergent_patterns":{"items":{"type":"string","maxLength":2000,"minLength":1},"type":"array","maxItems":50,"title":"Emergent Patterns","description":"Cross-call or cross-turn patterns detected by the analysis"},"call_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Call Entity Id","description":"UUID string of the associated call entity row (if resolved)"},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At","description":"When the analysis was produced by the pipeline"}},"type":"object","required":["call_sid"],"title":"TraceAnalysisResponse","description":"Deep call understanding produced by the Amigo intelligence pipeline.\n\nAnalyzes the raw call audio to identify emotional dynamics, key decision\nmoments, and actionable coaching - understanding that exceeds what either\nparticipant had during the call itself.\n\n**Latency note**: This endpoint is an analytics read. Expect 500ms-2s\nresponse time, not sub-10ms like transactional endpoints."},"TraceKeyMoment":{"properties":{"timestamp_seconds":{"anyOf":[{"type":"number","maximum":86400,"minimum":0},{"type":"null"}],"title":"Timestamp Seconds","description":"Approximate position in the recording (seconds from start)"},"what_happened":{"type":"string","maxLength":2000,"minLength":1,"title":"What Happened","description":"Plain-English description of the agent's decision"},"quality":{"anyOf":[{"type":"string","enum":["optimal","adequate","suboptimal"]},{"type":"null"}],"title":"Quality","description":"Assessment of the decision quality"},"reasoning":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Reasoning","description":"Why this was the right or wrong choice given the audio context"},"decision_factors":{"items":{"$ref":"#/components/schemas/DecisionFactor"},"type":"array","maxItems":20,"title":"Decision Factors","description":"Specific audio inputs that drove this decision"},"alternative":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Alternative","description":"What else the agent could have done and the likely outcome"}},"type":"object","required":["what_happened"],"title":"TraceKeyMoment","description":"A key decision point identified from the call audio."},"DecisionFactor":{"properties":{"factor":{"type":"string","maxLength":2000,"minLength":1,"title":"Factor","description":"What specifically drove this decision - exact words heard or tone described"},"source_type":{"type":"string","title":"Source Type","description":"Category of the audio input"}},"type":"object","required":["factor","source_type"],"title":"DecisionFactor","description":"A specific audio input that drove an agent decision."},"EmotionalShift":{"properties":{"timestamp_seconds":{"anyOf":[{"type":"number","maximum":86400,"minimum":0},{"type":"null"}],"title":"Timestamp Seconds","description":"When the shift occurred (seconds from start)"},"from_state":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"From State","description":"Emotional state before the shift"},"to_state":{"anyOf":[{"type":"string","maxLength":500,"minLength":1},{"type":"null"}],"title":"To State","description":"Emotional state after the shift"},"trigger":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Trigger","description":"What caused the shift - exact words and tone"},"agent_awareness":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Agent Awareness","description":"Whether the agent noticed and responded to this shift"}},"type":"object","title":"EmotionalShift","description":"A critical emotional state change detected in the caller's voice."},"InteractionDynamics":{"properties":{"turn_taking_quality":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Turn Taking Quality","description":"How well speakers managed turn-taking - interruptions, overlaps, pacing"},"information_density":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Information Density","description":"Whether the agent gave too much or too little information per turn"},"repair_effectiveness":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Repair Effectiveness","description":"How misunderstandings were detected and resolved"},"rapport_trajectory":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Rapport Trajectory","description":"How the interpersonal dynamic evolved across the call"}},"type":"object","title":"InteractionDynamics","description":"System-level analysis of the conversation as a whole."},"CoachingItem":{"properties":{"moment_timestamp":{"anyOf":[{"type":"number","maximum":86400,"minimum":0},{"type":"null"}],"title":"Moment Timestamp","description":"Position in the recording this coaching applies to (seconds)"},"observation":{"type":"string","maxLength":2000,"minLength":1,"title":"Observation","description":"What was observed in the audio at this moment"},"recommendation":{"type":"string","maxLength":2000,"minLength":1,"title":"Recommendation","description":"Specific improvement the agent should make"},"expected_impact":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Expected Impact","description":"How this improvement would change the interaction"}},"type":"object","required":["observation","recommendation"],"title":"CoachingItem","description":"A specific, actionable improvement tied to an exact moment in the call."},"Counterfactual":{"properties":{"timestamp_seconds":{"anyOf":[{"type":"number","maximum":86400,"minimum":0},{"type":"null"}],"title":"Timestamp Seconds","description":"When the alternative action was available (seconds)"},"actual":{"type":"string","maxLength":2000,"minLength":1,"title":"Actual","description":"What the agent actually did"},"alternative":{"type":"string","maxLength":2000,"minLength":1,"title":"Alternative","description":"What it could have done instead"},"predicted_impact":{"type":"string","maxLength":2000,"minLength":1,"title":"Predicted Impact","description":"How the call would have gone differently"}},"type":"object","required":["actual","alternative","predicted_impact"],"title":"Counterfactual","description":"An alternative action that would have meaningfully changed the call outcome."},"SignalResponseAlignment":{"properties":{"signal":{"type":"string","maxLength":2000,"minLength":1,"title":"Signal","description":"The signal observed (e.g. caller tone shift, tool result, silence)"},"agent_response":{"type":"string","maxLength":2000,"minLength":1,"title":"Agent Response","description":"What the agent did in response"},"alignment":{"type":"string","enum":["aligned","misaligned","partial"],"title":"Alignment","description":"Whether the response was aligned, misaligned, or partial"},"insight":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Insight","description":"Short insight on why the alignment went the way it did"}},"type":"object","required":["signal","agent_response","alignment"],"title":"SignalResponseAlignment","description":"Whether the agent's response aligned with a salient signal in the call."}}}}
```

## The TraceKeyMoment object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TraceKeyMoment":{"properties":{"timestamp_seconds":{"anyOf":[{"type":"number","maximum":86400,"minimum":0},{"type":"null"}],"title":"Timestamp Seconds","description":"Approximate position in the recording (seconds from start)"},"what_happened":{"type":"string","maxLength":2000,"minLength":1,"title":"What Happened","description":"Plain-English description of the agent's decision"},"quality":{"anyOf":[{"type":"string","enum":["optimal","adequate","suboptimal"]},{"type":"null"}],"title":"Quality","description":"Assessment of the decision quality"},"reasoning":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Reasoning","description":"Why this was the right or wrong choice given the audio context"},"decision_factors":{"items":{"$ref":"#/components/schemas/DecisionFactor"},"type":"array","maxItems":20,"title":"Decision Factors","description":"Specific audio inputs that drove this decision"},"alternative":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Alternative","description":"What else the agent could have done and the likely outcome"}},"type":"object","required":["what_happened"],"title":"TraceKeyMoment","description":"A key decision point identified from the call audio."},"DecisionFactor":{"properties":{"factor":{"type":"string","maxLength":2000,"minLength":1,"title":"Factor","description":"What specifically drove this decision - exact words heard or tone described"},"source_type":{"type":"string","title":"Source Type","description":"Category of the audio input"}},"type":"object","required":["factor","source_type"],"title":"DecisionFactor","description":"A specific audio input that drove an agent decision."}}}}
```

## The TracesExportRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TracesExportRequest":{"properties":{"start_time":{"type":"string","format":"date-time","title":"Start Time","description":"Inclusive lower bound on span ``effective_at`` (ISO-8601)."},"end_time":{"type":"string","format":"date-time","title":"End Time","description":"Exclusive upper bound on span ``effective_at`` (ISO-8601)."},"limit":{"type":"integer","maximum":1000,"exclusiveMinimum":0,"title":"Limit","description":"Max spans per page (1-1000).","default":500},"continuation_token":{"title":"Continuation Token","description":"Opaque page cursor — round-trip the value from the previous response."}},"type":"object","required":["start_time","end_time"],"title":"TracesExportRequest"}}}}
```

## The TracesExportResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TracesExportResponse":{"properties":{"resourceSpans":{"items":{"$ref":"#/components/schemas/ResourceSpans"},"type":"array","title":"Resourcespans","description":"OTLP/JSON ``ResourceSpans`` envelope (empty list when no spans match)."},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["resourceSpans","has_more"],"title":"TracesExportResponse","description":"Paginated PULL response — NOT a bare OTLP ``ExportTraceServiceRequest``.\n\n``resourceSpans`` is OTLP/JSON-conformant; to forward to an OTLP collector,\nextract ``.resourceSpans`` and re-wrap as ``{\"resourceSpans\": [...]}`` (a\nstrict protojson push receiver rejects the ``has_more``/``continuation_token``\nsiblings). Round-trip ``continuation_token`` to page."},"ResourceSpans":{"properties":{"resource":{"$ref":"#/components/schemas/Resource"},"scopeSpans":{"items":{"$ref":"#/components/schemas/ScopeSpans"},"type":"array","title":"Scopespans"}},"type":"object","required":["resource","scopeSpans"],"title":"ResourceSpans"},"Resource":{"properties":{"attributes":{"items":{"$ref":"#/components/schemas/KeyValue"},"type":"array","title":"Attributes"}},"type":"object","required":["attributes"],"title":"Resource"},"KeyValue":{"properties":{"key":{"type":"string","title":"Key"},"value":{"$ref":"#/components/schemas/AnyValue"}},"type":"object","required":["key","value"],"title":"KeyValue","description":"OTLP ``KeyValue`` attribute pair."},"AnyValue":{"additionalProperties":true,"type":"object"},"ScopeSpans":{"properties":{"scope":{"$ref":"#/components/schemas/InstrumentationScope"},"spans":{"items":{"$ref":"#/components/schemas/Span"},"type":"array","title":"Spans"}},"type":"object","required":["scope","spans"],"title":"ScopeSpans"},"InstrumentationScope":{"properties":{"name":{"type":"string","title":"Name"},"version":{"type":"string","title":"Version"}},"type":"object","required":["name","version"],"title":"InstrumentationScope"},"Span":{"properties":{"traceId":{"type":"string","title":"Traceid"},"spanId":{"type":"string","title":"Spanid"},"name":{"type":"string","title":"Name"},"kind":{"type":"integer","title":"Kind"},"startTimeUnixNano":{"type":"string","title":"Starttimeunixnano"},"endTimeUnixNano":{"type":"string","title":"Endtimeunixnano"},"attributes":{"items":{"$ref":"#/components/schemas/KeyValue"},"type":"array","title":"Attributes"},"status":{"$ref":"#/components/schemas/Status"}},"type":"object","required":["traceId","spanId","name","kind","startTimeUnixNano","endTimeUnixNano","attributes","status"],"title":"Span","description":"OTLP ``Span`` in OTLP/JSON encoding (ids hex, timestamps decimal-string)."},"Status":{"properties":{"code":{"type":"integer","title":"Code"}},"type":"object","required":["code"],"title":"Status","description":"OTLP ``Status`` — 0=UNSET, 1=OK, 2=ERROR."}}}}
```

## The TrajectoryStep object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TrajectoryStep":{"properties":{"seq":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Seq"},"kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Kind"},"actor":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Actor"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"tool_input_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Input Summary"},"tool_result_summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Result Summary"},"tool_succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tool Succeeded"},"decision_from_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Decision From State"},"decision_to_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Decision To State"},"effective_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Effective At"}},"type":"object","title":"TrajectoryStep","description":"One structural step of a framework run's trajectory. Fields are best-effort\n(only those the step actually carries are present), all optional, and free ``str``\nfor the same read-model resilience the ``Run`` descriptive fields use."}}}}
```

## The TranscriptSegment object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TranscriptSegment":{"properties":{"speaker_role":{"type":"string","title":"Speaker Role"},"transcript":{"type":"string","title":"Transcript"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp"},"escalation_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Escalation Id"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Confidence"}},"type":"object","required":["speaker_role","transcript","timestamp","escalation_id","confidence"],"title":"TranscriptSegment"}}}}
```

## The TransferReason object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The TransferReasonKey object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"}}}}
```

## The Transport object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Transport":{"type":"string","enum":["gateway","decisions","vertex","vertex_priority","vertex_batch","bedrock","openai_direct","voice_vendor"]}}}}
```

## The TriggerFireResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerFireResponse":{"properties":{"fired_event_id":{"type":"string","format":"uuid","title":"Fired Event Id"},"trigger_id":{"type":"string","format":"uuid","title":"Trigger Id"},"status":{"type":"string","const":"fired","title":"Status","default":"fired"}},"type":"object","required":["fired_event_id","trigger_id"],"title":"TriggerFireResponse"}}}}
```

## The TriggerListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TriggerResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"TriggerListResponse"},"TriggerResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name","description":"Trigger display name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description"},"event_type":{"type":"string","title":"Event Type","description":"Event type pattern to match"},"event_filter":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Event Filter","description":"JSONPath filter on event data"},"threshold":{"anyOf":[{"$ref":"#/components/schemas/TriggerThreshold"},{"type":"null"}],"description":"How many matching events fire the trigger, and within what window; null fires on every one"},"action_id":{"type":"string","format":"uuid","title":"Action Id","description":"Action (skill) to invoke when fired"},"input_template":{"additionalProperties":true,"type":"object","title":"Input Template","description":"Input template merged with event data"},"schedule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schedule","description":"Cron schedule expression (e.g. '0 9 * * 1-5')"},"timezone":{"type":"string","title":"Timezone","description":"IANA timezone for schedule evaluation"},"next_fire_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Fire At","description":"Next scheduled fire time"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the trigger is active"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"Entity ID of the creator"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the trigger was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the trigger was last updated"}},"type":"object","required":["id","workspace_id","name","event_type","action_id","input_template","timezone","is_active"],"title":"TriggerResponse"},"TriggerThreshold":{"properties":{"count":{"type":"integer","maximum":100,"minimum":1,"title":"Count"},"window_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Window Minutes"},"cooldown_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Cooldown Minutes","default":60}},"additionalProperties":false,"type":"object","required":["count","window_minutes"],"title":"TriggerThreshold","description":"How many matching events an event trigger waits for before it fires: ``count`` of them inside the last\n``window_minutes``. Once it fires, it holds off for ``cooldown_minutes`` however many more arrive."}}}}
```

## The TriggerResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"name":{"type":"string","title":"Name","description":"Trigger display name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Human-readable description"},"event_type":{"type":"string","title":"Event Type","description":"Event type pattern to match"},"event_filter":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Event Filter","description":"JSONPath filter on event data"},"threshold":{"anyOf":[{"$ref":"#/components/schemas/TriggerThreshold"},{"type":"null"}],"description":"How many matching events fire the trigger, and within what window; null fires on every one"},"action_id":{"type":"string","format":"uuid","title":"Action Id","description":"Action (skill) to invoke when fired"},"input_template":{"additionalProperties":true,"type":"object","title":"Input Template","description":"Input template merged with event data"},"schedule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Schedule","description":"Cron schedule expression (e.g. '0 9 * * 1-5')"},"timezone":{"type":"string","title":"Timezone","description":"IANA timezone for schedule evaluation"},"next_fire_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Fire At","description":"Next scheduled fire time"},"is_active":{"type":"boolean","title":"Is Active","description":"Whether the trigger is active"},"created_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created By","description":"Entity ID of the creator"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the trigger was created"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At","description":"When the trigger was last updated"}},"type":"object","required":["id","workspace_id","name","event_type","action_id","input_template","timezone","is_active"],"title":"TriggerResponse"},"TriggerThreshold":{"properties":{"count":{"type":"integer","maximum":100,"minimum":1,"title":"Count"},"window_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Window Minutes"},"cooldown_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Cooldown Minutes","default":60}},"additionalProperties":false,"type":"object","required":["count","window_minutes"],"title":"TriggerThreshold","description":"How many matching events an event trigger waits for before it fires: ``count`` of them inside the last\n``window_minutes``. Once it fires, it holds off for ``cooldown_minutes`` however many more arrive."}}}}
```

## The TriggerRunListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerRunListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/TriggerRunResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"TriggerRunListResponse"},"TriggerRunResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"trigger_id":{"type":"string","format":"uuid","title":"Trigger Id"},"fired_event_id":{"type":"string","format":"uuid","title":"Fired Event Id"},"source":{"type":"string","enum":["cron","manual","webhook","event"],"title":"Source","description":"Source that fired the trigger"},"input_override":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input Override","description":"Per-run input overrides"},"status":{"type":"string","enum":["queued","running","succeeded","failed","dead"],"title":"Status","description":"Run status"},"attempt_count":{"type":"integer","title":"Attempt Count","description":"Number of claim attempts"},"max_attempts":{"type":"integer","title":"Max Attempts","description":"Maximum claim attempts before dead-lettering"},"next_attempt_at":{"type":"string","format":"date-time","title":"Next Attempt At","description":"Next eligible claim time"},"claimed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Claimed By","description":"Dispatcher consumer that claimed the run"},"claimed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Claimed At","description":"When the run was claimed"},"lease_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lease Expires At","description":"When the running lease expires"},"result_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Result Text","description":"Text result emitted by the action"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Failure detail, if any"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the run was enqueued"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the run row last changed"}},"type":"object","required":["id","workspace_id","trigger_id","fired_event_id","source","status","attempt_count","max_attempts","next_attempt_at","created_at","updated_at"],"title":"TriggerRunResponse"}}}}
```

## The TriggerRunResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerRunResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"trigger_id":{"type":"string","format":"uuid","title":"Trigger Id"},"fired_event_id":{"type":"string","format":"uuid","title":"Fired Event Id"},"source":{"type":"string","enum":["cron","manual","webhook","event"],"title":"Source","description":"Source that fired the trigger"},"input_override":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input Override","description":"Per-run input overrides"},"status":{"type":"string","enum":["queued","running","succeeded","failed","dead"],"title":"Status","description":"Run status"},"attempt_count":{"type":"integer","title":"Attempt Count","description":"Number of claim attempts"},"max_attempts":{"type":"integer","title":"Max Attempts","description":"Maximum claim attempts before dead-lettering"},"next_attempt_at":{"type":"string","format":"date-time","title":"Next Attempt At","description":"Next eligible claim time"},"claimed_by":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Claimed By","description":"Dispatcher consumer that claimed the run"},"claimed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Claimed At","description":"When the run was claimed"},"lease_expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Lease Expires At","description":"When the running lease expires"},"result_text":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Result Text","description":"Text result emitted by the action"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Failure detail, if any"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the run was enqueued"},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the run row last changed"}},"type":"object","required":["id","workspace_id","trigger_id","fired_event_id","source","status","attempt_count","max_attempts","next_attempt_at","created_at","updated_at"],"title":"TriggerRunResponse"}}}}
```

## The TriggerThreshold object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerThreshold":{"properties":{"count":{"type":"integer","maximum":100,"minimum":1,"title":"Count"},"window_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Window Minutes"},"cooldown_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Cooldown Minutes","default":60}},"additionalProperties":false,"type":"object","required":["count","window_minutes"],"title":"TriggerThreshold","description":"How many matching events an event trigger waits for before it fires: ``count`` of them inside the last\n``window_minutes``. Once it fires, it holds off for ``cooldown_minutes`` however many more arrive."}}}}
```

## The TriggerableEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerableEvent":{"type":"string","enum":["amigo.trigger.cron","appointment.booked","appointment.cancelled","appointment.confirmed","booking.requested","call.ended","call.failure_signal","call.intelligence","call.outcome","channel.message.received","conversation.channel_switched","conversation.started","conversation.turn_recorded","coverage.created","entity.enriched","entity.resolved","medication.refill_requested","outbound.initiated","outbound.scheduled","patient.created","patient.updated","relationship.established","review.approve","review.correct","review.reject","surface.created","surface.submitted","ticket.created","triage.completed","trigger.completed","trigger.failed","trigger.fired"],"title":"TriggerableEvent","description":"Closed set of world events that trigger definitions may subscribe to.\n\nThe database column intentionally remains text for compatibility with old\nrows, but API writes must choose from this list so typoed event names do\nnot silently create never-matching triggers."}}}}
```

## The Turn object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Turn":{"properties":{"evidence":{"anyOf":[{"$ref":"#/components/schemas/TurnEvidence"},{"type":"null"}]},"id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"string"},{"type":"null"}],"title":"Id"},"engine_turn_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Engine Turn Id","description":"The engine turn whose trigger, state and timing this row carries: the turn its agent line\nanswers, or on a caller line nothing answered, the turn it opens. An agent line that names no\nturn (a filler, the emergency floor's script, a correction) takes the turn the call was in:\nthe caller turn whose words came last, or the turn of the last reply. Null on rows recorded\nbefore the id was stored, on calls no engine turn ran, and once the call's hot rows have\nexpired, about a day after it, when these rows are rebuilt from the saved transcript."},"trigger":{"type":"string","title":"Trigger","default":""},"user_transcript":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Transcript"},"agent_transcript":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Transcript"},"agent_action":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Action"},"interrupted":{"type":"boolean","title":"Interrupted","default":false},"incomplete":{"type":"boolean","title":"Incomplete","description":"The call ended while the caller was still saying ``user_transcript``, so nothing answered it.","default":false},"filler_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Type"},"speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Speaker Id"},"speaker_role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Speaker Role"},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eot Confidence"},"state":{"type":"string","title":"State","default":""},"tool_calls":{"items":{"$ref":"#/components/schemas/ToolCall"},"type":"array","title":"Tool Calls","default":[]},"state_transitions":{"items":{"$ref":"#/components/schemas/StateTransition"},"type":"array","title":"State Transitions","default":[]},"inner_thoughts":{"items":{"type":"string"},"type":"array","title":"Inner Thoughts","default":[]},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"user_speech_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"User Speech Start Ms"},"user_speech_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"User Speech End Ms"},"agent_speech_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Speech Start Ms"},"agent_speech_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Agent Speech End Ms"},"audio_window_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window Start Ms"},"audio_window_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window End Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Render Ms"},"audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Ttfb Ms"},"signal_kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signal Kind"},"signal_source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Signal Source"},"state_before":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State Before"},"state_after":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State After"},"primary_effect_kind":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Primary Effect Kind"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"tool_succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tool Succeeded"},"tool_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Tool Ms"},"modality":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Modality"},"empathy_tier":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Tier"},"decision_bearing":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Decision Bearing"},"packet_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Packet Id","description":"The signal-engine packet the turn answers. Null when none was cut for it."},"dynamic_behavior":{"anyOf":[{"$ref":"#/components/schemas/AppliedBehavior"},{"type":"null"}],"description":"The dynamic behavior the agent line was rendered with. Null when none was in force."},"dynamic_behavior_decision":{"anyOf":[{"$ref":"#/components/schemas/BehaviorDecision"},{"type":"null"}],"description":"What the caller turn's dynamic behavior decision did. Null when none ran."}},"type":"object","title":"Turn"},"TurnEvidence":{"properties":{"authored_kind":{"anyOf":[{"type":"string","enum":["disclosure","emergency","crisis","correction","safe_exit","authored"]},{"type":"null"}],"title":"Authored Kind"},"completed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Completed"},"verbatim":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Verbatim"},"safe_exit":{"anyOf":[{"$ref":"#/components/schemas/SafeExitEvidence"},{"type":"null"}]}},"type":"object","title":"TurnEvidence","description":"Playback provenance supplied by the runtime, never guessed from transcript words."},"SafeExitEvidence":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger"},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome"},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"Whether the disclosure completed before or during the exit."},"transfer_attempted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Transfer Attempted"}},"type":"object","required":["trigger","outcome","disclosure_heard"],"title":"SafeExitEvidence"},"ToolCall":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"input":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input"},"output":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output"},"output_truncated":{"type":"boolean","title":"Output Truncated","default":false},"output_original_length":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Output Original Length"},"output_truncated_to":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Output Truncated To"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"succeeded":{"type":"boolean","title":"Succeeded","default":true},"executed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Executed"},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"}},"type":"object","required":["tool_name"],"title":"ToolCall"},"StateTransition":{"properties":{"type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Type"},"previous_state":{"type":"string","title":"Previous State","default":""},"next_state":{"type":"string","title":"Next State","default":""},"annotation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Annotation"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"from_state":{"type":"string","title":"From State","readOnly":true},"to_state":{"type":"string","title":"To State","readOnly":true}},"type":"object","required":["from_state","to_state"],"title":"StateTransition"},"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"BehaviorDecision":{"description":"What one caller turn's dynamic behavior decision did.\n\n``outcome``: ``applied`` put the chosen behavior in force; ``kept`` left the active one in force because\nthe model chose it again or said it stays; ``held`` left the active one in force because it was still\ninside its ``sticky_turns`` and the model chose none, chose another behavior under the confidence floor,\nor gave no usable answer (a different behavior chosen at or over the floor replaces it as ``applied``,\ninside its ``sticky_turns`` too); ``none``, ``below_floor`` and ``failed`` left nothing in force (no\nbehavior applies, a choice under the confidence floor, no usable answer); ``skipped`` ran no decision\n(``reason`` says why) and ended the active behavior; ``superseded`` was cancelled by the caller's next\nturn before it landed.","properties":{"outcome":{"$ref":"#/components/schemas/DynamicBehaviorOutcome"},"reason":{"anyOf":[{"$ref":"#/components/schemas/FailureReason"},{"$ref":"#/components/schemas/DynamicBehaviorSkip"},{"type":"null"}],"default":null,"description":"Why a decision failed or was skipped, or why a held behavior was held.","title":"Reason"},"behavior_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior in force after the decision.","title":"Behavior Id"},"behavior_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior in force. Null where none is, and before behaviors were versioned.","title":"Behavior Version"},"chosen_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior the model chose. Null when it chose none or gave no usable answer.","title":"Chosen Id"},"chosen_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior the model chose. Null where it chose none, and before behaviors were versioned.","title":"Chosen Version"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The choice's confidence. Null where the decision got no usable answer.","title":"Confidence"},"kept_by_predicate":{"default":false,"description":"Whether the active behavior stayed because the model said it stays, rather than by its choice.","title":"Kept By Predicate","type":"boolean"},"keep_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The confidence of the answer to whether the active behavior stays, when that was asked.","title":"Keep Confidence"},"candidate_count":{"default":0,"description":"How many behaviors the decision chose between, ``none`` aside.","title":"Candidate Count","type":"integer"},"latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Latency Ms"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"description":"The context graph version the conversation ran when the decision was made. Null on a direct program's\ndecision, which ran no context graph: ``program_digest`` names what it ran.","title":"Context Graph Version"},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"The direct program the conversation ran when the decision was made, by the digest its run records\n(``RunManifest.program_digest``). Null on a context graph's decision."},"selector_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"What a direct program's decision rendered its request from. Null on a context graph's decision, whose run\nrecords it (``RunManifest.dynamic_behavior_prompt_template_hash``)."},"cited_message_indexes":{"default":[],"description":"The messages the decision read the turn from: the agent's line before the turn, then the caller's.","items":{"type":"integer"},"title":"Cited Message Indexes","type":"array"}},"required":["outcome"],"title":"BehaviorDecision","type":"object"},"DynamicBehaviorOutcome":{"enum":["applied","kept","held","none","below_floor","failed","skipped","superseded"],"type":"string"},"FailureReason":{"enum":["refusal","out_of_set","malformed","http_4xx","http_retryable","connection","timeout","breaker_open","options_exceeded"],"type":"string"},"DynamicBehaviorSkip":{"enum":["emergency_floor","person_request","empathy_hold","suspended","no_candidates"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The TurnConversationSnapshot object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnConversationSnapshot":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"status":{"type":"string","enum":["active","closed","completed","in-progress","failed","paused"],"title":"Status"},"turn_count":{"type":"integer","title":"Turn Count","default":0},"updated_at":{"type":"string","title":"Updated At"},"context_graph_state":{"anyOf":[{"$ref":"#/components/schemas/ContextGraphState-Output"},{"type":"null"}]}},"type":"object","required":["id","status","updated_at"],"title":"TurnConversationSnapshot"},"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."}}}}
```

## The TurnDelivery object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnDelivery":{"properties":{"delivery_id":{"type":"string","format":"uuid","title":"Delivery Id","description":"Stable identifier for this background delivery."},"request_id":{"type":"string","format":"uuid","title":"Request Id","description":"Stable poll request identifier bound to this claim."},"receipt":{"type":"string","format":"uuid","title":"Receipt","description":"Opaque receipt required to acknowledge this delivery."}},"type":"object","required":["delivery_id","request_id","receipt"],"title":"TurnDelivery"}}}}
```

## The TurnDeliveryAckRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnDeliveryAckRequest":{"properties":{"request_id":{"type":"string","format":"uuid","title":"Request Id"},"receipt":{"type":"string","format":"uuid","title":"Receipt"},"source":{"anyOf":[{"type":"string","const":"playground"},{"type":"null"}],"title":"Source","description":"Set to ``playground`` when the developer console Playground acknowledges the delivery. Refused with 403 on a real conversation, one no Playground session or test credential started."}},"additionalProperties":false,"type":"object","required":["request_id","receipt"],"title":"TurnDeliveryAckRequest"}}}}
```

## The TurnEvidence object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnEvidence":{"properties":{"authored_kind":{"anyOf":[{"type":"string","enum":["disclosure","emergency","crisis","correction","safe_exit","authored"]},{"type":"null"}],"title":"Authored Kind"},"completed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Completed"},"verbatim":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Verbatim"},"safe_exit":{"anyOf":[{"$ref":"#/components/schemas/SafeExitEvidence"},{"type":"null"}]}},"type":"object","title":"TurnEvidence","description":"Playback provenance supplied by the runtime, never guessed from transcript words."},"SafeExitEvidence":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger"},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome"},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"Whether the disclosure completed before or during the exit."},"transfer_attempted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Transfer Attempted"}},"type":"object","required":["trigger","outcome","disclosure_heard"],"title":"SafeExitEvidence"}}}}
```

## The TurnPolicy object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."}}}}
```

## The TurnPolicyOverrides object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnPolicyOverrides":{"properties":{"greeting_shield_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Greeting Shield S"},"barge_in_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Barge In Enabled"},"block_forward_call":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Block Forward Call"},"context_strategy":{"anyOf":[{"type":"string","const":"compact"},{"type":"null"}],"title":"Context Strategy"},"degradation_threshold":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Degradation Threshold"},"block_forward_call_after_turns":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Block Forward Call After Turns"}},"type":"object","title":"TurnPolicyOverrides"}}}}
```

## The TurnRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnRequest":{"properties":{"message":{"type":"string","maxLength":10000,"title":"Message","description":"The user's message. Leave it empty (with no ``content`` or media) only to kick off a conversation that has no turns yet: the agent answers with its greeting. Once the conversation has a turn, a turn with no user input is a 422.","default":""},"content":{"anyOf":[{"items":{"$ref":"#/components/schemas/ContentPartPayload"},"type":"array","maxItems":20},{"type":"null"}],"title":"Content"},"media_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Media Url"},"media_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Media Type"},"context":{"anyOf":[{"type":"string","maxLength":100000},{"type":"null"}],"title":"Context","description":"Injected into the agent's prompt as caller/patient context for this turn."},"viewport_width":{"anyOf":[{"type":"integer","maximum":500,"minimum":20},{"type":"null"}],"title":"Viewport Width"},"viewport_height":{"anyOf":[{"type":"integer","maximum":500,"minimum":5},{"type":"null"}],"title":"Viewport Height"},"wait_for_final":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Wait For Final","description":"Synchronous callers only: when a turn hands work to a background tool (``background_pending``), await this turn's answer inline instead of returning the acknowledgement immediately. The turn and the wait share one budget of about 170 seconds, so give the request a client timeout of at least 180 seconds. The response carries the answers the turn's background work commits, in order, in place of the acknowledgement, so a tool that hands off to another returns both messages; ``background_pending=false`` means ``output`` is the turn's whole answer. Otherwise (time ran out, or an earlier turn's answer is still waiting to be collected) it returns what arrived, or the acknowledgement, with ``background_pending=true``; collect the rest with ``poll=true``, and poll before sending the next turn. Send an ``Idempotency-Key`` with every waiting turn: if your own timeout fires or the connection drops first, retry with the same key, and the retry returns the answers the turn already collected instead of running it again. ``null`` (default) inherits the channel policy (web = do not wait). Ignored with ``poll=true`` (422)."},"suppress_filler":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Suppress Filler","description":"Synchronous callers only: when a turn ends ``background_pending``, omit the filler/acknowledgement text from ``output`` so a batch caller never mistakes the ack for the answer (``output`` is empty; ``background_pending=true`` is the poll-later signal). Answers a ``wait_for_final`` wait collected still come back. ``null`` (default) inherits the channel policy. Ignored with ``poll=true`` (422)."},"source":{"anyOf":[{"type":"string","const":"playground"},{"type":"null"}],"title":"Source","description":"Set to ``playground`` on every turn the developer console Playground sends, polls included. A Playground turn on a real conversation, one no Playground session or test credential started, is refused with 403."}},"type":"object","title":"TurnRequest"},"ContentPartPayload":{"properties":{"type":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9._-]*$","title":"Type","default":"text"},"text":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}],"title":"Text"},"url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Url"},"media_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Media Type"},"provider_id":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider Id"},"metadata":{"additionalProperties":true,"type":"object","maxProperties":50,"title":"Metadata"}},"type":"object","title":"ContentPartPayload","description":"HTTP/WebSocket shape for a modality-neutral conversation content part."}}}}
```

## The TurnResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnResponse":{"properties":{"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"Identifier of the user exchange this turn created — or, for ``poll=true`` and greeting-kickoff turns (empty ``message``), the exchange the returned messages attach to. A background delivery keeps the originating exchange even when later user turns already exist. Deterministic: matches the ``turn_id`` on this conversation's history turns, so it can anchor durable per-turn artifacts (e.g. feedback) across page reloads. Null only when the conversation has no user exchange yet (a poll or kickoff before the first user message)."},"input":{"$ref":"#/components/schemas/ConversationTurn"},"output":{"items":{"$ref":"#/components/schemas/ConversationTurn"},"type":"array","title":"Output"},"tool_calls":{"items":{"$ref":"#/components/schemas/ConversationToolCallDetail"},"type":"array","title":"Tool Calls","default":[]},"artifacts":{"items":{"$ref":"#/components/schemas/ClientArtifact"},"type":"array","title":"Artifacts","default":[]},"conversation":{"$ref":"#/components/schemas/TurnConversationSnapshot"},"background_pending":{"type":"boolean","title":"Background Pending","description":"Whether this turn's ``output`` is the final answer, or only an acknowledgement that\nwork is still running in the background.\n\n``false`` (default): ``output`` is the complete agent response for this turn.\n\n``true``: a tool crossed the server's blocking window and was handed to a background\ntask, so ``output`` is NOT the final answer — the definitive assistant answer is\nproduced later, out-of-band. Under delivery protocol v2, collect it by re-issuing\n``POST …/turns`` with ``poll=true`` (a no-message, receipt-backed claim), render or\ndurably persist the returned answer, then acknowledge its exact delivery receipt.\nThis is the per-conversation delivery contract — see\nthe web-integration paved path. (``GET /v1/{workspace_id}/events/stream?conversation_id=``\nmirrors this activity as ``text.tool_started`` / ``text.background_result`` /\n``text.agent_message`` for a view watching this one conversation, but is not the\nper-chat delivery path. The stream without ``conversation_id`` carries none of it.) A\nclient that treats a ``background_pending=true`` turn as complete without polling and\nacknowledging will miss the final answer.","default":false},"delivery":{"anyOf":[{"$ref":"#/components/schemas/TurnDelivery"},{"type":"null"}],"description":"Receipt for a background result returned by ``poll=true``. Render the response successfully, then acknowledge this delivery. Null for ordinary turns and idle/pending polls."},"delivery_protocol_version":{"anyOf":[{"type":"integer","const":2},{"type":"null"}],"title":"Delivery Protocol Version","description":"Version of the durable background-delivery protocol supported by the serving agent. Clients may retry polls only after observing version 2."}},"type":"object","required":["turn_id","input","output","conversation"],"title":"TurnResponse"},"ConversationTurn":{"properties":{"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"Stable identifier of the user exchange this message belongs to, derived deterministically from (conversation_id, turn_index) — identical across ``POST /turns`` responses and re-reads of the conversation history. User and agent messages from the same exchange share this value. Null on messages that precede the first user turn (proactive greetings, channel-event preludes)."},"turn_index":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Turn Index","description":"Zero-based ordinal of the user exchange this message belongs to (0 = first user turn). Derived server-side from the conversation's user-turn count — never stored. Null exactly when ``turn_id`` is null."},"engine_turn_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Engine Turn Id","description":"The agent engine's id for the turn this message opens (a user message) or answers (an agent message). One exchange can hold several engine turns, such as a tool call and the reply to its result. Null when no engine turn is recorded on the message: a filler line, a text reply, a channel event, or an older conversation that didn't record it."},"role":{"type":"string","enum":["agent","user","system"],"title":"Role"},"text":{"type":"string","title":"Text"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timestamp"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State","description":"The context-graph state of the conversation at this message: for a user message, the state it arrived in; for an agent message, the state after the turn's transitions. Null when the record names no state."},"speech_start_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speech Start Ms","description":"Where this message's speech starts in the call's recording, in milliseconds from the start of the recording. A user message starts when the caller began speaking; an agent message when its first audio was sent, slightly before the caller heard it. Null when no position was recorded: text messages, agent lines that never played, and older calls that didn't record one."},"speech_end_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speech End Ms","description":"Where this message's speech ends in the call's recording, in milliseconds from the start of the recording: when the caller stopped speaking, or when the agent line's last audio was sent. Null when no position was recorded, such as on a caller's line the call ended during."},"filler_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Type","description":"On an agent line the agent spoke while working on the reply, the kind of filler it was, such as ``receipt``, ``empathy`` or ``working``. Null on a reply and on user and system messages."},"interrupted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Interrupted","description":"On an agent line in a call, whether the caller cut it off, before or while it played. Null on user, system and text messages, and where the record doesn't say."},"channel":{"anyOf":[{"$ref":"#/components/schemas/ChannelKind"},{"type":"null"}],"description":"Channel this turn occurred on. A conversation that switched channels has a self-describing per-turn history; null on turns written before per-turn attribution or on channel-less internal turns."},"content":{"items":{"$ref":"#/components/schemas/ContentPartPayload"},"type":"array","title":"Content","default":[]},"tool_calls":{"items":{"$ref":"#/components/schemas/ConversationToolCallDetail"},"type":"array","title":"Tool Calls","description":"Tool calls executed during this (agent) turn. Populated only when the request opts in via ``include_tool_calls=true``; empty otherwise and on turns that did not invoke tools.","default":[]},"artifacts":{"items":{"$ref":"#/components/schemas/ClientArtifact"},"type":"array","title":"Artifacts","description":"Validated client-safe outputs produced during this agent turn.","default":[]},"selected_action_description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Selected Action Description","description":"Description of the context-graph action selected for this turn. Null means no action was selected or no selected action was recorded."},"state_transition":{"anyOf":[{"$ref":"#/components/schemas/ConversationTurnStateTransition"},{"type":"null"}],"description":"Context-graph state transition that occurred during this turn. Null means no transition took place or no transition was recorded. Deprecated: use state_transitions instead. If multiple transitions were recorded, this field reports the first source state and final destination state, with no exit condition.","deprecated":true},"state_transitions":{"items":{"$ref":"#/components/schemas/ConversationTurnStateTransition"},"type":"array","title":"State Transitions","description":"Ordered context-graph state transitions that occurred during this turn.","default":[]},"available_actions":{"items":{"$ref":"#/components/schemas/ConversationTurnAvailableAction"},"type":"array","title":"Available Actions","description":"Action choices available in the turn's resolved context-graph state. Empty when actions cannot be resolved or the resolved state is not an action state.","default":[]},"dynamic_behavior":{"anyOf":[{"$ref":"#/components/schemas/AppliedBehavior"},{"type":"null"}],"description":"On an agent message, the dynamic behavior its reply was rendered with. Null when none was in force, and on user and system messages."}},"type":"object","required":["role","text"],"title":"ConversationTurn"},"ChannelKind":{"type":"string","enum":["voice","sms","whatsapp","email","web","imessage"],"title":"ChannelKind","description":"HSM execution channel type.\n\nDetermines how the HSM engine communicates with end users.\nEach kind maps to one or more providers."},"ContentPartPayload":{"properties":{"type":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9._-]*$","title":"Type","default":"text"},"text":{"anyOf":[{"type":"string","maxLength":10000},{"type":"null"}],"title":"Text"},"url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Url"},"media_type":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Media Type"},"provider_id":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Provider Id"},"metadata":{"additionalProperties":true,"type":"object","maxProperties":50,"title":"Metadata"}},"type":"object","title":"ContentPartPayload","description":"HTTP/WebSocket shape for a modality-neutral conversation content part."},"ConversationToolCallDetail":{"properties":{"tool_name":{"type":"string","title":"Tool Name"},"call_id":{"type":"string","title":"Call Id"},"input":{"additionalProperties":true,"type":"object","title":"Input"},"result":{"type":"string","title":"Result","default":""},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded","description":"Whether the tool call succeeded. Null when no result was recorded, for example while it still runs.","default":true},"duration_ms":{"anyOf":[{"type":"number","maximum":3600000,"minimum":0},{"type":"null"}],"title":"Duration Ms","description":"Wall-clock tool execution time in milliseconds, measured at the engage_step call site. Omitted (null) on legacy turns that did not capture timing."},"error_message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error Message","description":"Failure detail recorded for the tool call when ``succeeded`` is false. Null on successful calls or when no message was captured."}},"type":"object","required":["tool_name","call_id"],"title":"ConversationToolCallDetail"},"ClientArtifact":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"payload":{"$ref":"#/components/schemas/ClientArtifactPayload"}},"type":"object","required":["type","schema_version","payload"],"title":"ClientArtifact","description":"A versioned JSON payload that a client can render as a product component."},"ClientArtifactPayload":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"}]},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]},"ConversationTurnStateTransition":{"properties":{"from":{"type":"string","title":"From","description":"Source context-graph state before the turn's state transition."},"to":{"type":"string","title":"To","description":"Destination context-graph state after the turn's state transition."},"exit_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exit Condition","description":"The exit condition the agent took out of ``from``, as the context graph worded it when the hop was taken. Null on a hop out of an annotation state, which has no exit conditions, and on a hop recorded without one. Never read from the current graph."}},"type":"object","required":["from","to"],"title":"ConversationTurnStateTransition"},"ConversationTurnAvailableAction":{"properties":{"description":{"type":"string","title":"Description","description":"Human-readable description of an action available in the turn's state."}},"type":"object","required":["description"],"title":"ConversationTurnAvailableAction"},"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"TurnConversationSnapshot":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"status":{"type":"string","enum":["active","closed","completed","in-progress","failed","paused"],"title":"Status"},"turn_count":{"type":"integer","title":"Turn Count","default":0},"updated_at":{"type":"string","title":"Updated At"},"context_graph_state":{"anyOf":[{"$ref":"#/components/schemas/ContextGraphState-Output"},{"type":"null"}]}},"type":"object","required":["id","status","updated_at"],"title":"TurnConversationSnapshot"},"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"TurnDelivery":{"properties":{"delivery_id":{"type":"string","format":"uuid","title":"Delivery Id","description":"Stable identifier for this background delivery."},"request_id":{"type":"string","format":"uuid","title":"Request Id","description":"Stable poll request identifier bound to this claim."},"receipt":{"type":"string","format":"uuid","title":"Receipt","description":"Opaque receipt required to acknowledge this delivery."}},"type":"object","required":["delivery_id","request_id","receipt"],"title":"TurnDelivery"}}}}
```

## The TurnTimeline object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnTimeline":{"properties":{"turn_index":{"type":"integer","title":"Turn Index","description":"The turn: its index in the response's ``turns`` on ``GET /conversations/{conversation_id}``,\nthe call-detail row the timeline was built from on ``GET /calls/{call_id}``."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on a turn\nbefore the first exchange."},"seek_to":{"type":"number","title":"Seek To"},"active_start":{"type":"number","title":"Active Start"},"active_end":{"type":"number","title":"Active End"}},"type":"object","required":["turn_index","seek_to","active_start","active_end"],"title":"TurnTimeline"}}}}
```

## The Unavailable object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Unavailable":{"type":"string","enum":["agent_not_in_workspace","version_not_found","config_unreadable","config_incompatible","channel_manager_unavailable"]}}}}
```

## The UnbackedActionClaimsCheck object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"}}}}
```

## The UpdateAgentRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateAgentRequest":{"properties":{"name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]}},"type":"object","title":"UpdateAgentRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The UpdateContextGraphRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateContextGraphRequest":{"properties":{"name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]}},"type":"object","title":"UpdateContextGraphRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The UpdateDashboardRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateDashboardRequest":{"properties":{"slug":{"anyOf":[{"type":"string","maxLength":128,"minLength":2,"pattern":"^[a-z0-9][a-z0-9\\-]*$"},{"type":"null"}],"title":"Slug"},"title":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"page_context":{"anyOf":[{"type":"string","enum":["home","patients","calls","data","analytics","pipeline","operators","surfaces","compliance","custom"]},{"type":"null"}],"title":"Page Context"},"panels":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array","maxItems":50},{"type":"null"}],"title":"Panels"},"filters":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array","maxItems":20},{"type":"null"}],"title":"Filters"},"refresh_interval":{"anyOf":[{"type":"integer","maximum":86400,"minimum":10},{"type":"null"}],"title":"Refresh Interval"}},"type":"object","title":"UpdateDashboardRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The UpdateDataResidencyRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateDataResidencyRequest":{"properties":{"data_residency":{"$ref":"#/components/schemas/DataResidency"}},"type":"object","required":["data_residency"],"title":"UpdateDataResidencyRequest"},"DataResidency":{"type":"string","enum":["any","regional"]}}}}
```

## The UpdateDataSourceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateDataSourceRequest":{"properties":{"display_name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"connection_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Connection Config"},"entity_types":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Entity Types"},"field_mappings":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Field Mappings"},"sync_strategy":{"anyOf":[{"type":"string","enum":["manual","scheduled","webhook","continuous"]},{"type":"null"}],"title":"Sync Strategy"},"sync_schedule":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Sync Schedule"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"UpdateDataSourceRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The UpdateDynamicBehaviorSetRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateDynamicBehaviorSetRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":120,"minLength":1},{"type":"null"}],"title":"Name","description":"What authors call it. The selector reads the name, so a rename changes what it sees for every service that\npins the set, without a new version."},"tags":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":10},{"type":"null"}],"title":"Tags"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"True archives the set, which a version set that pins it refuses. False brings it back."}},"additionalProperties":false,"type":"object","title":"UpdateDynamicBehaviorSetRequest","description":"What can change on a set without a new version. A field left out stays as it is."}}}}
```

## The UpdateOperatorRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateOperatorRequest":{"properties":{"name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"email":{"anyOf":[{"type":"string","format":"email"},{"type":"null"}],"title":"Email","description":"The email the operator was registered with, in any letter case. It is fixed once registered, so any other email is a 422."},"type":{"anyOf":[{"type":"string","enum":["clinical","administrative","crisis_counselor"]},{"type":"null"}],"title":"Type"},"skills":{"anyOf":[{"items":{"type":"string","maxLength":64,"minLength":1},"type":"array","maxItems":50},{"type":"null"}],"title":"Skills"},"connection_method":{"anyOf":[{"type":"string","enum":["browser","phone"]},{"type":"null"}],"title":"Connection Method"},"phone_number":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}],"description":"E.164 phone number. An omitted or null number is left unchanged, so a number cannot be cleared."},"role":{"anyOf":[{"type":"string","enum":["operator","supervisor","admin"]},{"type":"null"}],"title":"Role"},"status":{"anyOf":[{"type":"string","enum":["online","busy","offline"]},{"type":"null"}],"title":"Status"}},"type":"object","title":"UpdateOperatorRequest","description":"Fields to change on an operator. A field that is omitted or null is left unchanged."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DialE164":{"type":"string","maxLength":16,"minLength":2}}}}
```

## The UpdateProductionEvalDefinitionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateProductionEvalDefinitionRequest":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"eval_key":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Eval Key"},"eval_type":{"anyOf":[{"type":"string","enum":["assertion","metric"]},{"type":"null"}],"title":"Eval Type"},"assertion_kind":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Assertion Kind"},"metric_key":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Metric Key"},"expected":{"title":"Expected"},"params":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Params"},"active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Active"}},"type":"object","title":"UpdateProductionEvalDefinitionRequest"}}}}
```

## The UpdateSchedulingRuleSetRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateSchedulingRuleSetRequest":{"properties":{"params":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/ClinicOpenHoursParams"},{"$ref":"#/components/schemas/TMSMappingReleaseParams"},{"$ref":"#/components/schemas/TMSSessionGridParams"},{"$ref":"#/components/schemas/KetamineBlockOverlapParams"},{"$ref":"#/components/schemas/NinetyDayRollingParams"},{"$ref":"#/components/schemas/ConcurrentStartBlockParams"}],"discriminator":{"propertyName":"rule_kind","mapping":{"clinic_open_hours":"#/components/schemas/ClinicOpenHoursParams","concurrent_start_block":"#/components/schemas/ConcurrentStartBlockParams","ketamine_block_overlap":"#/components/schemas/KetamineBlockOverlapParams","ninety_day_rolling":"#/components/schemas/NinetyDayRollingParams","tms_mapping_release":"#/components/schemas/TMSMappingReleaseParams","tms_session_grid":"#/components/schemas/TMSSessionGridParams"}}},{"type":"null"}],"title":"Params"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"}},"type":"object","title":"UpdateSchedulingRuleSetRequest","description":"Partial update — fields not provided are unchanged. ``params``\nmust be the full per-kind shape (no patch within params); send the\nwhole RuleParams or omit."},"ClinicOpenHoursParams":{"properties":{"rule_kind":{"type":"string","const":"clinic_open_hours","title":"Rule Kind","default":"clinic_open_hours"},"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"monday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"tuesday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"wednesday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"thursday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"friday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"saturday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]},"sunday":{"anyOf":[{"$ref":"#/components/schemas/_DayHours"},{"type":"null"}]}},"type":"object","required":["timezone"],"title":"ClinicOpenHoursParams","description":"Workspace clinic open-hours by weekday.\n\nDays not present mean \"closed.\" Used by the rules engine to skip\nslots outside open hours and (combined with ``weekend_skip``) by the\nTMS-mapping release calculator."},"_DayHours":{"properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$","title":"Start"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$","title":"End"}},"type":"object","required":["start","end"],"title":"_DayHours","description":"Open-hours window for one weekday. Times in 24h ``HH:MM`` form,\ninterpreted in the rule set's ``timezone``."},"TMSMappingReleaseParams":{"properties":{"rule_kind":{"type":"string","const":"tms_mapping_release","title":"Rule Kind","default":"tms_mapping_release"},"reservation_window_hours":{"type":"integer","maximum":720,"minimum":0,"title":"Reservation Window Hours"},"weekend_skip":{"type":"boolean","title":"Weekend Skip","default":true}},"type":"object","required":["reservation_window_hours"],"title":"TMSMappingReleaseParams","description":"How long before a TMS mapping appointment its slot is released\nback to the pool. ``weekend_skip=True`` adds Saturday + Sunday days\nto the wall-clock countdown (clinic doesn't release on weekends)."},"TMSSessionGridParams":{"properties":{"rule_kind":{"type":"string","const":"tms_session_grid","title":"Rule Kind","default":"tms_session_grid"},"interval_minutes":{"type":"integer","maximum":120,"minimum":5,"title":"Interval Minutes"},"boundary_minutes":{"items":{"type":"integer"},"type":"array","maxItems":60,"minItems":1,"title":"Boundary Minutes"}},"type":"object","required":["interval_minutes","boundary_minutes"],"title":"TMSSessionGridParams","description":"TMS sessions only start at fixed minute-of-hour boundaries\n(e.g. ``:00`` and ``:30``) so the technician can run them\nback-to-back without gaps."},"KetamineBlockOverlapParams":{"properties":{"rule_kind":{"type":"string","const":"ketamine_block_overlap","title":"Rule Kind","default":"ketamine_block_overlap"},"window_days":{"type":"integer","maximum":365,"minimum":1,"title":"Window Days"}},"type":"object","required":["window_days"],"title":"KetamineBlockOverlapParams","description":"How many days after a ketamine session to block follow-up\nappointments (clinical safety window)."},"NinetyDayRollingParams":{"properties":{"rule_kind":{"type":"string","const":"ninety_day_rolling","title":"Rule Kind","default":"ninety_day_rolling"},"days":{"type":"integer","maximum":365,"minimum":1,"title":"Days"}},"type":"object","required":["days"],"title":"NinetyDayRollingParams","description":"Rolling-window cap on appointments per patient (e.g. 90 days\nbetween TMS sessions)."},"ConcurrentStartBlockParams":{"properties":{"rule_kind":{"type":"string","const":"concurrent_start_block","title":"Rule Kind","default":"concurrent_start_block"}},"type":"object","title":"ConcurrentStartBlockParams","description":"Disallow two slots starting at the same time within a TMS scope.\nNo additional params — the discriminator is the whole config."}}}}
```

## The UpdateServiceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateServiceRequest":{"properties":{"name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"agent_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Agent Id"},"context_graph_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Context Graph Id","description":"Binds the service to this context graph, one of this workspace's. Leaving it out, or sending null, keeps what\nis stored. Setting it on a service that binds none is how the service comes to run workflow agent versions."},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":500},{"type":"null"}],"title":"Keyterms"},"is_active":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Active"},"version_sets":{"additionalProperties":{"$ref":"#/components/schemas/VersionSet-Input"},"type":"object","title":"Version Sets","description":"Replaces the whole map: a version set left out of it is dropped, and `release` is required. Leaving the field\nout keeps what is stored. It cannot be cleared, so `null` is refused."},"tags":{"anyOf":[{"items":{"$ref":"#/components/schemas/ServiceTag"},"type":"array","maxItems":50},{"type":"null"}],"title":"Tags"},"tool_capacity":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Tool Capacity"},"channel_type":{"anyOf":[{"type":"string","enum":["voice","text"]},{"type":"null"}],"title":"Channel Type"},"environment":{"anyOf":[{"type":"string","enum":["sandbox","production"]},{"type":"null"}],"title":"Environment"},"demo_mode":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Demo Mode","description":"Voice calls on this service open with only the recording notice, without the AI disclosure. For demos only,\nnever for a service that takes real callers."},"platform_caller_verification":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Platform Caller Verification","description":"Whether the platform verifies a caller who may match a patient record by full name and date of\nbirth. Off, the agent never asks a caller to verify, and every platform tool that reads a patient\nrecord refuses. The service's integration tools run either way, unless one of them verifies its\ncallers (`caller_verification_endpoint_id`)."},"caller_verification_endpoint_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Caller Verification Endpoint Id","description":"The integration endpoint that verifies this service's callers, on a service with\n`platform_caller_verification` and `allow_unverified_integration_results` false: one of this\nworkspace's that declares `declarations.verifies` and never waits for approval under its\nintegration's `approval_policy`. `null` clears it, and leaving it out keeps what's stored. Takes effect\non the next call or turn."},"allow_unverified_integration_results":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allow Unverified Integration Results","description":"A dangerous bypass, off by default. On, results from the service's integration endpoints, reads and\nwrites, never count as a patient record for the output checker's unverified-caller check\n(`output_checks.phi_unverified`, which runs only on a service that sets it to `cut`), so the agent may read\nthem back to any caller, verified or not. Writes are still held to everything else, the platform's own\npatient reads still refuse until the caller verifies, and data queries and skills still count. Never on\nbeside `caller_verification_endpoint_id`. Every change is audited."},"voice_config":{"anyOf":[{"$ref":"#/components/schemas/ServiceVoiceConfig-Input"},{"type":"null"}],"description":"Replaces the voice block. `null` clears it, and leaving it out keeps what's stored."},"accepted_context":{"anyOf":[{"items":{"$ref":"#/components/schemas/ContextKeySpec"},"type":"array","maxItems":100},{"type":"null"}],"title":"Accepted Context"},"crisis_call_911_reply":{"anyOf":[{"$ref":"#/components/schemas/CrisisCall911Reply"},{"type":"null"}],"description":"Reply for an already-in-crisis caller asking us to call 911. Omit to keep; null clears it."},"contact_lines":{"anyOf":[{"items":{"$ref":"#/components/schemas/ContactLineInput"},"type":"array","maxItems":50},{"type":"null"}],"title":"Contact Lines","description":"Replace declared contact lines. Omit to keep them; an empty list clears them."},"medical_emergency_ending":{"anyOf":[{"type":"string","enum":["stay_on_line","end_after_script"]},{"type":"null"}],"title":"Medical Emergency Ending","description":"How a voice call ends after a medical emergency's script: ``stay_on_line`` (the default) or\n``end_after_script``, which plays the authored closing line and then ends the call. A self-harm or\ncrisis statement keeps the call open in either."},"output_checks":{"anyOf":[{"$ref":"#/components/schemas/ServiceOutputChecksRequest"},{"type":"null"}],"title":"Output Checks","description":"Which reply checks run. The block replaces what is stored: a key it names overrides the workspace default and a\nkey it leaves out inherits it. `null` clears the block, so every key inherits. Leaving it out keeps what's stored.\nTakes effect for a call set up after the update."},"emergency_floor":{"anyOf":[{"$ref":"#/components/schemas/ServiceEmergencyFloorRequest"},{"type":"null"}],"title":"Emergency Floor","description":"How the floor acts on the service's text conversations, voice notes and simulations. The block replaces what is\nstored, as `output_checks` does: `null` clears it and leaving it out keeps it. Takes effect for the next message."},"conversation_audit":{"anyOf":[{"$ref":"#/components/schemas/ConversationAuditSettings"},{"type":"null"}],"description":"Replace the audit settings. Omit to keep them; send `enabled: false` to turn the audit off."},"declared_languages":{"anyOf":[{"items":{"type":"string","enum":["en","es","ar","fr","de","pt","zh","ja","ko"]},"type":"array","maxItems":9,"minItems":1},{"type":"null"}],"title":"Declared Languages","description":"Replace the languages this service serves. `null` clears them, and leaving it out keeps them."}},"type":"object","title":"UpdateServiceRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"VersionSet-Input":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"ServiceTag":{"properties":{"key":{"type":"string","title":"Key"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value"}},"type":"object","required":["key"],"title":"ServiceTag"},"ServiceVoiceConfig-Input":{"properties":{"silence_policy":{"$ref":"#/components/schemas/SilencePolicy"},"max_buffer_delay_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Buffer Delay Ms"},"eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eager Eot Threshold"},"eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Eot Timeout Ms"},"filler_style":{"type":"string","enum":["backchannel","phrase","silent"],"title":"Filler Style","default":"backchannel"},"filler_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Filler Vocabulary"},"backchannel_delay_ms":{"type":"integer","title":"Backchannel Delay Ms","default":400},"max_response_sentences":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Sentences"},"max_response_words":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Response Words"},"barge_in_min_speech_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Min Speech S"},"barge_in_cooldown_s":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Barge In Cooldown S"},"held_turn_policy":{"type":"string","enum":["always","judged","never"],"title":"Held Turn Policy","description":"What a realtime voice call does with a caller turn committed while the agent's own opening, the notice and the greeting, is still playing. always: the turn is answered once the opening ends. judged: the turn is answered only when it asks for something the opening did not cover, so a greeting, an acknowledgement or an echo of the opening is left unanswered, and a turn that cannot be judged is answered. never: the turn is not answered, and the caller's next turn is answered as usual. Every turn is still recorded and checked for a medical emergency, whatever the setting. It applies to a call the agent opens itself; a call that waits for the caller to speak first answers the first turn.","default":"always"},"min_tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Min Tts Speed"},"post_eot_pause_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Post Eot Pause Ms"},"transition_deadline_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Transition Deadline Ms"},"progress_interval_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Progress Interval Ms"},"empathy_hold_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Empathy Hold Ms"},"filler_cooldown_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Filler Cooldown Ms"},"progress_vocabulary":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Progress Vocabulary"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"},"realtime_voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"type":"null"}],"title":"Realtime Voice","description":"Deprecated built-in OpenAI Realtime voice shortcut. Use realtime.voice instead; the two fields are mutually exclusive.","deprecated":true},"realtime":{"anyOf":[{"$ref":"#/components/schemas/RealtimeSessionConfig"},{"type":"null"}]},"eleven_realtime":{"anyOf":[{"$ref":"#/components/schemas/ElevenRealtimeSessionConfig"},{"type":"null"}]},"grok_voice":{"anyOf":[{"$ref":"#/components/schemas/GrokVoiceSessionConfig"},{"type":"null"}]},"gpt_live":{"anyOf":[{"$ref":"#/components/schemas/GptLiveSessionConfig"},{"type":"null"}]},"phonic":{"anyOf":[{"$ref":"#/components/schemas/PhonicSessionConfig"},{"type":"null"}]},"readiness_requires":{"anyOf":[{"items":{"type":"string","enum":["openai_realtime","decisions","warehouse"]},"type":"array","maxItems":10},{"type":"null"}],"title":"Readiness Requires"},"max_concurrent_calls":{"type":"integer","maximum":100,"minimum":1,"title":"Max Concurrent Calls","default":60},"max_calls_per_caller":{"type":"integer","maximum":100,"minimum":1,"title":"Max Calls Per Caller","default":2},"answer_hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"forwarding":{"anyOf":[{"$ref":"#/components/schemas/ServiceForwardingConfig-Input"},{"type":"null"}]}},"type":"object","title":"ServiceVoiceConfig","description":"Per-service voice pipeline tuning. Overrides workspace/env defaults.\n\nEach field is optional — None means inherit from the layer above\n(workspace VoiceSettings → env vars → hardcoded defaults).\n\nA field is read only by the families whose ``reads`` list it (``platform_lib.config.voice_families.specs``); a save\naccepts the others and reports them as ignored."},"SilencePolicy":{"properties":{"max_closing_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Closing Attempts","default":2},"max_cap_warning_attempts":{"type":"integer","maximum":5,"minimum":1,"title":"Max Cap Warning Attempts","default":2},"cap_warning_retry_seconds":{"type":"number","maximum":60,"minimum":1,"title":"Cap Warning Retry Seconds","default":10}},"additionalProperties":false,"type":"object","title":"SilencePolicy","description":"Per-service delivery retries around the signed silence cadence."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."},"RealtimeSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","enum":["gpt-realtime-2.1","gpt-realtime-2.1-mini"]},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["alloy","ash","ballad","coral","echo","sage","shimmer","verse","marin","cedar"]},{"$ref":"#/components/schemas/RealtimeCustomVoice"},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.25},{"type":"null"}],"title":"Speed"},"noise_reduction":{"anyOf":[{"type":"string","enum":["near_field","far_field","off"]},{"type":"null"}],"title":"Noise Reduction","description":"Input noise reduction. Omit or set null to use the Platform default; set 'off' to disable it."},"noise_reduction_strength":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Noise Reduction Strength","description":"OpenAI audio.input.noise_reduction.strength. Higher values suppress more noise.","docs_url":"https://developers.openai.com/api/reference/resources/realtime/client-events"},"transcription":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTranscriptionConfig"},{"type":"null"}]},"turn_detection":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/RealtimeServerVadConfig"},{"$ref":"#/components/schemas/RealtimeSemanticVadConfig"}],"discriminator":{"propertyName":"type","mapping":{"semantic_vad":"#/components/schemas/RealtimeSemanticVadConfig","server_vad":"#/components/schemas/RealtimeServerVadConfig"}}},{"type":"null"}],"title":"Turn Detection"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"max_output_tokens":{"anyOf":[{"type":"integer","maximum":4096,"minimum":1},{"type":"string","const":"inf"},{"type":"null"}],"title":"Max Output Tokens"},"truncation":{"anyOf":[{"$ref":"#/components/schemas/RealtimeTruncationConfig"},{"type":"null"}]},"required_tool_on_first_caller_turn":{"anyOf":[{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_.:-]*$"},{"type":"null"}],"title":"Required Tool On First Caller Turn","description":"Force one named function on the first caller-generated response, excluding the inbound greeting, then restore automatic tool choice. Runtime accepts this only for source_override='test' sessions and tools that the executor verifies are read-only or side-effect-free."}},"additionalProperties":false,"type":"object","title":"RealtimeSessionConfig","description":"Typed OpenAI Realtime session controls for a service."},"RealtimeCustomVoice":{"properties":{"id":{"type":"string","maxLength":256,"minLength":1,"pattern":"^voice_[A-Za-z0-9_-]+$","title":"Id"}},"additionalProperties":false,"type":"object","required":["id"],"title":"RealtimeCustomVoice","description":"Approved OpenAI custom voice reference."},"RealtimeTranscriptionConfig":{"properties":{"model":{"type":"string","const":"gpt-transcribe","title":"Model","default":"gpt-transcribe"},"language":{"anyOf":[{"type":"string","enum":["af","ar","az","be","bg","bn","bs","ca","cs","cy","da","de","el","en","es","et","fa","fi","fr","gl","gu","he","hi","hr","hu","hy","id","is","it","iw","ja","ka","kk","kn","ko","lt","lv","mi","mk","ml","mr","ms","nb","ne","nl","no","pl","pt","ro","ru","sk","sl","sr","sv","sw","ta","te","th","tl","tr","uk","ur","vi","zh","afr","amh","ara","aze","bel","ben","bos","bul","cat","ces","cmn","cym","dan","deu","ell","eng","est","fas","fil","fin","fra","gle","glg","guj","heb","hin","hrv","hun","hye","ind","isl","ita","jpn","kan","kat","kaz","kor","lav","lit","mal","mar","mkd","mon","mri","msa","mya","nep","nld","nor","pol","por","ron","rus","slk","slv","som","spa","srp","swa","swe","tam","tel","tgl","tha","tur","ukr","urd","vie","yue","zh-cn","zh-hk","zh-tw"]},{"type":"null"}],"title":"Language"},"prompt":{"anyOf":[{"type":"string","maxLength":1024,"minLength":1},{"type":"null"}],"title":"Prompt"},"keywords":{"anyOf":[{"items":{"type":"string","maxLength":256,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keywords","description":"Literal transcription hints. Unset, use the service keyterms.","docs_url":"https://developers.openai.com/api/docs/guides/transcription"}},"additionalProperties":false,"type":"object","title":"RealtimeTranscriptionConfig","description":"Asynchronous caller-audio transcription used for transcripts and observability."},"RealtimeServerVadConfig":{"properties":{"type":{"type":"string","const":"server_vad","title":"Type","default":"server_vad"},"threshold":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Threshold"},"prefix_padding_ms":{"anyOf":[{"type":"integer","maximum":5000,"minimum":0},{"type":"null"}],"title":"Prefix Padding Ms"},"silence_duration_ms":{"anyOf":[{"type":"integer","maximum":3000,"minimum":200},{"type":"null"}],"title":"Silence Duration Ms"}},"additionalProperties":false,"type":"object","title":"RealtimeServerVadConfig","description":"Volume-based turn detection controls."},"RealtimeSemanticVadConfig":{"properties":{"type":{"type":"string","const":"semantic_vad","title":"Type","default":"semantic_vad"},"eagerness":{"type":"string","enum":["auto","low","medium","high"],"title":"Eagerness","default":"auto"}},"additionalProperties":false,"type":"object","title":"RealtimeSemanticVadConfig","description":"Semantic turn detection controls."},"RealtimeTruncationConfig":{"properties":{"type":{"type":"string","enum":["auto","disabled","retention_ratio"],"title":"Type","description":"Use auto or retention_ratio. Legacy disabled values are readable but refused by voice sessions.","default":"auto","docs_url":"https://developers.openai.com/api/docs/guides/voice-latency-cost?api=realtime#truncation"},"retention_ratio":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Retention Ratio"},"post_instructions_tokens":{"anyOf":[{"type":"integer","minimum":1},{"type":"null"}],"title":"Post Instructions Tokens"}},"additionalProperties":false,"type":"object","title":"RealtimeTruncationConfig","description":"Conversation context truncation strategy."},"ElevenRealtimeSessionConfig":{"properties":{"voice":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9_-]+$","title":"Voice"},"model":{"anyOf":[{"type":"string","const":"eleven_realtime_v1_mini"},{"type":"null"}],"title":"Model"}},"additionalProperties":false,"type":"object","required":["voice"],"title":"ElevenRealtimeSessionConfig","description":"Eleven Realtime controls for a service: the ElevenLabs voice it speaks in, and the model."},"GrokVoiceSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"grok-voice-3.0"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["altair","ara","atlas","aurora","carina","castor","celeste","cosmo","eve","helios","helix","iris","kepler","leo","liora","lumen","luna","lux","naksh","orion","perseus","rex","rigel","sal","sirius","ursa","zagan","zenith"]},{"type":"null"}],"title":"Voice"},"speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.7},{"type":"null"}],"title":"Speed"},"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","high"]},{"type":"null"}],"title":"Reasoning Effort"},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Keyterms","description":"Transcription hints. Unset, use the service keyterms. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"},"language_hint":{"anyOf":[{"type":"string","enum":["en","ar-EG","ar-SA","ar-AE","bn","zh","fr","de","hi","id","it","ja","ko","pt-BR","pt-PT","ru","es-MX","es-ES","tr","vi"]},{"type":"null"}],"title":"Language Hint"},"replace":{"anyOf":[{"additionalProperties":{"type":"string","maxLength":100,"minLength":1},"propertyNames":{"maxLength":100,"minLength":1},"type":"object","maxProperties":100,"minProperties":1},{"type":"null"}],"title":"Replace","description":"Pronunciation replacements: a phrase the agent says mapped to how xAI speaks it. Matched case-insensitively on whole words, longest key first. Keys and values are stripped, and keys that differ only by case are refused. xAI changes the audio and not its transcript; the runtime applies the same map to the transcript before the output checks read it, so they judge what the caller hears. https://docs.x.ai/developers/model-capabilities/audio/speech-to-speech"}},"additionalProperties":false,"type":"object","title":"GrokVoiceSessionConfig","description":"Grok Voice controls for a service. Every field is optional: the provider supplies the defaults."},"GptLiveSessionConfig":{"properties":{"model":{"type":"string","enum":["gpt-live-1","gpt-live-1.1-leopard-2-alpha"],"title":"Model","default":"gpt-live-1"},"voice":{"type":"string","enum":["alloy","ash","ballad","beacon","bossa","brise","cedar","cinder","coral","delta","echo","flitz","gleam","harema","juni","marin","meridian","nira","noeul","nuri","quartz","ripple","sage","shida","shimmer","sillage","stone","tempo","verse","vesper","willow"],"title":"Voice","default":"marin"}},"additionalProperties":false,"type":"object","title":"GptLiveSessionConfig","description":"Live startup settings. Language comes from the agent's instructions, not a protocol field."},"PhonicSessionConfig":{"properties":{"model":{"anyOf":[{"type":"string","const":"phonic-1"},{"type":"null"}],"title":"Model"},"voice":{"anyOf":[{"type":"string","enum":["sabrina","grant","sandeep","landon","shelby","mason","virginia","eleanor","gabrielle","paula","nolan","roberto","hikari","tomoya","eloise","jerome","daniela","juliana","valeria","eduardo","henri","kourtney","kaspar","mei","stella","karoline","amelia","william","joon","hana","mia","derek","divya","alice","karin","phillip","jackson","gina","michelle"]},{"type":"null"}],"title":"Voice"},"intelligence_level":{"anyOf":[{"type":"string","enum":["standard","high"]},{"type":"null"}],"title":"Intelligence Level"},"audio_speed":{"anyOf":[{"type":"number","maximum":1.5,"minimum":0.5},{"type":"null"}],"title":"Audio Speed"},"vad":{"anyOf":[{"$ref":"#/components/schemas/PhonicVadConfig"},{"type":"null"}]},"boosted_keywords":{"anyOf":[{"items":{"type":"string","maxLength":50,"minLength":1},"type":"array","maxItems":100},{"type":"null"}],"title":"Boosted Keywords","description":"Recognition hints. Unset, use the service keyterms."},"pronunciation_dictionary":{"anyOf":[{"items":{"$ref":"#/components/schemas/PhonicPronunciation"},"type":"array","maxItems":100},{"type":"null"}],"title":"Pronunciation Dictionary"},"multilingual_mode":{"anyOf":[{"type":"string","enum":["auto","request","initial"]},{"type":"null"}],"title":"Multilingual Mode"}},"additionalProperties":false,"type":"object","title":"PhonicSessionConfig","description":"Phonic controls for a service."},"PhonicVadConfig":{"properties":{"threshold":{"anyOf":[{"type":"number","maximum":0.8,"minimum":0.2},{"type":"null"}],"title":"Threshold"},"prebuffer_duration_ms":{"anyOf":[{"type":"integer","maximum":2000,"minimum":0},{"type":"null"}],"title":"Prebuffer Duration Ms"},"min_speech_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Speech Duration Ms"},"min_silence_duration_ms":{"anyOf":[{"type":"integer","maximum":1500,"minimum":0},{"type":"null"}],"title":"Min Silence Duration Ms"},"min_words_to_interrupt":{"anyOf":[{"type":"integer","maximum":10,"minimum":1},{"type":"null"}],"title":"Min Words To Interrupt"}},"additionalProperties":false,"type":"object","title":"PhonicVadConfig","description":"Phonic's server VAD. Unset fields keep Phonic's defaults."},"PhonicPronunciation":{"properties":{"word":{"type":"string","maxLength":30,"minLength":1,"title":"Word"},"pronunciation":{"type":"string","maxLength":50,"minLength":1,"title":"Pronunciation"}},"additionalProperties":false,"type":"object","required":["word","pronunciation"],"title":"PhonicPronunciation"},"StaffedHours":{"properties":{"timezone":{"type":"string","maxLength":64,"minLength":1,"title":"Timezone"},"windows":{"items":{"$ref":"#/components/schemas/StaffedWindow"},"type":"array","maxItems":50,"minItems":1,"title":"Windows"},"closed_on_us_federal_holidays":{"type":"boolean","title":"Closed On Us Federal Holidays","default":false},"closed_dates":{"items":{"type":"string","maxLength":10,"minLength":10,"pattern":"^[0-9]{4}-[0-9]{2}-[0-9]{2}$"},"type":"array","maxItems":100,"title":"Closed Dates"}},"type":"object","required":["timezone","windows"],"title":"StaffedHours","description":"When the people who answer a service's lines are there.\n\nA weekday with no window is closed all day. A closed date, and a federal holiday when the service closes for\nthem, close the whole day whatever the windows say. Everything else is open exactly where a window covers the\nwall-clock time of the zone."},"StaffedWindow":{"properties":{"day":{"type":"string","enum":["mon","tue","wed","thu","fri","sat","sun"],"title":"Day"},"open":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Open"},"close":{"type":"string","maxLength":5,"minLength":5,"pattern":"^(?:(?:[01][0-9]|2[0-3]):[0-5][0-9]|24:00)$","title":"Close"}},"type":"object","required":["day","open","close"],"title":"StaffedWindow","description":"One stretch of one weekday that people answer: from ``open`` up to, not including, ``close``."},"ServiceForwardingConfig-Input":{"properties":{"forward_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"warm_transfer_answer_timeout_s":{"type":"integer","maximum":55,"minimum":10,"title":"Warm Transfer Answer Timeout S","default":30},"warm_transfer_on_queue":{"type":"string","enum":["hand_over","treat_as_miss"],"title":"Warm Transfer On Queue","default":"hand_over"},"warm_transfer_on_miss":{"type":"string","enum":["hand_back","offer_number","cold_to_fallback"],"title":"Warm Transfer On Miss","default":"hand_back"},"receiver_classifier":{"type":"string","enum":["twilio_amd","platform"],"title":"Receiver Classifier","default":"twilio_amd"},"approved_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Approved Destinations"},"fallback_to":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"test_destinations":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":20,"title":"Test Destinations"},"verification_callers":{"additionalProperties":{"$ref":"#/components/schemas/NameString"},"propertyNames":{"$ref":"#/components/schemas/PhoneE164"},"type":"object","maxProperties":10,"title":"Verification Callers"},"hours":{"anyOf":[{"$ref":"#/components/schemas/StaffedHours"},{"type":"null"}]},"after_hours_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"default_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]},"transfer_reasons":{"items":{"$ref":"#/components/schemas/TransferReason"},"type":"array","maxItems":20,"title":"Transfer Reasons"},"destination_hours":{"additionalProperties":{"$ref":"#/components/schemas/DestinationHours"},"propertyNames":{"$ref":"#/components/schemas/DialE164"},"type":"object","maxProperties":50,"title":"Destination Hours"},"unsupported_language_destination":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"type":"object","required":["forward_to"],"title":"ServiceForwardingConfig","description":"Per-service call-forwarding destination + transfer mechanism.\n\nThis block gates the ``forward_call`` tool: None means the agent cannot\ntransfer at all. When present, ``forward_to`` picks the destination mode,\nand the tool schema follows it — a static service gets an argument-less\ntool, a dynamic one gets a required ``phone_number`` that must be one of\n``approved_destinations`` (none approved means no tool). Nothing cascades:\na service is one mode or the other. ``fallback_to`` is no mode: it is the\nline the safe exit dials, in either, and ``forward_call`` never offers it.\nA call tagged as a test reaches only ``test_destinations``, in either mode, unless\nits caller is one of ``verification_callers``.\n``hours`` is none either: on a dynamic service, a transfer outside its staffed\nhours dials ``after_hours_destination`` whichever approved line was asked for, unless that line keeps\nhours of its own in ``destination_hours``.\nA dynamic service can also name a ``default_destination``, the line a transfer that names none dials. A service\nin either mode can list the ``transfer_reasons`` each of its transfers names and the call records."},"DialE164":{"type":"string","maxLength":16,"minLength":2},"PhoneE164":{"type":"string","maxLength":16,"minLength":2},"TransferReason":{"properties":{"key":{"$ref":"#/components/schemas/TransferReasonKey"},"description":{"$ref":"#/components/schemas/DescriptionString","maxLength":200}},"additionalProperties":false,"type":"object","required":["key","description"],"title":"TransferReason","description":"One reason a service's transfers name (``ServiceForwardingConfig.transfer_reasons``)."},"TransferReasonKey":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"},"DestinationHours":{"properties":{"hours":{"$ref":"#/components/schemas/StaffedHours"},"after_hours":{"anyOf":[{"$ref":"#/components/schemas/DialE164"},{"type":"null"}]}},"additionalProperties":false,"type":"object","required":["hours"],"title":"DestinationHours","description":"One approved line's own staffed hours and after-hours line, in place of its service's\n(``ServiceForwardingConfig.destination_hours``)."},"ContextKeySpec":{"properties":{"key":{"$ref":"#/components/schemas/SlugString"},"type":{"type":"string","enum":["string","number"],"title":"Type"},"description":{"$ref":"#/components/schemas/DescriptionString"},"required":{"type":"boolean","title":"Required"}},"type":"object","required":["key","type","description","required"],"title":"ContextKeySpec","description":"One key a conversation may supply as start-time context for a service.\n\nThe value is validated against ``type`` at conversation start; a tool can then\nbind the key to one of its parameters (injected, hidden from the model)."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"CrisisCall911Reply":{"properties":{"en":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1},"es":{"$ref":"#/components/schemas/DescriptionString","maxLength":1000,"minLength":1}},"additionalProperties":false,"type":"object","required":["en","es"],"title":"CrisisCall911Reply","description":"Per-service wording added when a caller already in crisis asks for emergency dispatch."},"ContactLineInput":{"properties":{"kind":{"type":"string","enum":["crisis","domestic_violence","child_abuse","poison_help","clinical_24h","front_desk"],"title":"Kind"},"number":{"$ref":"#/components/schemas/DialE164"},"spoken_name":{"$ref":"#/components/schemas/NameString","maxLength":80},"spoken_name_es":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"area":{"anyOf":[{"$ref":"#/components/schemas/NameString","maxLength":80},{"type":"null"}]},"available_24h":{"type":"boolean","title":"Available 24H"},"may_read_aloud":{"type":"boolean","title":"May Read Aloud"}},"additionalProperties":false,"type":"object","required":["kind","number","spoken_name","available_24h","may_read_aloud"],"title":"ContactLineInput","description":"Save-time number policy; persisted declarations remain readable after policy changes."},"ServiceOutputChecksRequest":{"properties":{"phi_unverified":{"$ref":"#/components/schemas/PhiUnverifiedCheck","description":"On a voice call, `cut` stops a reply that reads something from a patient's record to a caller who has not\nverified, and the caller hears a correction in its place. `off`, the platform default, does not run the check."},"blocklisted_number":{"$ref":"#/components/schemas/BlocklistedNumberCheck","description":"`cut`, the platform default, stops a reply that speaks a number on the platform phone blocklist, and the caller\nhears the no-confirmed-number correction in its place. `off` lets the reply speak it. A listed number is still\nnever dialed and is still refused as a destination."},"misspelled_word":{"$ref":"#/components/schemas/MisspelledWordCheck","description":"`cut`, the platform default, stops a reply that spells back, letter by letter, a word close to but not the one\nthe caller just said. `off` lets the spelling play."},"dosing_or_med_change":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that gives dosing advice or tells the caller to change a medication. `cut` (the platform default)\nreplaces it with a correction, `count` lets it play and counts it, `off` lets it play."},"diagnosis":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says what is wrong with the caller, or that a symptom needs no care. `cut`, `count` or `off`."},"false_confirmation":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says a booking, message or other action is done when no write on the call backs it. `cut`,\n`count` or `off`."},"dispatch_promise":{"$ref":"#/components/schemas/CheckerLabelCheck","description":"A reply that says emergency help is called, sent or on the way. `cut`, `count` or `off`."},"action_promise":{"$ref":"#/components/schemas/ActionPromiseCheck","description":"A reply that called no tool and tells the caller the agent is doing something now, on text or a realtime call.\n`retry`, the platform default, gives the agent one more go with a note to act or say what it can't do. `off`\nsends the reply as written."},"unbacked_action_claims":{"$ref":"#/components/schemas/UnbackedActionClaimsCheck","description":"Text only. A reply that says something was done for the client, such as an escalation, a handoff or a message\npassed to a team, when no tool that succeeded in the turn did it. `off`, the platform default, does not read the\nreply. `log` reads it and counts a claim it finds; the reply goes out as written. `enforce` holds the reply back\nand gives the agent one more go with a note to call the tool first or not claim it; a second reply that still\nclaims it goes out cut before the claim, with the false-confirmation correction in its place."}},"additionalProperties":false,"type":"object","title":"ServiceOutputChecksRequest","description":"The reply checks a service or a workspace sets. A key left out inherits: a service's from the workspace default,\nthe workspace's from the platform default. Every key can be set to `off`."},"PhiUnverifiedCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"PhiUnverifiedCheck"},"BlocklistedNumberCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"BlocklistedNumberCheck"},"MisspelledWordCheck":{"properties":{"mode":{"type":"string","enum":["cut","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"MisspelledWordCheck"},"CheckerLabelCheck":{"properties":{"mode":{"type":"string","enum":["cut","count","off"],"title":"Mode","default":"cut"}},"additionalProperties":false,"type":"object","title":"CheckerLabelCheck"},"ActionPromiseCheck":{"properties":{"mode":{"type":"string","enum":["retry","off"],"title":"Mode","default":"retry"}},"additionalProperties":false,"type":"object","title":"ActionPromiseCheck"},"UnbackedActionClaimsCheck":{"properties":{"mode":{"type":"string","enum":["off","log","enforce"],"title":"Mode","default":"off"}},"additionalProperties":false,"type":"object","title":"UnbackedActionClaimsCheck"},"ServiceEmergencyFloorRequest":{"properties":{"text_self_harm":{"$ref":"#/components/schemas/TextSelfHarmFloor","description":"A message that says the person is thinking about harming or killing themselves. `enforce`, the platform default,\nanswers it with the floor's crisis script (the region's crisis line, the service's crisis contacts and the\nemergency number) in place of the agent's reply. `off` leaves it to the agent."},"text_medical":{"$ref":"#/components/schemas/TextMedicalFloor","description":"A message that describes a medical emergency, such as chest pain or trouble breathing. `shadow`, the platform\ndefault, detects and counts it and opens the floor's hold, and the agent's reply goes out. `enforce` answers it\nwith the floor's emergency-number script instead. `off` leaves it to the agent."},"held_text":{"$ref":"#/components/schemas/HeldTextFloor","description":"A message on a conversation an operator holds. `enforce`, the platform default, answers it with the floor's\nscript when it names any emergency. `off` leaves every held message to the operator."}},"additionalProperties":false,"type":"object","title":"ServiceEmergencyFloorRequest","description":"How the medical-emergency and crisis floor acts on text conversations (SMS, email, web chat and the other\nmessaging channels), voice notes and simulations. A key left out inherits: a service's from the workspace default,\nthe workspace's from the platform default, which is today's behavior. Every key can be set to `off`, and then the\nfloor neither replaces nor alters the reply: the agent's own reply and tools run, no hold opens, and the hit is\nonly counted. A voice call's floor is not set here."},"TextSelfHarmFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"TextSelfHarmFloor"},"TextMedicalFloor":{"properties":{"mode":{"type":"string","enum":["enforce","shadow","off"],"title":"Mode","default":"shadow"}},"additionalProperties":false,"type":"object","title":"TextMedicalFloor"},"HeldTextFloor":{"properties":{"mode":{"type":"string","enum":["enforce","off"],"title":"Mode","default":"enforce"}},"additionalProperties":false,"type":"object","title":"HeldTextFloor"},"ConversationAuditSettings":{"properties":{"enabled":{"type":"boolean","title":"Enabled","default":false},"checks":{"items":{"$ref":"#/components/schemas/ConversationAuditCheck"},"type":"array","maxItems":4,"minItems":1,"title":"Checks"},"threshold":{"type":"integer","maximum":100,"minimum":1,"title":"Threshold","default":80}},"additionalProperties":false,"type":"object","title":"ConversationAuditSettings"},"ConversationAuditCheck":{"type":"string","enum":["obvious_errors","missed_escalation","wrong_information","missed_safety_event"]}}}}
```

## The UpdateSimulationCaseRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateSimulationCaseRequest":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"persona":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Persona"},"description":{"anyOf":[{"type":"string","maxLength":2000,"minLength":1},{"type":"null"}],"title":"Description"},"scenario":{"anyOf":[{"$ref":"#/components/schemas/SimulationCaseScenario"},{"type":"null"}]},"grounding":{"anyOf":[{"$ref":"#/components/schemas/SimulationCaseGrounding"},{"type":"null"}]},"evals":{"anyOf":[{"items":{"$ref":"#/components/schemas/SimulationCaseEval"},"type":"array","maxItems":100},{"type":"null"}],"title":"Evals"},"tags":{"anyOf":[{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20},{"type":"null"}],"title":"Tags"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata"}},"additionalProperties":false,"type":"object","title":"UpdateSimulationCaseRequest","description":"Partial update for one durable simulation case.\n\nEvery field is optional, and only the fields the caller sends are updated. The nested submodels are the\nsame as on create, so the durable fields (``scenario``, ``grounding``, ``evals``, ``metadata``) can be\nupdated. The retired flat fields (``scenario_instructions``, ``initial_message``, ``temperament``,\n``fixtures``, ``constraints``, ``target_spec``, ``assertions``, ``provenance``) are refused with 422."},"SimulationCaseScenario":{"properties":{"instructions":{"type":"string","maxLength":10000,"minLength":1,"title":"Instructions"},"initial_message":{"type":"string","maxLength":2000,"title":"Initial Message","default":""},"temperament":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Temperament"}},"type":"object","required":["instructions"],"title":"SimulationCaseScenario","description":"Runnable patient-side scenario content for a saved case."},"SimulationCaseGrounding":{"properties":{"patient_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Patient Entity Id"},"context":{"additionalProperties":{"anyOf":[{"type":"integer"},{"type":"number"},{"type":"string","maxLength":8192}]},"propertyNames":{"$ref":"#/components/schemas/SlugString"},"type":"object","maxProperties":50,"title":"Context","description":"Start context a run of this case begins with: key-value pairs, each key one the service accepts (`accepted_context`) and each value a string or a number. A tool parameter the service's graph binds to a key is filled from it on every turn and branch. A run is refused, and a suite skips the case, when a required key is missing, a key is not one the service accepts, or a value has the wrong type. A launch's own `context` is added to it and wins where both name a key."}},"type":"object","title":"SimulationCaseGrounding","description":"Optional bindings that start the sim from existing workspace data."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"SimulationCaseEval":{"oneOf":[{"$ref":"#/components/schemas/SimulationCaseMetricEval"},{"$ref":"#/components/schemas/SimulationCaseAssertionEval"},{"$ref":"#/components/schemas/SimulationCaseBooleanAssertionEval"}]},"SimulationCaseMetricEval":{"properties":{"type":{"type":"string","const":"metric","title":"Type"},"metric_key":{"type":"string","maxLength":128,"minLength":1,"title":"Metric Key"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","metric_key"],"title":"SimulationCaseMetricEval"},"SimulationCaseAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","enum":["transcript_contains","must_contain","transcript_not_contains","must_not_contain","tool_called","final_state"],"title":"Assertion Kind"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"expected":{"anyOf":[{},{"type":"null"}],"title":"Expected"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"}},"type":"object","required":["type","key","assertion_kind"],"title":"SimulationCaseAssertionEval","description":"An assertion checked in code against the transcript, the tools called or the final state."},"SimulationCaseBooleanAssertionEval":{"properties":{"type":{"type":"string","const":"assertion","title":"Type"},"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"assertion_kind":{"type":"string","const":"llm_boolean","title":"Assertion Kind"},"instructions":{"type":"string","maxLength":2000,"minLength":1,"title":"Instructions","description":"The question, and what makes its answer true or false."},"expected":{"type":"boolean","title":"Expected","description":"The answer that passes the check."}},"additionalProperties":false,"type":"object","required":["type","key","assertion_kind","instructions","expected"],"title":"SimulationCaseBooleanAssertionEval","description":"A yes-or-no question about the conversation, graded by comparing what a judge observed with ``expected``.\n\nThe judge sees the case and the transcript, never ``expected``, and answers true,\nfalse, or that the conversation does not show enough to tell. The check passes\nwhen the answer equals ``expected`` and fails when it doesn't. When the judge\ncan't tell, the check is skipped and stays out of pass rates."}}}}
```

## The UpdateSimulationSuiteRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateSimulationSuiteRequest":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Description"},"case_ids":{"anyOf":[{"items":{"type":"string","format":"uuid"},"type":"array","maxItems":500},{"type":"null"}],"title":"Case Ids"},"required_tags":{"anyOf":[{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20},{"type":"null"}],"title":"Required Tags"},"tags":{"anyOf":[{"items":{"type":"string","maxLength":128},"type":"array","maxItems":20},{"type":"null"}],"title":"Tags"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata"}},"additionalProperties":false,"type":"object","title":"UpdateSimulationSuiteRequest"}}}}
```

## The UpdateSkillRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateSkillRequest":{"properties":{"name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"system_prompt":{"anyOf":[{"$ref":"#/components/schemas/BackgroundString"},{"type":"null"}]},"input_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input Schema"},"result_schema":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Result Schema"},"model":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Model","description":"Anthropic model id; see CreateSkillRequest. null/absent leaves it unchanged."},"max_tokens":{"anyOf":[{"type":"integer","maximum":200000,"minimum":1},{"type":"null"}],"title":"Max Tokens"},"max_result_chars":{"anyOf":[{"type":"integer","maximum":200000,"minimum":1},{"type":"null"}],"title":"Max Result Chars"},"max_input_tokens":{"anyOf":[{"type":"integer","maximum":2000000,"minimum":1},{"type":"null"}],"title":"Max Input Tokens"},"timeout_s":{"anyOf":[{"type":"number","maximum":900,"minimum":0.1},{"type":"null"}],"title":"Timeout S"},"thinking_effort":{"anyOf":[{"$ref":"#/components/schemas/ThinkingEffort"},{"type":"null"}]},"temperature":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Temperature","description":"Anthropic sampling temperature (0-1); see CreateSkillRequest. null/absent leaves it unchanged."},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P","description":"Anthropic nucleus sampling (0-1); see CreateSkillRequest. null/absent leaves it unchanged."},"enable_caching":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Caching"},"enable_citations":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Citations"},"use_structured_output":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Use Structured Output"},"integration_tools":{"anyOf":[{"items":{"$ref":"#/components/schemas/IntegrationToolRef-Input"},"type":"array","maxItems":50},{"type":"null"}],"title":"Integration Tools"},"static_tools":{"anyOf":[{"items":{"$ref":"#/components/schemas/StaticToolDef-Input"},"type":"array","maxItems":50},{"type":"null"}],"title":"Static Tools"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled"},"max_agent_turns":{"anyOf":[{"type":"integer","maximum":200,"minimum":1},{"type":"null"}],"title":"Max Agent Turns"},"checkpoint_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Checkpoint Enabled"},"approval_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Approval Required"},"write_kind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"null"}],"description":"What this skill's writes do; see CreateSkillRequest. null/absent leaves it unchanged."}},"type":"object","title":"UpdateSkillRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"BackgroundString":{"type":"string","maxLength":10000},"ThinkingEffort":{"type":"string","enum":["low","medium","high"]},"IntegrationToolRef-Input":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string","maxLength":256,"minLength":1},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","maxProperties":50,"title":"Skill Input Bindings","description":"Endpoint parameter -> parent skill input mappings injected at dispatch."}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef","description":"Reference to an integration endpoint by integration + endpoint name."},"StaticToolDef-Input":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef","description":"A built-in tool available to companion agents."},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]}}}}
```

## The UpdateSurfaceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateSurfaceRequest":{"properties":{"title":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"fields":{"anyOf":[{"items":{"$ref":"#/components/schemas/SurfaceField"},"type":"array","maxItems":200,"minItems":1},{"type":"null"}],"title":"Fields"},"branding":{"anyOf":[{"$ref":"#/components/schemas/BrandingConfig"},{"type":"null"}]},"sections":{"anyOf":[{"items":{"$ref":"#/components/schemas/SurfaceSection"},"type":"array"},{"type":"null"}],"title":"Sections"},"completion_title":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Completion Title"},"completion_message":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Completion Message"},"completion_action_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Completion Action Url"},"submit_button_text":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Submit Button Text"},"channel":{"anyOf":[{"$ref":"#/components/schemas/StoredChannelType"},{"type":"null"}]},"resource_type":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Resource Type"}},"type":"object","title":"UpdateSurfaceRequest","description":"Partial update to an existing surface.\n\nAll fields are optional. Only provided fields are merged into the spec.\nOnly allowed while status is CREATED or DELIVERED."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"SurfaceField":{"properties":{"key":{"type":"string","maxLength":128,"minLength":1,"title":"Key"},"label":{"$ref":"#/components/schemas/NameString"},"field_type":{"$ref":"#/components/schemas/FieldType"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"placeholder":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Placeholder"},"prefill_value":{"anyOf":[{},{"type":"null"}],"title":"Prefill Value"},"validation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Validation"},"sensitive":{"type":"boolean","title":"Sensitive","default":false},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"},"consent_text":{"anyOf":[{"type":"string","maxLength":5000},{"type":"null"}],"title":"Consent Text"}},"type":"object","required":["key","label","field_type"],"title":"SurfaceField","description":"A single data collection field in a surface spec.\n\nGenerated by agents from HSM analysis. Each field maps\nto a specific piece of data the world model needs."},"FieldType":{"type":"string","enum":["text","textarea","date","phone","email","number","select","multiselect","checkbox","photo","signature","file","heading","info"],"title":"FieldType","description":"Input field types for surface data collection."},"BrandingConfig":{"properties":{"logo_url":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Logo Url"},"primary_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Primary Color"},"background_color":{"anyOf":[{"type":"string","maxLength":32},{"type":"null"}],"title":"Background Color"},"font_family":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Font Family"}},"type":"object","title":"BrandingConfig","description":"Visual branding for patient-facing surfaces."},"SurfaceSection":{"properties":{"title":{"$ref":"#/components/schemas/NameString"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"field_keys":{"items":{"type":"string"},"type":"array","maxItems":100,"minItems":1,"title":"Field Keys"},"condition":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Condition"}},"type":"object","required":["title","field_keys"],"title":"SurfaceSection","description":"A page/step in a multi-page surface form."},"StoredChannelType":{"type":"string","enum":["email","web","sms"],"title":"StoredChannelType","description":"Channel as stored on a surface row or outreach rule.\n\n``sms`` predates the end of SMS delivery. It stays readable, and an edit may send a stored ``sms`` back\nunchanged, but no surface or rule is ever switched to it or created with it."}}}}
```

## The UpdateTriggerRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateTriggerRequest":{"properties":{"name":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"event_type":{"anyOf":[{"$ref":"#/components/schemas/TriggerableEvent"},{"type":"null"}]},"event_filter":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Event Filter"},"action_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Action Id"},"input_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Input Template"},"schedule":{"anyOf":[{"type":"string","maxLength":128,"minLength":1},{"type":"null"}],"title":"Schedule"},"timezone":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"Timezone"},"threshold":{"anyOf":[{"$ref":"#/components/schemas/TriggerThreshold"},{"type":"null"}],"description":"Event triggers only: replaces the trigger's threshold, and an explicit null clears it, so the trigger fires on every matching event again. Refused on a cron trigger, or with a schedule."}},"type":"object","title":"UpdateTriggerRequest"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"TriggerableEvent":{"type":"string","enum":["amigo.trigger.cron","appointment.booked","appointment.cancelled","appointment.confirmed","booking.requested","call.ended","call.failure_signal","call.intelligence","call.outcome","channel.message.received","conversation.channel_switched","conversation.started","conversation.turn_recorded","coverage.created","entity.enriched","entity.resolved","medication.refill_requested","outbound.initiated","outbound.scheduled","patient.created","patient.updated","relationship.established","review.approve","review.correct","review.reject","surface.created","surface.submitted","ticket.created","triage.completed","trigger.completed","trigger.failed","trigger.fired"],"title":"TriggerableEvent","description":"Closed set of world events that trigger definitions may subscribe to.\n\nThe database column intentionally remains text for compatibility with old\nrows, but API writes must choose from this list so typoed event names do\nnot silently create never-matching triggers."},"TriggerThreshold":{"properties":{"count":{"type":"integer","maximum":100,"minimum":1,"title":"Count"},"window_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Window Minutes"},"cooldown_minutes":{"type":"integer","maximum":1440,"minimum":1,"title":"Cooldown Minutes","default":60}},"additionalProperties":false,"type":"object","required":["count","window_minutes"],"title":"TriggerThreshold","description":"How many matching events an event trigger waits for before it fires: ``count`` of them inside the last\n``window_minutes``. Once it fires, it holds off for ``cooldown_minutes`` however many more arrive."}}}}
```

## The UpdateWorkspaceRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpdateWorkspaceRequest":{"properties":{"name":{"anyOf":[{"$ref":"#/components/schemas/StrippedNonemptyString"},{"type":"null"}]},"topic_modeling_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Topic Modeling Enabled"},"delta_sharing_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Delta Sharing Enabled"},"delta_sharing_mode":{"type":"string","enum":["open","databricks"],"title":"Delta Sharing Mode"},"delta_sharing_identifier":{"type":"string","maxLength":512,"minLength":1,"title":"Delta Sharing Identifier"},"timezone":{"anyOf":[{"type":"string","maxLength":64,"minLength":1},{"type":"null"}],"title":"Timezone"},"region":{"anyOf":[{"type":"string","enum":["us-east-1","ap-southeast-2","eu-central-1","ca-central-1"]},{"type":"null"}],"title":"Region"},"connector_type":{"anyOf":[{"type":"string","enum":["epic","cerner","allscripts","fhir_store","athenahealth","charmhealth","eclinicalworks","meditab"]},{"type":"null"}],"title":"Connector Type"}},"type":"object","title":"UpdateWorkspaceRequest"},"StrippedNonemptyString":{"type":"string","minLength":1}}}}
```

## The UpsertRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpsertRequest":{"properties":{"source":{"type":"string","maxLength":128,"minLength":1,"title":"Source"},"external_subject_key":{"type":"string","maxLength":512,"minLength":1,"title":"External Subject Key"},"external_subject_id":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"External Subject Id"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"display_name":{"anyOf":[{"type":"string","maxLength":512},{"type":"null"}],"title":"Display Name"},"roles":{"items":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,63}$"},"type":"array","maxItems":64,"title":"Roles"},"roles_verified":{"type":"boolean","title":"Roles Verified","default":false},"provisioned_via":{"type":"string","enum":["roster_sync","jit"],"title":"Provisioned Via"}},"additionalProperties":false,"type":"object","required":["source","external_subject_key","entity_id","provisioned_via"],"title":"UpsertRequest"}}}}
```

## The UpsertVersionSetRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UpsertVersionSetRequest":{"properties":{"version_set":{"$ref":"#/components/schemas/VersionSet-Input","description":"The version set to store. Its `dynamic_behavior_sets` left out keep the pins the stored version set has, and\n`[]` clears them."},"expected_updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expected Updated At","description":"The service's `updated_at` this write was made from, exactly as the service returned it. When the service\nhas changed since, the write is refused with 409 and nothing is stored, so a stale page can't overwrite\nanother editor's pins. Left out, the write is not compared to what the caller last read."}},"type":"object","required":["version_set"],"title":"UpsertVersionSetRequest"},"VersionSet-Input":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The UsageAttribution object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageAttribution":{"properties":{"conversation_attribution_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Conversation Attribution Rate","description":"Linked requests divided by all requests; null when there are no requests."},"service_attribution_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Service Attribution Rate","description":"Service-attributed input tokens divided by all input tokens; null when there are none."}},"type":"object","required":["conversation_attribution_rate","service_attribution_rate"],"title":"UsageAttribution","description":"Coverage of conversation and service attribution."}}}}
```

## The UsageBucket object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageBucket":{"properties":{"event_type":{"type":"string","title":"Event Type","description":"World event type"},"event_date":{"type":"string","format":"date","title":"Event Date","description":"Date of the usage bucket"},"count":{"type":"integer","title":"Count","description":"Number of events in this bucket"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Average event duration in seconds"},"total_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Total Duration Seconds","description":"Total event duration in seconds"}},"type":"object","required":["event_type","event_date","count"],"title":"UsageBucket"}}}}
```

## The UsageClassesResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageClassesResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"classes":{"items":{"$ref":"#/components/schemas/ClassUsage"},"type":"array","title":"Classes","description":"All recorded usage classes, including production and non-production, after any service filter."}},"type":"object","required":["workspace_id","period","calculation_run_id","classes"],"title":"UsageClassesResponse","description":"Usage grouped by usage class, returned for `group_by=class`."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"ClassUsage":{"properties":{"usage_class":{"type":"string","title":"Usage Class"},"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["usage_class","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ClassUsage","description":"Usage attributed to one usage class."}}}}
```

## The UsageCostAppliedRate object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostAppliedRate":{"properties":{"rate_card_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rate Card Version","description":"Null in V0 because the published facts do not retain a reproducible rate-card identifier."},"effective_from":{"type":"string","format":"date-time","title":"Effective From","description":"Inclusive input-rate start date, represented as midnight UTC."},"effective_to":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective To","description":"Exclusive input-rate end date at midnight UTC; null means no end date."},"input_per_million":{"type":"string","title":"Input Per Million","description":"USD per million uncached input tokens, as a decimal string."},"cached_input_per_million":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cached Input Per Million","description":"USD per million cached input tokens; null if no cached rate applied."},"output_per_million":{"type":"string","title":"Output Per Million","description":"USD per million output tokens, as a decimal string."}},"type":"object","required":["rate_card_version","effective_from","effective_to","input_per_million","cached_input_per_million","output_per_million"],"title":"UsageCostAppliedRate","description":"Rate record applied to this model during the requested period."}}}}
```

## The UsageCostAttribution object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostAttribution":{"properties":{"conversation_attribution_rate":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Conversation Attribution Rate","description":"Linked-token share; null because the published facts do not retain linked-token totals."},"service_attribution_rate":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Service Attribution Rate","description":"Service-attributed input and output tokens / all tokens in the selected scope; null with no tokens."},"may_include_amigo_operated_usage":{"type":"boolean","title":"May Include Amigo Operated Usage","description":"Whether production-classified totals may include usage operated by Amigo."}},"type":"object","required":["conversation_attribution_rate","service_attribution_rate","may_include_amigo_operated_usage"],"title":"UsageCostAttribution","description":"Known coverage and limitations of usage attribution."}}}}
```

## The UsageCostDaily object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostDaily":{"properties":{"usage_date":{"type":"string","format":"date","title":"Usage Date"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"}},"type":"object","required":["usage_date","uncached_input_tokens"],"title":"UsageCostDaily","description":"Uncached input-token usage for one UTC date."}}}}
```

## The UsageCostError object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostError":{"properties":{"code":{"type":"string","enum":["invalid_usage_period","workspace_usage_forbidden","workspace_not_found","usage_data_unavailable"],"title":"Code"},"message":{"type":"string","title":"Message"}},"type":"object","required":["code","message"],"title":"UsageCostError"}}}}
```

## The UsageCostErrorResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostErrorResponse":{"properties":{"error":{"$ref":"#/components/schemas/UsageCostError"}},"type":"object","required":["error"],"title":"UsageCostErrorResponse","description":"Stable error envelope for the customer usage-cost contract."},"UsageCostError":{"properties":{"code":{"type":"string","enum":["invalid_usage_period","workspace_usage_forbidden","workspace_not_found","usage_data_unavailable"],"title":"Code"},"message":{"type":"string","title":"Message"}},"type":"object","required":["code","message"],"title":"UsageCostError"}}}}
```

## The UsageCostExcludedClass object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostExcludedClass":{"properties":{"usage_class":{"type":"string","enum":["simulation","playground_test","customer_test","amigo_internal","unknown"],"title":"Usage Class"},"exclusion_reason":{"type":"string","enum":["simulation","playground","customer_test","amigo_internal","operator_attribution_unavailable"],"title":"Exclusion Reason"},"conversation_count":{"type":"integer","title":"Conversation Count","description":"Distinct linked conversations in this excluded class; zero when none are linked."},"request_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Request Count","description":"Provider requests in this class; null when the source cannot supply a request count."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cached Input Tokens","description":"Cached input tokens in this class; null when the source cannot supply the count."},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["usage_class","exclusion_reason","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"UsageCostExcludedClass","description":"Usage totals and exclusion reason for one non-production class."}}}}
```

## The UsageCostExcludedResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostExcludedResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"period":{"$ref":"#/components/schemas/Period"},"classes":{"items":{"$ref":"#/components/schemas/UsageCostExcludedClass"},"type":"array","title":"Classes"}},"type":"object","required":["workspace_id","period","classes"],"title":"UsageCostExcludedResponse","description":"Usage explicitly excluded from production-classified totals."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"UsageCostExcludedClass":{"properties":{"usage_class":{"type":"string","enum":["simulation","playground_test","customer_test","amigo_internal","unknown"],"title":"Usage Class"},"exclusion_reason":{"type":"string","enum":["simulation","playground","customer_test","amigo_internal","operator_attribution_unavailable"],"title":"Exclusion Reason"},"conversation_count":{"type":"integer","title":"Conversation Count","description":"Distinct linked conversations in this excluded class; zero when none are linked."},"request_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Request Count","description":"Provider requests in this class; null when the source cannot supply a request count."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cached Input Tokens","description":"Cached input tokens in this class; null when the source cannot supply the count."},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["usage_class","exclusion_reason","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"UsageCostExcludedClass","description":"Usage totals and exclusion reason for one non-production class."}}}}
```

## The UsageCostLatestClose object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostLatestClose":{"properties":{"close_month":{"type":"string","format":"date","title":"Close Month"},"status":{"type":"string","const":"complete","title":"Status"},"calculated_at":{"type":"string","format":"date-time","title":"Calculated At"},"calculation_run_id":{"type":"string","title":"Calculation Run Id"},"rate_card_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rate Card Version"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage"},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens"}},"type":"object","required":["close_month","status","calculated_at","calculation_run_id","rate_card_version","calculated_cost_usd","uncached_input_tokens","cached_input_tokens","output_tokens","has_unpriced_usage","unpriced_tokens"],"title":"UsageCostLatestClose","description":"Latest compatible completed monthly close, when available."}}}}
```

## The UsageCostModel object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostModel":{"properties":{"model_id":{"type":"string","title":"Model Id"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"request_count":{"type":"integer","title":"Request Count"},"calls_per_conversation":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Calls Per Conversation","description":"This model's linked provider requests / its distinct linked conversations; null if none are linked."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"cache_rate":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Cache Rate","description":"Cached input tokens / total input tokens; null when there are no input tokens."},"output_tokens":{"type":"integer","title":"Output Tokens"},"applied_rates":{"items":{"$ref":"#/components/schemas/UsageCostAppliedRate"},"type":"array","title":"Applied Rates"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Model cost rounded to cents; null if any contributing usage is unpriced, including partially priced models."},"cost_share":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Cost Share","description":"Model cost / fully priced model costs in the selected scope, after any service filter.\nPartially priced models are excluded from both sides; null if unpriced or the denominator is zero."},"is_priced":{"type":"boolean","title":"Is Priced","description":"Whether every contributing usage row for this model is priced."},"unpriced_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unpriced Reason","description":"One reason contributing usage could not be priced; null when all usage is priced."}},"type":"object","required":["model_id","provider","request_count","calls_per_conversation","uncached_input_tokens","cached_input_tokens","cache_rate","output_tokens","applied_rates","calculated_cost_usd","cost_share","is_priced","unpriced_reason"],"title":"UsageCostModel","description":"Production-classified usage and calculated cost for one model."},"UsageCostAppliedRate":{"properties":{"rate_card_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rate Card Version","description":"Null in V0 because the published facts do not retain a reproducible rate-card identifier."},"effective_from":{"type":"string","format":"date-time","title":"Effective From","description":"Inclusive input-rate start date, represented as midnight UTC."},"effective_to":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective To","description":"Exclusive input-rate end date at midnight UTC; null means no end date."},"input_per_million":{"type":"string","title":"Input Per Million","description":"USD per million uncached input tokens, as a decimal string."},"cached_input_per_million":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cached Input Per Million","description":"USD per million cached input tokens; null if no cached rate applied."},"output_per_million":{"type":"string","title":"Output Per Million","description":"USD per million output tokens, as a decimal string."}},"type":"object","required":["rate_card_version","effective_from","effective_to","input_per_million","cached_input_per_million","output_per_million"],"title":"UsageCostAppliedRate","description":"Rate record applied to this model during the requested period."}}}}
```

## The UsageCostModelsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostModelsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"period":{"$ref":"#/components/schemas/Period"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"conversation_count":{"type":"integer","title":"Conversation Count","description":"Distinct linked conversations in the selected scope; conversations shared by models are counted once."},"currency":{"type":"string","const":"USD","title":"Currency"},"models":{"items":{"$ref":"#/components/schemas/UsageCostModel"},"type":"array","title":"Models"}},"type":"object","required":["workspace_id","period","service_id","conversation_count","currency","models"],"title":"UsageCostModelsResponse","description":"Customer usage and calculated model-provider cost grouped by model."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"UsageCostModel":{"properties":{"model_id":{"type":"string","title":"Model Id"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"request_count":{"type":"integer","title":"Request Count"},"calls_per_conversation":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Calls Per Conversation","description":"This model's linked provider requests / its distinct linked conversations; null if none are linked."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"cache_rate":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Cache Rate","description":"Cached input tokens / total input tokens; null when there are no input tokens."},"output_tokens":{"type":"integer","title":"Output Tokens"},"applied_rates":{"items":{"$ref":"#/components/schemas/UsageCostAppliedRate"},"type":"array","title":"Applied Rates"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Model cost rounded to cents; null if any contributing usage is unpriced, including partially priced models."},"cost_share":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Cost Share","description":"Model cost / fully priced model costs in the selected scope, after any service filter.\nPartially priced models are excluded from both sides; null if unpriced or the denominator is zero."},"is_priced":{"type":"boolean","title":"Is Priced","description":"Whether every contributing usage row for this model is priced."},"unpriced_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Unpriced Reason","description":"One reason contributing usage could not be priced; null when all usage is priced."}},"type":"object","required":["model_id","provider","request_count","calls_per_conversation","uncached_input_tokens","cached_input_tokens","cache_rate","output_tokens","applied_rates","calculated_cost_usd","cost_share","is_priced","unpriced_reason"],"title":"UsageCostModel","description":"Production-classified usage and calculated cost for one model."},"UsageCostAppliedRate":{"properties":{"rate_card_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rate Card Version","description":"Null in V0 because the published facts do not retain a reproducible rate-card identifier."},"effective_from":{"type":"string","format":"date-time","title":"Effective From","description":"Inclusive input-rate start date, represented as midnight UTC."},"effective_to":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Effective To","description":"Exclusive input-rate end date at midnight UTC; null means no end date."},"input_per_million":{"type":"string","title":"Input Per Million","description":"USD per million uncached input tokens, as a decimal string."},"cached_input_per_million":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cached Input Per Million","description":"USD per million cached input tokens; null if no cached rate applied."},"output_per_million":{"type":"string","title":"Output Per Million","description":"USD per million output tokens, as a decimal string."}},"type":"object","required":["rate_card_version","effective_from","effective_to","input_per_million","cached_input_per_million","output_per_million"],"title":"UsageCostAppliedRate","description":"Rate record applied to this model during the requested period."}}}}
```

## The UsageCostOverviewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostOverviewResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"period":{"$ref":"#/components/schemas/UsageCostPeriod"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"The service the request was filtered to; null when it was not filtered."},"attribution_status":{"type":"string","const":"best_effort","title":"Attribution Status"},"attribution":{"anyOf":[{"$ref":"#/components/schemas/UsageCostAttribution"},{"type":"null"}]},"data_status":{"type":"string","enum":["complete","partial","delayed","failed"],"title":"Data Status","description":"V0 returns partial for a published calculation, or failed when no complete calculation covers the period."},"data_as_of":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Data As Of","description":"Source-event freshness; null because the published facts do not retain it."},"calculation_run_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculation Run Id","description":"Opaque published-calculation identifier; null when no complete calculation covers the period."},"rate_card_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rate Card Version","description":"Reproducible rate-card identifier; null because the published facts do not retain it."},"currency":{"type":"string","const":"USD","title":"Currency"},"totals":{"anyOf":[{"$ref":"#/components/schemas/UsageCostOverviewTotals"},{"type":"null"}]},"daily":{"anyOf":[{"items":{"$ref":"#/components/schemas/UsageCostDaily"},"type":"array"},{"type":"null"}],"title":"Daily","description":"Ascending UTC dates, zero-filled across the requested period; null when no complete calculation is available."},"services":{"anyOf":[{"items":{"$ref":"#/components/schemas/UsageCostService"},"type":"array"},{"type":"null"}],"title":"Services"},"latest_close":{"anyOf":[{"$ref":"#/components/schemas/UsageCostLatestClose"},{"type":"null"}],"description":"Null in V0 because no monthly close uses the same production-classification policy."}},"type":"object","required":["workspace_id","period","service_id","attribution_status","attribution","data_status","data_as_of","calculation_run_id","rate_card_version","currency","totals","daily","services","latest_close"],"title":"UsageCostOverviewResponse","description":"Customer usage and calculated model-provider cost overview."},"UsageCostPeriod":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"timezone":{"type":"string","const":"UTC","title":"Timezone"}},"type":"object","required":["start_date","end_date","timezone"],"title":"UsageCostPeriod","description":"Inclusive UTC calendar-date range covered by the report."},"UsageCostAttribution":{"properties":{"conversation_attribution_rate":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Conversation Attribution Rate","description":"Linked-token share; null because the published facts do not retain linked-token totals."},"service_attribution_rate":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Service Attribution Rate","description":"Service-attributed input and output tokens / all tokens in the selected scope; null with no tokens."},"may_include_amigo_operated_usage":{"type":"boolean","title":"May Include Amigo Operated Usage","description":"Whether production-classified totals may include usage operated by Amigo."}},"type":"object","required":["conversation_attribution_rate","service_attribution_rate","may_include_amigo_operated_usage"],"title":"UsageCostAttribution","description":"Known coverage and limitations of usage attribution."},"UsageCostOverviewTotals":{"properties":{"conversation_count":{"type":"integer","title":"Conversation Count","description":"Distinct linked conversations in the selected scope, not the sum of per-model counts."},"request_count":{"type":"integer","title":"Request Count","description":"Provider requests in the selected scope, including requests without a linked conversation."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Priced subtotal rounded to cents; excludes unpriced usage. Zero for no usage, null if none can be priced."},"cost_per_conversation_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost Per Conversation Usd","description":"Priced linked cost / distinct priced linked conversations; cents, or null without a denominator."},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any selected usage is omitted from the priced subtotal."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens","description":"Input and output tokens belonging to usage that could not be priced."}},"type":"object","required":["conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens","calculated_cost_usd","cost_per_conversation_usd","has_unpriced_usage","unpriced_tokens"],"title":"UsageCostOverviewTotals","description":"Production-classified usage and calculated cost totals."},"UsageCostDaily":{"properties":{"usage_date":{"type":"string","format":"date","title":"Usage Date"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"}},"type":"object","required":["usage_date","uncached_input_tokens"],"title":"UsageCostDaily","description":"Uncached input-token usage for one UTC date."},"UsageCostService":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service identifier; null for unattributed usage."},"service_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Name","description":"Service name at the latest metadata refresh; null if unavailable. Unattributed for a null service ID."},"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Service priced subtotal rounded to cents; excludes unpriced usage, null if none can be priced."},"cost_per_conversation_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost Per Conversation Usd","description":"Service priced linked cost / its distinct priced linked conversations; cents, or null without a denominator."},"cost_share":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Cost Share","description":"Service priced subtotal / workspace-wide priced subtotal, even when service_id filters the response.\nNull if this service has no priced cost or the workspace denominator is zero or unavailable."},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any usage for this service is omitted from its priced subtotal."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens"}},"type":"object","required":["service_id","service_name","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens","calculated_cost_usd","cost_per_conversation_usd","cost_share","has_unpriced_usage","unpriced_tokens"],"title":"UsageCostService","description":"Production-classified usage and calculated cost for one service."},"UsageCostLatestClose":{"properties":{"close_month":{"type":"string","format":"date","title":"Close Month"},"status":{"type":"string","const":"complete","title":"Status"},"calculated_at":{"type":"string","format":"date-time","title":"Calculated At"},"calculation_run_id":{"type":"string","title":"Calculation Run Id"},"rate_card_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rate Card Version"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage"},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens"}},"type":"object","required":["close_month","status","calculated_at","calculation_run_id","rate_card_version","calculated_cost_usd","uncached_input_tokens","cached_input_tokens","output_tokens","has_unpriced_usage","unpriced_tokens"],"title":"UsageCostLatestClose","description":"Latest compatible completed monthly close, when available."}}}}
```

## The UsageCostOverviewTotals object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostOverviewTotals":{"properties":{"conversation_count":{"type":"integer","title":"Conversation Count","description":"Distinct linked conversations in the selected scope, not the sum of per-model counts."},"request_count":{"type":"integer","title":"Request Count","description":"Provider requests in the selected scope, including requests without a linked conversation."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Priced subtotal rounded to cents; excludes unpriced usage. Zero for no usage, null if none can be priced."},"cost_per_conversation_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost Per Conversation Usd","description":"Priced linked cost / distinct priced linked conversations; cents, or null without a denominator."},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any selected usage is omitted from the priced subtotal."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens","description":"Input and output tokens belonging to usage that could not be priced."}},"type":"object","required":["conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens","calculated_cost_usd","cost_per_conversation_usd","has_unpriced_usage","unpriced_tokens"],"title":"UsageCostOverviewTotals","description":"Production-classified usage and calculated cost totals."}}}}
```

## The UsageCostPeriod object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostPeriod":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"},"timezone":{"type":"string","const":"UTC","title":"Timezone"}},"type":"object","required":["start_date","end_date","timezone"],"title":"UsageCostPeriod","description":"Inclusive UTC calendar-date range covered by the report."}}}}
```

## The UsageCostService object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageCostService":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service identifier; null for unattributed usage."},"service_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Service Name","description":"Service name at the latest metadata refresh; null if unavailable. Unattributed for a null service ID."},"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"calculated_cost_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Calculated Cost Usd","description":"Service priced subtotal rounded to cents; excludes unpriced usage, null if none can be priced."},"cost_per_conversation_usd":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cost Per Conversation Usd","description":"Service priced linked cost / its distinct priced linked conversations; cents, or null without a denominator."},"cost_share":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Cost Share","description":"Service priced subtotal / workspace-wide priced subtotal, even when service_id filters the response.\nNull if this service has no priced cost or the workspace denominator is zero or unavailable."},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any usage for this service is omitted from its priced subtotal."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens"}},"type":"object","required":["service_id","service_name","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens","calculated_cost_usd","cost_per_conversation_usd","cost_share","has_unpriced_usage","unpriced_tokens"],"title":"UsageCostService","description":"Production-classified usage and calculated cost for one service."}}}}
```

## The UsageModelsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageModelsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"models":{"items":{"$ref":"#/components/schemas/ModelUsage"},"type":"array","title":"Models"}},"type":"object","required":["workspace_id","period","calculation_run_id","models"],"title":"UsageModelsResponse","description":"Usage grouped by model, returned for `group_by=model`."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"ModelUsage":{"properties":{"model_id":{"type":"string","title":"Model Id"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"request_count":{"type":"integer","title":"Request Count"},"calls_per_conversation":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Calls Per Conversation","description":"This model's linked requests / its distinct linked conversations in the selected scope; null if none."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["model_id","provider","request_count","calls_per_conversation","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ModelUsage","description":"Usage attributed to one model and provider."}}}}
```

## The UsageOverviewResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageOverviewResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"attribution":{"$ref":"#/components/schemas/UsageAttribution"},"totals":{"$ref":"#/components/schemas/UsageTotals"},"daily":{"items":{"$ref":"#/components/schemas/DailyUsage"},"type":"array","title":"Daily","description":"Daily usage ordered from oldest to newest."},"services":{"items":{"$ref":"#/components/schemas/ServiceUsage"},"type":"array","title":"Services","description":"Services ordered by descending input-token usage."}},"type":"object","required":["workspace_id","period","calculation_run_id","attribution","totals","daily","services"],"title":"UsageOverviewResponse","description":"Usage overview returned when `group_by` is omitted."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"UsageAttribution":{"properties":{"conversation_attribution_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Conversation Attribution Rate","description":"Linked requests divided by all requests; null when there are no requests."},"service_attribution_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Service Attribution Rate","description":"Service-attributed input tokens divided by all input tokens; null when there are none."}},"type":"object","required":["conversation_attribution_rate","service_attribution_rate"],"title":"UsageAttribution","description":"Coverage of conversation and service attribution."},"UsageTotals":{"properties":{"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any usage in the period could not be priced."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens","description":"Tokens excluded from calculated cost because no rate applied."}},"type":"object","required":["conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens","has_unpriced_usage","unpriced_tokens"],"title":"UsageTotals","description":"Workspace totals for the requested period."},"DailyUsage":{"properties":{"usage_date":{"type":"string","format":"date","title":"Usage Date"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["usage_date","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"DailyUsage","description":"Token usage for one calendar date."},"ServiceUsage":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service identifier, or null for usage that could not be attributed."},"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["service_id","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ServiceUsage","description":"Usage attributed to one service."}}}}
```

## The UsageResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageResponse":{"anyOf":[{"$ref":"#/components/schemas/UsageOverviewResponse"},{"$ref":"#/components/schemas/UsageModelsResponse"},{"$ref":"#/components/schemas/UsageClassesResponse"}]},"UsageOverviewResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"attribution":{"$ref":"#/components/schemas/UsageAttribution"},"totals":{"$ref":"#/components/schemas/UsageTotals"},"daily":{"items":{"$ref":"#/components/schemas/DailyUsage"},"type":"array","title":"Daily","description":"Daily usage ordered from oldest to newest."},"services":{"items":{"$ref":"#/components/schemas/ServiceUsage"},"type":"array","title":"Services","description":"Services ordered by descending input-token usage."}},"type":"object","required":["workspace_id","period","calculation_run_id","attribution","totals","daily","services"],"title":"UsageOverviewResponse","description":"Usage overview returned when `group_by` is omitted."},"Period":{"properties":{"start_date":{"type":"string","format":"date","title":"Start Date"},"end_date":{"type":"string","format":"date","title":"End Date"}},"type":"object","required":["start_date","end_date"],"title":"Period","description":"Inclusive calendar-date range covered by the report."},"UsageAttribution":{"properties":{"conversation_attribution_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Conversation Attribution Rate","description":"Linked requests divided by all requests; null when there are no requests."},"service_attribution_rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Service Attribution Rate","description":"Service-attributed input tokens divided by all input tokens; null when there are none."}},"type":"object","required":["conversation_attribution_rate","service_attribution_rate"],"title":"UsageAttribution","description":"Coverage of conversation and service attribution."},"UsageTotals":{"properties":{"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any usage in the period could not be priced."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens","description":"Tokens excluded from calculated cost because no rate applied."}},"type":"object","required":["conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens","has_unpriced_usage","unpriced_tokens"],"title":"UsageTotals","description":"Workspace totals for the requested period."},"DailyUsage":{"properties":{"usage_date":{"type":"string","format":"date","title":"Usage Date"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["usage_date","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"DailyUsage","description":"Token usage for one calendar date."},"ServiceUsage":{"properties":{"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"Service identifier, or null for usage that could not be attributed."},"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["service_id","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ServiceUsage","description":"Usage attributed to one service."},"UsageModelsResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"models":{"items":{"$ref":"#/components/schemas/ModelUsage"},"type":"array","title":"Models"}},"type":"object","required":["workspace_id","period","calculation_run_id","models"],"title":"UsageModelsResponse","description":"Usage grouped by model, returned for `group_by=model`."},"ModelUsage":{"properties":{"model_id":{"type":"string","title":"Model Id"},"provider":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Provider"},"request_count":{"type":"integer","title":"Request Count"},"calls_per_conversation":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Calls Per Conversation","description":"This model's linked requests / its distinct linked conversations in the selected scope; null if none."},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["model_id","provider","request_count","calls_per_conversation","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ModelUsage","description":"Usage attributed to one model and provider."},"UsageClassesResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace whose usage or cost is reported."},"period":{"$ref":"#/components/schemas/Period","description":"Inclusive requested date range."},"calculation_run_id":{"type":"string","format":"uuid","title":"Calculation Run Id","description":"Immutable published calculation run selected for the entire range."},"classes":{"items":{"$ref":"#/components/schemas/ClassUsage"},"type":"array","title":"Classes","description":"All recorded usage classes, including production and non-production, after any service filter."}},"type":"object","required":["workspace_id","period","calculation_run_id","classes"],"title":"UsageClassesResponse","description":"Usage grouped by usage class, returned for `group_by=class`."},"ClassUsage":{"properties":{"usage_class":{"type":"string","title":"Usage Class"},"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"}},"type":"object","required":["usage_class","conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens"],"title":"ClassUsage","description":"Usage attributed to one usage class."}}}}
```

## The UsageSummaryResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageSummaryResponse":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace identifier"},"period_start":{"type":"string","format":"date","title":"Period Start","description":"Start of the reporting period"},"period_end":{"type":"string","format":"date","title":"Period End","description":"End of the reporting period"},"buckets":{"items":{"$ref":"#/components/schemas/UsageBucket"},"type":"array","title":"Buckets","description":"Usage data grouped by event type and date"},"total_events":{"type":"integer","title":"Total Events","description":"Total number of events in the period"}},"type":"object","required":["workspace_id","period_start","period_end","buckets","total_events"],"title":"UsageSummaryResponse"},"UsageBucket":{"properties":{"event_type":{"type":"string","title":"Event Type","description":"World event type"},"event_date":{"type":"string","format":"date","title":"Event Date","description":"Date of the usage bucket"},"count":{"type":"integer","title":"Count","description":"Number of events in this bucket"},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds","description":"Average event duration in seconds"},"total_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Total Duration Seconds","description":"Total event duration in seconds"}},"type":"object","required":["event_type","event_date","count"],"title":"UsageBucket"}}}}
```

## The UsageTotals object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageTotals":{"properties":{"conversation_count":{"type":"integer","title":"Conversation Count"},"request_count":{"type":"integer","title":"Request Count"},"uncached_input_tokens":{"type":"integer","title":"Uncached Input Tokens"},"cached_input_tokens":{"type":"integer","title":"Cached Input Tokens"},"output_tokens":{"type":"integer","title":"Output Tokens"},"has_unpriced_usage":{"type":"boolean","title":"Has Unpriced Usage","description":"Whether any usage in the period could not be priced."},"unpriced_tokens":{"type":"integer","title":"Unpriced Tokens","description":"Tokens excluded from calculated cost because no rate applied."}},"type":"object","required":["conversation_count","request_count","uncached_input_tokens","cached_input_tokens","output_tokens","has_unpriced_usage","unpriced_tokens"],"title":"UsageTotals","description":"Workspace totals for the requested period."}}}}
```

## The UsageUnavailableResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UsageUnavailableResponse":{"properties":{"detail":{"type":"string","const":"Usage and cost data unavailable","title":"Detail"},"published_through":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Published Through","description":"Last usage date the workspace's latest published calculation covers, when the period ends after it.\n\nPresent when no complete calculation covers the period: null when nothing is published or publication\nalready reaches the period's end. Absent when the warehouse is unavailable."}},"type":"object","required":["detail"],"title":"UsageUnavailableResponse","description":"Usage is unavailable for the requested period."}}}}
```

## The UseCaseDialability object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UseCaseDialability":{"type":"string","enum":["own_number","listed","not_listed"]}}}}
```

## The ValidationError object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"}}}}
```

## The ValidationErrorResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ValidationErrorResponse":{"properties":{"detail":{"anyOf":[{"type":"string"},{"items":{"additionalProperties":true,"type":"object"},"type":"array"}],"title":"Detail"}},"type":"object","required":["detail"],"title":"ValidationErrorResponse","description":"The body of a 422.\n\n``detail`` is a string when a route refuses the request itself, and a list of error objects when\nthe request fails validation before the route runs."}}}}
```

## The VerificationSuccess object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."}}}}
```

## The VerifiesCaller-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VerifiesCaller-Input":{"properties":{"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the identifier of\nthe patient the caller verified as, such as ``/patient/id``: the identifier the service's reads\nname the patient by. Only a string there with more than whitespace in it verifies anyone, never a\nnumber, and never a value the model sent."},"success":{"$ref":"#/components/schemas/VerificationSuccess","description":"How the response says the caller verified: any 2xx (``http_status``), or a field holding the\nvalue that means they did (``field``). A response that doesn't say so verifies nobody, whatever\nidentifier it holds. The author vouches that it says so only once the caller proved who they are\n(a code checked, a name and date of birth matched), never on a lookup or a code sent, and that\n``patient`` names the patient the vendor matched, not a copy of something the request sent."}},"type":"object","required":["patient","success"],"title":"VerifiesCaller","description":"A successful call verifies the caller as one patient: the one its response names. Declaring it\nopens nothing: only a service that names the endpoint its verifier\n(``Service.caller_verification_endpoint_id``) verifies anyone by it."},"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."}}}}
```

## The VerifiesCaller-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VerifiesCaller-Output":{"properties":{"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the identifier of\nthe patient the caller verified as, such as ``/patient/id``: the identifier the service's reads\nname the patient by. Only a string there with more than whitespace in it verifies anyone, never a\nnumber, and never a value the model sent."},"success":{"$ref":"#/components/schemas/VerificationSuccess","description":"How the response says the caller verified: any 2xx (``http_status``), or a field holding the\nvalue that means they did (``field``). A response that doesn't say so verifies nobody, whatever\nidentifier it holds. The author vouches that it says so only once the caller proved who they are\n(a code checked, a name and date of birth matched), never on a lookup or a code sent, and that\n``patient`` names the patient the vendor matched, not a copy of something the request sent."}},"type":"object","required":["patient","success"],"title":"VerifiesCaller","description":"A successful call verifies the caller as one patient: the one its response names. Declaring it\nopens nothing: only a service that names the endpoint its verifier\n(``Service.caller_verification_endpoint_id``) verifies anyone by it."},"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."}}}}
```

## The VersionNumber object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VersionNumber":{"type":"integer","maximum":2147483647,"minimum":1}}}}
```

## The VersionSet-Input object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VersionSet-Input":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The VersionSet-Output object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VersionSet-Output":{"properties":{"agent_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Agent Version Number"},"context_graph_version_number":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Context Graph Version Number"},"llm_model_preferences":{"additionalProperties":{"$ref":"#/components/schemas/LLMConfig"},"type":"object","title":"Llm Model Preferences"},"dynamic_behavior_sets":{"anyOf":[{"items":{"$ref":"#/components/schemas/VersionSetBehaviorPin"},"type":"array","maxItems":254},{"type":"null"}],"title":"Dynamic Behavior Sets"}},"type":"object","title":"VersionSet","description":"Pins agent, state machine, LLM model and dynamic behavior versions for a service."},"LLMConfig":{"properties":{"llm_name":{"type":"string","title":"Llm Name"},"params":{"additionalProperties":true,"type":"object","title":"Params"},"experience_controls":{"anyOf":[{"$ref":"#/components/schemas/LLMExperienceControls"},{"type":"null"}]}},"type":"object","required":["llm_name"],"title":"LLMConfig"},"LLMExperienceControls":{"properties":{"reasoning_effort":{"anyOf":[{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},{"type":"null"}],"title":"Reasoning Effort"},"temperature":{"anyOf":[{"type":"number","maximum":2,"minimum":0},{"type":"null"}],"title":"Temperature"},"top_p":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Top P"}},"additionalProperties":false,"type":"object","title":"LLMExperienceControls","description":"Typed model-tuning controls for a version set's LLM preference.\n\n``params`` stays available as a provider-specific escape hatch. These three fields are the ones deployments\nuse. Token budgets are left out on purpose, so a version set cannot cut a response short by accident."},"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The VersionSetBehaviorPin object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VersionSetBehaviorPin":{"properties":{"set_id":{"type":"string","format":"uuid","title":"Set Id","description":"The library set. It belongs to the service's workspace and isn't archived."},"version":{"type":"integer","maximum":2147483647,"minimum":1,"title":"Version","description":"The version of the set the service runs. A later version of the set changes nothing until the pin moves."},"enabled":{"type":"boolean","title":"Enabled","description":"A disabled pin stays on the version set and is never offered.","default":true},"states":{"items":{"$ref":"#/components/schemas/NameString"},"type":"array","maxItems":200,"title":"States","description":"The action and data collection states it applies in. Empty: every one."}},"additionalProperties":false,"type":"object","required":["set_id","version"],"title":"VersionSetBehaviorPin","description":"One library set a version set uses, at one version."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The VersionSetStarts object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VersionSetStarts":{"properties":{"version_set":{"$ref":"#/components/schemas/ReadinessLabel"},"kinds":{"items":{"$ref":"#/components/schemas/StartKind"},"type":"array","title":"Kinds"},"kinds_known":{"type":"boolean","title":"Kinds Known","description":"False when the version set's family is unknown (families[].source is agent_missing): kinds is then empty and says nothing; a client offers no start from it and shows why."}},"type":"object","required":["version_set","kinds","kinds_known"],"title":"VersionSetStarts"},"ReadinessLabel":{"type":"string"},"StartKind":{"type":"string","enum":["text","test_call","app_session"]}}}}
```

## The Voice object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Voice":{"properties":{"id":{"type":"string","maxLength":256,"title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"language":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Language"},"category":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Category"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"preview_url":{"anyOf":[{"type":"string","maxLength":4096},{"type":"null"}],"title":"Preview Url"}},"type":"object","required":["id","name"],"title":"Voice"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The VoiceConfig object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceConfig":{"properties":{"voice_id":{"type":"string","title":"Voice Id"},"stability":{"type":"number","title":"Stability","default":0},"similarity_boost":{"type":"number","title":"Similarity Boost","default":0},"style":{"type":"number","title":"Style","default":0},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object","maxProperties":10},{"type":"null"}],"title":"Language Providers"},"session_provider":{"anyOf":[{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Session Provider"}},"type":"object","required":["voice_id"],"title":"VoiceConfig"},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."}}}}
```

## The VoiceDetail object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceDetail":{"properties":{"recording_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recording Path"},"twilio_recording_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Twilio Recording Sid"},"twilio_recording_duration":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Twilio Recording Duration"},"has_recording":{"type":"boolean","title":"Has Recording","default":false},"barge_in_events":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Barge In Events","default":[]},"states_visited":{"items":{"type":"string"},"type":"array","title":"States Visited","default":[]},"participants":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Participants","default":[]},"config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Config"},"call_analysis":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Call Analysis"},"forwarding":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Forwarding"},"escalation":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Escalation"},"safety":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Safety"},"quality_breakdown":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Quality Breakdown"},"risk_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Risk Summary"},"latency_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Latency Summary"},"conversation_metrics":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conversation Metrics"},"tool_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tool Summary"},"safety_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Safety Summary"},"operator_summary":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Operator Summary"},"safe_exit":{"anyOf":[{"$ref":"#/components/schemas/src__services__safe_exit_reader__SafeExit"},{"type":"null"}],"description":"The call's safe exit, from its ``call.minimal_risk`` event. Null when the call didn't take it."},"timeline":{"anyOf":[{"$ref":"#/components/schemas/ConversationTimeline"},{"type":"null"}],"description":"Where the call's lines sit in its recording, from the positions its turns carry, with the wait from each user message to the first reply. ``turn_index`` on its turns and segments is a position in this response's ``turns``, not a turn's own ``turn_index``, which counts exchanges. ``turn_id`` names that turn's exchange. A truncated read's timeline stops where its turns do. An agent line's span is from when its first audio was sent to when its last was, ahead of when the caller finished hearing it, so the timeline places no silence. Tool calls and state transitions record no position, so they stay on the turns. Null when no line has a recorded start and end."}},"type":"object","title":"VoiceDetail"},"src__services__safe_exit_reader__SafeExit":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger","description":"Why the call took the safe exit."},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome","description":"``mrc_transferred`` once the hand-off to the human line was placed, ``mrc_failed`` when the hand-off raised\n(the caller may still be on the line), else ``mrc_ended`` (hung up). The conversation's ``completion_reason``\nreads these as ``transferred`` and ``error``."},"lines_played":{"items":{"type":"string","enum":["disclosure","transfer","end","fallback_missed","hearing_failure"]},"type":"array","title":"Lines Played","description":"The script lines that played whole, in order. ``disclosure`` is the AI and recording notice."},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"The caller had heard all of the AI and recording notice before the exit began, so the exit did not\nplay it again. When false, the notice was heard only if ``lines_played`` holds ``disclosure``."},"trigger_description":{"type":"string","title":"Trigger Description","description":"``trigger`` in plain words.","readOnly":true}},"type":"object","required":["trigger","outcome","lines_played","disclosure_heard","trigger_description"],"title":"SafeExit","description":"The call's safe exit: the agent stopped and a fixed script handed the caller to a person or ended the call."},"ConversationTimeline":{"properties":{"turns":{"items":{"$ref":"#/components/schemas/TurnTimeline"},"type":"array","title":"Turns","description":"One entry per message whose speech has a recorded start and end: ``seek_to`` and ``active_start`` are where it starts and ``active_end`` where it ends, in seconds from the start of the recording."},"segments":{"items":{"$ref":"#/components/schemas/TimelineSegment"},"type":"array","title":"Segments","description":"Each placed line's speech (``caller_speech``, ``agent_speech``, ``filler``, or ``interrupted_speech`` for a reply the caller cut off; a filler stays ``filler`` when cut off, and its turn's ``filler_type`` and ``interrupted`` say both) and each ``processing_gap``: the wait from a user message's end to the first reply after it, when that reply started once the user had stopped. A line already playing when the user started answers an earlier message. Later lines start no wait: the caller had heard the agent, and an agent line's end is when its audio was sent, so the time after it isn't measured. A gap's ``e2e_ttfb_ms`` is the wait the caller heard, to the first filler that started after their line or to the reply. A wait is placed only where the user message, the reply and every line that played between them have a start and an end, so every gap ends at a line in ``turns``. Ordered by start, then end."},"avg_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Processing Gap Ms","description":"Mean of the placed processing gaps, in ms. Null when there are none."},"max_processing_gap_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Max Processing Gap Ms","description":"Longest placed processing gap, in ms. Null when there are none."},"avg_perceived_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Perceived Latency Ms","description":"Mean of the placed gaps' ``e2e_ttfb_ms``. Null when there are none."}},"type":"object","required":["turns","segments"],"title":"ConversationTimeline","description":"Where a voice call's lines sit in its recording, and the waits between them."},"TurnTimeline":{"properties":{"turn_index":{"type":"integer","title":"Turn Index","description":"The turn: its index in the response's ``turns`` on ``GET /conversations/{conversation_id}``,\nthe call-detail row the timeline was built from on ``GET /calls/{call_id}``."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on a turn\nbefore the first exchange."},"seek_to":{"type":"number","title":"Seek To"},"active_start":{"type":"number","title":"Active Start"},"active_end":{"type":"number","title":"Active End"}},"type":"object","required":["turn_index","seek_to","active_start","active_end"],"title":"TurnTimeline"},"TimelineSegment":{"properties":{"type":{"type":"string","enum":["agent_speech","barge_in","caller_speech","filler","filler_hesitation","filler_nav","greeting","interrupted_speech","processing_gap","silence","silence_check","state_transition","tool_call"],"title":"Type"},"lane":{"type":"string","enum":["agent","caller","events","operator","system","tool"],"title":"Lane"},"track":{"anyOf":[{"type":"string","enum":["agent","caller","operator","system","tool"]},{"type":"null"}],"title":"Track","description":"Actor-semantic display track for the segment. Inferred for legacy producers."},"lane_id":{"anyOf":[{"type":"string","maxLength":160,"minLength":1},{"type":"null"}],"title":"Lane Id","description":"Canonical lane id. Must match PlaybackTimeline.lanes[].id after platform normalization."},"order":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Order","description":"Canonical event order after platform time/lane normalization."},"actor":{"anyOf":[{"$ref":"#/components/schemas/TimelineActor"},{"type":"null"}],"description":"Actor responsible for the segment. Inferred for legacy producers."},"start":{"type":"number","title":"Start"},"end":{"type":"number","title":"End"},"label":{"type":"string","title":"Label"},"turn_index":{"type":"integer","title":"Turn Index","description":"The segment's turn: its index in the response's ``turns`` on\n``GET /conversations/{conversation_id}``, the call-detail row the timeline was built from on\n``GET /calls/{call_id}``, or -1 when no turn owns it (a silence, a barge-in)."},"turn_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Turn Id","description":"The conversation exchange the segment's turn belongs to, its ``turn_id``. Set on\n``GET /conversations/{conversation_id}``, null on ``GET /calls/{call_id}`` and on segments no\nexchange owns."},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Eot Confidence"},"audio_window_start":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window Start"},"audio_window_end":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Window End"},"engine_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Engine Ms"},"nav_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Nav Ms"},"render_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Render Ms"},"audio_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Ttfb Ms"},"e2e_ttfb_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"E2E Ttfb Ms"},"tool_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tool Name"},"call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Id"},"parent_call_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Call Id"},"integration_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Integration Name"},"endpoint_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Endpoint Name"},"protocol":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Protocol"},"succeeded":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Succeeded"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Ms"},"from_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"From State"},"to_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"To State"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State"}},"type":"object","required":["type","lane","start","end","label","turn_index"],"title":"TimelineSegment"},"TimelineActor":{"properties":{"kind":{"type":"string","enum":["agent","human","operator","system","tool"],"title":"Kind"},"role":{"type":"string","enum":["agent","caller","operator","runtime","state","tool"],"title":"Role"},"label":{"type":"string","title":"Label"},"participant_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Participant Id"}},"type":"object","required":["kind","role","label"],"title":"TimelineActor"}}}}
```

## The VoiceFamilyListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceFamilyListResponse":{"properties":{"families":{"items":{"$ref":"#/components/schemas/Family"},"type":"array","title":"Families"}},"type":"object","required":["families"],"title":"VoiceFamilyListResponse"},"Family":{"properties":{"id":{"type":"string","enum":["concurrence","gpt_realtime","eleven_realtime","gpt_live","grok_voice","phonic"],"title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"summary":{"$ref":"#/components/schemas/DescriptionString"},"standing":{"type":"string","enum":["current","to_be_deprecated"],"title":"Standing","description":"current, or to_be_deprecated: the family stays in service and gets fixes and improvements only."},"availability":{"$ref":"#/components/schemas/Availability"},"capabilities":{"$ref":"#/components/schemas/SessionCapabilities"},"config_key":{"anyOf":[{"type":"string","enum":["realtime","eleven_realtime","gpt_live","grok_voice","phonic"]},{"type":"null"}],"title":"Config Key"},"legacy_keys":{"items":{"type":"string","const":"realtime_voice"},"type":"array","title":"Legacy Keys"},"models":{"items":{"type":"string","maxLength":256},"type":"array","title":"Models"},"voices":{"anyOf":[{"$ref":"#/components/schemas/Voices"},{"type":"null"}]},"options":{"anyOf":[{"additionalProperties":true,"propertyNames":{"maxLength":256},"type":"object"},{"type":"null"}],"title":"Options"},"honored_settings":{"items":{"type":"string","maxLength":64},"type":"array","title":"Honored Settings","description":"The service settings this family reads, as dotted paths from the service (keyterms, voice_config.silence_policy). Saving any other setting is accepted, and the family ignores it."}},"type":"object","required":["id","name","summary","standing","availability","capabilities","config_key","legacy_keys","models","voices","options","honored_settings"],"title":"Family"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000},"Availability":{"properties":{"available":{"type":"boolean","title":"Available"},"reason":{"anyOf":[{"$ref":"#/components/schemas/AvailabilityReason"},{"type":"null"}]}},"type":"object","required":["available","reason"],"title":"Availability"},"AvailabilityReason":{"properties":{"code":{"type":"string","maxLength":128,"title":"Code"},"message":{"$ref":"#/components/schemas/DescriptionString"}},"type":"object","required":["code","message"],"title":"AvailabilityReason"},"SessionCapabilities":{"properties":{"multi_state":{"type":"boolean","title":"Multi State"},"dynamic_behaviors":{"type":"boolean","title":"Dynamic Behaviors"},"completion_navigation":{"type":"boolean","title":"Completion Navigation"},"channels":{"items":{"type":"string","enum":["app","phone","playground","test_call"]},"type":"array","title":"Channels"},"outbound_calls":{"type":"boolean","title":"Outbound Calls"},"operator_takeover":{"type":"boolean","title":"Operator Takeover"},"end_call":{"type":"boolean","title":"End Call"},"warm_transfer":{"type":"boolean","title":"Warm Transfer","default":false},"authored_lines":{"type":"string","enum":["tts","model_checked","clips"],"title":"Authored Lines","default":"clips"},"floor_enforced":{"type":"boolean","title":"Floor Enforced","default":false},"state_carrier":{"anyOf":[{"type":"string","enum":["session_update_and_note","note_only"]},{"type":"null"}],"title":"State Carrier"},"typed_guardrails":{"type":"boolean","title":"Typed Guardrails","default":false}},"type":"object","required":["multi_state","dynamic_behaviors","completion_navigation","channels","outbound_calls","operator_takeover","end_call","warm_transfer","authored_lines","floor_enforced","state_carrier","typed_guardrails"],"title":"SessionCapabilities"},"Voices":{"properties":{"listing":{"type":"string","enum":["static","vendor"],"title":"Listing"},"path":{"type":"string","maxLength":512,"title":"Path"}},"type":"object","required":["listing","path"],"title":"Voices"}}}}
```

## The VoiceJudgeRecentResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceJudgeRecentResponse":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"},"count":{"type":"integer","minimum":0,"title":"Count"},"items":{"items":{"$ref":"#/components/schemas/VoiceJudgeResultRow"},"type":"array","title":"Items"}},"type":"object","required":["service_id","count","items"],"title":"VoiceJudgeRecentResponse"},"VoiceJudgeResultRow":{"properties":{"call_sid":{"type":"string","maxLength":64,"title":"Call Sid"},"call_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Call Entity Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"latency_dead_air_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latency Dead Air Score"},"pronunciation_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pronunciation Score"},"clarity_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Clarity Score"},"filler_silence_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Filler Silence Score"},"interruption_handling_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Interruption Handling Score"},"audio_consistency_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Consistency Score"},"pacing_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pacing Score"},"warmth_tone_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Warmth Tone Score"},"accent_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Accent Quality Score"},"voice_identity_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Voice Identity Score"},"overall_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overall Score"},"critical_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Critical Count"},"flag_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Flag Count"},"warning_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Warning Count"},"judge_json":{"anyOf":[{"type":"string","maxLength":32768},{"type":"null"}],"title":"Judge Json","description":"Raw Gemini judge output (evidence quotes, per-dim severity). Intended for UI drill-in; opaque string. Capped at 32KB."},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"}},"type":"object","required":["call_sid"],"title":"VoiceJudgeResultRow","description":"One call's voice-judge scoring."}}}}
```

## The VoiceJudgeResultRow object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceJudgeResultRow":{"properties":{"call_sid":{"type":"string","maxLength":64,"title":"Call Sid"},"call_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Call Entity Id"},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id"},"latency_dead_air_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latency Dead Air Score"},"pronunciation_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pronunciation Score"},"clarity_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Clarity Score"},"filler_silence_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Filler Silence Score"},"interruption_handling_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Interruption Handling Score"},"audio_consistency_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Consistency Score"},"pacing_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pacing Score"},"warmth_tone_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Warmth Tone Score"},"accent_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Accent Quality Score"},"voice_identity_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Voice Identity Score"},"overall_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Overall Score"},"critical_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Critical Count"},"flag_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Flag Count"},"warning_count":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Warning Count"},"judge_json":{"anyOf":[{"type":"string","maxLength":32768},{"type":"null"}],"title":"Judge Json","description":"Raw Gemini judge output (evidence quotes, per-dim severity). Intended for UI drill-in; opaque string. Capped at 32KB."},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"}},"type":"object","required":["call_sid"],"title":"VoiceJudgeResultRow","description":"One call's voice-judge scoring."}}}}
```

## The VoiceListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceListResponse":{"properties":{"voices":{"items":{"$ref":"#/components/schemas/Voice"},"type":"array","maxItems":100,"title":"Voices"},"next_cursor":{"anyOf":[{"type":"string","maxLength":4096},{"type":"null"}],"title":"Next Cursor"}},"type":"object","required":["voices"],"title":"VoiceListResponse"},"Voice":{"properties":{"id":{"type":"string","maxLength":256,"title":"Id"},"name":{"$ref":"#/components/schemas/NameString"},"language":{"anyOf":[{"type":"string","maxLength":64},{"type":"null"}],"title":"Language"},"category":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Category"},"description":{"anyOf":[{"$ref":"#/components/schemas/DescriptionString"},{"type":"null"}]},"preview_url":{"anyOf":[{"type":"string","maxLength":4096},{"type":"null"}],"title":"Preview Url"}},"type":"object","required":["id","name"],"title":"Voice"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"DescriptionString":{"type":"string","maxLength":2000}}}}
```

## The VoiceMetrics object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceMetrics":{"properties":{"active_calls":{"type":"integer","title":"Active Calls","default":0},"active_escalated":{"type":"integer","title":"Active Escalated","default":0},"calls_today":{"type":"integer","title":"Calls Today","default":0},"avg_quality_score_today":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality Score Today"},"escalation_rate_today":{"type":"number","title":"Escalation Rate Today","default":0}},"type":"object","title":"VoiceMetrics"}}}}
```

## The VoiceQualityResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceQualityResponse":{"properties":{"call_sid":{"$ref":"#/components/schemas/NameString"},"call_date_utc":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Call Date Utc","description":"UTC day the call was recorded."},"pickup_to_first_audio_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Pickup To First Audio Ms","description":"Pickup to the first agent audio sent, in ms. Null when no agent audio was sent."},"heard_initial_response":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Heard Initial Response","description":"Whether any agent audio reached the caller. Null when the call has no turn rows."},"turn_count":{"type":"integer","title":"Turn Count","description":"Caller turns whose wait is measured.","default":0},"turn_latency_p50_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Turn Latency P50 Ms","description":"Median wait a caller heard, from their line's end to the first filler or reply."},"turn_latency_p95_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Turn Latency P95 Ms","description":"95th percentile of the same waits."},"total_silence_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Total Silence Ms","description":"Dead air the caller heard: pickup to first audio plus each measured wait."},"longest_silence_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longest Silence Ms","description":"The longest single stretch of that dead air."},"duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Duration Seconds","description":"Call duration from the call record."},"completion_reason":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}]},"ended_by":{"type":"string","enum":["caller","agent","transfer","system","unknown"],"title":"Ended By","description":"Who ended the call, read from the completion reason."},"abandoned":{"type":"boolean","title":"Abandoned","description":"The completion reason is abandoned, or the caller hung up without hearing any agent audio."},"computed_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Computed At"}},"type":"object","required":["call_sid","ended_by","abandoned"],"title":"VoiceQualityResponse","description":"What a caller experienced on one voice call, computed from its turn traces and call record.\n\nA metric the call did not record is null, never 0."},"NameString":{"maxLength":256,"minLength":1,"type":"string"}}}}
```

## The VoiceSettingsRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceSettingsRequest":{"properties":{"voice_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Voice Id"},"tone":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}],"title":"Tone"},"speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speed"},"volume":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Volume"},"language":{"anyOf":[{"type":"string","enum":["en","es","ar","fr","de","pt","zh","ja","ko","multilingual"]},{"type":"null"}],"title":"Language","description":"The language calls are spoken in when the caller's record names none. `multilingual` starts each call in English and follows the language the caller speaks."},"keyterms":{"anyOf":[{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":200},{"type":"null"}],"title":"Keyterms"},"pronunciation_dict_id":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Pronunciation Dict Id"},"sensitive_topics":{"anyOf":[{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":50},{"type":"null"}],"title":"Sensitive Topics"},"post_call_analysis_enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Post Call Analysis Enabled"},"stt_provider":{"anyOf":[{"type":"string","enum":["deepgram","openai","cartesia"]},{"type":"null"}],"title":"Stt Provider"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object"},{"type":"null"}],"title":"Language Providers","description":"TTS provider for each call language. Keys must be one of ar, de, en, es, fr, ja, ko, multilingual, pt, zh, with at most 10 entries. An empty map is refused; send null to clear the map."},"text_model":{"anyOf":[{"type":"string","maxLength":128},{"type":"null"}],"title":"Text Model"}},"type":"object","title":"VoiceSettingsRequest","description":"Voice experience control plane — PM-facing, high-level controls.\n\nControls the caller experience without exposing engineering internals.\nFiller speech and buffer tuning are always-on internals managed by\nengineering."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."}}}}
```

## The VoiceSettingsResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceSettingsResponse":{"properties":{"voice_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Voice Id"},"tone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tone"},"speed":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Speed"},"volume":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Volume"},"language":{"type":"string","title":"Language"},"keyterms":{"items":{"type":"string"},"type":"array","title":"Keyterms"},"pronunciation_dict_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pronunciation Dict Id"},"sensitive_topics":{"items":{"type":"string"},"type":"array","title":"Sensitive Topics"},"post_call_analysis_enabled":{"type":"boolean","title":"Post Call Analysis Enabled"},"stt_provider":{"anyOf":[{"type":"string","enum":["deepgram","openai","cartesia"]},{"type":"null"}],"title":"Stt Provider"},"tts_provider":{"anyOf":[{"type":"string","enum":["cartesia","elevenlabs"]},{"type":"null"}],"title":"Tts Provider"},"tts_config":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Tts Config"},"language_providers":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/LanguageProviderEntry"},"type":"object"},{"type":"null"}],"title":"Language Providers"},"text_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Text Model"}},"type":"object","required":["voice_id","tone","speed","volume","language","keyterms","pronunciation_dict_id","sensitive_topics","post_call_analysis_enabled","stt_provider","tts_provider","tts_config","text_model"],"title":"VoiceSettingsResponse","description":"Voice experience state — what the PM configured."},"LanguageProviderEntry":{"properties":{"provider":{"type":"string","enum":["cartesia","elevenlabs"],"title":"Provider"},"config":{"additionalProperties":true,"type":"object","maxProperties":20,"title":"Config"}},"type":"object","required":["provider"],"title":"LanguageProviderEntry","description":"Per-language TTS provider configuration."}}}}
```

## The VoiceUseCase object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceUseCase":{"properties":{"label":{"$ref":"#/components/schemas/ReadinessLabel"},"channel":{"anyOf":[{"$ref":"#/components/schemas/ReadinessLabel"},{"type":"null"}]},"available":{"type":"boolean","title":"Available"},"fallback_forwarding_number_set":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Fallback Forwarding Number Set","description":"Whether an inbound voice use case has a fallback forwarding number, where inbound calls forward when channel-manager does not answer. Informational: unset does not block a save. Null for an outbound or unavailable use case. The number itself is never returned."}},"type":"object","required":["label","channel","available","fallback_forwarding_number_set"],"title":"VoiceUseCase"},"ReadinessLabel":{"type":"string"}}}}
```

## The Voices object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"Voices":{"properties":{"listing":{"type":"string","enum":["static","vendor"],"title":"Listing"},"path":{"type":"string","maxLength":512,"title":"Path"}},"type":"object","required":["listing","path"],"title":"Voices"}}}}
```

## The WorkflowProgram object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkflowProgram":{"properties":{"kind":{"type":"string","const":"workflow","title":"Kind","default":"workflow"}},"additionalProperties":false,"type":"object","title":"WorkflowProgram","description":"The agent runs the context graph its service binds. Every agent version saved without a program is this."}}}}
```

## The WorkspaceBenchmarks object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceBenchmarks":{"properties":{"avg_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Quality Score"},"p50_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P50 Quality Score"},"p25_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P25 Quality Score"},"p75_quality_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"P75 Quality Score"},"total_calls":{"type":"integer","title":"Total Calls","default":0},"avg_duration_seconds":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Avg Duration Seconds"},"escalation_rate":{"type":"number","title":"Escalation Rate","default":0},"quality_distribution":{"additionalProperties":{"type":"integer"},"type":"object","title":"Quality Distribution","default":{}}},"type":"object","title":"WorkspaceBenchmarks","description":"Workspace-level call quality benchmarks for contextual comparison."}}}}
```

## The WorkspaceDataQueryItem object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceDataQueryItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"sql_template":{"type":"string","title":"Sql Template"},"parameters":{"items":{"$ref":"#/components/schemas/StoredParameter"},"type":"array","title":"Parameters"},"timeout_ms":{"type":"integer","title":"Timeout Ms"},"declarations":{"$ref":"#/components/schemas/DataQueryDeclarations","description":"What the query's author declares about its calls. A declaration it never made is null."},"last_invoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Invoked At"},"deployed_at":{"type":"string","format":"date-time","title":"Deployed At"},"deployed_by":{"type":"string","format":"uuid","title":"Deployed By"}},"type":"object","required":["id","name","description","sql_template","parameters","timeout_ms","declarations","deployed_at","deployed_by"],"title":"WorkspaceDataQueryItem","description":"Wire shape for the response of every read + create/update handler.\n\n``id`` (UUID) is the stable handle — every URL except list takes it.\n``name`` is the workspace-visible label (UNIQUE per workspace) and is\nstill what the LLM tool registry keys on (``wsq_<name>``), but it is\nnot the route identifier.\n\n``input_schema`` is deliberately NOT exposed — it is fully derivable\nfrom ``parameters[]``. UI consumers can build the JSON Schema view\nlocally if they need it."},"StoredParameter":{"properties":{"name":{"type":"string","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","title":"Description"},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Default"},"authorization_binding":{"anyOf":[{"$ref":"#/components/schemas/RoleGrantKeysBinding"},{"type":"null"}]},"authorization_binding_test_value":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Authorization Binding Test Value","description":"Canonical CSV resource keys used only by trusted playground execution when no live authorization block exists."}},"additionalProperties":false,"type":"object","required":["name","type","description"],"title":"StoredParameter","description":"One typed input parameter of a workspace data query.\n\nA null `default` marks the parameter as required: a call that omits it is refused, unless the parameter is\nbound by `authorization_binding`. Otherwise an omitted argument takes the default."},"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."},"DataQueryDeclarations":{"properties":{"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nparameters name (``params``, each one of the query's ``parameters``), the ones its rows hold\n(``response``, where ``records`` points into the rows the query returns, a list of objects keyed\nby column, so the empty pointer is every row), or none (``none``: practice data, such as\narticles, locations or opening hours). Null when undeclared: the voice agent then counts a\ncall's result as one that may hold a patient's record."},"freshness":{"anyOf":[{"$ref":"#/components/schemas/DataFreshness"},{"type":"null"}],"description":"None: rows are returned as they are, with no staleness."}},"type":"object","title":"DataQueryDeclarations","description":"What a data query's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses. A reader ignores a key it doesn't\nknow, so a later declaration never breaks an older reader."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"DataFreshness":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshness","description":"How fresh a query's rows must be to be stated as current."}}}}
```

## The WorkspaceListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/WorkspaceResponse"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"WorkspaceListResponse"},"WorkspaceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"backend_org_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Backend Org Id"},"membership_provisioning":{"type":"string","enum":["domain_policies","explicit"],"title":"Membership Provisioning"},"region":{"type":"string","title":"Region"},"connector_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connector Type"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"topic_modeling_enabled":{"type":"boolean","title":"Topic Modeling Enabled"},"delta_sharing_enabled":{"type":"boolean","title":"Delta Sharing Enabled"},"delta_sharing_mode":{"type":"string","enum":["open","databricks"],"title":"Delta Sharing Mode"},"delta_sharing_identifier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delta Sharing Identifier"},"provisioned_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Provisioned At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","slug","name","backend_org_id","membership_provisioning","region","connector_type","timezone","topic_modeling_enabled","delta_sharing_enabled","delta_sharing_mode","delta_sharing_identifier","provisioned_at","created_at","updated_at"],"title":"WorkspaceResponse"}}}}
```

## The WorkspaceModelListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceModelListResponse":{"properties":{"region":{"type":"string","enum":["us-east-1","ap-southeast-2","eu-central-1","ca-central-1"],"title":"Region"},"geography":{"type":"string","title":"Geography"},"data_residency":{"$ref":"#/components/schemas/DataResidency"},"items":{"items":{"$ref":"#/components/schemas/src__routes__workspace_models__WorkspaceModelListResponse__Item"},"type":"array","title":"Items"}},"type":"object","required":["region","geography","data_residency","items"],"title":"WorkspaceModelListResponse"},"DataResidency":{"type":"string","enum":["any","regional"]},"src__routes__workspace_models__WorkspaceModelListResponse__Item":{"properties":{"id":{"type":"string","title":"Id"},"family":{"$ref":"#/components/schemas/ProviderFamily"},"transport":{"$ref":"#/components/schemas/Transport"},"regional":{"type":"boolean","title":"Regional","description":"Whether every path this model's requests can take stays in the region's geography."},"usable_for":{"items":{"$ref":"#/components/schemas/ModelUse"},"type":"array","title":"Usable For"},"reasoning_efforts":{"anyOf":[{"items":{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},"type":"array"},{"type":"null"}],"title":"Reasoning Efforts","description":"The engage reasoning efforts a version set may set on this model here; unset runs the model's default.\nNone when its provider sets its own effort (Claude, Gemini) and a version set's is not sent. Empty when it\ncan run no engage tool round in this region (GPT-6 Astra and GPT-6.1 Sol where the gateway serves no\nResponses route)."}},"type":"object","required":["id","family","transport","regional","usable_for","reasoning_efforts"],"title":"Item"},"ProviderFamily":{"type":"string","enum":["anthropic","google","openai","xai"]},"Transport":{"type":"string","enum":["gateway","decisions","vertex","vertex_priority","vertex_batch","bedrock","openai_direct","voice_vendor"]},"ModelUse":{"type":"string","enum":["engage","skill"]}}}}
```

## The WorkspaceResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"slug":{"type":"string","title":"Slug"},"name":{"type":"string","title":"Name"},"backend_org_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Backend Org Id"},"membership_provisioning":{"type":"string","enum":["domain_policies","explicit"],"title":"Membership Provisioning"},"region":{"type":"string","title":"Region"},"connector_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Connector Type"},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"topic_modeling_enabled":{"type":"boolean","title":"Topic Modeling Enabled"},"delta_sharing_enabled":{"type":"boolean","title":"Delta Sharing Enabled"},"delta_sharing_mode":{"type":"string","enum":["open","databricks"],"title":"Delta Sharing Mode"},"delta_sharing_identifier":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Delta Sharing Identifier"},"provisioned_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Provisioned At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","slug","name","backend_org_id","membership_provisioning","region","connector_type","timezone","topic_modeling_enabled","delta_sharing_enabled","delta_sharing_mode","delta_sharing_identifier","provisioned_at","created_at","updated_at"],"title":"WorkspaceResponse"}}}}
```

## The WorldDashboardResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorldDashboardResponse":{"properties":{"entity_counts":{"$ref":"#/components/schemas/EntityStatsSummary"},"events_24h":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Events 24H","description":"Event count from the event summary; null when the summary is empty or unavailable."},"events_7d":{"anyOf":[{"type":"integer","minimum":0},{"type":"null"}],"title":"Events 7D","description":"Event count from the event summary; null when the summary is empty or unavailable."},"avg_confidence":{"anyOf":[{"type":"number","maximum":1,"minimum":0},{"type":"null"}],"title":"Avg Confidence"},"event_read_model_status":{"type":"string","enum":["ready","empty","unavailable"],"title":"Event Read Model Status","description":"ready = the summary returned a row; empty = no summary row; unavailable = read failed.","default":"empty"},"event_read_model_synced_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Event Read Model Synced At","description":"The time the workspace's event velocity summary was last synced."},"sources":{"items":{"$ref":"#/components/schemas/SourceBreakdownItem"},"type":"array","maxItems":500,"title":"Sources"}},"type":"object","required":["entity_counts"],"title":"WorldDashboardResponse"},"EntityStatsSummary":{"properties":{"total_entities":{"type":"integer","title":"Total Entities"},"total_events":{"type":"integer","title":"Total Events"},"sync_pending":{"type":"integer","title":"Sync Pending"},"sync_synced":{"type":"integer","title":"Sync Synced"},"sync_failed":{"type":"integer","title":"Sync Failed"},"by_event_type":{"additionalProperties":{"type":"integer"},"type":"object","title":"By Event Type"}},"type":"object","required":["total_entities","total_events","sync_pending","sync_synced","sync_failed"],"title":"EntityStatsSummary"},"SourceBreakdownItem":{"properties":{"source_system":{"type":"string","title":"Source System"},"entity_type":{"type":"string","title":"Entity Type"},"count":{"type":"integer","title":"Count"}},"type":"object","required":["source_system","entity_type","count"],"title":"SourceBreakdownItem"}}}}
```

## The WorldScope object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorldScope":{"properties":{"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"scoped_entity_ids":{"items":{"type":"string","format":"uuid"},"type":"array","title":"Scoped Entity Ids","default":[]},"allow_create":{"type":"boolean","title":"Allow Create","default":false}},"type":"object","required":["workspace_id"],"title":"WorldScope","description":"The world slice — ids only (the leaf stays I/O-free). This is the\nread/subject scope, NOT the write bound (see ``write_floor``).\n``allow_create`` records context intent and is not an authorization grant."}}}}
```

## The WrapUpRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WrapUpRequest":{"properties":{"call_sid":{"type":"string","maxLength":64,"minLength":1,"title":"Call Sid"},"outcome":{"type":"string","enum":["resolved","escalated","transferred"],"title":"Outcome"},"notes":{"type":"string","maxLength":2000,"title":"Notes","default":""}},"type":"object","required":["call_sid","outcome"],"title":"WrapUpRequest","description":"Request to record operator intervention wrap-up."}}}}
```

## The WrapUpResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WrapUpResponse":{"properties":{"success":{"type":"boolean","title":"Success"}},"type":"object","required":["success"],"title":"WrapUpResponse"}}}}
```

## The WriteFloor object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WriteFloor":{"properties":{"enforced_at":{"type":"string","title":"Enforced At","default":"mcp-world-tools-edge"},"requires_entity_anchor":{"type":"boolean","title":"Requires Entity Anchor","default":true},"clinical_write_principal":{"type":"string","title":"Clinical Write Principal","default":"provider-only"},"clinical_write_scope":{"type":"string","title":"Clinical Write Scope","default":"any-entity-in-workspace"},"enrichment_write_scope":{"type":"string","title":"Enrichment Write Scope","default":"caller-anchor-only"},"unanchored_or_api_key_writes":{"type":"string","title":"Unanchored Or Api Key Writes","default":"none"},"allow_create":{"type":"boolean","title":"Allow Create","default":false}},"type":"object","title":"WriteFloor","description":"A static summary of the MCP write policy.\n\nThe MCP edge resolves the caller's actual principal and enforces the\nresult. These fields do not grant write access: API-key and unanchored\ncallers get no writes."}}}}
```

## The WriteKind object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]}}}}
```

## The WriteSuccess object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."}}}}
```

## The \_Access object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_Access":{"type":"string","enum":["read","write"]}}}}
```

## The \_AgentSortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_AgentSortField":{"type":"string","enum":["name","created_at","updated_at"]}}}}
```

## The \_CaseSortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_CaseSortField":{"type":"string","enum":["created_at","updated_at","description"]}}}}
```

## The \_DatasetSlug object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_DatasetSlug":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$"}}}}
```

## The \_DatasetUpdateStatus object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_DatasetUpdateStatus":{"type":"string","enum":["checking_drive","preparing","publishing","completed","needs_review","failed"]}}}}
```

## The \_DayHours object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_DayHours":{"properties":{"start":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$","title":"Start"},"end":{"type":"string","pattern":"^([01]\\d|2[0-3]):[0-5]\\d$","title":"End"}},"type":"object","required":["start","end"],"title":"_DayHours","description":"Open-hours window for one weekday. Times in 24h ``HH:MM`` form,\ninterpreted in the rule set's ``timezone``."}}}}
```

## The \_FieldName object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_FieldName":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[A-Za-z_][A-Za-z0-9_]*$"}}}}
```

## The \_FileStatus object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_FileStatus":{"type":"string","enum":["received","scanned","processing","curated","rejected","failed","held"]}}}}
```

## The \_FileType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_FileType":{"type":"string","maxLength":16,"minLength":1,"pattern":"^[a-z0-9]+$"}}}}
```

## The \_ResourceType object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_ResourceType":{"type":"string","enum":["integration_endpoint","skill","kb_scope"]}}}}
```

## The \_RunSortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_RunSortField":{"type":"string","const":"created_at"}}}}
```

## The \_SourceEventSortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_SourceEventSortField":{"type":"string","enum":["ingested_at","event_type","confidence"]}}}}
```

## The \_ToolMockKey object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_ToolMockKey":{"type":"string","maxLength":128,"minLength":1}}}}
```

## The \_ToolMockValue object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_ToolMockValue":{"type":"string","maxLength":16384}}}}
```

## The \_TurnRole object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_TurnRole":{"type":"string","enum":["agent","user","system"]}}}}
```

## The \_VolumePath object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"_VolumePath":{"type":"string","maxLength":1024,"minLength":1,"pattern":"^[A-Za-z0-9/._-]+$"}}}}
```

## The platform\_lib\_\_calls\_\_evidence\_\_CallEvidence\_\_SafeExit object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"platform_lib__calls__evidence__CallEvidence__SafeExit":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger"},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome"},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"Whether the disclosure completed before or during the exit."},"transfer_attempted":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Transfer Attempted"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp"}},"type":"object","required":["trigger","outcome","disclosure_heard"],"title":"SafeExit"}}}}
```

## The platform\_lib\_\_platform\_functions\_\_models\_\_Parameter object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"platform_lib__platform_functions__models__Parameter":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","maxLength":512,"minLength":1,"title":"Description"},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Default"},"authorization_binding":{"anyOf":[{"$ref":"#/components/schemas/RoleGrantKeysBinding"},{"type":"null"}]},"authorization_binding_test_value":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Authorization Binding Test Value","description":"Canonical CSV resource keys used only by trusted function-test or playground execution when no live authorization block exists."}},"additionalProperties":false,"type":"object","required":["name","type","description"],"title":"Parameter","description":"Typed declaration of one input parameter.\n\nFor SQL function types, ``name`` becomes the ``:name`` placeholder\nin the SQL template. For Python function types, ``name`` becomes\nthe positional argument name in ``def main(...)`` and the input\ncolumn name on the UC UDF signature.\n\nThe ``description`` propagates into the LLM tool spec (this is\nwhat Databricks' Agent Framework reads, and what Anthropic's\ntool-use spec exposes to the model). Missing descriptions\nsilently break tool selection — the registration layer rejects\nempty strings."},"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."}}}}
```

## The src\_\_models\_\_IntegrationToolRef object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__models__IntegrationToolRef":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string","maxLength":256,"minLength":1},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","maxProperties":50,"title":"Skill Input Bindings","description":"Endpoint parameter -> parent skill input mappings injected at dispatch."}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef","description":"Reference to an integration endpoint by integration + endpoint name."}}}}
```

## The src\_\_models\_\_StaticToolDef object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__models__StaticToolDef":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef","description":"A built-in tool available to companion agents."}}}}
```

## The src\_\_routes\_\_api\_keys\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__api_keys___SortField":{"type":"string","const":"created_at"}}}}
```

## The src\_\_routes\_\_audit\_\_AuditEventResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__audit__AuditEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Unique audit event identifier"},"workspace_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Workspace Id","description":"Workspace that owns this event; null for pre-workspace events (e.g. login)"},"timestamp":{"type":"string","title":"Timestamp","description":"ISO-8601 timestamp of the event"},"service":{"type":"string","title":"Service","description":"Service that produced the event"},"actor_entity_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Actor Entity Id","description":"Entity ID of the actor who performed the action"},"actor_credential_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Actor Credential Id","description":"Credential ID used by the actor"},"action":{"type":"string","title":"Action","description":"Action that was performed (e.g. 'entity.read')"},"resource_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Type","description":"Type of resource that was accessed"},"resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Id","description":"ID of the accessed resource"},"resource_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Resource Name","description":"Human-readable name of the accessed resource"},"ip_address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ip Address","description":"IP address of the actor"},"user_agent":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"User Agent","description":"User-Agent header from the request"},"metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Metadata","description":"Additional event-specific metadata"},"phi_accessed":{"type":"boolean","title":"Phi Accessed","description":"Whether protected health information was accessed","default":false}},"type":"object","required":["id","timestamp","service","action"],"title":"AuditEventResponse"}}}}
```

## The src\_\_routes\_\_context\_graphs\_\_context\_graph\_crud\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__context_graphs__context_graph_crud___SortField":{"type":"string","enum":["name","created_at","updated_at"]}}}}
```

## The src\_\_routes\_\_conversations\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__conversations___SortField":{"type":"string","enum":["turn_index","timestamp"]}}}}
```

## The src\_\_routes\_\_dynamic\_behavior\_sets\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__dynamic_behavior_sets___SortField":{"type":"string","enum":["name","updated_at"]}}}}
```

## The src\_\_routes\_\_external\_auth\_claim\_mappings\_\_CreateRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_auth_claim_mappings__CreateRequest":{"properties":{"claim_namespace":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_.:-]{0,63}$","title":"Claim Namespace"},"claim_key":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_.:-]{0,63}$","title":"Claim Key"},"external_value":{"type":"string","maxLength":256,"minLength":1,"title":"External Value"},"external_role_id":{"type":"string","format":"uuid","title":"External Role Id"}},"additionalProperties":false,"type":"object","required":["claim_namespace","claim_key","external_value","external_role_id"],"title":"CreateRequest"}}}}
```

## The src\_\_routes\_\_external\_auth\_claim\_mappings\_\_ListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_auth_claim_mappings__ListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ClaimMappingItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ListResponse"},"ClaimMappingItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"claim_namespace":{"type":"string","title":"Claim Namespace"},"claim_key":{"type":"string","title":"Claim Key"},"external_value":{"type":"string","title":"External Value"},"external_role_id":{"type":"string","format":"uuid","title":"External Role Id"},"status":{"type":"string","enum":["active","superseded"],"title":"Status"},"changed_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Changed By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","claim_namespace","claim_key","external_value","external_role_id","status","created_at"],"title":"ClaimMappingItem"}}}}
```

## The src\_\_routes\_\_external\_auth\_claim\_mappings\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_auth_claim_mappings___SortField":{"type":"string","const":"created_at"}}}}
```

## The src\_\_routes\_\_external\_identity\_bindings\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_identity_bindings___SortField":{"type":"string","enum":["created_at","external_subject_key"]}}}}
```

## The src\_\_routes\_\_external\_integrations\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_integrations___SortField":{"type":"string","enum":["created_at","name","updated_at"]}}}}
```

## The src\_\_routes\_\_external\_role\_assignments\_\_ListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_role_assignments__ListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ExternalRoleAssignmentItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ListResponse"},"ExternalRoleAssignmentItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"source":{"type":"string","title":"Source"},"external_subject_key":{"type":"string","title":"External Subject Key"},"external_subject_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Subject Id"},"entity_id":{"type":"string","format":"uuid","title":"Entity Id"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Display Name"},"roles":{"items":{"type":"string"},"type":"array","title":"Roles"},"roles_verified":{"type":"boolean","title":"Roles Verified"},"status":{"type":"string","enum":["active","suspended","revoked"],"title":"Status"},"provisioned_via":{"type":"string","enum":["roster_sync","jit"],"title":"Provisioned Via"},"last_verified_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Verified At"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","source","external_subject_key","entity_id","roles","roles_verified","status","provisioned_via","created_at","updated_at"],"title":"ExternalRoleAssignmentItem"}}}}
```

## The src\_\_routes\_\_external\_role\_assignments\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_role_assignments___SortField":{"type":"string","enum":["created_at","external_subject_key"]}}}}
```

## The src\_\_routes\_\_external\_roles\_\_CreateRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_roles__CreateRequest":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,63}$","title":"Name"},"external_name":{"type":"string","maxLength":256,"minLength":1,"title":"External Name"},"description":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Description"}},"additionalProperties":false,"type":"object","required":["name","external_name"],"title":"CreateRequest"}}}}
```

## The src\_\_routes\_\_external\_roles\_\_ListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_roles__ListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/ExternalRoleItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ListResponse"},"ExternalRoleItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"external_name":{"type":"string","title":"External Name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"updated_at":{"type":"string","format":"date-time","title":"Updated At"}},"type":"object","required":["id","name","external_name","created_at","updated_at"],"title":"ExternalRoleItem","description":"Wire shape for read + create responses."}}}}
```

## The src\_\_routes\_\_external\_roles\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_roles___SortField":{"type":"string","const":"created_at"}}}}
```

## The src\_\_routes\_\_external\_write\_proposals\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__external_write_proposals___SortField":{"type":"string","const":"created_at"}}}}
```

## The src\_\_routes\_\_harness\_platform\_\_HarnessReleaseListResponse\_\_Item object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__harness_platform__HarnessReleaseListResponse__Item":{"properties":{"kind":{"$ref":"#/components/schemas/HarnessKind"},"harness":{"type":"string","title":"Harness"},"repo":{"type":"string","title":"Repo"},"tag":{"type":"string","title":"Tag"},"asset":{"type":"string","title":"Asset"},"sha256":{"type":"string","title":"Sha256"},"contract_version":{"type":"string","title":"Contract Version"},"harness_version":{"type":"string","title":"Harness Version"},"conformance":{"type":"string","title":"Conformance"},"refusal":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refusal","description":"Why the platform may not run it (revoked, an unsupported contract, conformance not ``pass``), or None when a\npin or a default may name it."},"baked":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Baked","description":"Whether the running agent-engine image carries it, None when agent-engine could not say. A pin or a default\nnaming a release the image does not carry is refused until agent-engine's CD deploys it."}},"type":"object","required":["kind","harness","repo","tag","asset","sha256","contract_version","harness_version","conformance","refusal","baked"],"title":"Item"},"HarnessKind":{"type":"string","enum":["voice","text"]}}}}
```

## The src\_\_routes\_\_integrations\_\_create\_endpoint\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__integrations__create_endpoint__Request":{"properties":{"name":{"type":"string","maxLength":128,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Name","description":"Slug-like identifier, immutable post-create."},"description":{"type":"string","maxLength":2048,"minLength":1,"title":"Description","description":"LLM-facing description shown in the tool definition."},"method":{"type":"string","enum":["GET","POST","PUT","PATCH","DELETE"],"title":"Method","description":"HTTP method.","default":"POST"},"path":{"type":"string","maxLength":2048,"minLength":1,"pattern":"^[^/]","title":"Path","description":"URL path appended to the integration's base_url. Must NOT start with `/` — the path is\njoined onto the base URL (which already carries the leading slash). Supports `{param}` substitution."},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","description":"JSON Schema describing the tool's input arguments."},"headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Headers","description":"Request headers. An exact ``$param.<name>`` value binds and consumes an input parameter."},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields","description":"Static body fields merged into POST/PUT/PATCH bodies. Keys are RFC 6901 JSON Pointers\n(e.g. ``/meta/tool_name`` for nested, ``/foo`` for a root-level field)."},"body_format":{"type":"string","enum":["json","form"],"title":"Body Format","description":"Outbound body encoding for write methods.","default":"json"},"response_template":{"anyOf":[{"type":"string","maxLength":16384},{"type":"null"}],"title":"Response Template","description":"Jinja template (sandboxed, StrictUndefined) rendered against the parsed JSON response."},"client_output":{"anyOf":[{"$ref":"#/components/schemas/ClientOutputConfig"},{"type":"null"}],"description":"Optional external-user-safe output contract. Uses response_template as its projection."},"declarations":{"$ref":"#/components/schemas/EndpointDeclarations-Input","description":"What the endpoint's author declares about its calls. Leave a declaration out when unknown:\nwith no `writes`, the voice agent never treats the endpoint's calls as a booking or cancellation."},"max_response_length":{"type":"integer","maximum":1000000,"minimum":0,"title":"Max Response Length","description":"Truncate the rendered string to this many chars. 0 = no truncation.","default":0},"timeout_seconds":{"type":"number","maximum":600,"exclusiveMinimum":0,"title":"Timeout Seconds","description":"Per-request timeout.","default":30},"max_retries":{"type":"integer","maximum":10,"minimum":0,"title":"Max Retries","description":"How many times a failed call goes out again. A read goes again after a status in `retry_on_status`,\na timeout or a connection that failed. A write goes again only after a 429 or 503 that\n`retry_on_status` lists, or a connection that never opened. Integration writes carry no idempotency key, so a write\nthat timed out, lost its connection or got any other status may already have been made, and isn't\nsent again. A write is a call to an endpoint that declares `declarations.writes` of any kind but\n`none`, or declares nothing and uses POST, PUT, PATCH or DELETE. An endpoint that only reads over\nPOST can declare `declarations.writes.kind` `none` to retry like a read.","default":2},"retry_on_status":{"items":{"type":"integer"},"type":"array","maxItems":20,"uniqueItems":true,"title":"Retry On Status","description":"HTTP statuses after which a failed call goes out again, up to `max_retries` times. A write goes\nagain only after a 429 or 503 listed here: any other status, 502 and 504 included, can follow a\nwrite the vendor made, so a write that gets one isn't sent again. An endpoint that only reads over\nPOST can declare `declarations.writes.kind` `none` to retry on every status listed here."}},"type":"object","required":["name","description","path"],"title":"Request","description":"Add a new endpoint to a REST integration."},"ClientOutputConfig":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"json_schema":{"additionalProperties":true,"type":"object","title":"Json Schema"},"max_bytes":{"type":"integer","maximum":262144,"minimum":1,"title":"Max Bytes","default":262144},"external_user_enabled":{"type":"boolean","title":"External User Enabled","default":false}},"type":"object","required":["type","schema_version","json_schema"],"title":"ClientOutputConfig","description":"External-user-safe projection contract for a direct integration endpoint.\n\nThe endpoint's existing ``response_template`` performs the projection. With no\ntemplate, the parsed upstream JSON body is emitted unchanged."},"EndpointDeclarations-Input":{"properties":{"writes":{"anyOf":[{"$ref":"#/components/schemas/EndpointWrites-Input"},{"type":"null"}],"description":"What a successful call writes and how its response reports it. Null when undeclared: the\nvoice agent then never treats the endpoint's calls as a booking or cancellation."},"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nrequest names (``params``), the ones its response holds (``response``), or none (``none``).\nNull when undeclared."},"verifies":{"anyOf":[{"$ref":"#/components/schemas/VerifiesCaller-Input"},{"type":"null"}],"description":"How a successful call verifies the caller, and as which patient, for a service that names\nthis endpoint its verifier (``Service.caller_verification_endpoint_id``). Null when undeclared:\na call verifies nobody."}},"type":"object","title":"EndpointDeclarations","description":"What an endpoint's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses."},"EndpointWrites-Input":{"properties":{"kind":{"$ref":"#/components/schemas/EndpointWriteKind","description":"What the write does, ``none`` when the endpoint never writes, ``varies`` when the\ncompanion skill that calls it says, or ``verification`` for a step that verifies the caller\nby sending or checking a one-time code, which the voice agent runs without asking the caller\nto agree or read back its destination first."},"success":{"anyOf":[{"$ref":"#/components/schemas/WriteSuccess"},{"type":"null"}],"description":"How the response says the write happened. Required unless ``kind`` is ``none``. A ``field`` or\n``graphql`` rule reads the write from the body: the member the pointer names, in a JSON object or\narray or a form-encoded body, or a GraphQL response's ``errors`` or ``data``. A 2xx whose body\ndoesn't hold it, such as an HTML page, plain text, an empty 204, JSON that doesn't parse, JSON\nwithout the field, or JSON that isn't a GraphQL response, such as a gateway's own, leaves the\nwrite's outcome unknown: the vendor may have made it. So does a GraphQL answer with errors\nthat neither says the mutation was refused or never ran nor holds its result, such as a payload\nnulled by an error below the mutation's field, which came after the write, an error with no\npath beside ``data``, or a null ``data`` in a document of more than one mutation, which hides\nwhat the ones before the failing one did. A field with another value, or a GraphQL error at the\nmutation's own field, with that field null, or in an answer with no ``data``, is a write that\ndidn't happen."}},"type":"object","required":["kind"],"title":"EndpointWrites","description":"What a successful call to an endpoint writes, and how its response reports the write."},"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]},"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"VerifiesCaller-Input":{"properties":{"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the identifier of\nthe patient the caller verified as, such as ``/patient/id``: the identifier the service's reads\nname the patient by. Only a string there with more than whitespace in it verifies anyone, never a\nnumber, and never a value the model sent."},"success":{"$ref":"#/components/schemas/VerificationSuccess","description":"How the response says the caller verified: any 2xx (``http_status``), or a field holding the\nvalue that means they did (``field``). A response that doesn't say so verifies nobody, whatever\nidentifier it holds. The author vouches that it says so only once the caller proved who they are\n(a code checked, a name and date of birth matched), never on a lookup or a code sent, and that\n``patient`` names the patient the vendor matched, not a copy of something the request sent."}},"type":"object","required":["patient","success"],"title":"VerifiesCaller","description":"A successful call verifies the caller as one patient: the one its response names. Declaring it\nopens nothing: only a service that names the endpoint its verifier\n(``Service.caller_verification_endpoint_id``) verifies anyone by it."},"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}}}}}
```

## The src\_\_routes\_\_integrations\_\_create\_integration\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__integrations__create_integration__Request":{"properties":{"name":{"type":"string","maxLength":128,"minLength":2,"pattern":"^[a-z0-9][a-z0-9_-]*[a-z0-9]$","title":"Name","description":"Slug-like identifier, lowercase alphanumeric + hyphens/underscores. Immutable post-create."},"display_name":{"$ref":"#/components/schemas/NameString","description":"Human-readable name."},"base_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Base Url","description":"Base URL for the upstream REST API."},"auth":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/StaticHeaderAuthRequest"},{"$ref":"#/components/schemas/OAuth2ClientCredentialsAuthRequest"},{"$ref":"#/components/schemas/OAuth2JwtBearerAuthRequest"},{"$ref":"#/components/schemas/CustomTokenExchangeAuthRequest"}],"discriminator":{"propertyName":"type","mapping":{"custom_token_exchange":"#/components/schemas/CustomTokenExchangeAuthRequest","oauth2_client_credentials":"#/components/schemas/OAuth2ClientCredentialsAuthRequest","oauth2_jwt_bearer":"#/components/schemas/OAuth2JwtBearerAuthRequest","static_header":"#/components/schemas/StaticHeaderAuthRequest"}}},{"type":"null"}],"title":"Auth","description":"Auth configuration. When set, ``secret_value`` is required."},"secret_value":{"anyOf":[{"type":"string","maxLength":8192,"minLength":1},{"type":"null"}],"title":"Secret Value","description":"Inline secret literal — auto-provisioned to the per-integration SSM path.\nRequired when ``auth`` is set. Bounded to fit a PEM RSA-4096 key + cert chain."},"enabled":{"type":"boolean","title":"Enabled","description":"Whether the integration is active on create.","default":true},"managed":{"type":"boolean","title":"Managed","description":"Whether this is a system-managed integration protected from workspace CRUD.","default":false},"approval_policy":{"type":"string","enum":["none","writes","all"],"title":"Approval Policy","description":"Human-in-the-loop approval gate. ``none`` (default) = no approval\nrequired; ``writes`` = approval required for an endpoint that may write: one\nthat uses POST, PUT, PATCH or DELETE, or declares ``declarations.writes`` of any\nkind but ``none``, whatever its method; ``all`` = approval required for every\nendpoint.","default":"none"}},"type":"object","required":["name","display_name","base_url"],"title":"Request","description":"Create body — REST only."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"StaticHeaderAuthRequest":{"properties":{"type":{"type":"string","const":"static_header","title":"Type","default":"static_header"},"header_name":{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$","title":"Header Name","description":"Outbound header name (RFC 7230 tchar)."}},"type":"object","required":["header_name"],"title":"StaticHeaderAuthRequest","description":"Static workspace-level secret used verbatim as a single header value."},"OAuth2ClientCredentialsAuthRequest":{"properties":{"type":{"type":"string","const":"oauth2_client_credentials","title":"Type","default":"oauth2_client_credentials"},"token_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Token Url"},"client_id":{"type":"string","title":"Client Id"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"client_auth_method":{"type":"string","enum":["basic","body"],"title":"Client Auth Method","description":"RFC 6749 § 2.3.1: ``basic`` sends client_id+secret as HTTP Basic auth; ``body`` sends them in the form body.","default":"basic"}},"type":"object","required":["token_url","client_id"],"title":"OAuth2ClientCredentialsAuthRequest","description":"OAuth 2.0 Client Credentials Grant — RFC 6749 § 4.4.\n\nStrict RFC 6749 § 4.4.2 access token request: ``grant_type`` + optional\n``scope``. Client authentication (RFC 6749 § 2.3.1) is orthogonal —\n``client_auth_method`` picks between HTTP Basic auth and form-body\ncredentials. RFC 8707 ``resource`` and non-standard ``audience`` extensions\nare NOT supported here — add them back when a vendor needs one."},"OAuth2JwtBearerAuthRequest":{"properties":{"type":{"type":"string","const":"oauth2_jwt_bearer","title":"Type","default":"oauth2_jwt_bearer"},"token_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Token Url"},"assertion_issuer":{"type":"string","title":"Assertion Issuer","description":"RFC 7523 ``iss`` claim — typically the service-account email or client_id."},"assertion_audience":{"type":"string","title":"Assertion Audience","description":"RFC 7523 ``aud`` claim — typically the token_url."},"assertion_subject":{"type":"string","title":"Assertion Subject","description":"RFC 7523 § 3 ``sub`` claim — MUST be present. For service-account flows\nwhere the client is its own subject, set to the same value as ``assertion_issuer``.\nUse a different value only for delegation / impersonation grants."},"assertion_lifetime_seconds":{"type":"integer","title":"Assertion Lifetime Seconds","default":3600},"include_iat":{"type":"boolean","title":"Include Iat","description":"RFC 7523 § 3 item 6 — ``iat`` claim set to mint time. Most IdPs (Google, Azure)\nrequire it for anti-replay; leave True unless a specific vendor rejects it.","default":true},"include_jti":{"type":"boolean","title":"Include Jti","description":"When True, generate a fresh ``jti`` (anti-replay) on every mint.","default":true},"assertion_algorithm":{"type":"string","enum":["RS256","RS384","RS512","PS256","PS384","PS512","ES256","ES384","ES512"],"title":"Assertion Algorithm","default":"RS256"},"assertion_usage":{"type":"string","enum":["authorization_grant","client_authentication"],"title":"Assertion Usage","description":"RFC 7523 flow selector — required; the caller must pick a flow.\n``authorization_grant`` (§ 2.1) sends the JWT as ``assertion`` under\n``grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer``.\n``client_authentication`` (§ 2.2, the ``private_key_jwt`` method) sends it as\n``client_assertion`` + ``client_assertion_type`` under ``grant_type=client_credentials``\n— required by Epic / SMART Backend Services."},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes","description":"RFC 7523 § 2.1 ``scope`` form-body parameter. Vendors that put scopes inside\nthe JWT instead (Google service accounts) use ``extra_claims = {\"scope\": \"...\"}``\nand leave this empty."},"extra_claims":{"additionalProperties":true,"type":"object","title":"Extra Claims","description":"RFC 7523 § 3 item 8 — arbitrary additional JWT claims (e.g. Google's\n``scope`` claim, Azure's tenant claim). Merged BEFORE the required claims so\nIdP-specific extensions can't override ``iss`` / ``sub`` / ``aud`` / ``exp`` /\n``iat`` / ``nbf`` / ``jti``.","default":{}}},"type":"object","required":["token_url","assertion_issuer","assertion_audience","assertion_subject","assertion_usage"],"title":"OAuth2JwtBearerAuthRequest","description":"OAuth 2.0 JWT Bearer Token — RFC 7523.\n\n``assertion_usage`` (required) selects the flow: § 2.1 (JWT as authorization\ngrant) or § 2.2 (JWT as client authentication / private_key_jwt)."},"CustomTokenExchangeAuthRequest":{"properties":{"type":{"type":"string","const":"custom_token_exchange","title":"Type","default":"custom_token_exchange"},"exchange_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Exchange Url"},"body_encoding":{"type":"string","enum":["json","form"],"title":"Body Encoding","description":"``json`` (default) sends static_body_fields + param_body_fields as JSON; ``form`` sends as application/x-www-form-urlencoded.","default":"json"},"static_headers":{"patternProperties":{"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$":{"type":"string"}},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","title":"Static Headers","description":"Workspace-level headers on the exchange request (keys are RFC 7230 tchar). Values may contain ``{secret}`` placeholder.","default":{}},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields","description":"Workspace-level body fields keyed by RFC 6901 JSON Pointer (e.g. ``/meta/tool_name``\nfor nested fields, or ``/foo`` for a root-level field). Values may contain ``{secret}``\nplaceholder.","default":{}},"param_headers":{"patternProperties":{"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$":{"$ref":"#/components/schemas/ParamValueRequest"}},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","title":"Param Headers","description":"Per-request params routed to headers on the exchange request, keyed by wire-name.","default":{}},"param_body_fields":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueRequest"},"type":"object","title":"Param Body Fields","description":"Per-request params routed to body fields on the exchange request, keyed by RFC 6901 JSON Pointer.","default":{}},"identity_bindings":{"additionalProperties":{"type":"string","enum":["principal.subject_key","principal.subject_id","external_user.subject_key"]},"type":"object","maxProperties":50,"title":"Identity Bindings","description":"Maps a declared ``param_name`` to the verified identity attribute that supplies it\nat dispatch. A bound param is dropped from the LLM-facing tool schema and injected from the\nverified session context (never model-supplied), closing the per-user-identity impersonation hole.\nKeys MUST reference a ``param_name`` declared on ``param_headers`` / ``param_body_fields``.","default":{}},"identity_binding_test_values":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Binding Test Values","description":"Author-configured test values for identity-bound params.\n\nOnly ``external_user.subject_key`` bindings may carry test values. Runtime\ndispatch uses them only when a backend execution path explicitly opts in.","default":{}},"response_token_path":{"type":"string","title":"Response Token Path","description":"RFC 6901 JSON Pointer into the exchange response body that extracts the bearer token\n(e.g. ``/access_token`` or ``/data/bearer``). NO default — every config commits explicitly."}},"type":"object","required":["exchange_url","response_token_path"],"title":"CustomTokenExchangeAuthRequest","description":"Pre-flight exchange that mints a downstream bearer.\n\nReplaces legacy ``json_token_exchange`` AND ``bearer_token_exchange``.\nPath-shaped fields (``response_token_path``, ``static_body_fields`` keys,\n``param_body_fields`` keys) MUST be valid RFC 6901 JSON Pointer — one\nsyntax throughout."},"ParamValueRequest":{"properties":{"param_name":{"type":"string","title":"Param Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["param_name","description"],"title":"ParamValueRequest","description":"Routing target for a single per-request parameter on the exchange call.\n\nPaired with a wire-name (header / body-field key) on\n``CustomTokenExchangeAuthRequest.param_headers`` / ``param_body_fields``."}}}}
```

## The src\_\_routes\_\_integrations\_\_list\_endpoints\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__integrations__list_endpoints__Response":{"properties":{"items":{"items":{"$ref":"#/components/schemas/EndpointResponse"},"type":"array","title":"Items","description":"The endpoints under this integration."},"has_more":{"type":"boolean","title":"Has More","description":"Whether there are more endpoints to retrieve."},"continuation_token":{"title":"Continuation Token","description":"Opaque token for the next page. Null when there are no more results."}},"type":"object","required":["items","has_more"],"title":"Response"},"EndpointResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Endpoint ID — stable, used in subsequent GET/PATCH/DELETE/test URLs."},"name":{"type":"string","title":"Name","description":"Slug-like identifier. Unique per integration; immutable post-create."},"description":{"type":"string","title":"Description","description":"LLM-facing description."},"method":{"type":"string","enum":["GET","POST","PUT","PATCH","DELETE"],"title":"Method","description":"HTTP method."},"path":{"type":"string","title":"Path","description":"URL path appended to the integration's base_url."},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema","description":"JSON Schema for the tool's input arguments."},"headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Headers","description":"Static headers or exact ``$param.<name>`` input-parameter bindings."},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields","description":"Static body fields merged into every request. Keys are RFC 6901 JSON Pointers\n(e.g. ``/meta/tool_name`` for nested, ``/foo`` for a root-level field)."},"body_format":{"type":"string","enum":["json","form"],"title":"Body Format","description":"Outbound body encoding.","default":"json"},"response_template":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Response Template","description":"Jinja template rendered against the parsed JSON response."},"client_output":{"anyOf":[{"$ref":"#/components/schemas/ClientOutputConfig"},{"type":"null"}],"description":"Opt-in typed artifact contract for external-user conversation delivery."},"declarations":{"$ref":"#/components/schemas/EndpointDeclarations-Output","description":"What the endpoint's author declares about its calls. A declaration left out is unknown:\nwith no `writes`, the voice agent never treats the endpoint's calls as a booking or cancellation."},"max_response_length":{"type":"integer","title":"Max Response Length","description":"Truncate the final rendered string to this many chars.","default":0},"timeout_seconds":{"type":"number","title":"Timeout Seconds","description":"Per-request timeout.","default":30},"max_retries":{"type":"integer","title":"Max Retries","description":"How many times a failed call goes out again. A read goes again after a status in `retry_on_status`,\na timeout or a connection that failed. A write goes again only after a 429 or 503 that\n`retry_on_status` lists, or a connection that never opened. Integration writes carry no idempotency key, so a write\nthat timed out, lost its connection or got any other status may already have been made, and isn't\nsent again. A write is a call to an endpoint that declares `declarations.writes` of any kind but\n`none`, or declares nothing and uses POST, PUT, PATCH or DELETE. An endpoint that only reads over\nPOST can declare `declarations.writes.kind` `none` to retry like a read.","default":2},"retry_on_status":{"items":{"type":"integer"},"type":"array","uniqueItems":true,"title":"Retry On Status","description":"HTTP statuses after which a failed call goes out again, up to `max_retries` times. A write goes\nagain only after a 429 or 503 listed here: any other status, 502 and 504 included, can follow a\nwrite the vendor made, so a write that gets one isn't sent again. An endpoint that only reads over\nPOST can declare `declarations.writes.kind` `none` to retry on every status listed here."}},"type":"object","required":["id","name","description","method","path","declarations"],"title":"EndpointResponse","description":"Per-endpoint response."},"ClientOutputConfig":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"json_schema":{"additionalProperties":true,"type":"object","title":"Json Schema"},"max_bytes":{"type":"integer","maximum":262144,"minimum":1,"title":"Max Bytes","default":262144},"external_user_enabled":{"type":"boolean","title":"External User Enabled","default":false}},"type":"object","required":["type","schema_version","json_schema"],"title":"ClientOutputConfig","description":"External-user-safe projection contract for a direct integration endpoint.\n\nThe endpoint's existing ``response_template`` performs the projection. With no\ntemplate, the parsed upstream JSON body is emitted unchanged."},"EndpointDeclarations-Output":{"properties":{"writes":{"anyOf":[{"$ref":"#/components/schemas/EndpointWrites-Output"},{"type":"null"}],"description":"What a successful call writes and how its response reports it. Null when undeclared: the\nvoice agent then never treats the endpoint's calls as a booking or cancellation."},"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nrequest names (``params``), the ones its response holds (``response``), or none (``none``).\nNull when undeclared."},"verifies":{"anyOf":[{"$ref":"#/components/schemas/VerifiesCaller-Output"},{"type":"null"}],"description":"How a successful call verifies the caller, and as which patient, for a service that names\nthis endpoint its verifier (``Service.caller_verification_endpoint_id``). Null when undeclared:\na call verifies nobody."}},"type":"object","title":"EndpointDeclarations","description":"What an endpoint's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses."},"EndpointWrites-Output":{"properties":{"kind":{"$ref":"#/components/schemas/EndpointWriteKind","description":"What the write does, ``none`` when the endpoint never writes, ``varies`` when the\ncompanion skill that calls it says, or ``verification`` for a step that verifies the caller\nby sending or checking a one-time code, which the voice agent runs without asking the caller\nto agree or read back its destination first."},"success":{"anyOf":[{"$ref":"#/components/schemas/WriteSuccess"},{"type":"null"}],"description":"How the response says the write happened. Required unless ``kind`` is ``none``. A ``field`` or\n``graphql`` rule reads the write from the body: the member the pointer names, in a JSON object or\narray or a form-encoded body, or a GraphQL response's ``errors`` or ``data``. A 2xx whose body\ndoesn't hold it, such as an HTML page, plain text, an empty 204, JSON that doesn't parse, JSON\nwithout the field, or JSON that isn't a GraphQL response, such as a gateway's own, leaves the\nwrite's outcome unknown: the vendor may have made it. So does a GraphQL answer with errors\nthat neither says the mutation was refused or never ran nor holds its result, such as a payload\nnulled by an error below the mutation's field, which came after the write, an error with no\npath beside ``data``, or a null ``data`` in a document of more than one mutation, which hides\nwhat the ones before the failing one did. A field with another value, or a GraphQL error at the\nmutation's own field, with that field null, or in an answer with no ``data``, is a write that\ndidn't happen."}},"type":"object","required":["kind"],"title":"EndpointWrites","description":"What a successful call to an endpoint writes, and how its response reports the write."},"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]},"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"VerifiesCaller-Output":{"properties":{"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the identifier of\nthe patient the caller verified as, such as ``/patient/id``: the identifier the service's reads\nname the patient by. Only a string there with more than whitespace in it verifies anyone, never a\nnumber, and never a value the model sent."},"success":{"$ref":"#/components/schemas/VerificationSuccess","description":"How the response says the caller verified: any 2xx (``http_status``), or a field holding the\nvalue that means they did (``field``). A response that doesn't say so verifies nobody, whatever\nidentifier it holds. The author vouches that it says so only once the caller proved who they are\n(a code checked, a name and date of birth matched), never on a lookup or a code sent, and that\n``patient`` names the patient the vendor matched, not a copy of something the request sent."}},"type":"object","required":["patient","success"],"title":"VerifiesCaller","description":"A successful call verifies the caller as one patient: the one its response names. Declaring it\nopens nothing: only a service that names the endpoint its verifier\n(``Service.caller_verification_endpoint_id``) verifies anyone by it."},"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}}}}}
```

## The src\_\_routes\_\_integrations\_\_list\_integrations\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__integrations__list_integrations__Response":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RestIntegrationResponse"},"type":"array","title":"Items","description":"The integrations matching the request filters."},"has_more":{"type":"boolean","title":"Has More","description":"Whether there are more integrations to retrieve."},"continuation_token":{"title":"Continuation Token","description":"Opaque token for the next page. Null when there are no more results."}},"type":"object","required":["items","has_more"],"title":"Response"},"RestIntegrationResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id","description":"Integration ID."},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id","description":"Workspace ID."},"name":{"type":"string","title":"Name","description":"Slug-like identifier, immutable post-create."},"display_name":{"type":"string","title":"Display Name","description":"Human-readable name."},"enabled":{"type":"boolean","title":"Enabled","description":"Whether the integration is active."},"managed":{"type":"boolean","title":"Managed","description":"Whether the integration is system-managed and protected from workspace CRUD.","default":false},"approval_policy":{"type":"string","enum":["none","writes","all"],"title":"Approval Policy","description":"Human-in-the-loop approval gate. ``none`` = no approval required;\n``writes`` = approval required for an endpoint that may write: one that uses\nPOST, PUT, PATCH or DELETE, or declares ``declarations.writes`` of any kind but\n``none``, whatever its method; ``all`` = approval required for every endpoint.","default":"none"},"created_at":{"type":"string","format":"date-time","title":"Created At","description":"When the integration was created."},"updated_at":{"type":"string","format":"date-time","title":"Updated At","description":"When the integration was last updated."},"kind":{"type":"string","const":"rest","title":"Kind","description":"Discriminator.","default":"rest"},"base_url":{"type":"string","title":"Base Url","description":"Base URL for REST integrations."},"auth":{"anyOf":[{"$ref":"#/components/schemas/StaticHeaderAuthDict"},{"$ref":"#/components/schemas/OAuth2ClientCredentialsAuthDict"},{"$ref":"#/components/schemas/OAuth2JwtBearerAuthDict"},{"$ref":"#/components/schemas/CustomTokenExchangeAuthDict"},{"type":"null"}],"title":"Auth","description":"Authentication configuration (lib TypedDict union)."},"endpoint_count":{"type":"integer","title":"Endpoint Count","description":"Number of configured endpoints. Fetch the full list via GET /endpoints."}},"type":"object","required":["id","workspace_id","name","display_name","enabled","created_at","updated_at","base_url","endpoint_count"],"title":"RestIntegrationResponse","description":"REST variant — base URL, auth config, endpoint count."},"StaticHeaderAuthDict":{"properties":{"type":{"type":"string","const":"static_header","title":"Type"},"header_name":{"type":"string","title":"Header Name"}},"type":"object","required":["type","header_name"],"title":"StaticHeaderAuthDict","description":"Static workspace-level secret used verbatim as a single header value.\n\nBearer is just ``header_name=\"Authorization\"`` with the SSM secret holding\n``\"Bearer <token>\"``."},"OAuth2ClientCredentialsAuthDict":{"properties":{"type":{"type":"string","const":"oauth2_client_credentials","title":"Type"},"token_url":{"type":"string","title":"Token Url"},"client_id":{"type":"string","title":"Client Id"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"client_auth_method":{"type":"string","enum":["basic","body"],"title":"Client Auth Method"}},"type":"object","required":["type","token_url","client_id","scopes","client_auth_method"],"title":"OAuth2ClientCredentialsAuthDict","description":"OAuth 2.0 Client Credentials Grant — RFC 6749 § 4.4."},"OAuth2JwtBearerAuthDict":{"properties":{"type":{"type":"string","const":"oauth2_jwt_bearer","title":"Type"},"token_url":{"type":"string","title":"Token Url"},"assertion_issuer":{"type":"string","title":"Assertion Issuer"},"assertion_audience":{"type":"string","title":"Assertion Audience"},"assertion_subject":{"type":"string","title":"Assertion Subject"},"assertion_lifetime_seconds":{"type":"integer","title":"Assertion Lifetime Seconds"},"include_iat":{"type":"boolean","title":"Include Iat"},"include_jti":{"type":"boolean","title":"Include Jti"},"assertion_algorithm":{"type":"string","enum":["RS256","RS384","RS512","PS256","PS384","PS512","ES256","ES384","ES512"],"title":"Assertion Algorithm"},"assertion_usage":{"type":"string","enum":["authorization_grant","client_authentication"],"title":"Assertion Usage"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"extra_claims":{"additionalProperties":true,"type":"object","title":"Extra Claims"}},"type":"object","required":["type","token_url","assertion_issuer","assertion_audience","assertion_subject","assertion_lifetime_seconds","include_iat","include_jti","assertion_algorithm","assertion_usage","scopes","extra_claims"],"title":"OAuth2JwtBearerAuthDict","description":"OAuth 2.0 JWT Bearer Token — RFC 7523.\n\n``assertion_usage`` selects the flow: § 2.1 (JWT as authorization grant) or\n§ 2.2 (JWT as client authentication / private_key_jwt)."},"CustomTokenExchangeAuthDict":{"properties":{"type":{"type":"string","const":"custom_token_exchange","title":"Type"},"exchange_url":{"type":"string","title":"Exchange Url"},"body_encoding":{"type":"string","enum":["json","form"],"title":"Body Encoding"},"static_headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Headers"},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields"},"param_headers":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueDict"},"type":"object","title":"Param Headers"},"param_body_fields":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueDict"},"type":"object","title":"Param Body Fields"},"response_token_path":{"type":"string","title":"Response Token Path"},"identity_bindings":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Bindings"},"identity_binding_test_values":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Binding Test Values"}},"type":"object","required":["type","exchange_url","body_encoding","static_headers","static_body_fields","param_headers","param_body_fields","response_token_path","identity_bindings"],"title":"CustomTokenExchangeAuthDict","description":"Pre-flight exchange that mints a downstream bearer.\n\nDownstream call always receives ``Authorization: Bearer {token}``. No\nin-process caching — every call mints fresh."},"ParamValueDict":{"properties":{"param_name":{"type":"string","title":"Param Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["param_name","description"],"title":"ParamValueDict","description":"Routing target for one per-request parameter on the exchange call.\n\nPaired with a wire-name (header / body-field key) on\n``CustomTokenExchangeAuthDict.param_headers`` / ``param_body_fields``."}}}}
```

## The src\_\_routes\_\_integrations\_\_test\_endpoint\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__integrations__test_endpoint__Request":{"properties":{"params":{"additionalProperties":true,"type":"object","maxProperties":200,"title":"Params","description":"Tool arguments — the endpoint's ``input_schema``-declared inputs (path/query/body)."},"auth_params":{"additionalProperties":true,"type":"object","maxProperties":200,"title":"Auth Params","description":"Caller-supplied values for auth-routed params — the AUTH-ONLY channel.\n\nA ``custom_token_exchange`` integration declares ``param_headers`` /\n``param_body_fields`` whose ``param_name`` placeholders are NOT part of the\nendpoint's ``input_schema`` (they feed the pre-flight token exchange, not the\nendpoint call). They never reach the auth renderer through ``params`` alone, so\nthe renderer raised before any HTTP call. Supply them here to exercise the\nexchange end-to-end.\n\nPLA-980: these values resolve the token exchange but are STRIPPED before the\ndownstream endpoint request is built, so a pure-auth secret put here never\nechoes into the outbound body/query. A param that legitimately feeds BOTH the\nexchange and the endpoint call belongs in ``params`` (which keeps its existing\ndual-use behavior). ``auth_params`` is for pure-auth keys absent from ``params``;\non a key collision the ``params`` value wins (for both the exchange and the call)."}},"type":"object","title":"Request","description":"Inputs to ``POST /{integration_id}/endpoints/{endpoint_id}/test``."}}}}
```

## The src\_\_routes\_\_integrations\_\_test\_endpoint\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__integrations__test_endpoint__Response":{"properties":{"status_code":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Status Code","description":"HTTP status code from the upstream call."},"duration_ms":{"type":"number","title":"Duration Ms","description":"Request duration in milliseconds.","default":0},"retries":{"type":"integer","title":"Retries","description":"Number of retry attempts.","default":0},"raw_response":{"title":"Raw Response","description":"Raw response body from the upstream call."},"rendered":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rendered","description":"Response after Jinja `response_template` rendering, pre-truncation."},"final_result":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Final Result","description":"Final processed result (rendered + truncated to max_response_length)."},"outcome":{"type":"string","enum":["succeeded","failed","unknown"],"title":"Outcome","description":"How the call ended. `succeeded`: the vendor answered with a 2xx, and `wrote` says whether a\ndeclared write happened. A write that succeeded can still carry an `error` saying why its body\ncouldn't be shaped into the result. `failed`: the call failed, and nothing says the vendor acted\non it. `unknown`: a write went out and no answer says whether it went through: a timeout, a\ndropped connection, a gateway's 502, 504, 520 or 524, or a 2xx or 3xx that still failed, such as\na 2xx whose body a `field` or `graphql` success rule can't read. The vendor may have made the\nwrite, so check the vendor before sending it again."},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Error message if the call failed or its `outcome` is `unknown`, and then it ends by saying the\nvendor may have made the write. A non-null `error` alone doesn't mean nothing was written: read\n`outcome`. Also set on a write the vendor answered with a 2xx whose `response_template` failed,\nor whose body didn't parse when no `field` or `graphql` success rule reads it: the write went\nthrough, `outcome` is `succeeded`, and `final_result` is the body unshaped."},"artifact":{"anyOf":[{"$ref":"#/components/schemas/ClientArtifact"},{"type":"null"}],"description":"Client artifact preview after JSON Schema and size validation."},"artifact_error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Artifact Error","description":"Safe validation summary when client output is enabled but cannot be emitted."},"wrote":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Wrote","description":"Whether the endpoint's declared write happened, as its `declarations.writes.success` reads\nthis response. Null when the endpoint declares no write, or the call didn't succeed. After an\n`unknown` outcome null says nothing either way: the vendor may have made the write."},"over_text_budget":{"type":"boolean","title":"Over Text Budget","description":"Whether this call took as long as a text turn waits on one, or longer: `duration_ms`, which counts retries and the waits between them, is `text_budget_ms` or more. The test waits as long as the endpoint's `timeout_seconds` and retries allow, but a text turn gives up on a call at 20 s, so a call this slow fails there as a timeout even when it succeeded here. A write the text turn cuts off mid-request has an unknown outcome. Voice calls, background calls and a companion skill's sub-tools keep the endpoint's timeout."},"text_budget_ms":{"type":"integer","title":"Text Budget Ms","description":"How long a text turn waits on an integration call before it gives up: 20000 ms (20 s), retries and the waits between them included. Each attempt still stops at the endpoint's `timeout_seconds`, so an endpoint set lower keeps its own timeout. Voice calls, background calls and a companion skill's sub-tools aren't held to it: they keep the endpoint's timeout."}},"type":"object","required":["outcome","over_text_budget","text_budget_ms"],"title":"Response","description":"Full breadcrumb returned by the test handler."},"ClientArtifact":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"payload":{"$ref":"#/components/schemas/ClientArtifactPayload"}},"type":"object","required":["type","schema_version","payload"],"title":"ClientArtifact","description":"A versioned JSON payload that a client can render as a product component."},"ClientArtifactPayload":{"anyOf":[{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"}]},"JsonValue":{"anyOf":[{"type":"boolean"},{"type":"integer"},{"type":"number"},{"type":"string"},{"items":{"$ref":"#/components/schemas/JsonValue"},"type":"array"},{"additionalProperties":{"$ref":"#/components/schemas/JsonValue"},"type":"object"},{"type":"null"}]}}}}
```

## The src\_\_routes\_\_integrations\_\_update\_endpoint\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__integrations__update_endpoint__Request":{"properties":{"description":{"type":"string","maxLength":2048,"minLength":1,"title":"Description"},"method":{"type":"string","enum":["GET","POST","PUT","PATCH","DELETE"],"title":"Method"},"path":{"type":"string","maxLength":2048,"minLength":1,"pattern":"^[^/]","title":"Path","description":"URL path appended to the integration's base_url. Must NOT start with `/`."},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"},"headers":{"additionalProperties":{"type":"string"},"type":"object","title":"Headers"},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields"},"body_format":{"type":"string","enum":["json","form"],"title":"Body Format"},"response_template":{"anyOf":[{"type":"string","maxLength":16384},{"type":"null"}],"title":"Response Template","description":"Jinja template; pass `null` to clear (the only DB-nullable column on this row)."},"client_output":{"anyOf":[{"$ref":"#/components/schemas/ClientOutputConfig"},{"type":"null"}],"title":"Client Output","description":"Client output contract; pass `null` to disable external artifact delivery."},"declarations":{"$ref":"#/components/schemas/EndpointDeclarations-Input","title":"Declarations","description":"The declarations to change. Each one named replaces the stored one (`null` undeclares it),\nand each one left out stays as stored."},"max_response_length":{"type":"integer","maximum":1000000,"minimum":0,"title":"Max Response Length"},"timeout_seconds":{"type":"number","maximum":600,"exclusiveMinimum":0,"title":"Timeout Seconds"},"max_retries":{"type":"integer","maximum":10,"minimum":0,"title":"Max Retries","description":"How many times a failed call goes out again. A read goes again after a status in `retry_on_status`,\na timeout or a connection that failed. A write goes again only after a 429 or 503 that\n`retry_on_status` lists, or a connection that never opened. Integration writes carry no idempotency key, so a write\nthat timed out, lost its connection or got any other status may already have been made, and isn't\nsent again. A write is a call to an endpoint that declares `declarations.writes` of any kind but\n`none`, or declares nothing and uses POST, PUT, PATCH or DELETE. An endpoint that only reads over\nPOST can declare `declarations.writes.kind` `none` to retry like a read."},"retry_on_status":{"items":{"type":"integer"},"type":"array","maxItems":20,"uniqueItems":true,"title":"Retry On Status","description":"HTTP statuses after which a failed call goes out again, up to `max_retries` times. A write goes\nagain only after a 429 or 503 listed here: any other status, 502 and 504 included, can follow a\nwrite the vendor made, so a write that gets one isn't sent again. An endpoint that only reads over\nPOST can declare `declarations.writes.kind` `none` to retry on every status listed here."}},"type":"object","title":"Request","description":"Patch an existing endpoint. ``name`` is immutable."},"ClientOutputConfig":{"properties":{"type":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type"},"schema_version":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version"},"json_schema":{"additionalProperties":true,"type":"object","title":"Json Schema"},"max_bytes":{"type":"integer","maximum":262144,"minimum":1,"title":"Max Bytes","default":262144},"external_user_enabled":{"type":"boolean","title":"External User Enabled","default":false}},"type":"object","required":["type","schema_version","json_schema"],"title":"ClientOutputConfig","description":"External-user-safe projection contract for a direct integration endpoint.\n\nThe endpoint's existing ``response_template`` performs the projection. With no\ntemplate, the parsed upstream JSON body is emitted unchanged."},"EndpointDeclarations-Input":{"properties":{"writes":{"anyOf":[{"$ref":"#/components/schemas/EndpointWrites-Input"},{"type":"null"}],"description":"What a successful call writes and how its response reports it. Null when undeclared: the\nvoice agent then never treats the endpoint's calls as a booking or cancellation."},"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nrequest names (``params``), the ones its response holds (``response``), or none (``none``).\nNull when undeclared."},"verifies":{"anyOf":[{"$ref":"#/components/schemas/VerifiesCaller-Input"},{"type":"null"}],"description":"How a successful call verifies the caller, and as which patient, for a service that names\nthis endpoint its verifier (``Service.caller_verification_endpoint_id``). Null when undeclared:\na call verifies nobody."}},"type":"object","title":"EndpointDeclarations","description":"What an endpoint's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses."},"EndpointWrites-Input":{"properties":{"kind":{"$ref":"#/components/schemas/EndpointWriteKind","description":"What the write does, ``none`` when the endpoint never writes, ``varies`` when the\ncompanion skill that calls it says, or ``verification`` for a step that verifies the caller\nby sending or checking a one-time code, which the voice agent runs without asking the caller\nto agree or read back its destination first."},"success":{"anyOf":[{"$ref":"#/components/schemas/WriteSuccess"},{"type":"null"}],"description":"How the response says the write happened. Required unless ``kind`` is ``none``. A ``field`` or\n``graphql`` rule reads the write from the body: the member the pointer names, in a JSON object or\narray or a form-encoded body, or a GraphQL response's ``errors`` or ``data``. A 2xx whose body\ndoesn't hold it, such as an HTML page, plain text, an empty 204, JSON that doesn't parse, JSON\nwithout the field, or JSON that isn't a GraphQL response, such as a gateway's own, leaves the\nwrite's outcome unknown: the vendor may have made it. So does a GraphQL answer with errors\nthat neither says the mutation was refused or never ran nor holds its result, such as a payload\nnulled by an error below the mutation's field, which came after the write, an error with no\npath beside ``data``, or a null ``data`` in a document of more than one mutation, which hides\nwhat the ones before the failing one did. A field with another value, or a GraphQL error at the\nmutation's own field, with that field null, or in an answer with no ``data``, is a write that\ndidn't happen."}},"type":"object","required":["kind"],"title":"EndpointWrites","description":"What a successful call to an endpoint writes, and how its response reports the write."},"EndpointWriteKind":{"anyOf":[{"$ref":"#/components/schemas/WriteKind"},{"type":"string","enum":["none","varies","verification"]}]},"WriteKind":{"type":"string","enum":["booking","cancellation","reschedule","message","other"]},"WriteSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/GraphQLSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","graphql":"#/components/schemas/GraphQLSuccess","http_status":"#/components/schemas/StatusSuccess"}}},"StatusSuccess":{"properties":{"reported_by":{"type":"string","const":"http_status","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"StatusSuccess","description":"Any 2xx response is the write, or the verification. For a vendor that turns one down with an\nerror status."},"GraphQLSuccess":{"properties":{"reported_by":{"type":"string","const":"graphql","title":"Reported By"}},"type":"object","required":["reported_by"],"title":"GraphQLSuccess","description":"The request is a GraphQL mutation, and every mutation payload holds something other than null\npast its user errors. Top-level ``errors`` in an answer with no ``data`` are a request that never\nran. Beside ``data`` they're read by their ``path``: one at the mutation's own field, with that\nfield null, is its resolver refusing, and one below it came after the write, so a payload that\nstill holds its result wrote. A request that never ran, or a resolver that refused, is a write\nthat didn't happen. Any other answer with errors leaves the outcome unknown, such as a payload\nGraphQL nulled on the way up, or an error with no path beside ``data``. So does a null ``data`` in\na document of more than one mutation: they run in order, and the null hides what the ones before\nthe failing one did."},"FieldSuccess":{"properties":{"reported_by":{"type":"string","const":"field","title":"Reported By"},"pointer":{"type":"string","maxLength":512,"minLength":1,"title":"Pointer","description":"RFC 6901 JSON Pointer into the parsed response body, such as ``/code``."},"equals":{"anyOf":[{"type":"string","maxLength":256},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Equals","description":"The value at ``pointer`` when the write happened, or the caller verified. Compared as JSON:\n``\"0\"`` is not ``0``, and ``true`` is not ``1``. A form-encoded response holds only strings."}},"type":"object","required":["reported_by","pointer","equals"],"title":"FieldSuccess","description":"A field of the JSON response holds the value that means the write happened, or the caller\nverified."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"VerifiesCaller-Input":{"properties":{"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the identifier of\nthe patient the caller verified as, such as ``/patient/id``: the identifier the service's reads\nname the patient by. Only a string there with more than whitespace in it verifies anyone, never a\nnumber, and never a value the model sent."},"success":{"$ref":"#/components/schemas/VerificationSuccess","description":"How the response says the caller verified: any 2xx (``http_status``), or a field holding the\nvalue that means they did (``field``). A response that doesn't say so verifies nobody, whatever\nidentifier it holds. The author vouches that it says so only once the caller proved who they are\n(a code checked, a name and date of birth matched), never on a lookup or a code sent, and that\n``patient`` names the patient the vendor matched, not a copy of something the request sent."}},"type":"object","required":["patient","success"],"title":"VerifiesCaller","description":"A successful call verifies the caller as one patient: the one its response names. Declaring it\nopens nothing: only a service that names the endpoint its verifier\n(``Service.caller_verification_endpoint_id``) verifies anyone by it."},"VerificationSuccess":{"oneOf":[{"$ref":"#/components/schemas/StatusSuccess"},{"$ref":"#/components/schemas/FieldSuccess"}],"discriminator":{"propertyName":"reported_by","mapping":{"field":"#/components/schemas/FieldSuccess","http_status":"#/components/schemas/StatusSuccess"}}}}}}
```

## The src\_\_routes\_\_integrations\_\_update\_integration\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__integrations__update_integration__Request":{"properties":{"display_name":{"$ref":"#/components/schemas/NameString","title":"Display Name","description":"New display name."},"base_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Base Url","description":"New base URL."},"auth":{"anyOf":[{"oneOf":[{"$ref":"#/components/schemas/StaticHeaderAuthRequest"},{"$ref":"#/components/schemas/OAuth2ClientCredentialsAuthRequest"},{"$ref":"#/components/schemas/OAuth2JwtBearerAuthRequest"},{"$ref":"#/components/schemas/CustomTokenExchangeAuthRequest"}],"discriminator":{"propertyName":"type","mapping":{"custom_token_exchange":"#/components/schemas/CustomTokenExchangeAuthRequest","oauth2_client_credentials":"#/components/schemas/OAuth2ClientCredentialsAuthRequest","oauth2_jwt_bearer":"#/components/schemas/OAuth2JwtBearerAuthRequest","static_header":"#/components/schemas/StaticHeaderAuthRequest"}}},{"type":"null"}],"title":"Auth","description":"New auth config. Absent ⇒ untouched; null ⇒ clear; value ⇒ replace.\nIndependent of ``secret_value`` — updating ``auth`` alone reuses the\nexisting SSM secret."},"secret_value":{"type":"string","maxLength":8192,"minLength":1,"title":"Secret Value","description":"Rotate the per-integration SSM secret. Absent ⇒ existing secret\nuntouched; value ⇒ overwrite SSM at the canonical path. Explicit\n``null`` is rejected at validation — there is no \"clear the secret\"\noperation (clearing ``auth`` makes the secret unreachable; that's the\nintended clear path)."},"enabled":{"type":"boolean","title":"Enabled","description":"Toggle the integration on/off."},"managed":{"type":"boolean","title":"Managed","description":"Mark/unmark the integration as system-managed. Requires ``platform:admin`` scope."},"approval_policy":{"type":"string","enum":["none","writes","all"],"title":"Approval Policy","description":"Change the human-in-the-loop approval gate. ``none`` = no approval\nrequired; ``writes`` = approval required for an endpoint that may write: one\nthat uses POST, PUT, PATCH or DELETE, or declares ``declarations.writes`` of any\nkind but ``none``, whatever its method; ``all`` = approval required for every\nendpoint. Absent ⇒ untouched."}},"type":"object","title":"Request","description":"PATCH body — each field is sentinel-defaulted; absent ≠ explicit-null."},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"StaticHeaderAuthRequest":{"properties":{"type":{"type":"string","const":"static_header","title":"Type","default":"static_header"},"header_name":{"type":"string","maxLength":256,"minLength":1,"pattern":"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$","title":"Header Name","description":"Outbound header name (RFC 7230 tchar)."}},"type":"object","required":["header_name"],"title":"StaticHeaderAuthRequest","description":"Static workspace-level secret used verbatim as a single header value."},"OAuth2ClientCredentialsAuthRequest":{"properties":{"type":{"type":"string","const":"oauth2_client_credentials","title":"Type","default":"oauth2_client_credentials"},"token_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Token Url"},"client_id":{"type":"string","title":"Client Id"},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes"},"client_auth_method":{"type":"string","enum":["basic","body"],"title":"Client Auth Method","description":"RFC 6749 § 2.3.1: ``basic`` sends client_id+secret as HTTP Basic auth; ``body`` sends them in the form body.","default":"basic"}},"type":"object","required":["token_url","client_id"],"title":"OAuth2ClientCredentialsAuthRequest","description":"OAuth 2.0 Client Credentials Grant — RFC 6749 § 4.4.\n\nStrict RFC 6749 § 4.4.2 access token request: ``grant_type`` + optional\n``scope``. Client authentication (RFC 6749 § 2.3.1) is orthogonal —\n``client_auth_method`` picks between HTTP Basic auth and form-body\ncredentials. RFC 8707 ``resource`` and non-standard ``audience`` extensions\nare NOT supported here — add them back when a vendor needs one."},"OAuth2JwtBearerAuthRequest":{"properties":{"type":{"type":"string","const":"oauth2_jwt_bearer","title":"Type","default":"oauth2_jwt_bearer"},"token_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Token Url"},"assertion_issuer":{"type":"string","title":"Assertion Issuer","description":"RFC 7523 ``iss`` claim — typically the service-account email or client_id."},"assertion_audience":{"type":"string","title":"Assertion Audience","description":"RFC 7523 ``aud`` claim — typically the token_url."},"assertion_subject":{"type":"string","title":"Assertion Subject","description":"RFC 7523 § 3 ``sub`` claim — MUST be present. For service-account flows\nwhere the client is its own subject, set to the same value as ``assertion_issuer``.\nUse a different value only for delegation / impersonation grants."},"assertion_lifetime_seconds":{"type":"integer","title":"Assertion Lifetime Seconds","default":3600},"include_iat":{"type":"boolean","title":"Include Iat","description":"RFC 7523 § 3 item 6 — ``iat`` claim set to mint time. Most IdPs (Google, Azure)\nrequire it for anti-replay; leave True unless a specific vendor rejects it.","default":true},"include_jti":{"type":"boolean","title":"Include Jti","description":"When True, generate a fresh ``jti`` (anti-replay) on every mint.","default":true},"assertion_algorithm":{"type":"string","enum":["RS256","RS384","RS512","PS256","PS384","PS512","ES256","ES384","ES512"],"title":"Assertion Algorithm","default":"RS256"},"assertion_usage":{"type":"string","enum":["authorization_grant","client_authentication"],"title":"Assertion Usage","description":"RFC 7523 flow selector — required; the caller must pick a flow.\n``authorization_grant`` (§ 2.1) sends the JWT as ``assertion`` under\n``grant_type=urn:ietf:params:oauth:grant-type:jwt-bearer``.\n``client_authentication`` (§ 2.2, the ``private_key_jwt`` method) sends it as\n``client_assertion`` + ``client_assertion_type`` under ``grant_type=client_credentials``\n— required by Epic / SMART Backend Services."},"scopes":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Scopes","description":"RFC 7523 § 2.1 ``scope`` form-body parameter. Vendors that put scopes inside\nthe JWT instead (Google service accounts) use ``extra_claims = {\"scope\": \"...\"}``\nand leave this empty."},"extra_claims":{"additionalProperties":true,"type":"object","title":"Extra Claims","description":"RFC 7523 § 3 item 8 — arbitrary additional JWT claims (e.g. Google's\n``scope`` claim, Azure's tenant claim). Merged BEFORE the required claims so\nIdP-specific extensions can't override ``iss`` / ``sub`` / ``aud`` / ``exp`` /\n``iat`` / ``nbf`` / ``jti``.","default":{}}},"type":"object","required":["token_url","assertion_issuer","assertion_audience","assertion_subject","assertion_usage"],"title":"OAuth2JwtBearerAuthRequest","description":"OAuth 2.0 JWT Bearer Token — RFC 7523.\n\n``assertion_usage`` (required) selects the flow: § 2.1 (JWT as authorization\ngrant) or § 2.2 (JWT as client authentication / private_key_jwt)."},"CustomTokenExchangeAuthRequest":{"properties":{"type":{"type":"string","const":"custom_token_exchange","title":"Type","default":"custom_token_exchange"},"exchange_url":{"type":"string","maxLength":2083,"minLength":1,"format":"uri","title":"Exchange Url"},"body_encoding":{"type":"string","enum":["json","form"],"title":"Body Encoding","description":"``json`` (default) sends static_body_fields + param_body_fields as JSON; ``form`` sends as application/x-www-form-urlencoded.","default":"json"},"static_headers":{"patternProperties":{"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$":{"type":"string"}},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","title":"Static Headers","description":"Workspace-level headers on the exchange request (keys are RFC 7230 tchar). Values may contain ``{secret}`` placeholder.","default":{}},"static_body_fields":{"additionalProperties":{"type":"string"},"type":"object","title":"Static Body Fields","description":"Workspace-level body fields keyed by RFC 6901 JSON Pointer (e.g. ``/meta/tool_name``\nfor nested fields, or ``/foo`` for a root-level field). Values may contain ``{secret}``\nplaceholder.","default":{}},"param_headers":{"patternProperties":{"^[A-Za-z0-9!#$%&'*+\\-.^_`|~]+$":{"$ref":"#/components/schemas/ParamValueRequest"}},"propertyNames":{"maxLength":256,"minLength":1},"type":"object","title":"Param Headers","description":"Per-request params routed to headers on the exchange request, keyed by wire-name.","default":{}},"param_body_fields":{"additionalProperties":{"$ref":"#/components/schemas/ParamValueRequest"},"type":"object","title":"Param Body Fields","description":"Per-request params routed to body fields on the exchange request, keyed by RFC 6901 JSON Pointer.","default":{}},"identity_bindings":{"additionalProperties":{"type":"string","enum":["principal.subject_key","principal.subject_id","external_user.subject_key"]},"type":"object","maxProperties":50,"title":"Identity Bindings","description":"Maps a declared ``param_name`` to the verified identity attribute that supplies it\nat dispatch. A bound param is dropped from the LLM-facing tool schema and injected from the\nverified session context (never model-supplied), closing the per-user-identity impersonation hole.\nKeys MUST reference a ``param_name`` declared on ``param_headers`` / ``param_body_fields``.","default":{}},"identity_binding_test_values":{"additionalProperties":{"type":"string"},"type":"object","title":"Identity Binding Test Values","description":"Author-configured test values for identity-bound params.\n\nOnly ``external_user.subject_key`` bindings may carry test values. Runtime\ndispatch uses them only when a backend execution path explicitly opts in.","default":{}},"response_token_path":{"type":"string","title":"Response Token Path","description":"RFC 6901 JSON Pointer into the exchange response body that extracts the bearer token\n(e.g. ``/access_token`` or ``/data/bearer``). NO default — every config commits explicitly."}},"type":"object","required":["exchange_url","response_token_path"],"title":"CustomTokenExchangeAuthRequest","description":"Pre-flight exchange that mints a downstream bearer.\n\nReplaces legacy ``json_token_exchange`` AND ``bearer_token_exchange``.\nPath-shaped fields (``response_token_path``, ``static_body_fields`` keys,\n``param_body_fields`` keys) MUST be valid RFC 6901 JSON Pointer — one\nsyntax throughout."},"ParamValueRequest":{"properties":{"param_name":{"type":"string","title":"Param Name"},"description":{"type":"string","title":"Description"}},"type":"object","required":["param_name","description"],"title":"ParamValueRequest","description":"Routing target for a single per-request parameter on the exchange call.\n\nPaired with a wire-name (header / body-field key) on\n``CustomTokenExchangeAuthRequest.param_headers`` / ``param_body_fields``."}}}}
```

## The src\_\_routes\_\_internal\_skills\_\_IntegrationToolRef object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__internal_skills__IntegrationToolRef":{"properties":{"integration":{"type":"string","title":"Integration"},"endpoint":{"type":"string","title":"Endpoint"},"skill_input_bindings":{"additionalProperties":{"type":"string"},"type":"object","title":"Skill Input Bindings","default":{}}},"type":"object","required":["integration","endpoint"],"title":"IntegrationToolRef"}}}}
```

## The src\_\_routes\_\_internal\_skills\_\_StaticToolDef object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__internal_skills__StaticToolDef":{"properties":{"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"input_schema":{"additionalProperties":true,"type":"object","title":"Input Schema"}},"type":"object","required":["name","description","input_schema"],"title":"StaticToolDef"}}}}
```

## The src\_\_routes\_\_memory\_dimensions\_\_create\_memory\_dimension\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__memory_dimensions__create_memory_dimension__Request":{"properties":{"service_id":{"type":"string","format":"uuid","title":"Service Id"},"key":{"type":"string","maxLength":64,"minLength":1,"title":"Key"},"description":{"type":"string","maxLength":2000,"minLength":1,"title":"Description"}},"type":"object","required":["service_id","key","description"],"title":"Request"}}}}
```

## The src\_\_routes\_\_metrics\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__metrics___SortField":{"type":"string","enum":["metric_key","period_start"]}}}}
```

## The src\_\_routes\_\_operation\_grants\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__operation_grants___SortField":{"type":"string","const":"expires_at"}}}}
```

## The src\_\_routes\_\_operators\_models\_\_AuditEventResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__operators_models__AuditEventResponse":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"event_type":{"type":"string","title":"Event Type","description":"Audit event type (e.g. operator.status_change)"},"data":{"additionalProperties":true,"type":"object","title":"Data","description":"Audit payload — shape varies by event_type"},"source":{"type":"string","title":"Source","description":"System that emitted the event"},"ingested_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Ingested At","description":"When the event was ingested"},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At","description":"When the event occurred"}},"type":"object","required":["id","workspace_id","event_type","data","source"],"title":"AuditEventResponse"}}}}
```

## The src\_\_routes\_\_production\_eval\_results\_\_ProductionEvalResultListResponse\_\_Item object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__production_eval_results__ProductionEvalResultListResponse__Item":{"properties":{"conversation_id":{"type":"string","format":"uuid","title":"Conversation Id","description":"The conversation the verdict is for."},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Call Sid","description":"The conversation's call SID, when it has one."},"service_id":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Service Id","description":"The service the check is assigned to. Null when the check applies to every service."},"status":{"type":"string","enum":["passed","failed","pending","skipped","error"],"title":"Status","description":"How the check graded the conversation: `passed`, `failed`, `skipped` (no pass or fail: the grader found no\nanswer, or the check has no pass rule), `error` (the check could not run) or `pending`."},"passed":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Passed","description":"True for `passed`, false for `failed` and null for every other status. The pass rate counts the verdicts\nwhere this isn't null."},"value":{"title":"Value","description":"What the check observed: the metric's value, a number, a boolean or a label. Null when it observed none, and\nfor the older checks that aren't metrics."},"rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rationale","description":"Why the value passed or failed the check's rule, or why there is no pass or fail."},"justification":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Justification","description":"The grader's explanation of the value. It can quote the conversation."},"cited_turns":{"items":{"type":"integer"},"type":"array","title":"Cited Turns","description":"The turns of the conversation that `justification` cites, by turn number."},"computed_at":{"type":"string","format":"date-time","title":"Computed At","description":"When the verdict was last computed. Evaluating a conversation again replaces its verdict."}},"type":"object","required":["conversation_id","call_sid","service_id","status","passed","value","rationale","justification","cited_turns","computed_at"],"title":"Item","description":"One conversation's verdict on the eval, with the reasoning behind it."}}}}
```

## The src\_\_routes\_\_production\_eval\_results\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__production_eval_results___SortField":{"type":"string","enum":["computed_at","score"]}}}}
```

## The src\_\_routes\_\_production\_evals\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__production_evals___SortField":{"type":"string","const":"created_at"}}}}
```

## The src\_\_routes\_\_role\_grants\_\_CreateRequest object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__role_grants__CreateRequest":{"properties":{"role_id":{"type":"string","format":"uuid","title":"Role Id"},"resource_type":{"$ref":"#/components/schemas/_ResourceType"},"resource_key":{"type":"string","maxLength":512,"minLength":1,"title":"Resource Key"},"access":{"$ref":"#/components/schemas/_Access"},"param_binding":{"anyOf":[{"type":"string","maxLength":256},{"type":"null"}],"title":"Param Binding"}},"additionalProperties":false,"type":"object","required":["role_id","resource_type","resource_key","access"],"title":"CreateRequest"},"_ResourceType":{"type":"string","enum":["integration_endpoint","skill","kb_scope"]},"_Access":{"type":"string","enum":["read","write"]}}}}
```

## The src\_\_routes\_\_role\_grants\_\_ListResponse object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__role_grants__ListResponse":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RoleGrantItem"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"ListResponse"},"RoleGrantItem":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"role_id":{"type":"string","format":"uuid","title":"Role Id"},"resource_type":{"$ref":"#/components/schemas/_ResourceType"},"resource_key":{"type":"string","title":"Resource Key"},"access":{"$ref":"#/components/schemas/_Access"},"param_binding":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Param Binding"},"status":{"type":"string","enum":["active","superseded"],"title":"Status"},"changed_by":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}],"title":"Changed By"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","role_id","resource_type","resource_key","access","status","created_at"],"title":"RoleGrantItem"},"_ResourceType":{"type":"string","enum":["integration_endpoint","skill","kb_scope"]},"_Access":{"type":"string","enum":["read","write"]}}}}
```

## The src\_\_routes\_\_role\_grants\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__role_grants___SortField":{"type":"string","const":"created_at"}}}}
```

## The src\_\_routes\_\_runs\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__runs___SortField":{"type":"string","const":"started_at"}}}}
```

## The src\_\_routes\_\_scheduling\_rule\_sets\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__scheduling_rule_sets___SortField":{"type":"string","enum":["agent_kind","rule_kind"]}}}}
```

## The src\_\_routes\_\_services\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__services___SortField":{"type":"string","enum":["name","created_at","updated_at"]}}}}
```

## The src\_\_routes\_\_simulations\_\_coverage\_\_SimulationSessionListResponse\_\_Item object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__simulations__coverage__SimulationSessionListResponse__Item":{"properties":{"metric_status":{"anyOf":[{"type":"string","enum":["pending","available","unavailable"]},{"type":"null"}],"title":"Metric Status"},"metric_result_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Metric Result Count"},"metrics_last_checked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Metrics Last Checked At"},"immediate_score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Immediate Score","description":"The session's score, the same value as score."},"immediate_score_rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Immediate Score Rationale"},"session_id":{"type":"string","title":"Session Id"},"run_id":{"type":"string","format":"uuid","title":"Run Id"},"parent_session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parent Session Id"},"fork_turn_index":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Fork Turn Index"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","description":"Bridge-written tags, such as `scenario_index:<n>`, `temperament:<x>` and `forked`."},"total_turns":{"type":"integer","title":"Total Turns"},"terminal_reached":{"type":"boolean","title":"Terminal Reached"},"score":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Score"},"score_rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Score Rationale"},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"}},"type":"object","required":["session_id","run_id","parent_session_id","fork_turn_index","tags","total_turns","terminal_reached","score","score_rationale","created_at"],"title":"Item"}}}}
```

## The src\_\_routes\_\_simulations\_\_runs\_\_SimulationRunListResponse\_\_Item object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__simulations__runs__SimulationRunListResponse__Item":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"service_id":{"type":"string","format":"uuid","title":"Service Id"},"branch_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Branch Name"},"status":{"type":"string","enum":["running","completed","failed"],"title":"Status"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags"},"total_sessions":{"type":"integer","title":"Total Sessions"},"total_turns":{"type":"integer","title":"Total Turns"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Error","description":"Failure reason saved by complete-run. Null unless status is failed, and null on\nfailed runs older than the column."},"created_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Created At"},"completed_at":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Completed At"}},"type":"object","required":["id","service_id","branch_name","status","tags","total_sessions","total_turns","error","created_at","completed_at"],"title":"Item"}}}}
```

## The src\_\_routes\_\_skills\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__skills___SortField":{"type":"string","enum":["name","created_at","updated_at","slug"]}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_create\_workspace\_data\_query\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__create_workspace_data_query__Request":{"properties":{"name":{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"description":{"type":"string","maxLength":2048,"minLength":1,"title":"Description"},"sql_template":{"type":"string","maxLength":8192,"minLength":1,"title":"Sql Template"},"parameters":{"items":{"$ref":"#/components/schemas/src__routes__workspace_data_queries__create_workspace_data_query__Request__Parameter"},"type":"array","maxItems":32,"title":"Parameters"},"timeout_ms":{"type":"integer","maximum":30000,"minimum":100,"title":"Timeout Ms","default":5000},"declarations":{"$ref":"#/components/schemas/DataQueryDeclarationsBody","description":"What the query's author declares about its calls. A declaration left out is undeclared. A query\nover practice data, such as FAQ articles, locations or hours, declares `reads` of\n`{\"patient_in\": \"none\"}`, so the voice agent never counts its result as a patient's record."}},"additionalProperties":false,"type":"object","required":["name","description","sql_template"],"title":"Request","description":"A new workspace data query: a SQL template and the parameters it declares.\n\nThe SQL template must be one SELECT, INSERT, UPDATE, DELETE or TRUNCATE statement that calls only built-in\nfunctions which run no SQL text and change no session state. Its `:name` placeholders and the declared\nparameters must be the same set of names: each placeholder is declared, and each declared parameter appears\nin the template. A parameter's `default`, when set, must be of its declared `type`. A body that breaks any\nof these rules returns 422."},"src__routes__workspace_data_queries__create_workspace_data_query__Request__Parameter":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","maxLength":512,"minLength":1,"title":"Description"},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Default"},"authorization_binding":{"anyOf":[{"$ref":"#/components/schemas/RoleGrantKeysBinding"},{"type":"null"}]},"authorization_binding_test_value":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Authorization Binding Test Value","description":"Canonical CSV resource keys used only by trusted playground execution when no live authorization block exists."}},"additionalProperties":false,"type":"object","required":["name","type","description"],"title":"Parameter","description":"One parameter the query declares."},"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."},"DataQueryDeclarationsBody":{"properties":{"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nparameters name (``params``, each one of the query's ``parameters``), the ones its rows hold\n(``response``, where ``records`` points into the rows the query returns, a list of objects keyed\nby column, so the empty pointer is every row), or none (``none``: practice data, such as\narticles, locations or opening hours). Null when undeclared: the voice agent then counts a\ncall's result as one that may hold a patient's record."},"freshness":{"anyOf":[{"$ref":"#/components/schemas/DataFreshnessBody"},{"type":"null"}],"description":"None: rows are returned as they are, with no staleness."}},"additionalProperties":false,"type":"object","title":"DataQueryDeclarationsBody","description":"The declarations a create or PATCH names. One a data query can't make, such as an endpoint's\n``writes`` or a misspelled ``reads``, is a 422, never a key dropped with a 200. Only the write\nboundary refuses one: a reader ignores a key it doesn't know (``DataQueryDeclarations``)."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"DataFreshnessBody":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"additionalProperties":false,"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshnessBody","description":"The freshness a create or PATCH names. A key it doesn't have, such as a unit, is a 422."}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_create\_workspace\_data\_query\_\_Request\_\_Parameter object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__create_workspace_data_query__Request__Parameter":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","maxLength":512,"minLength":1,"title":"Description"},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Default"},"authorization_binding":{"anyOf":[{"$ref":"#/components/schemas/RoleGrantKeysBinding"},{"type":"null"}]},"authorization_binding_test_value":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Authorization Binding Test Value","description":"Canonical CSV resource keys used only by trusted playground execution when no live authorization block exists."}},"additionalProperties":false,"type":"object","required":["name","type","description"],"title":"Parameter","description":"One parameter the query declares."},"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_invoke\_workspace\_data\_query\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__invoke_workspace_data_query__Request":{"properties":{"input":{"additionalProperties":true,"type":"object","title":"Input","description":"Caller arguments matching the declared parameters."}},"type":"object","title":"Request"}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_invoke\_workspace\_data\_query\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__invoke_workspace_data_query__Response":{"properties":{"result":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Result"},"duration_ms":{"type":"number","title":"Duration Ms","default":0},"row_count":{"type":"integer","title":"Row Count","default":0}},"type":"object","title":"Response"}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_list\_workspace\_data\_queries\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__list_workspace_data_queries__Response":{"properties":{"items":{"items":{"$ref":"#/components/schemas/src__routes__workspace_data_queries__list_workspace_data_queries__Response__Item"},"type":"array","title":"Items"},"has_more":{"type":"boolean","title":"Has More"},"continuation_token":{"title":"Continuation Token"}},"type":"object","required":["items","has_more"],"title":"Response"},"src__routes__workspace_data_queries__list_workspace_data_queries__Response__Item":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"sql_template":{"type":"string","title":"Sql Template"},"parameter_count":{"type":"integer","title":"Parameter Count"},"timeout_ms":{"type":"integer","title":"Timeout Ms"},"declarations":{"$ref":"#/components/schemas/DataQueryDeclarations","description":"What the query's author declares about its calls. A declaration it never made is null."},"last_invoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Invoked At"},"deployed_at":{"type":"string","format":"date-time","title":"Deployed At"},"deployed_by":{"type":"string","format":"uuid","title":"Deployed By"}},"type":"object","required":["id","name","description","sql_template","parameter_count","timeout_ms","declarations","deployed_at","deployed_by"],"title":"Item"},"DataQueryDeclarations":{"properties":{"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nparameters name (``params``, each one of the query's ``parameters``), the ones its rows hold\n(``response``, where ``records`` points into the rows the query returns, a list of objects keyed\nby column, so the empty pointer is every row), or none (``none``: practice data, such as\narticles, locations or opening hours). Null when undeclared: the voice agent then counts a\ncall's result as one that may hold a patient's record."},"freshness":{"anyOf":[{"$ref":"#/components/schemas/DataFreshness"},{"type":"null"}],"description":"None: rows are returned as they are, with no staleness."}},"type":"object","title":"DataQueryDeclarations","description":"What a data query's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses. A reader ignores a key it doesn't\nknow, so a later declaration never breaks an older reader."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"DataFreshness":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshness","description":"How fresh a query's rows must be to be stated as current."}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_list\_workspace\_data\_queries\_\_Response\_\_Item object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__list_workspace_data_queries__Response__Item":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"name":{"type":"string","title":"Name"},"description":{"type":"string","title":"Description"},"sql_template":{"type":"string","title":"Sql Template"},"parameter_count":{"type":"integer","title":"Parameter Count"},"timeout_ms":{"type":"integer","title":"Timeout Ms"},"declarations":{"$ref":"#/components/schemas/DataQueryDeclarations","description":"What the query's author declares about its calls. A declaration it never made is null."},"last_invoked_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Invoked At"},"deployed_at":{"type":"string","format":"date-time","title":"Deployed At"},"deployed_by":{"type":"string","format":"uuid","title":"Deployed By"}},"type":"object","required":["id","name","description","sql_template","parameter_count","timeout_ms","declarations","deployed_at","deployed_by"],"title":"Item"},"DataQueryDeclarations":{"properties":{"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nparameters name (``params``, each one of the query's ``parameters``), the ones its rows hold\n(``response``, where ``records`` points into the rows the query returns, a list of objects keyed\nby column, so the empty pointer is every row), or none (``none``: practice data, such as\narticles, locations or opening hours). Null when undeclared: the voice agent then counts a\ncall's result as one that may hold a patient's record."},"freshness":{"anyOf":[{"$ref":"#/components/schemas/DataFreshness"},{"type":"null"}],"description":"None: rows are returned as they are, with no staleness."}},"type":"object","title":"DataQueryDeclarations","description":"What a data query's author declares about its calls. Each declaration is optional, and one\nleft out is unknown, never a default the platform guesses. A reader ignores a key it doesn't\nknow, so a later declaration never breaks an older reader."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"DataFreshness":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshness","description":"How fresh a query's rows must be to be stated as current."}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_list\_workspace\_data\_queries\_\_\_SortField object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__list_workspace_data_queries___SortField":{"type":"string","const":"deployed_at"}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_update\_workspace\_data\_query\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__update_workspace_data_query__Request":{"properties":{"name":{"anyOf":[{"type":"string","maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$"},{"type":"null"}],"title":"Name"},"description":{"anyOf":[{"type":"string","maxLength":2048,"minLength":1},{"type":"null"}],"title":"Description"},"sql_template":{"anyOf":[{"type":"string","maxLength":8192,"minLength":1},{"type":"null"}],"title":"Sql Template"},"parameters":{"anyOf":[{"items":{"$ref":"#/components/schemas/src__routes__workspace_data_queries__update_workspace_data_query__Request__Parameter"},"type":"array","maxItems":32},{"type":"null"}],"title":"Parameters"},"timeout_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Timeout Ms"},"declarations":{"anyOf":[{"$ref":"#/components/schemas/DataQueryDeclarationsBody"},{"type":"null"}],"description":"The declarations to change. Each one named replaces the stored one (`null` undeclares it), and\none left out keeps what is stored."}},"additionalProperties":false,"type":"object","title":"Request","description":"A change to a workspace data query. A field left out, or sent as null, keeps its stored value; inside\n`declarations`, a key sent as null removes that declaration. `parameters`, when sent, replaces the whole list,\nand `[]` clears it.\n\nThe SQL template and parameters are checked as they will stand after the change, by the same rules as a new\nquery: the template must be one SELECT, INSERT, UPDATE, DELETE or TRUNCATE statement that calls only built-in\nfunctions which run no SQL text and change no session state, its `:name` placeholders must be the same set of\nnames as the declared parameters, and a parameter's `default`, when set, must be of its declared `type`. A body\nthat breaks any of these rules returns 422."},"src__routes__workspace_data_queries__update_workspace_data_query__Request__Parameter":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","maxLength":512,"minLength":1,"title":"Description"},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Default"},"authorization_binding":{"anyOf":[{"$ref":"#/components/schemas/RoleGrantKeysBinding"},{"type":"null"}]},"authorization_binding_test_value":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Authorization Binding Test Value","description":"Canonical CSV resource keys used only by trusted playground execution when no live authorization block exists."}},"additionalProperties":false,"type":"object","required":["name","type","description"],"title":"Parameter","description":"One parameter the query declares."},"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."},"DataQueryDeclarationsBody":{"properties":{"reads":{"anyOf":[{"$ref":"#/components/schemas/EndpointReads"},{"type":"null"}],"description":"Whose patient record a call returns, and how the call names that patient: the one its\nparameters name (``params``, each one of the query's ``parameters``), the ones its rows hold\n(``response``, where ``records`` points into the rows the query returns, a list of objects keyed\nby column, so the empty pointer is every row), or none (``none``: practice data, such as\narticles, locations or opening hours). Null when undeclared: the voice agent then counts a\ncall's result as one that may hold a patient's record."},"freshness":{"anyOf":[{"$ref":"#/components/schemas/DataFreshnessBody"},{"type":"null"}],"description":"None: rows are returned as they are, with no staleness."}},"additionalProperties":false,"type":"object","title":"DataQueryDeclarationsBody","description":"The declarations a create or PATCH names. One a data query can't make, such as an endpoint's\n``writes`` or a misspelled ``reads``, is a 422, never a key dropped with a 200. Only the write\nboundary refuses one: a reader ignores a key it doesn't know (``DataQueryDeclarations``)."},"EndpointReads":{"oneOf":[{"$ref":"#/components/schemas/PatientInParams"},{"$ref":"#/components/schemas/PatientsInResponse"},{"$ref":"#/components/schemas/NoPatient"}],"discriminator":{"propertyName":"patient_in","mapping":{"none":"#/components/schemas/NoPatient","params":"#/components/schemas/PatientInParams","response":"#/components/schemas/PatientsInResponse"}}},"PatientInParams":{"properties":{"patient_in":{"type":"string","const":"params","title":"Patient In"},"params":{"items":{"type":"string","maxLength":128,"minLength":1},"type":"array","maxItems":8,"minItems":1,"title":"Params","description":"The input parameters that name the patient, by an identifier their record on file carries:\nits entity_id, MRN, FHIR id or source system id. Each one is a property of the endpoint's\n``input_schema``. On a service that verifies its callers through its own integration, they name\nthe patient by the identifier its verifier returns."}},"type":"object","required":["patient_in","params"],"title":"PatientInParams","description":"A call returns the record of the patient its request names."},"PatientsInResponse":{"properties":{"patient_in":{"type":"string","const":"response","title":"Patient In"},"records":{"type":"string","maxLength":512,"title":"Records","description":"RFC 6901 JSON Pointer into the parsed response body, before any template, to the records:\na list of records, or one record. ``/patients`` is the list under ``patients``, and the empty\npointer is the whole body. A held call keeps only the records a caller may hear, and nothing\nbeside them, and the template renders those."},"patient":{"type":"string","maxLength":512,"minLength":1,"title":"Patient","description":"RFC 6901 JSON Pointer into each record to the identifier of the patient it belongs to, one\ntheir record on file carries, such as ``/patient_id``. On a service that verifies its callers\nthrough its own integration, the identifier its verifier returns."}},"type":"object","required":["patient_in","records","patient"],"title":"PatientsInResponse","description":"A call's response holds the patient records it found: a search, or a read by some other key."},"NoPatient":{"properties":{"patient_in":{"type":"string","const":"none","title":"Patient In"}},"type":"object","required":["patient_in"],"title":"NoPatient","description":"A call returns no patient's record: practice data, such as open slots, providers or articles."},"DataFreshnessBody":{"properties":{"as_of_column":{"type":"string","maxLength":63,"pattern":"^[a-z][a-z0-9_]*$","title":"As Of Column","description":"The result column holding when the row was last verified (a timestamp or ISO date). A lowercase\nidentifier, so the SQL names it without quoting."},"max_age_days":{"type":"integer","maximum":365,"minimum":1,"title":"Max Age Days","description":"A row older than this, or with no value, is stale."}},"additionalProperties":false,"type":"object","required":["as_of_column","max_age_days"],"title":"DataFreshnessBody","description":"The freshness a create or PATCH names. A key it doesn't have, such as a unit, is a 422."}}}}
```

## The src\_\_routes\_\_workspace\_data\_queries\_\_update\_workspace\_data\_query\_\_Request\_\_Parameter object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_data_queries__update_workspace_data_query__Request__Parameter":{"properties":{"name":{"type":"string","maxLength":64,"minLength":1,"pattern":"^[a-z][a-z0-9_]*$","title":"Name"},"type":{"type":"string","enum":["string","integer","number","boolean"],"title":"Type"},"description":{"type":"string","maxLength":512,"minLength":1,"title":"Description"},"default":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"type":"null"}],"title":"Default"},"authorization_binding":{"anyOf":[{"$ref":"#/components/schemas/RoleGrantKeysBinding"},{"type":"null"}]},"authorization_binding_test_value":{"anyOf":[{"type":"string","maxLength":2048},{"type":"null"}],"title":"Authorization Binding Test Value","description":"Canonical CSV resource keys used only by trusted playground execution when no live authorization block exists."}},"additionalProperties":false,"type":"object","required":["name","type","description"],"title":"Parameter","description":"One parameter the query declares."},"RoleGrantKeysBinding":{"properties":{"source":{"type":"string","const":"role_grant_resource_keys","title":"Source"},"resource_type":{"type":"string","const":"kb_scope","title":"Resource Type"},"access":{"type":"string","const":"read","title":"Access","default":"read"},"encoding":{"type":"string","const":"csv","title":"Encoding","default":"csv"}},"additionalProperties":false,"type":"object","required":["source","resource_type"],"title":"RoleGrantKeysBinding","description":"Binds a SQL parameter to the authorization of the turn, so the platform fills it in and the caller does not.\n\nAt execution the platform discards any caller value, takes the resource keys the turn's authorization\nholds for `resource_type` and `access`, encodes them as `encoding`, and binds the result to the parameter's\n`:name` placeholder. Neither the model nor the caller sees or supplies it. In a trusted test run with no live\nauthorization, the parameter's `authorization_binding_test_value` is bound instead. A bound parameter has no\n`default`. Only the values shown in the schema are accepted."}}}}
```

## The src\_\_routes\_\_workspace\_models\_\_WorkspaceModelListResponse\_\_Item object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_models__WorkspaceModelListResponse__Item":{"properties":{"id":{"type":"string","title":"Id"},"family":{"$ref":"#/components/schemas/ProviderFamily"},"transport":{"$ref":"#/components/schemas/Transport"},"regional":{"type":"boolean","title":"Regional","description":"Whether every path this model's requests can take stays in the region's geography."},"usable_for":{"items":{"$ref":"#/components/schemas/ModelUse"},"type":"array","title":"Usable For"},"reasoning_efforts":{"anyOf":[{"items":{"type":"string","enum":["none","minimal","low","medium","high","xhigh"]},"type":"array"},{"type":"null"}],"title":"Reasoning Efforts","description":"The engage reasoning efforts a version set may set on this model here; unset runs the model's default.\nNone when its provider sets its own effort (Claude, Gemini) and a version set's is not sent. Empty when it\ncan run no engage tool round in this region (GPT-6 Astra and GPT-6.1 Sol where the gateway serves no\nResponses route)."}},"type":"object","required":["id","family","transport","regional","usable_for","reasoning_efforts"],"title":"Item"},"ProviderFamily":{"type":"string","enum":["anthropic","google","openai","xai"]},"Transport":{"type":"string","enum":["gateway","decisions","vertex","vertex_priority","vertex_batch","bedrock","openai_direct","voice_vendor"]},"ModelUse":{"type":"string","enum":["engage","skill"]}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_create\_workspace\_table\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__create_workspace_table__Request":{"properties":{"table_name":{"$ref":"#/components/schemas/IdentifierString"},"columns":{"items":{"$ref":"#/components/schemas/Column-Input"},"type":"array","maxItems":100,"minItems":1,"title":"Columns"},"primary_key":{"anyOf":[{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array"},{"type":"null"}],"title":"Primary Key"},"unique":{"items":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1},"type":"array","title":"Unique"},"indexes":{"items":{"$ref":"#/components/schemas/Index-Input"},"type":"array","title":"Indexes"}},"type":"object","required":["table_name","columns"],"title":"Request"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"},"Column-Input":{"properties":{"name":{"$ref":"#/components/schemas/IdentifierString"},"type":{"$ref":"#/components/schemas/ColumnType"},"nullable":{"type":"boolean","title":"Nullable","default":true},"default":{"anyOf":[{"$ref":"#/components/schemas/Default"},{"type":"null"}]}},"type":"object","required":["name","type"],"title":"Column"},"ColumnType":{"type":"string","enum":["text","int","bigint","numeric","boolean","uuid","timestamptz","date","time","jsonb","bytea"]},"Default":{"properties":{"kind":{"type":"string","enum":["literal","uuid_v4","now","current_date"],"title":"Kind"},"value":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value","description":"Only meaningful for ``kind=\"literal\"``. Other kinds ignore it.\nA ``dict`` value is rendered as a JSONB literal — pair it with a\n``jsonb`` column."}},"type":"object","required":["kind"],"title":"Default"},"Index-Input":{"properties":{"columns":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1,"title":"Columns"}},"type":"object","required":["columns"],"title":"Index"}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_create\_workspace\_table\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__create_workspace_table__Response":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"table_name":{"type":"string","title":"Table Name"},"physical_name":{"type":"string","title":"Physical Name"}},"type":"object","required":["id","workspace_id","table_name","physical_name"],"title":"Response"}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_execute\_workspace\_query\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__execute_workspace_query__Request":{"properties":{"sql":{"type":"string","maxLength":16384,"minLength":1,"title":"Sql","description":"One SQL statement, run under the workspace's own role: a SELECT (with its WITH, UNION and the like),\nINSERT, UPDATE, DELETE or TRUNCATE. It may call only built-in functions that run no SQL text and change no\nsession state, written unquoted and unqualified. Anything else rejects with 422: DDL, SET, RESET and SET\nROLE, transaction control, a call to any other function, more than one statement, and SQL that doesn't\nparse."}},"type":"object","required":["sql"],"title":"Request"}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_execute\_workspace\_query\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__execute_workspace_query__Response":{"properties":{"columns":{"items":{"type":"string"},"type":"array","title":"Columns"},"rows":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Rows"},"row_count":{"type":"integer","title":"Row Count"}},"type":"object","required":["columns","rows","row_count"],"title":"Response"}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_get\_workspace\_table\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__get_workspace_table__Response":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"table_name":{"type":"string","title":"Table Name"},"physical_name":{"type":"string","title":"Physical Name"},"created_at":{"type":"string","format":"date-time","title":"Created At"},"columns":{"items":{"$ref":"#/components/schemas/Column-Output"},"type":"array","title":"Columns"},"indexes":{"items":{"$ref":"#/components/schemas/Index-Output"},"type":"array","title":"Indexes"},"constraints":{"items":{"$ref":"#/components/schemas/Constraint"},"type":"array","title":"Constraints"}},"type":"object","required":["id","workspace_id","table_name","physical_name","created_at","columns","indexes","constraints"],"title":"Response"},"Column-Output":{"properties":{"name":{"type":"string","title":"Name"},"data_type":{"type":"string","title":"Data Type","description":"Postgres-side type as reported by ``information_schema.columns``\n(e.g. ``uuid``, ``text``, ``timestamp with time zone``)."},"is_nullable":{"type":"boolean","title":"Is Nullable"},"default":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Default","description":"Postgres-side default expression text, or NULL if no DEFAULT."}},"type":"object","required":["name","data_type","is_nullable","default"],"title":"Column"},"Index-Output":{"properties":{"name":{"type":"string","title":"Name"},"definition":{"type":"string","title":"Definition","description":"``pg_indexes.indexdef`` — the full CREATE INDEX statement."}},"type":"object","required":["name","definition"],"title":"Index"},"Constraint":{"properties":{"name":{"type":"string","title":"Name"},"definition":{"type":"string","title":"Definition","description":"``pg_get_constraintdef(oid)`` — the postgres-rendered definition."}},"type":"object","required":["name","definition"],"title":"Constraint"}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_list\_workspace\_tables\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__list_workspace_tables__Response":{"properties":{"items":{"items":{"$ref":"#/components/schemas/src__routes__workspace_tables__list_workspace_tables__Response__Item"},"type":"array","title":"Items"}},"type":"object","required":["items"],"title":"Response"},"src__routes__workspace_tables__list_workspace_tables__Response__Item":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"table_name":{"type":"string","title":"Table Name"},"physical_name":{"type":"string","title":"Physical Name"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","workspace_id","table_name","physical_name","created_at"],"title":"Item"}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_list\_workspace\_tables\_\_Response\_\_Item object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__list_workspace_tables__Response__Item":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"table_name":{"type":"string","title":"Table Name"},"physical_name":{"type":"string","title":"Physical Name"},"created_at":{"type":"string","format":"date-time","title":"Created At"}},"type":"object","required":["id","workspace_id","table_name","physical_name","created_at"],"title":"Item"}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_update\_workspace\_table\_\_Request object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__update_workspace_table__Request":{"properties":{"actions":{"items":{"oneOf":[{"$ref":"#/components/schemas/AlterAction"}],"discriminator":{"propertyName":"op","mapping":{"add_column":"#/components/schemas/AlterAction","add_index":"#/components/schemas/AlterAction","add_unique":"#/components/schemas/AlterAction","change_column_type":"#/components/schemas/AlterAction","drop_column":"#/components/schemas/AlterAction","drop_column_default":"#/components/schemas/AlterAction","drop_constraint":"#/components/schemas/AlterAction","drop_index":"#/components/schemas/AlterAction","rename_column":"#/components/schemas/AlterAction","set_column_default":"#/components/schemas/AlterAction","set_column_nullable":"#/components/schemas/AlterAction"}}},"type":"array","maxItems":50,"minItems":1,"title":"Actions"}},"type":"object","required":["actions"],"title":"Request"},"AlterAction":{"anyOf":[{"$ref":"#/components/schemas/AddColumnAction"},{"$ref":"#/components/schemas/DropColumnAction"},{"$ref":"#/components/schemas/RenameColumnAction"},{"$ref":"#/components/schemas/ChangeColumnTypeAction"},{"$ref":"#/components/schemas/SetColumnNullableAction"},{"$ref":"#/components/schemas/SetColumnDefaultAction"},{"$ref":"#/components/schemas/DropColumnDefaultAction"},{"$ref":"#/components/schemas/AddUniqueAction"},{"$ref":"#/components/schemas/DropConstraintAction"},{"$ref":"#/components/schemas/AddIndexAction"},{"$ref":"#/components/schemas/DropIndexAction"}]},"AddColumnAction":{"properties":{"op":{"type":"string","const":"add_column","title":"Op"},"column":{"$ref":"#/components/schemas/Column-Input"}},"type":"object","required":["op","column"],"title":"AddColumnAction"},"Column-Input":{"properties":{"name":{"$ref":"#/components/schemas/IdentifierString"},"type":{"$ref":"#/components/schemas/ColumnType"},"nullable":{"type":"boolean","title":"Nullable","default":true},"default":{"anyOf":[{"$ref":"#/components/schemas/Default"},{"type":"null"}]}},"type":"object","required":["name","type"],"title":"Column"},"IdentifierString":{"type":"string","maxLength":63,"minLength":1,"pattern":"^[a-z][a-z0-9_]{0,62}$"},"ColumnType":{"type":"string","enum":["text","int","bigint","numeric","boolean","uuid","timestamptz","date","time","jsonb","bytea"]},"Default":{"properties":{"kind":{"type":"string","enum":["literal","uuid_v4","now","current_date"],"title":"Kind"},"value":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"number"},{"type":"boolean"},{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value","description":"Only meaningful for ``kind=\"literal\"``. Other kinds ignore it.\nA ``dict`` value is rendered as a JSONB literal — pair it with a\n``jsonb`` column."}},"type":"object","required":["kind"],"title":"Default"},"DropColumnAction":{"properties":{"op":{"type":"string","const":"drop_column","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropColumnAction"},"RenameColumnAction":{"properties":{"op":{"type":"string","const":"rename_column","title":"Op"},"from":{"$ref":"#/components/schemas/IdentifierString"},"to":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","from","to"],"title":"RenameColumnAction"},"ChangeColumnTypeAction":{"properties":{"op":{"type":"string","const":"change_column_type","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"new_type":{"$ref":"#/components/schemas/ColumnType"}},"type":"object","required":["op","name","new_type"],"title":"ChangeColumnTypeAction"},"SetColumnNullableAction":{"properties":{"op":{"type":"string","const":"set_column_nullable","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"nullable":{"type":"boolean","title":"Nullable"}},"type":"object","required":["op","name","nullable"],"title":"SetColumnNullableAction"},"SetColumnDefaultAction":{"properties":{"op":{"type":"string","const":"set_column_default","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"},"default":{"$ref":"#/components/schemas/Default"}},"type":"object","required":["op","name","default"],"title":"SetColumnDefaultAction"},"DropColumnDefaultAction":{"properties":{"op":{"type":"string","const":"drop_column_default","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropColumnDefaultAction"},"AddUniqueAction":{"properties":{"op":{"type":"string","const":"add_unique","title":"Op"},"columns":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1,"title":"Columns"},"constraint_name":{"anyOf":[{"$ref":"#/components/schemas/IdentifierString"},{"type":"null"}]}},"type":"object","required":["op","columns"],"title":"AddUniqueAction"},"DropConstraintAction":{"properties":{"op":{"type":"string","const":"drop_constraint","title":"Op"},"name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","name"],"title":"DropConstraintAction"},"AddIndexAction":{"properties":{"op":{"type":"string","const":"add_index","title":"Op"},"index_name":{"$ref":"#/components/schemas/IdentifierString"},"columns":{"items":{"$ref":"#/components/schemas/IdentifierString"},"type":"array","maxItems":32,"minItems":1,"title":"Columns"}},"type":"object","required":["op","index_name","columns"],"title":"AddIndexAction"},"DropIndexAction":{"properties":{"op":{"type":"string","const":"drop_index","title":"Op"},"index_name":{"$ref":"#/components/schemas/IdentifierString"}},"type":"object","required":["op","index_name"],"title":"DropIndexAction"}}}}
```

## The src\_\_routes\_\_workspace\_tables\_\_update\_workspace\_table\_\_Response object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__routes__workspace_tables__update_workspace_table__Response":{"properties":{"id":{"type":"string","format":"uuid","title":"Id"},"workspace_id":{"type":"string","format":"uuid","title":"Workspace Id"},"table_name":{"type":"string","title":"Table Name"},"physical_name":{"type":"string","title":"Physical Name"}},"type":"object","required":["id","workspace_id","table_name","physical_name"],"title":"Response"}}}}
```

## The src\_\_services\_\_safe\_exit\_reader\_\_SafeExit object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"src__services__safe_exit_reader__SafeExit":{"properties":{"trigger":{"type":"string","enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger","description":"Why the call took the safe exit."},"outcome":{"type":"string","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome","description":"``mrc_transferred`` once the hand-off to the human line was placed, ``mrc_failed`` when the hand-off raised\n(the caller may still be on the line), else ``mrc_ended`` (hung up). The conversation's ``completion_reason``\nreads these as ``transferred`` and ``error``."},"lines_played":{"items":{"type":"string","enum":["disclosure","transfer","end","fallback_missed","hearing_failure"]},"type":"array","title":"Lines Played","description":"The script lines that played whole, in order. ``disclosure`` is the AI and recording notice."},"disclosure_heard":{"type":"boolean","title":"Disclosure Heard","description":"The caller had heard all of the AI and recording notice before the exit began, so the exit did not\nplay it again. When false, the notice was heard only if ``lines_played`` holds ``disclosure``."},"trigger_description":{"type":"string","title":"Trigger Description","description":"``trigger`` in plain words.","readOnly":true}},"type":"object","required":["trigger","outcome","lines_played","disclosure_heard","trigger_description"],"title":"SafeExit","description":"The call's safe exit: the agent stopped and a fixed script handed the caller to a person or ended the call."}}}}
```

## The WorkspaceSSEEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceSSEEvent":{"discriminator":{"mapping":{"call.ended":"#/components/schemas/CallEndedEvent","call.escalated":"#/components/schemas/CallEscalatedEvent","call.started":"#/components/schemas/CallStartedEvent","encounter.updated":"#/components/schemas/EncounterUpdatedEvent","integration.approval_granted":"#/components/schemas/IntegrationApprovalGrantedEvent","integration.approval_rejected":"#/components/schemas/IntegrationApprovalRejectedEvent","operator.joined_call":"#/components/schemas/OperatorJoinedCallEvent","operator.left_call":"#/components/schemas/OperatorLeftCallEvent","operator.mode_changed":"#/components/schemas/OperatorModeChangedEvent","operator.profile_updated":"#/components/schemas/OperatorProfileUpdatedEvent","operator.registered":"#/components/schemas/OperatorRegisteredEvent","operator.status_changed":"#/components/schemas/OperatorStatusChangedEvent","operator.wrap_up":"#/components/schemas/OperatorWrapUpEvent","pipeline.error":"#/components/schemas/PipelineErrorEvent","pipeline.sync_completed":"#/components/schemas/PipelineSyncCompletedEvent","review.submitted":"#/components/schemas/ReviewSubmittedEvent","self_image.brief_generated":"#/components/schemas/NarrativeUpdatedEvent","simulation.turn_stored":"#/components/schemas/SimulationTurnStoredEvent","surface.archived":"#/components/schemas/SurfaceArchivedEvent","surface.created":"#/components/schemas/SurfaceCreatedEvent","surface.delivered":"#/components/schemas/SurfaceDeliveredEvent","surface.field_saved":"#/components/schemas/SurfaceFieldSavedEvent","surface.opened":"#/components/schemas/SurfaceOpenedEvent","surface.pending_review":"#/components/schemas/SurfacePendingReviewEvent","surface.reshaped":"#/components/schemas/SurfaceReshapedEvent","surface.review_approved":"#/components/schemas/SurfaceReviewApprovedEvent","surface.review_rejected":"#/components/schemas/SurfaceReviewRejectedEvent","surface.submitted":"#/components/schemas/SurfaceSubmittedEvent","surface.updated":"#/components/schemas/SurfaceUpdatedEvent","text.agent_message":"#/components/schemas/TextAgentMessageEvent","text.background_result":"#/components/schemas/TextBackgroundResultEvent","text.completed":"#/components/schemas/TextCompletedEvent","text.started":"#/components/schemas/TextStartedEvent","text.tool_started":"#/components/schemas/TextToolStartedEvent","trigger.completed":"#/components/schemas/TriggerCompletedEvent","trigger.failed":"#/components/schemas/TriggerFailedEvent","trigger.fired":"#/components/schemas/TriggerFiredEvent","workspace.invitation_accepted":"#/components/schemas/WorkspaceInvitationAcceptedEvent","workspace.invitation_sent":"#/components/schemas/WorkspaceInvitationSentEvent","workspace.member_added":"#/components/schemas/WorkspaceMemberAddedEvent","workspace.member_role_updated":"#/components/schemas/WorkspaceMemberRoleUpdatedEvent"},"propertyName":"event_type"},"oneOf":[{"$ref":"#/components/schemas/CallStartedEvent"},{"$ref":"#/components/schemas/CallEndedEvent"},{"$ref":"#/components/schemas/CallEscalatedEvent"},{"$ref":"#/components/schemas/EncounterUpdatedEvent"},{"$ref":"#/components/schemas/NarrativeUpdatedEvent"},{"$ref":"#/components/schemas/ReviewSubmittedEvent"},{"$ref":"#/components/schemas/SimulationTurnStoredEvent"},{"$ref":"#/components/schemas/SurfaceCreatedEvent"},{"$ref":"#/components/schemas/SurfaceDeliveredEvent"},{"$ref":"#/components/schemas/SurfaceUpdatedEvent"},{"$ref":"#/components/schemas/SurfaceArchivedEvent"},{"$ref":"#/components/schemas/SurfaceReshapedEvent"},{"$ref":"#/components/schemas/SurfaceSubmittedEvent"},{"$ref":"#/components/schemas/SurfaceFieldSavedEvent"},{"$ref":"#/components/schemas/SurfaceOpenedEvent"},{"$ref":"#/components/schemas/SurfacePendingReviewEvent"},{"$ref":"#/components/schemas/SurfaceReviewApprovedEvent"},{"$ref":"#/components/schemas/SurfaceReviewRejectedEvent"},{"$ref":"#/components/schemas/IntegrationApprovalGrantedEvent"},{"$ref":"#/components/schemas/IntegrationApprovalRejectedEvent"},{"$ref":"#/components/schemas/TextStartedEvent"},{"$ref":"#/components/schemas/TextCompletedEvent"},{"$ref":"#/components/schemas/TextToolStartedEvent"},{"$ref":"#/components/schemas/TextBackgroundResultEvent"},{"$ref":"#/components/schemas/TextAgentMessageEvent"},{"$ref":"#/components/schemas/TriggerFiredEvent"},{"$ref":"#/components/schemas/TriggerCompletedEvent"},{"$ref":"#/components/schemas/TriggerFailedEvent"},{"$ref":"#/components/schemas/PipelineSyncCompletedEvent"},{"$ref":"#/components/schemas/PipelineErrorEvent"},{"$ref":"#/components/schemas/OperatorRegisteredEvent"},{"$ref":"#/components/schemas/OperatorStatusChangedEvent"},{"$ref":"#/components/schemas/OperatorProfileUpdatedEvent"},{"$ref":"#/components/schemas/OperatorJoinedCallEvent"},{"$ref":"#/components/schemas/OperatorLeftCallEvent"},{"$ref":"#/components/schemas/OperatorModeChangedEvent"},{"$ref":"#/components/schemas/OperatorWrapUpEvent"},{"$ref":"#/components/schemas/WorkspaceMemberAddedEvent"},{"$ref":"#/components/schemas/WorkspaceMemberRoleUpdatedEvent"},{"$ref":"#/components/schemas/WorkspaceInvitationSentEvent"},{"$ref":"#/components/schemas/WorkspaceInvitationAcceptedEvent"}]},"CallStartedEvent":{"properties":{"event_type":{"const":"call.started","default":"call.started","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"direction":{"enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","type":"string"},"service_id":{"format":"uuid","title":"Service Id","type":"string"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Caller Id"}},"required":["call_sid","direction","service_id"],"title":"CallStartedEvent","type":"object"},"CallEndedEvent":{"properties":{"event_type":{"const":"call.ended","default":"call.ended","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"direction":{"enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","type":"string"},"duration_seconds":{"title":"Duration Seconds","type":"number"},"completion_reason":{"enum":["completed","silence_hangup","abandoned","escalated","transferred","timeout","error","voicemail","no_answer","caller_hangup","forwarded","terminal_state","warm_transfer_completed","no_inbound_audio","cancelled","closed"],"title":"Completion Reason","type":"string"},"escalated":{"default":false,"title":"Escalated","type":"boolean"}},"required":["call_sid","direction","duration_seconds","completion_reason"],"title":"CallEndedEvent","type":"object"},"CallEscalatedEvent":{"properties":{"event_type":{"const":"call.escalated","default":"call.escalated","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"escalation_id":{"title":"Escalation Id","type":"string"},"trigger":{"enum":["caller","ai","operator"],"title":"Trigger","type":"string"},"reason":{"title":"Reason","type":"string"}},"required":["call_sid","escalation_id","trigger","reason"],"title":"CallEscalatedEvent","type":"object"},"EncounterUpdatedEvent":{"properties":{"event_type":{"const":"encounter.updated","default":"encounter.updated","title":"Event Type","type":"string"},"encounter_entity_id":{"format":"uuid","title":"Encounter Entity Id","type":"string"},"session_id":{"title":"Session Id","type":"string"}},"required":["encounter_entity_id","session_id"],"title":"EncounterUpdatedEvent","type":"object"},"NarrativeUpdatedEvent":{"properties":{"event_type":{"const":"self_image.brief_generated","default":"self_image.brief_generated","title":"Event Type","type":"string"},"target_entity_id":{"format":"uuid","title":"Target Entity Id","type":"string"},"target_entity_type":{"title":"Target Entity Type","type":"string"},"event_id":{"format":"uuid","title":"Event Id","type":"string"},"version":{"title":"Version","type":"string"},"confidence":{"title":"Confidence","type":"number"},"event_count":{"title":"Event Count","type":"integer"}},"required":["target_entity_id","target_entity_type","event_id","version","confidence","event_count"],"title":"NarrativeUpdatedEvent","type":"object"},"ReviewSubmittedEvent":{"properties":{"event_type":{"const":"review.submitted","default":"review.submitted","title":"Event Type","type":"string"},"action":{"enum":["approve","reject","correct","batch_approve","batch_reject"],"title":"Action","type":"string"},"item_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Item Id"},"entity_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Entity Id"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Entity Type"},"count":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Count"}},"required":["action"],"title":"ReviewSubmittedEvent","type":"object"},"SimulationTurnStoredEvent":{"properties":{"event_type":{"const":"simulation.turn_stored","default":"simulation.turn_stored","title":"Event Type","type":"string"},"service_id":{"format":"uuid","title":"Service Id","type":"string"},"run_id":{"title":"Run Id","type":"string"},"session_id":{"title":"Session Id","type":"string"},"turn_index":{"title":"Turn Index","type":"integer"},"state_before":{"title":"State Before","type":"string"},"state_after":{"title":"State After","type":"string"},"is_terminal":{"title":"Is Terminal","type":"boolean"}},"required":["service_id","run_id","session_id","turn_index","state_before","state_after","is_terminal"],"title":"SimulationTurnStoredEvent","type":"object"},"SurfaceCreatedEvent":{"properties":{"event_type":{"const":"surface.created","default":"surface.created","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Channel"},"fields_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Fields Count"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Source"},"form_template_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Form Template Id"},"review_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Review Required"}},"required":["surface_id","entity_id"],"title":"SurfaceCreatedEvent","type":"object"},"SurfaceDeliveredEvent":{"properties":{"event_type":{"const":"surface.delivered","default":"surface.delivered","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"channel":{"title":"Channel","type":"string"},"channel_address":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Channel Address"},"delivery_status":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Delivery Status"},"message_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Message Id"},"short_url":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Short Url"}},"required":["surface_id","entity_id","channel"],"title":"SurfaceDeliveredEvent","type":"object"},"SurfaceUpdatedEvent":{"properties":{"event_type":{"const":"surface.updated","default":"surface.updated","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"}},"required":["surface_id"],"title":"SurfaceUpdatedEvent","type":"object"},"SurfaceArchivedEvent":{"properties":{"event_type":{"const":"surface.archived","default":"surface.archived","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"}},"required":["surface_id"],"title":"SurfaceArchivedEvent","type":"object"},"SurfaceReshapedEvent":{"properties":{"event_type":{"const":"surface.reshaped","default":"surface.reshaped","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"original_surface_id":{"format":"uuid","title":"Original Surface Id","type":"string"}},"required":["surface_id","original_surface_id"],"title":"SurfaceReshapedEvent","type":"object"},"SurfaceSubmittedEvent":{"properties":{"event_type":{"const":"surface.submitted","default":"surface.submitted","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"conversation_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The text conversation the surface was made for, or null for a surface made outside\none.","title":"Conversation Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"description":"The form's title, so an agent can name the form that came back.","title":"Title"},"submitted_at":{"anyOf":[{"maxLength":64,"type":"string"},{"type":"null"}],"default":null,"title":"Submitted At"},"fields_submitted":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"default":null,"title":"Fields Submitted"}},"required":["surface_id","entity_id"],"title":"SurfaceSubmittedEvent","type":"object"},"SurfaceFieldSavedEvent":{"properties":{"event_type":{"const":"surface.field_saved","default":"surface.field_saved","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"field_key":{"title":"Field Key","type":"string"}},"required":["surface_id","entity_id","field_key"],"title":"SurfaceFieldSavedEvent","type":"object"},"SurfaceOpenedEvent":{"properties":{"event_type":{"const":"surface.opened","default":"surface.opened","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"}},"required":["surface_id","entity_id"],"title":"SurfaceOpenedEvent","type":"object"},"SurfacePendingReviewEvent":{"properties":{"event_type":{"const":"surface.pending_review","default":"surface.pending_review","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Source"},"form_template_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Form Template Id"},"review_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Review Required"}},"required":["surface_id","entity_id"],"title":"SurfacePendingReviewEvent","type":"object"},"SurfaceReviewApprovedEvent":{"properties":{"event_type":{"const":"surface.review_approved","default":"surface.review_approved","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"}},"required":["surface_id"],"title":"SurfaceReviewApprovedEvent","type":"object"},"SurfaceReviewRejectedEvent":{"properties":{"event_type":{"const":"surface.review_rejected","default":"surface.review_rejected","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Reason"}},"required":["surface_id"],"title":"SurfaceReviewRejectedEvent","type":"object"},"IntegrationApprovalGrantedEvent":{"properties":{"event_type":{"const":"integration.approval_granted","default":"integration.approval_granted","title":"Event Type","type":"string"},"conversation_id":{"maxLength":256,"minLength":1,"title":"Conversation Id","type":"string"}},"required":["conversation_id"],"title":"IntegrationApprovalGrantedEvent","type":"object"},"IntegrationApprovalRejectedEvent":{"properties":{"event_type":{"const":"integration.approval_rejected","default":"integration.approval_rejected","title":"Event Type","type":"string"},"conversation_id":{"maxLength":256,"minLength":1,"title":"Conversation Id","type":"string"},"reason":{"anyOf":[{"maxLength":2000,"type":"string"},{"type":"null"}],"default":null,"title":"Reason"}},"required":["conversation_id"],"title":"IntegrationApprovalRejectedEvent","type":"object"},"TextStartedEvent":{"properties":{"event_type":{"const":"text.started","default":"text.started","title":"Event Type","type":"string"},"session_id":{"title":"Session Id","type":"string"},"service_id":{"format":"uuid","title":"Service Id","type":"string"},"channel_kind":{"title":"Channel Kind","type":"string"},"entity_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Entity Id"}},"required":["session_id","service_id","channel_kind"],"title":"TextStartedEvent","type":"object"},"TextCompletedEvent":{"properties":{"event_type":{"const":"text.completed","default":"text.completed","title":"Event Type","type":"string"},"session_id":{"title":"Session Id","type":"string"},"duration_seconds":{"title":"Duration Seconds","type":"number"},"turn_count":{"title":"Turn Count","type":"integer"},"completion_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Completion Reason"},"final_state":{"title":"Final State","type":"string"},"channel_kind":{"title":"Channel Kind","type":"string"}},"required":["session_id","duration_seconds","turn_count","final_state","channel_kind"],"title":"TextCompletedEvent","type":"object"},"TextToolStartedEvent":{"description":"A slow text tool *began* running for a web text conversation — pushed live\nthe instant the tool is dispatched, before the 15s blocking floor elapses, so a\nsubscribed client shows progress immediately instead of waiting out the floor in\nsilence (PLA-986). Emitted for tools that route through the background/floor-promoted\ndispatch paths (companion skills and ``execution=\"background\"`` tools) — the ones\nthat can outlast the turn's synchronous response.\n\nThe start/completion pair share one card identity: ``call_id`` is ``bg:<task_id>``,\nmatching the eventual ``TextBackgroundResultEvent`` (and the next-turn drained card\nfrom ``build_background_completion_effect``), so a client collapses started → result\ninto one card rather than rendering two. Web-only: ``conversation_id`` is the durable\nconversation UUID (non-web channels route by a composite key and deliver via their own\ntransport).","properties":{"conversation_id":{"format":"uuid","title":"Conversation Id","type":"string"},"event_type":{"const":"text.tool_started","default":"text.tool_started","title":"Event Type","type":"string"},"tool_name":{"title":"Tool Name","type":"string"},"call_id":{"title":"Call Id","type":"string"},"depth":{"title":"Depth","type":"integer"}},"required":["conversation_id","tool_name","call_id","depth"],"title":"TextToolStartedEvent","type":"object"},"TextBackgroundResultEvent":{"description":"A background (``execution=\"background\"``) tool finished for a web text\nconversation. Pushed live the instant the completion lands so a client watching\nthe conversation renders the result without polling or sending another message.\n\n``call_id`` is ``bg:<task_id>`` to match the card identity the next-turn drain\nsurfaces (``build_background_completion_effect``), so a client that receives\nboth the live push and the eventual drained card sees one consistent card.\nWeb-only: ``conversation_id`` is the durable conversation UUID (non-web\nchannels route by a composite key and deliver via their own transport).","properties":{"conversation_id":{"format":"uuid","title":"Conversation Id","type":"string"},"event_type":{"const":"text.background_result","default":"text.background_result","title":"Event Type","type":"string"},"tool_name":{"title":"Tool Name","type":"string"},"call_id":{"title":"Call Id","type":"string"},"succeeded":{"title":"Succeeded","type":"boolean"},"result":{"title":"Result","type":"string"},"depth":{"title":"Depth","type":"integer"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Duration Ms"}},"required":["conversation_id","tool_name","call_id","succeeded","result","depth"],"title":"TextBackgroundResultEvent","type":"object"},"TextAgentMessageEvent":{"description":"An agent text turn pushed live to the conversation's stream — the outbox of the\ndurable text-conversation actor (text-conversation-actor Stage A).\n\nWhere ``TextBackgroundResultEvent`` surfaces the raw tool card,\nthis carries the agent's *narrated* response: every turn the actor sends, whether it\nanswers a user turn or follows a background completion or other off-request signal, so\na client watching the conversation renders it as a normal agent message with no polling.\n``conversation_id`` is the durable conversation UUID (web-only).","properties":{"conversation_id":{"format":"uuid","title":"Conversation Id","type":"string"},"event_type":{"const":"text.agent_message","default":"text.agent_message","title":"Event Type","type":"string"},"text":{"title":"Text","type":"string"},"delivery_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Delivery Id"}},"required":["conversation_id","text"],"title":"TextAgentMessageEvent","type":"object"},"TriggerFiredEvent":{"properties":{"event_type":{"const":"trigger.fired","default":"trigger.fired","title":"Event Type","type":"string"},"trigger_id":{"format":"uuid","title":"Trigger Id","type":"string"},"trigger_name":{"title":"Trigger Name","type":"string"},"manual":{"default":false,"title":"Manual","type":"boolean"}},"required":["trigger_id","trigger_name"],"title":"TriggerFiredEvent","type":"object"},"TriggerCompletedEvent":{"properties":{"event_type":{"const":"trigger.completed","default":"trigger.completed","title":"Event Type","type":"string"},"trigger_id":{"format":"uuid","title":"Trigger Id","type":"string"},"trigger_name":{"title":"Trigger Name","type":"string"},"status":{"title":"Status","type":"string"}},"required":["trigger_id","trigger_name","status"],"title":"TriggerCompletedEvent","type":"object"},"TriggerFailedEvent":{"properties":{"event_type":{"const":"trigger.failed","default":"trigger.failed","title":"Event Type","type":"string"},"trigger_id":{"format":"uuid","title":"Trigger Id","type":"string"},"trigger_name":{"maxLength":256,"title":"Trigger Name","type":"string"},"status":{"maxLength":32,"title":"Status","type":"string"}},"required":["trigger_id","trigger_name","status"],"title":"TriggerFailedEvent","type":"object"},"PipelineSyncCompletedEvent":{"properties":{"event_type":{"const":"pipeline.sync_completed","default":"pipeline.sync_completed","title":"Event Type","type":"string"},"data_source_id":{"format":"uuid","title":"Data Source Id","type":"string"},"event_count":{"title":"Event Count","type":"integer"},"duration_ms":{"title":"Duration Ms","type":"integer"}},"required":["data_source_id","event_count","duration_ms"],"title":"PipelineSyncCompletedEvent","type":"object"},"PipelineErrorEvent":{"properties":{"event_type":{"const":"pipeline.error","default":"pipeline.error","title":"Event Type","type":"string"},"data_source_id":{"format":"uuid","title":"Data Source Id","type":"string"},"error":{"title":"Error","type":"string"}},"required":["data_source_id","error"],"title":"PipelineErrorEvent","type":"object"},"OperatorRegisteredEvent":{"properties":{"event_type":{"const":"operator.registered","default":"operator.registered","title":"Event Type","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Timestamp"}},"required":["operator_id"],"title":"OperatorRegisteredEvent","type":"object"},"OperatorStatusChangedEvent":{"properties":{"event_type":{"const":"operator.status_changed","default":"operator.status_changed","title":"Event Type","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"status":{"enum":["online","busy","offline"],"title":"Status","type":"string"}},"required":["operator_id","status"],"title":"OperatorStatusChangedEvent","type":"object"},"OperatorProfileUpdatedEvent":{"properties":{"event_type":{"const":"operator.profile_updated","default":"operator.profile_updated","title":"Event Type","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"changes":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},{"type":"null"}],"default":null,"title":"Changes"}},"required":["operator_id"],"title":"OperatorProfileUpdatedEvent","type":"object"},"OperatorJoinedCallEvent":{"properties":{"event_type":{"const":"operator.joined_call","default":"operator.joined_call","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"mode":{"enum":["listen","takeover"],"title":"Mode","type":"string"}},"required":["call_sid","operator_id","mode"],"title":"OperatorJoinedCallEvent","type":"object"},"OperatorLeftCallEvent":{"properties":{"event_type":{"const":"operator.left_call","default":"operator.left_call","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"human_segment_turn_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Human Segment Turn Count"}},"required":["call_sid","operator_id"],"title":"OperatorLeftCallEvent","type":"object"},"OperatorModeChangedEvent":{"properties":{"event_type":{"const":"operator.mode_changed","default":"operator.mode_changed","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"mode":{"enum":["listen","takeover"],"title":"Mode","type":"string"}},"required":["call_sid","operator_id","mode"],"title":"OperatorModeChangedEvent","type":"object"},"OperatorWrapUpEvent":{"properties":{"event_type":{"const":"operator.wrap_up","default":"operator.wrap_up","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"wrap_up_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Wrap Up Reason"}},"required":["call_sid"],"title":"OperatorWrapUpEvent","type":"object"},"WorkspaceMemberAddedEvent":{"properties":{"event_type":{"const":"workspace.member_added","default":"workspace.member_added","title":"Event Type","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"role":{"title":"Role","type":"string"}},"required":["entity_id","role"],"title":"WorkspaceMemberAddedEvent","type":"object"},"WorkspaceMemberRoleUpdatedEvent":{"properties":{"event_type":{"const":"workspace.member_role_updated","default":"workspace.member_role_updated","title":"Event Type","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"role":{"title":"Role","type":"string"},"previous_role":{"title":"Previous Role","type":"string"}},"required":["entity_id","role","previous_role"],"title":"WorkspaceMemberRoleUpdatedEvent","type":"object"},"WorkspaceInvitationSentEvent":{"properties":{"event_type":{"const":"workspace.invitation_sent","default":"workspace.invitation_sent","title":"Event Type","type":"string"},"invitation_id":{"title":"Invitation Id","type":"string"},"role":{"title":"Role","type":"string"},"resent":{"default":false,"title":"Resent","type":"boolean"}},"required":["invitation_id","role"],"title":"WorkspaceInvitationSentEvent","type":"object"},"WorkspaceInvitationAcceptedEvent":{"properties":{"event_type":{"const":"workspace.invitation_accepted","default":"workspace.invitation_accepted","title":"Event Type","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"role":{"title":"Role","type":"string"}},"required":["entity_id","role"],"title":"WorkspaceInvitationAcceptedEvent","type":"object"}}}}
```

## The WorkspaceInvitationAcceptedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceInvitationAcceptedEvent":{"properties":{"event_type":{"const":"workspace.invitation_accepted","default":"workspace.invitation_accepted","title":"Event Type","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"role":{"title":"Role","type":"string"}},"required":["entity_id","role"],"title":"WorkspaceInvitationAcceptedEvent","type":"object"}}}}
```

## The WorkspaceInvitationSentEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceInvitationSentEvent":{"properties":{"event_type":{"const":"workspace.invitation_sent","default":"workspace.invitation_sent","title":"Event Type","type":"string"},"invitation_id":{"title":"Invitation Id","type":"string"},"role":{"title":"Role","type":"string"},"resent":{"default":false,"title":"Resent","type":"boolean"}},"required":["invitation_id","role"],"title":"WorkspaceInvitationSentEvent","type":"object"}}}}
```

## The WorkspaceMemberRoleUpdatedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceMemberRoleUpdatedEvent":{"properties":{"event_type":{"const":"workspace.member_role_updated","default":"workspace.member_role_updated","title":"Event Type","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"role":{"title":"Role","type":"string"},"previous_role":{"title":"Previous Role","type":"string"}},"required":["entity_id","role","previous_role"],"title":"WorkspaceMemberRoleUpdatedEvent","type":"object"}}}}
```

## The WorkspaceMemberAddedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"WorkspaceMemberAddedEvent":{"properties":{"event_type":{"const":"workspace.member_added","default":"workspace.member_added","title":"Event Type","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"role":{"title":"Role","type":"string"}},"required":["entity_id","role"],"title":"WorkspaceMemberAddedEvent","type":"object"}}}}
```

## The OperatorWrapUpEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorWrapUpEvent":{"properties":{"event_type":{"const":"operator.wrap_up","default":"operator.wrap_up","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"wrap_up_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Wrap Up Reason"}},"required":["call_sid"],"title":"OperatorWrapUpEvent","type":"object"}}}}
```

## The OperatorModeChangedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorModeChangedEvent":{"properties":{"event_type":{"const":"operator.mode_changed","default":"operator.mode_changed","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"mode":{"enum":["listen","takeover"],"title":"Mode","type":"string"}},"required":["call_sid","operator_id","mode"],"title":"OperatorModeChangedEvent","type":"object"}}}}
```

## The OperatorLeftCallEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorLeftCallEvent":{"properties":{"event_type":{"const":"operator.left_call","default":"operator.left_call","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"human_segment_turn_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Human Segment Turn Count"}},"required":["call_sid","operator_id"],"title":"OperatorLeftCallEvent","type":"object"}}}}
```

## The OperatorJoinedCallEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorJoinedCallEvent":{"properties":{"event_type":{"const":"operator.joined_call","default":"operator.joined_call","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"mode":{"enum":["listen","takeover"],"title":"Mode","type":"string"}},"required":["call_sid","operator_id","mode"],"title":"OperatorJoinedCallEvent","type":"object"}}}}
```

## The OperatorProfileUpdatedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorProfileUpdatedEvent":{"properties":{"event_type":{"const":"operator.profile_updated","default":"operator.profile_updated","title":"Event Type","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"changes":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"null"}]},"type":"object"},{"type":"null"}],"default":null,"title":"Changes"}},"required":["operator_id"],"title":"OperatorProfileUpdatedEvent","type":"object"}}}}
```

## The OperatorStatusChangedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorStatusChangedEvent":{"properties":{"event_type":{"const":"operator.status_changed","default":"operator.status_changed","title":"Event Type","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"status":{"enum":["online","busy","offline"],"title":"Status","type":"string"}},"required":["operator_id","status"],"title":"OperatorStatusChangedEvent","type":"object"}}}}
```

## The OperatorRegisteredEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"OperatorRegisteredEvent":{"properties":{"event_type":{"const":"operator.registered","default":"operator.registered","title":"Event Type","type":"string"},"operator_id":{"format":"uuid","title":"Operator Id","type":"string"},"timestamp":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Timestamp"}},"required":["operator_id"],"title":"OperatorRegisteredEvent","type":"object"}}}}
```

## The PipelineErrorEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PipelineErrorEvent":{"properties":{"event_type":{"const":"pipeline.error","default":"pipeline.error","title":"Event Type","type":"string"},"data_source_id":{"format":"uuid","title":"Data Source Id","type":"string"},"error":{"title":"Error","type":"string"}},"required":["data_source_id","error"],"title":"PipelineErrorEvent","type":"object"}}}}
```

## The PipelineSyncCompletedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"PipelineSyncCompletedEvent":{"properties":{"event_type":{"const":"pipeline.sync_completed","default":"pipeline.sync_completed","title":"Event Type","type":"string"},"data_source_id":{"format":"uuid","title":"Data Source Id","type":"string"},"event_count":{"title":"Event Count","type":"integer"},"duration_ms":{"title":"Duration Ms","type":"integer"}},"required":["data_source_id","event_count","duration_ms"],"title":"PipelineSyncCompletedEvent","type":"object"}}}}
```

## The TriggerFailedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerFailedEvent":{"properties":{"event_type":{"const":"trigger.failed","default":"trigger.failed","title":"Event Type","type":"string"},"trigger_id":{"format":"uuid","title":"Trigger Id","type":"string"},"trigger_name":{"maxLength":256,"title":"Trigger Name","type":"string"},"status":{"maxLength":32,"title":"Status","type":"string"}},"required":["trigger_id","trigger_name","status"],"title":"TriggerFailedEvent","type":"object"}}}}
```

## The TriggerCompletedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerCompletedEvent":{"properties":{"event_type":{"const":"trigger.completed","default":"trigger.completed","title":"Event Type","type":"string"},"trigger_id":{"format":"uuid","title":"Trigger Id","type":"string"},"trigger_name":{"title":"Trigger Name","type":"string"},"status":{"title":"Status","type":"string"}},"required":["trigger_id","trigger_name","status"],"title":"TriggerCompletedEvent","type":"object"}}}}
```

## The TriggerFiredEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TriggerFiredEvent":{"properties":{"event_type":{"const":"trigger.fired","default":"trigger.fired","title":"Event Type","type":"string"},"trigger_id":{"format":"uuid","title":"Trigger Id","type":"string"},"trigger_name":{"title":"Trigger Name","type":"string"},"manual":{"default":false,"title":"Manual","type":"boolean"}},"required":["trigger_id","trigger_name"],"title":"TriggerFiredEvent","type":"object"}}}}
```

## The TextAgentMessageEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TextAgentMessageEvent":{"description":"An agent text turn pushed live to the conversation's stream — the outbox of the\ndurable text-conversation actor (text-conversation-actor Stage A).\n\nWhere ``TextBackgroundResultEvent`` surfaces the raw tool card,\nthis carries the agent's *narrated* response: every turn the actor sends, whether it\nanswers a user turn or follows a background completion or other off-request signal, so\na client watching the conversation renders it as a normal agent message with no polling.\n``conversation_id`` is the durable conversation UUID (web-only).","properties":{"conversation_id":{"format":"uuid","title":"Conversation Id","type":"string"},"event_type":{"const":"text.agent_message","default":"text.agent_message","title":"Event Type","type":"string"},"text":{"title":"Text","type":"string"},"delivery_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Delivery Id"}},"required":["conversation_id","text"],"title":"TextAgentMessageEvent","type":"object"}}}}
```

## The TextBackgroundResultEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TextBackgroundResultEvent":{"description":"A background (``execution=\"background\"``) tool finished for a web text\nconversation. Pushed live the instant the completion lands so a client watching\nthe conversation renders the result without polling or sending another message.\n\n``call_id`` is ``bg:<task_id>`` to match the card identity the next-turn drain\nsurfaces (``build_background_completion_effect``), so a client that receives\nboth the live push and the eventual drained card sees one consistent card.\nWeb-only: ``conversation_id`` is the durable conversation UUID (non-web\nchannels route by a composite key and deliver via their own transport).","properties":{"conversation_id":{"format":"uuid","title":"Conversation Id","type":"string"},"event_type":{"const":"text.background_result","default":"text.background_result","title":"Event Type","type":"string"},"tool_name":{"title":"Tool Name","type":"string"},"call_id":{"title":"Call Id","type":"string"},"succeeded":{"title":"Succeeded","type":"boolean"},"result":{"title":"Result","type":"string"},"depth":{"title":"Depth","type":"integer"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Duration Ms"}},"required":["conversation_id","tool_name","call_id","succeeded","result","depth"],"title":"TextBackgroundResultEvent","type":"object"}}}}
```

## The TextToolStartedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TextToolStartedEvent":{"description":"A slow text tool *began* running for a web text conversation — pushed live\nthe instant the tool is dispatched, before the 15s blocking floor elapses, so a\nsubscribed client shows progress immediately instead of waiting out the floor in\nsilence (PLA-986). Emitted for tools that route through the background/floor-promoted\ndispatch paths (companion skills and ``execution=\"background\"`` tools) — the ones\nthat can outlast the turn's synchronous response.\n\nThe start/completion pair share one card identity: ``call_id`` is ``bg:<task_id>``,\nmatching the eventual ``TextBackgroundResultEvent`` (and the next-turn drained card\nfrom ``build_background_completion_effect``), so a client collapses started → result\ninto one card rather than rendering two. Web-only: ``conversation_id`` is the durable\nconversation UUID (non-web channels route by a composite key and deliver via their own\ntransport).","properties":{"conversation_id":{"format":"uuid","title":"Conversation Id","type":"string"},"event_type":{"const":"text.tool_started","default":"text.tool_started","title":"Event Type","type":"string"},"tool_name":{"title":"Tool Name","type":"string"},"call_id":{"title":"Call Id","type":"string"},"depth":{"title":"Depth","type":"integer"}},"required":["conversation_id","tool_name","call_id","depth"],"title":"TextToolStartedEvent","type":"object"}}}}
```

## The TextCompletedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TextCompletedEvent":{"properties":{"event_type":{"const":"text.completed","default":"text.completed","title":"Event Type","type":"string"},"session_id":{"title":"Session Id","type":"string"},"duration_seconds":{"title":"Duration Seconds","type":"number"},"turn_count":{"title":"Turn Count","type":"integer"},"completion_reason":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Completion Reason"},"final_state":{"title":"Final State","type":"string"},"channel_kind":{"title":"Channel Kind","type":"string"}},"required":["session_id","duration_seconds","turn_count","final_state","channel_kind"],"title":"TextCompletedEvent","type":"object"}}}}
```

## The TextStartedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TextStartedEvent":{"properties":{"event_type":{"const":"text.started","default":"text.started","title":"Event Type","type":"string"},"session_id":{"title":"Session Id","type":"string"},"service_id":{"format":"uuid","title":"Service Id","type":"string"},"channel_kind":{"title":"Channel Kind","type":"string"},"entity_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Entity Id"}},"required":["session_id","service_id","channel_kind"],"title":"TextStartedEvent","type":"object"}}}}
```

## The IntegrationApprovalRejectedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IntegrationApprovalRejectedEvent":{"properties":{"event_type":{"const":"integration.approval_rejected","default":"integration.approval_rejected","title":"Event Type","type":"string"},"conversation_id":{"maxLength":256,"minLength":1,"title":"Conversation Id","type":"string"},"reason":{"anyOf":[{"maxLength":2000,"type":"string"},{"type":"null"}],"default":null,"title":"Reason"}},"required":["conversation_id"],"title":"IntegrationApprovalRejectedEvent","type":"object"}}}}
```

## The IntegrationApprovalGrantedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"IntegrationApprovalGrantedEvent":{"properties":{"event_type":{"const":"integration.approval_granted","default":"integration.approval_granted","title":"Event Type","type":"string"},"conversation_id":{"maxLength":256,"minLength":1,"title":"Conversation Id","type":"string"}},"required":["conversation_id"],"title":"IntegrationApprovalGrantedEvent","type":"object"}}}}
```

## The SurfaceReviewRejectedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceReviewRejectedEvent":{"properties":{"event_type":{"const":"surface.review_rejected","default":"surface.review_rejected","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"reason":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Reason"}},"required":["surface_id"],"title":"SurfaceReviewRejectedEvent","type":"object"}}}}
```

## The SurfaceReviewApprovedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceReviewApprovedEvent":{"properties":{"event_type":{"const":"surface.review_approved","default":"surface.review_approved","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"}},"required":["surface_id"],"title":"SurfaceReviewApprovedEvent","type":"object"}}}}
```

## The SurfacePendingReviewEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfacePendingReviewEvent":{"properties":{"event_type":{"const":"surface.pending_review","default":"surface.pending_review","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Source"},"form_template_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Form Template Id"},"review_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Review Required"}},"required":["surface_id","entity_id"],"title":"SurfacePendingReviewEvent","type":"object"}}}}
```

## The SurfaceOpenedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceOpenedEvent":{"properties":{"event_type":{"const":"surface.opened","default":"surface.opened","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"}},"required":["surface_id","entity_id"],"title":"SurfaceOpenedEvent","type":"object"}}}}
```

## The SurfaceFieldSavedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceFieldSavedEvent":{"properties":{"event_type":{"const":"surface.field_saved","default":"surface.field_saved","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"field_key":{"title":"Field Key","type":"string"}},"required":["surface_id","entity_id","field_key"],"title":"SurfaceFieldSavedEvent","type":"object"}}}}
```

## The SurfaceSubmittedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceSubmittedEvent":{"properties":{"event_type":{"const":"surface.submitted","default":"surface.submitted","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"conversation_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The text conversation the surface was made for, or null for a surface made outside\none.","title":"Conversation Id"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"description":"The form's title, so an agent can name the form that came back.","title":"Title"},"submitted_at":{"anyOf":[{"maxLength":64,"type":"string"},{"type":"null"}],"default":null,"title":"Submitted At"},"fields_submitted":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"default":null,"title":"Fields Submitted"}},"required":["surface_id","entity_id"],"title":"SurfaceSubmittedEvent","type":"object"}}}}
```

## The SurfaceReshapedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceReshapedEvent":{"properties":{"event_type":{"const":"surface.reshaped","default":"surface.reshaped","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"original_surface_id":{"format":"uuid","title":"Original Surface Id","type":"string"}},"required":["surface_id","original_surface_id"],"title":"SurfaceReshapedEvent","type":"object"}}}}
```

## The SurfaceArchivedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceArchivedEvent":{"properties":{"event_type":{"const":"surface.archived","default":"surface.archived","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"}},"required":["surface_id"],"title":"SurfaceArchivedEvent","type":"object"}}}}
```

## The SurfaceUpdatedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceUpdatedEvent":{"properties":{"event_type":{"const":"surface.updated","default":"surface.updated","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"}},"required":["surface_id"],"title":"SurfaceUpdatedEvent","type":"object"}}}}
```

## The SurfaceDeliveredEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceDeliveredEvent":{"properties":{"event_type":{"const":"surface.delivered","default":"surface.delivered","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"channel":{"title":"Channel","type":"string"},"channel_address":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Channel Address"},"delivery_status":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Delivery Status"},"message_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Message Id"},"short_url":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Short Url"}},"required":["surface_id","entity_id","channel"],"title":"SurfaceDeliveredEvent","type":"object"}}}}
```

## The SurfaceCreatedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SurfaceCreatedEvent":{"properties":{"event_type":{"const":"surface.created","default":"surface.created","title":"Event Type","type":"string"},"surface_id":{"format":"uuid","title":"Surface Id","type":"string"},"entity_id":{"format":"uuid","title":"Entity Id","type":"string"},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Channel"},"fields_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Fields Count"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Source"},"form_template_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Form Template Id"},"review_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Review Required"}},"required":["surface_id","entity_id"],"title":"SurfaceCreatedEvent","type":"object"}}}}
```

## The SimulationTurnStoredEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SimulationTurnStoredEvent":{"properties":{"event_type":{"const":"simulation.turn_stored","default":"simulation.turn_stored","title":"Event Type","type":"string"},"service_id":{"format":"uuid","title":"Service Id","type":"string"},"run_id":{"title":"Run Id","type":"string"},"session_id":{"title":"Session Id","type":"string"},"turn_index":{"title":"Turn Index","type":"integer"},"state_before":{"title":"State Before","type":"string"},"state_after":{"title":"State After","type":"string"},"is_terminal":{"title":"Is Terminal","type":"boolean"}},"required":["service_id","run_id","session_id","turn_index","state_before","state_after","is_terminal"],"title":"SimulationTurnStoredEvent","type":"object"}}}}
```

## The ReviewSubmittedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ReviewSubmittedEvent":{"properties":{"event_type":{"const":"review.submitted","default":"review.submitted","title":"Event Type","type":"string"},"action":{"enum":["approve","reject","correct","batch_approve","batch_reject"],"title":"Action","type":"string"},"item_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Item Id"},"entity_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Entity Id"},"entity_type":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Entity Type"},"count":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Count"}},"required":["action"],"title":"ReviewSubmittedEvent","type":"object"}}}}
```

## The NarrativeUpdatedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NarrativeUpdatedEvent":{"properties":{"event_type":{"const":"self_image.brief_generated","default":"self_image.brief_generated","title":"Event Type","type":"string"},"target_entity_id":{"format":"uuid","title":"Target Entity Id","type":"string"},"target_entity_type":{"title":"Target Entity Type","type":"string"},"event_id":{"format":"uuid","title":"Event Id","type":"string"},"version":{"title":"Version","type":"string"},"confidence":{"title":"Confidence","type":"number"},"event_count":{"title":"Event Count","type":"integer"}},"required":["target_entity_id","target_entity_type","event_id","version","confidence","event_count"],"title":"NarrativeUpdatedEvent","type":"object"}}}}
```

## The EncounterUpdatedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EncounterUpdatedEvent":{"properties":{"event_type":{"const":"encounter.updated","default":"encounter.updated","title":"Event Type","type":"string"},"encounter_entity_id":{"format":"uuid","title":"Encounter Entity Id","type":"string"},"session_id":{"title":"Session Id","type":"string"}},"required":["encounter_entity_id","session_id"],"title":"EncounterUpdatedEvent","type":"object"}}}}
```

## The CallEscalatedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallEscalatedEvent":{"properties":{"event_type":{"const":"call.escalated","default":"call.escalated","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"escalation_id":{"title":"Escalation Id","type":"string"},"trigger":{"enum":["caller","ai","operator"],"title":"Trigger","type":"string"},"reason":{"title":"Reason","type":"string"}},"required":["call_sid","escalation_id","trigger","reason"],"title":"CallEscalatedEvent","type":"object"}}}}
```

## The CallEndedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallEndedEvent":{"properties":{"event_type":{"const":"call.ended","default":"call.ended","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"direction":{"enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","type":"string"},"duration_seconds":{"title":"Duration Seconds","type":"number"},"completion_reason":{"enum":["completed","silence_hangup","abandoned","escalated","transferred","timeout","error","voicemail","no_answer","caller_hangup","forwarded","terminal_state","warm_transfer_completed","no_inbound_audio","cancelled","closed"],"title":"Completion Reason","type":"string"},"escalated":{"default":false,"title":"Escalated","type":"boolean"}},"required":["call_sid","direction","duration_seconds","completion_reason"],"title":"CallEndedEvent","type":"object"}}}}
```

## The CallStartedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"CallStartedEvent":{"properties":{"event_type":{"const":"call.started","default":"call.started","title":"Event Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"direction":{"enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","type":"string"},"service_id":{"format":"uuid","title":"Service Id","type":"string"},"caller_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Caller Id"}},"required":["call_sid","direction","service_id"],"title":"CallStartedEvent","type":"object"}}}}
```

## The ObserverSSEEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ObserverSSEEvent":{"discriminator":{"mapping":{"actor_allocated":"#/components/schemas/ActorAllocatedEvent","actor_shutdown":"#/components/schemas/ActorShutdownEvent","agent_transcript":"#/components/schemas/AgentTranscriptEvent","agent_transcript_delta":"#/components/schemas/AgentTranscriptDeltaEvent","barge_in":"#/components/schemas/BargeInEvent","disclosure_played":"#/components/schemas/DisclosurePlayedEvent","dynamic_behavior_decided":"#/components/schemas/DynamicBehaviorDecidedEvent","empathy_classified":"#/components/schemas/EmpathyClassifiedEvent","forward_call_resolved":"#/components/schemas/ForwardCallResolvedEvent","latency":"#/components/schemas/LatencyEvent","media_attached":"#/components/schemas/MediaAttachedEvent","minimal_risk_completed":"#/components/schemas/MinimalRiskCompletedEvent","minimal_risk_started":"#/components/schemas/MinimalRiskStartedEvent","nav_timing":"#/components/schemas/NavTimingEvent","participant_joined":"#/components/schemas/ParticipantJoinedEvent","participant_left":"#/components/schemas/ParticipantLeftEvent","session_end":"#/components/schemas/SessionEndEvent","session_info":"#/components/schemas/SessionInfoEvent","session_start":"#/components/schemas/SessionStartEvent","speaker_muted":"#/components/schemas/SpeakerMutedEvent","state_transition":"#/components/schemas/StateTransitionEvent","tool_call_completed":"#/components/schemas/ToolCallCompletedEvent","tool_call_started":"#/components/schemas/ToolCallStartedEvent","user_transcript":"#/components/schemas/UserTranscriptEvent","voice_context_applied":"#/components/schemas/VoiceContextAppliedEvent"},"propertyName":"type"},"oneOf":[{"$ref":"#/components/schemas/ActorAllocatedEvent"},{"$ref":"#/components/schemas/ActorShutdownEvent"},{"$ref":"#/components/schemas/AgentTranscriptDeltaEvent"},{"$ref":"#/components/schemas/AgentTranscriptEvent"},{"$ref":"#/components/schemas/BargeInEvent"},{"$ref":"#/components/schemas/DisclosurePlayedEvent"},{"$ref":"#/components/schemas/DynamicBehaviorDecidedEvent"},{"$ref":"#/components/schemas/EmpathyClassifiedEvent"},{"$ref":"#/components/schemas/ForwardCallResolvedEvent"},{"$ref":"#/components/schemas/LatencyEvent"},{"$ref":"#/components/schemas/MediaAttachedEvent"},{"$ref":"#/components/schemas/MinimalRiskCompletedEvent"},{"$ref":"#/components/schemas/MinimalRiskStartedEvent"},{"$ref":"#/components/schemas/NavTimingEvent"},{"$ref":"#/components/schemas/ParticipantJoinedEvent"},{"$ref":"#/components/schemas/ParticipantLeftEvent"},{"$ref":"#/components/schemas/SessionEndEvent"},{"$ref":"#/components/schemas/SessionInfoEvent"},{"$ref":"#/components/schemas/SessionStartEvent"},{"$ref":"#/components/schemas/SpeakerMutedEvent"},{"$ref":"#/components/schemas/StateTransitionEvent"},{"$ref":"#/components/schemas/ToolCallCompletedEvent"},{"$ref":"#/components/schemas/ToolCallStartedEvent"},{"$ref":"#/components/schemas/UserTranscriptEvent"},{"$ref":"#/components/schemas/VoiceContextAppliedEvent"}]},"ActorAllocatedEvent":{"description":"The call was bound to its isolated runtime — one call = one Agones GameServer.\n\nEmitted by the dispatcher the moment it allocates a warm GameServer for the call,\nso an observer can see WHICH pod/node powers this call and how long allocation took.","properties":{"type":{"const":"actor_allocated","default":"actor_allocated","title":"Type","type":"string"},"gameserver":{"maxLength":256,"title":"Gameserver","type":"string"},"node":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Node"},"alloc_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Alloc Latency Ms"}},"required":["gameserver"],"title":"ActorAllocatedEvent","type":"object"},"ActorShutdownEvent":{"description":"The call's GameServer was reaped (Allocated GameServers are deploy-immune).\n\nToday only ``reason=call_ended`` is produced (normal call-end teardown).\n``orphan_no_media`` is reserved in the contract for the orphan reaper — a pod that\nwent Allocated but never received media — but that emit is not yet wired: at reap\ntime the reaper pod has no call identity (allocation is cross-pod), so plumbing the\ncall_sid to it is a follow-up. The value is pre-declared so adding it later is a\nnon-breaking widening for SDK consumers, not a breaking enum change.","properties":{"type":{"const":"actor_shutdown","default":"actor_shutdown","title":"Type","type":"string"},"reason":{"default":"call_ended","enum":["call_ended","orphan_no_media"],"title":"Reason","type":"string"},"lifetime_s":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Lifetime S"}},"title":"ActorShutdownEvent","type":"object"},"AgentTranscriptDeltaEvent":{"properties":{"type":{"const":"agent_transcript_delta","default":"agent_transcript_delta","title":"Type","type":"string"},"delta":{"title":"Delta","type":"string"}},"required":["delta"],"title":"AgentTranscriptDeltaEvent","type":"object"},"AgentTranscriptEvent":{"properties":{"type":{"const":"agent_transcript","default":"agent_transcript","title":"Type","type":"string"},"transcript":{"title":"Transcript","type":"string"},"action":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Action"},"interrupted":{"default":false,"title":"Interrupted","type":"boolean"},"filler_type":{"anyOf":[{"enum":["empathy","receipt","working"],"type":"string"},{"type":"null"}],"default":null,"title":"Filler Type"},"speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Speaker Id"},"speaker_role":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Speaker Role"},"streaming":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Streaming"}},"required":["transcript"],"title":"AgentTranscriptEvent","type":"object"},"BargeInEvent":{"properties":{"type":{"const":"barge_in","default":"barge_in","title":"Type","type":"string"},"interrupted_text":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupted Text"},"discarded_texts":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"default":null,"title":"Discarded Texts"},"interrupted_speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupted Speaker Id"},"interrupting_speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Interrupting Speaker Id"},"total_barge_ins":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Total Barge Ins"}},"title":"BargeInEvent","type":"object"},"DisclosurePlayedEvent":{"description":"One play of the call's AI and recording notice, or an attempt none of which could play.\n\nIts fields keep the ``voice.disclosure.*`` keys the call's trace records them under.","properties":{"type":{"const":"disclosure_played","default":"disclosure_played","title":"Type","type":"string"},"voice.disclosure.path":{"description":"What played it: the cascade (``direct``, ``speaker``), the realtime model, or the safe exit.","enum":["direct","speaker","realtime","minimal_risk"],"title":"Voice.Disclosure.Path","type":"string"},"voice.disclosure.completed":{"description":"Every chunk of the notice reached the line.","title":"Voice.Disclosure.Completed","type":"boolean"},"voice.disclosure.region":{"title":"Voice.Disclosure.Region","type":"string"},"voice.disclosure.language":{"enum":["en","es"],"title":"Voice.Disclosure.Language","type":"string"},"voice.disclosure.text":{"description":"The authored notice text.","title":"Voice.Disclosure.Text","type":"string"},"voice.disclosure.variant":{"enum":["full","demo"],"title":"Voice.Disclosure.Variant","type":"string"},"voice.disclosure.started_at":{"description":"ISO 8601 time the first chunk was sent, or the attempt began when none was.","title":"Voice.Disclosure.Started At","type":"string"},"voice.disclosure.duration_ms":{"description":"Milliseconds of the notice's audio that went out.","title":"Voice.Disclosure.Duration Ms","type":"integer"},"voice.disclosure.failure":{"anyOf":[{"enum":["error","timeout","no_audio","no_script"],"type":"string"},{"type":"null"}],"description":"Why none of it could play, or null when it played.","title":"Voice.Disclosure.Failure"},"voice.disclosure.verbatim":{"description":"False when a model-spoken play said other words than the authored text.","title":"Voice.Disclosure.Verbatim","type":"boolean"},"voice.disclosure.outcome":{"anyOf":[{"enum":["verbatim","replayed","missed","clip","failed_closed"],"type":"string"},{"type":"null"}],"description":"What a model-spoken play came to. Null for a play cut off and for every other path.","title":"Voice.Disclosure.Outcome"}},"required":["voice.disclosure.path","voice.disclosure.completed","voice.disclosure.region","voice.disclosure.language","voice.disclosure.text","voice.disclosure.variant","voice.disclosure.started_at","voice.disclosure.duration_ms","voice.disclosure.failure","voice.disclosure.verbatim","voice.disclosure.outcome"],"title":"DisclosurePlayedEvent","type":"object"},"DynamicBehaviorDecidedEvent":{"description":"A caller turn's dynamic behavior decision committed. ``behavior`` is the behavior in force after it.","properties":{"type":{"const":"dynamic_behavior_decided","default":"dynamic_behavior_decided","title":"Type","type":"string"},"decision":{"$ref":"#/components/schemas/BehaviorDecision"},"behavior":{"anyOf":[{"$ref":"#/components/schemas/AppliedBehavior"},{"type":"null"}],"default":null}},"required":["decision"],"title":"DynamicBehaviorDecidedEvent","type":"object"},"BehaviorDecision":{"description":"What one caller turn's dynamic behavior decision did.\n\n``outcome``: ``applied`` put the chosen behavior in force; ``kept`` left the active one in force because\nthe model chose it again or said it stays; ``held`` left the active one in force because it was still\ninside its ``sticky_turns`` and the model chose none, chose another behavior under the confidence floor,\nor gave no usable answer (a different behavior chosen at or over the floor replaces it as ``applied``,\ninside its ``sticky_turns`` too); ``none``, ``below_floor`` and ``failed`` left nothing in force (no\nbehavior applies, a choice under the confidence floor, no usable answer); ``skipped`` ran no decision\n(``reason`` says why) and ended the active behavior; ``superseded`` was cancelled by the caller's next\nturn before it landed.","properties":{"outcome":{"$ref":"#/components/schemas/DynamicBehaviorOutcome"},"reason":{"anyOf":[{"$ref":"#/components/schemas/FailureReason"},{"$ref":"#/components/schemas/DynamicBehaviorSkip"},{"type":"null"}],"default":null,"description":"Why a decision failed or was skipped, or why a held behavior was held.","title":"Reason"},"behavior_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior in force after the decision.","title":"Behavior Id"},"behavior_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior in force. Null where none is, and before behaviors were versioned.","title":"Behavior Version"},"chosen_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior the model chose. Null when it chose none or gave no usable answer.","title":"Chosen Id"},"chosen_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior the model chose. Null where it chose none, and before behaviors were versioned.","title":"Chosen Version"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The choice's confidence. Null where the decision got no usable answer.","title":"Confidence"},"kept_by_predicate":{"default":false,"description":"Whether the active behavior stayed because the model said it stays, rather than by its choice.","title":"Kept By Predicate","type":"boolean"},"keep_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The confidence of the answer to whether the active behavior stays, when that was asked.","title":"Keep Confidence"},"candidate_count":{"default":0,"description":"How many behaviors the decision chose between, ``none`` aside.","title":"Candidate Count","type":"integer"},"latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Latency Ms"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"description":"The context graph version the conversation ran when the decision was made. Null on a direct program's\ndecision, which ran no context graph: ``program_digest`` names what it ran.","title":"Context Graph Version"},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"The direct program the conversation ran when the decision was made, by the digest its run records\n(``RunManifest.program_digest``). Null on a context graph's decision."},"selector_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"What a direct program's decision rendered its request from. Null on a context graph's decision, whose run\nrecords it (``RunManifest.dynamic_behavior_prompt_template_hash``)."},"cited_message_indexes":{"default":[],"description":"The messages the decision read the turn from: the agent's line before the turn, then the caller's.","items":{"type":"integer"},"title":"Cited Message Indexes","type":"array"}},"required":["outcome"],"title":"BehaviorDecision","type":"object"},"DynamicBehaviorOutcome":{"enum":["applied","kept","held","none","below_floor","failed","skipped","superseded"],"type":"string"},"FailureReason":{"enum":["refusal","out_of_set","malformed","http_4xx","http_retryable","connection","timeout","breaker_open","options_exceeded"],"type":"string"},"DynamicBehaviorSkip":{"enum":["emergency_floor","person_request","empathy_hold","suspended","no_candidates"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"},"EmpathyClassifiedEvent":{"properties":{"type":{"const":"empathy_classified","default":"empathy_classified","title":"Type","type":"string"},"tier":{"title":"Tier","type":"integer"},"tier_name":{"enum":["FUNCTIONAL","LIGHT_TOUCH","FULL_EMPATHY","HOLD_SPACE"],"title":"Tier Name","type":"string"},"should_pause":{"title":"Should Pause","type":"boolean"},"suppress_filler":{"title":"Suppress Filler","type":"boolean"},"filler_type":{"enum":["empathy","receipt","working"],"title":"Filler Type","type":"string"},"empathy_baseline":{"title":"Empathy Baseline","type":"number"}},"required":["tier","tier_name","should_pause","suppress_filler","filler_type","empathy_baseline"],"title":"EmpathyClassifiedEvent","type":"object"},"ForwardCallResolvedEvent":{"properties":{"type":{"const":"forward_call_resolved","default":"forward_call_resolved","title":"Type","type":"string"},"target_number":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Target Number"},"location_name":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Location Name"},"result":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Result"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Error"}},"title":"ForwardCallResolvedEvent","type":"object"},"LatencyEvent":{"properties":{"type":{"const":"latency","default":"latency","title":"Type","type":"string"},"e2e_ttfb_ms":{"title":"E2E Ttfb Ms","type":"number"},"engine_ms":{"title":"Engine Ms","type":"number"},"nav_ms":{"title":"Nav Ms","type":"number"},"render_ms":{"title":"Render Ms","type":"number"},"audio_ttfb_ms":{"title":"Audio Ttfb Ms","type":"number"},"continuation":{"title":"Continuation","type":"boolean"},"is_greeting":{"default":false,"title":"Is Greeting","type":"boolean"}},"required":["e2e_ttfb_ms","engine_ms","nav_ms","render_ms","audio_ttfb_ms","continuation"],"title":"LatencyEvent","type":"object"},"MediaAttachedEvent":{"description":"A media WebSocket actually reached the call's GameServer — the audio-path signal.\n\nFires once per leg (caller / agent / callee). Its ABSENCE for a leg is the no-audio failure\nmode (media never landed on the pod). The per-call cold-start / time-to-first-speech\nmetric is deliberately NOT carried here yet: TTFS is measured against the first\nsynthesized-audio frame, a signal not available at attach time, so it is wired in a\nfocused follow-up (Front 3) rather than shipped as a permanently-null field that would\nlock a misleading shape into the SDK contract.","properties":{"type":{"const":"media_attached","default":"media_attached","title":"Type","type":"string"},"leg":{"enum":["caller","agent","operator","callee"],"title":"Leg","type":"string"}},"required":["leg"],"title":"MediaAttachedEvent","type":"object"},"MinimalRiskCompletedEvent":{"description":"How the safe exit ended.","properties":{"type":{"const":"minimal_risk_completed","default":"minimal_risk_completed","title":"Type","type":"string"},"trigger":{"enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger","type":"string"},"outcome":{"description":"``mrc_transferred`` once the hand-off to the human line was placed, ``mrc_failed`` when the hand-off raised\n(the caller may still be on the line), else ``mrc_ended`` (hung up).","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome","type":"string"},"lines_played":{"description":"The script lines that played whole, in order.","items":{"enum":["disclosure","transfer","end","fallback_missed","hearing_failure"],"type":"string"},"title":"Lines Played","type":"array"},"disclosure_heard":{"description":"The caller had heard all of the notice before the exit began, so the exit did not play it again.","title":"Disclosure Heard","type":"boolean"}},"required":["trigger","outcome","lines_played","disclosure_heard"],"title":"MinimalRiskCompletedEvent","type":"object"},"MinimalRiskStartedEvent":{"description":"The call took the safe exit: the agent stops and a fixed script hands the caller to a person or ends the call.","properties":{"type":{"const":"minimal_risk_started","default":"minimal_risk_started","title":"Type","type":"string"},"trigger":{"enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger","type":"string"}},"required":["trigger"],"title":"MinimalRiskStartedEvent","type":"object"},"NavTimingEvent":{"properties":{"type":{"const":"nav_timing","default":"nav_timing","title":"Type","type":"string"},"nav_ms":{"title":"Nav Ms","type":"number"},"render_ms":{"title":"Render Ms","type":"number"},"total_ms":{"title":"Total Ms","type":"number"},"input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Input Tokens"},"output_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Output Tokens"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Model"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"State"},"retry_attempts":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Retry Attempts"},"used_fallback":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Used Fallback"},"selected_action":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Selected Action"}},"required":["nav_ms","render_ms","total_ms"],"title":"NavTimingEvent","type":"object"},"ParticipantJoinedEvent":{"properties":{"type":{"const":"participant_joined","default":"participant_joined","title":"Type","type":"string"},"participant_id":{"title":"Participant Id","type":"string"},"participant_role":{"enum":["caller","agent","operator","callee"],"title":"Participant Role","type":"string"},"conference_sid":{"title":"Conference Sid","type":"string"},"participant_name":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Participant Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Display Name"},"operator_entity_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Operator Entity Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Phone Number"}},"required":["participant_id","participant_role","conference_sid"],"title":"ParticipantJoinedEvent","type":"object"},"ParticipantLeftEvent":{"properties":{"type":{"const":"participant_left","default":"participant_left","title":"Type","type":"string"},"participant_id":{"title":"Participant Id","type":"string"},"participant_role":{"enum":["caller","agent","operator","callee"],"title":"Participant Role","type":"string"},"conference_sid":{"title":"Conference Sid","type":"string"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Display Name"},"operator_entity_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Operator Entity Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Phone Number"}},"required":["participant_id","participant_role","conference_sid"],"title":"ParticipantLeftEvent","type":"object"},"SessionEndEvent":{"properties":{"type":{"const":"session_end","default":"session_end","title":"Type","type":"string"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Call Sid"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Session Id"},"duration_s":{"default":0,"title":"Duration S","type":"number"},"turns":{"default":0,"title":"Turns","type":"integer"},"completion_reason":{"default":"","title":"Completion Reason","type":"string"},"final_state":{"default":"","title":"Final State","type":"string"},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Trace Id"},"has_recording":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Has Recording"}},"title":"SessionEndEvent","type":"object"},"SessionInfoEvent":{"properties":{"type":{"const":"session_info","default":"session_info","title":"Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"service_id":{"default":"","title":"Service Id","type":"string"},"workspace_id":{"default":"","title":"Workspace Id","type":"string"},"caller_id":{"default":"","title":"Caller Id","type":"string"},"start_time":{"default":0,"title":"Start Time","type":"number"},"current_state":{"default":"","title":"Current State","type":"string"},"direction":{"default":"inbound","enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","type":"string"},"duration_seconds":{"default":0,"title":"Duration Seconds","type":"number"}},"required":["call_sid"],"title":"SessionInfoEvent","type":"object"},"SessionStartEvent":{"properties":{"type":{"const":"session_start","default":"session_start","title":"Type","type":"string"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Call Sid"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Session Id"},"service_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Service Id"},"workspace_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Workspace Id"},"initial_state":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Initial State"},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Trace Id"},"mode":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Mode"}},"title":"SessionStartEvent","type":"object"},"SpeakerMutedEvent":{"properties":{"type":{"const":"speaker_muted","default":"speaker_muted","title":"Type","type":"string"},"muted":{"title":"Muted","type":"boolean"}},"required":["muted"],"title":"SpeakerMutedEvent","type":"object"},"StateTransitionEvent":{"properties":{"type":{"const":"state_transition","default":"state_transition","title":"Type","type":"string"},"previous_state":{"title":"Previous State","type":"string"},"next_state":{"title":"Next State","type":"string"},"transition_type":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Transition Type"},"annotation":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Annotation"}},"required":["previous_state","next_state"],"title":"StateTransitionEvent","type":"object"},"ToolCallCompletedEvent":{"properties":{"type":{"const":"tool_call_completed","default":"tool_call_completed","title":"Type","type":"string"},"tool_name":{"maxLength":256,"title":"Tool Name","type":"string"},"call_id":{"maxLength":256,"title":"Call Id","type":"string"},"output":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Output"},"succeeded":{"default":true,"title":"Succeeded","type":"boolean"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Duration Ms"},"error_message":{"anyOf":[{"maxLength":2048,"type":"string"},{"type":"null"}],"default":null,"title":"Error Message"},"parent_call_id":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Parent Call Id"},"integration_name":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Integration Name"},"endpoint_name":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Endpoint Name"},"protocol":{"anyOf":[{"maxLength":64,"type":"string"},{"type":"null"}],"default":null,"title":"Protocol"}},"required":["tool_name","call_id"],"title":"ToolCallCompletedEvent","type":"object"},"ToolCallStartedEvent":{"properties":{"type":{"const":"tool_call_started","default":"tool_call_started","title":"Type","type":"string"},"tool_name":{"maxLength":256,"title":"Tool Name","type":"string"},"call_id":{"maxLength":256,"title":"Call Id","type":"string"},"input":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"string"},{"type":"null"}],"default":null,"title":"Input"},"parent_call_id":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Parent Call Id"},"integration_name":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Integration Name"},"endpoint_name":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Endpoint Name"},"protocol":{"anyOf":[{"maxLength":64,"type":"string"},{"type":"null"}],"default":null,"title":"Protocol"}},"required":["tool_name","call_id"],"title":"ToolCallStartedEvent","type":"object"},"UserTranscriptEvent":{"properties":{"type":{"const":"user_transcript","default":"user_transcript","title":"Type","type":"string"},"transcript":{"title":"Transcript","type":"string"},"state":{"default":"","title":"State","type":"string"},"speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Speaker Id"},"speaker_role":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Speaker Role"},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Eot Confidence"},"is_barge_in":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Is Barge In"}},"required":["transcript"],"title":"UserTranscriptEvent","type":"object"},"VoiceContextAppliedEvent":{"properties":{"type":{"const":"voice_context_applied","default":"voice_context_applied","title":"Type","type":"string"},"tts_emotion":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Tts Emotion"},"tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Tts Speed"},"tts_volume":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Tts Volume"},"filler_enabled":{"title":"Filler Enabled","type":"boolean"},"reasoning":{"title":"Reasoning","type":"string"}},"required":["filler_enabled","reasoning"],"title":"VoiceContextAppliedEvent","type":"object"}}}}
```

## The VoiceContextAppliedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"VoiceContextAppliedEvent":{"properties":{"type":{"const":"voice_context_applied","default":"voice_context_applied","title":"Type","type":"string"},"tts_emotion":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Tts Emotion"},"tts_speed":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Tts Speed"},"tts_volume":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Tts Volume"},"filler_enabled":{"title":"Filler Enabled","type":"boolean"},"reasoning":{"title":"Reasoning","type":"string"}},"required":["filler_enabled","reasoning"],"title":"VoiceContextAppliedEvent","type":"object"}}}}
```

## The UserTranscriptEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"UserTranscriptEvent":{"properties":{"type":{"const":"user_transcript","default":"user_transcript","title":"Type","type":"string"},"transcript":{"title":"Transcript","type":"string"},"state":{"default":"","title":"State","type":"string"},"speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Speaker Id"},"speaker_role":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Speaker Role"},"stt_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Stt Confidence"},"eot_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Eot Confidence"},"is_barge_in":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Is Barge In"}},"required":["transcript"],"title":"UserTranscriptEvent","type":"object"}}}}
```

## The ToolCallStartedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolCallStartedEvent":{"properties":{"type":{"const":"tool_call_started","default":"tool_call_started","title":"Type","type":"string"},"tool_name":{"maxLength":256,"title":"Tool Name","type":"string"},"call_id":{"maxLength":256,"title":"Call Id","type":"string"},"input":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"string"},{"type":"null"}],"default":null,"title":"Input"},"parent_call_id":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Parent Call Id"},"integration_name":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Integration Name"},"endpoint_name":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Endpoint Name"},"protocol":{"anyOf":[{"maxLength":64,"type":"string"},{"type":"null"}],"default":null,"title":"Protocol"}},"required":["tool_name","call_id"],"title":"ToolCallStartedEvent","type":"object"}}}}
```

## The ToolCallCompletedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ToolCallCompletedEvent":{"properties":{"type":{"const":"tool_call_completed","default":"tool_call_completed","title":"Type","type":"string"},"tool_name":{"maxLength":256,"title":"Tool Name","type":"string"},"call_id":{"maxLength":256,"title":"Call Id","type":"string"},"output":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Output"},"succeeded":{"default":true,"title":"Succeeded","type":"boolean"},"duration_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Duration Ms"},"error_message":{"anyOf":[{"maxLength":2048,"type":"string"},{"type":"null"}],"default":null,"title":"Error Message"},"parent_call_id":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Parent Call Id"},"integration_name":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Integration Name"},"endpoint_name":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Endpoint Name"},"protocol":{"anyOf":[{"maxLength":64,"type":"string"},{"type":"null"}],"default":null,"title":"Protocol"}},"required":["tool_name","call_id"],"title":"ToolCallCompletedEvent","type":"object"}}}}
```

## The StateTransitionEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"StateTransitionEvent":{"properties":{"type":{"const":"state_transition","default":"state_transition","title":"Type","type":"string"},"previous_state":{"title":"Previous State","type":"string"},"next_state":{"title":"Next State","type":"string"},"transition_type":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Transition Type"},"annotation":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Annotation"}},"required":["previous_state","next_state"],"title":"StateTransitionEvent","type":"object"}}}}
```

## The SpeakerMutedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SpeakerMutedEvent":{"properties":{"type":{"const":"speaker_muted","default":"speaker_muted","title":"Type","type":"string"},"muted":{"title":"Muted","type":"boolean"}},"required":["muted"],"title":"SpeakerMutedEvent","type":"object"}}}}
```

## The SessionStartEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SessionStartEvent":{"properties":{"type":{"const":"session_start","default":"session_start","title":"Type","type":"string"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Call Sid"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Session Id"},"service_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Service Id"},"workspace_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Workspace Id"},"initial_state":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Initial State"},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Trace Id"},"mode":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Mode"}},"title":"SessionStartEvent","type":"object"}}}}
```

## The SessionInfoEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SessionInfoEvent":{"properties":{"type":{"const":"session_info","default":"session_info","title":"Type","type":"string"},"call_sid":{"title":"Call Sid","type":"string"},"service_id":{"default":"","title":"Service Id","type":"string"},"workspace_id":{"default":"","title":"Workspace Id","type":"string"},"caller_id":{"default":"","title":"Caller Id","type":"string"},"start_time":{"default":0,"title":"Start Time","type":"number"},"current_state":{"default":"","title":"Current State","type":"string"},"direction":{"default":"inbound","enum":["inbound","outbound","playground","simulated","test"],"title":"Direction","type":"string"},"duration_seconds":{"default":0,"title":"Duration Seconds","type":"number"}},"required":["call_sid"],"title":"SessionInfoEvent","type":"object"}}}}
```

## The SessionEndEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"SessionEndEvent":{"properties":{"type":{"const":"session_end","default":"session_end","title":"Type","type":"string"},"call_sid":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Call Sid"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Session Id"},"duration_s":{"default":0,"title":"Duration S","type":"number"},"turns":{"default":0,"title":"Turns","type":"integer"},"completion_reason":{"default":"","title":"Completion Reason","type":"string"},"final_state":{"default":"","title":"Final State","type":"string"},"trace_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Trace Id"},"has_recording":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Has Recording"}},"title":"SessionEndEvent","type":"object"}}}}
```

## The ParticipantLeftEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ParticipantLeftEvent":{"properties":{"type":{"const":"participant_left","default":"participant_left","title":"Type","type":"string"},"participant_id":{"title":"Participant Id","type":"string"},"participant_role":{"enum":["caller","agent","operator","callee"],"title":"Participant Role","type":"string"},"conference_sid":{"title":"Conference Sid","type":"string"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Display Name"},"operator_entity_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Operator Entity Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Phone Number"}},"required":["participant_id","participant_role","conference_sid"],"title":"ParticipantLeftEvent","type":"object"}}}}
```

## The ParticipantJoinedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ParticipantJoinedEvent":{"properties":{"type":{"const":"participant_joined","default":"participant_joined","title":"Type","type":"string"},"participant_id":{"title":"Participant Id","type":"string"},"participant_role":{"enum":["caller","agent","operator","callee"],"title":"Participant Role","type":"string"},"conference_sid":{"title":"Conference Sid","type":"string"},"participant_name":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Participant Name"},"display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Display Name"},"operator_entity_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"title":"Operator Entity Id"},"phone_number":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Phone Number"}},"required":["participant_id","participant_role","conference_sid"],"title":"ParticipantJoinedEvent","type":"object"}}}}
```

## The NavTimingEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"NavTimingEvent":{"properties":{"type":{"const":"nav_timing","default":"nav_timing","title":"Type","type":"string"},"nav_ms":{"title":"Nav Ms","type":"number"},"render_ms":{"title":"Render Ms","type":"number"},"total_ms":{"title":"Total Ms","type":"number"},"input_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Input Tokens"},"output_tokens":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Output Tokens"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Model"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"State"},"retry_attempts":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Retry Attempts"},"used_fallback":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Used Fallback"},"selected_action":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Selected Action"}},"required":["nav_ms","render_ms","total_ms"],"title":"NavTimingEvent","type":"object"}}}}
```

## The MinimalRiskStartedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MinimalRiskStartedEvent":{"description":"The call took the safe exit: the agent stops and a fixed script hands the caller to a person or ends the call.","properties":{"type":{"const":"minimal_risk_started","default":"minimal_risk_started","title":"Type","type":"string"},"trigger":{"enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger","type":"string"}},"required":["trigger"],"title":"MinimalRiskStartedEvent","type":"object"}}}}
```

## The MinimalRiskCompletedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MinimalRiskCompletedEvent":{"description":"How the safe exit ended.","properties":{"type":{"const":"minimal_risk_completed","default":"minimal_risk_completed","title":"Type","type":"string"},"trigger":{"enum":["stt_fatal","turn_stalled","wire_failed","disclosure_failed","session_rejected","setup_failed","service_budget","caller_cap","outside_answer_hours","health_alert","data_residency_refused","attach_failed"],"title":"Trigger","type":"string"},"outcome":{"description":"``mrc_transferred`` once the hand-off to the human line was placed, ``mrc_failed`` when the hand-off raised\n(the caller may still be on the line), else ``mrc_ended`` (hung up).","enum":["mrc_transferred","mrc_ended","mrc_failed"],"title":"Outcome","type":"string"},"lines_played":{"description":"The script lines that played whole, in order.","items":{"enum":["disclosure","transfer","end","fallback_missed","hearing_failure"],"type":"string"},"title":"Lines Played","type":"array"},"disclosure_heard":{"description":"The caller had heard all of the notice before the exit began, so the exit did not play it again.","title":"Disclosure Heard","type":"boolean"}},"required":["trigger","outcome","lines_played","disclosure_heard"],"title":"MinimalRiskCompletedEvent","type":"object"}}}}
```

## The MediaAttachedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"MediaAttachedEvent":{"description":"A media WebSocket actually reached the call's GameServer — the audio-path signal.\n\nFires once per leg (caller / agent / callee). Its ABSENCE for a leg is the no-audio failure\nmode (media never landed on the pod). The per-call cold-start / time-to-first-speech\nmetric is deliberately NOT carried here yet: TTFS is measured against the first\nsynthesized-audio frame, a signal not available at attach time, so it is wired in a\nfocused follow-up (Front 3) rather than shipped as a permanently-null field that would\nlock a misleading shape into the SDK contract.","properties":{"type":{"const":"media_attached","default":"media_attached","title":"Type","type":"string"},"leg":{"enum":["caller","agent","operator","callee"],"title":"Leg","type":"string"}},"required":["leg"],"title":"MediaAttachedEvent","type":"object"}}}}
```

## The LatencyEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"LatencyEvent":{"properties":{"type":{"const":"latency","default":"latency","title":"Type","type":"string"},"e2e_ttfb_ms":{"title":"E2E Ttfb Ms","type":"number"},"engine_ms":{"title":"Engine Ms","type":"number"},"nav_ms":{"title":"Nav Ms","type":"number"},"render_ms":{"title":"Render Ms","type":"number"},"audio_ttfb_ms":{"title":"Audio Ttfb Ms","type":"number"},"continuation":{"title":"Continuation","type":"boolean"},"is_greeting":{"default":false,"title":"Is Greeting","type":"boolean"}},"required":["e2e_ttfb_ms","engine_ms","nav_ms","render_ms","audio_ttfb_ms","continuation"],"title":"LatencyEvent","type":"object"}}}}
```

## The ForwardCallResolvedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ForwardCallResolvedEvent":{"properties":{"type":{"const":"forward_call_resolved","default":"forward_call_resolved","title":"Type","type":"string"},"target_number":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Target Number"},"location_name":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Location Name"},"result":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Result"},"error":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Error"}},"title":"ForwardCallResolvedEvent","type":"object"}}}}
```

## The EmpathyClassifiedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"EmpathyClassifiedEvent":{"properties":{"type":{"const":"empathy_classified","default":"empathy_classified","title":"Type","type":"string"},"tier":{"title":"Tier","type":"integer"},"tier_name":{"enum":["FUNCTIONAL","LIGHT_TOUCH","FULL_EMPATHY","HOLD_SPACE"],"title":"Tier Name","type":"string"},"should_pause":{"title":"Should Pause","type":"boolean"},"suppress_filler":{"title":"Suppress Filler","type":"boolean"},"filler_type":{"enum":["empathy","receipt","working"],"title":"Filler Type","type":"string"},"empathy_baseline":{"title":"Empathy Baseline","type":"number"}},"required":["tier","tier_name","should_pause","suppress_filler","filler_type","empathy_baseline"],"title":"EmpathyClassifiedEvent","type":"object"}}}}
```

## The DynamicBehaviorDecidedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DynamicBehaviorDecidedEvent":{"description":"A caller turn's dynamic behavior decision committed. ``behavior`` is the behavior in force after it.","properties":{"type":{"const":"dynamic_behavior_decided","default":"dynamic_behavior_decided","title":"Type","type":"string"},"decision":{"$ref":"#/components/schemas/BehaviorDecision"},"behavior":{"anyOf":[{"$ref":"#/components/schemas/AppliedBehavior"},{"type":"null"}],"default":null}},"required":["decision"],"title":"DynamicBehaviorDecidedEvent","type":"object"},"BehaviorDecision":{"description":"What one caller turn's dynamic behavior decision did.\n\n``outcome``: ``applied`` put the chosen behavior in force; ``kept`` left the active one in force because\nthe model chose it again or said it stays; ``held`` left the active one in force because it was still\ninside its ``sticky_turns`` and the model chose none, chose another behavior under the confidence floor,\nor gave no usable answer (a different behavior chosen at or over the floor replaces it as ``applied``,\ninside its ``sticky_turns`` too); ``none``, ``below_floor`` and ``failed`` left nothing in force (no\nbehavior applies, a choice under the confidence floor, no usable answer); ``skipped`` ran no decision\n(``reason`` says why) and ended the active behavior; ``superseded`` was cancelled by the caller's next\nturn before it landed.","properties":{"outcome":{"$ref":"#/components/schemas/DynamicBehaviorOutcome"},"reason":{"anyOf":[{"$ref":"#/components/schemas/FailureReason"},{"$ref":"#/components/schemas/DynamicBehaviorSkip"},{"type":"null"}],"default":null,"description":"Why a decision failed or was skipped, or why a held behavior was held.","title":"Reason"},"behavior_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior in force after the decision.","title":"Behavior Id"},"behavior_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior in force. Null where none is, and before behaviors were versioned.","title":"Behavior Version"},"chosen_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"The behavior the model chose. Null when it chose none or gave no usable answer.","title":"Chosen Id"},"chosen_version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior the model chose. Null where it chose none, and before behaviors were versioned.","title":"Chosen Version"},"confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The choice's confidence. Null where the decision got no usable answer.","title":"Confidence"},"kept_by_predicate":{"default":false,"description":"Whether the active behavior stayed because the model said it stays, rather than by its choice.","title":"Kept By Predicate","type":"boolean"},"keep_confidence":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"description":"The confidence of the answer to whether the active behavior stays, when that was asked.","title":"Keep Confidence"},"candidate_count":{"default":0,"description":"How many behaviors the decision chose between, ``none`` aside.","title":"Candidate Count","type":"integer"},"latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Latency Ms"},"context_graph_version":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"description":"The context graph version the conversation ran when the decision was made. Null on a direct program's\ndecision, which ran no context graph: ``program_digest`` names what it ran.","title":"Context Graph Version"},"program_digest":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"The direct program the conversation ran when the decision was made, by the digest its run records\n(``RunManifest.program_digest``). Null on a context graph's decision."},"selector_prompt_hash":{"anyOf":[{"$ref":"#/components/schemas/NameString"},{"type":"null"}],"default":null,"description":"What a direct program's decision rendered its request from. Null on a context graph's decision, whose run\nrecords it (``RunManifest.dynamic_behavior_prompt_template_hash``)."},"cited_message_indexes":{"default":[],"description":"The messages the decision read the turn from: the agent's line before the turn, then the caller's.","items":{"type":"integer"},"title":"Cited Message Indexes","type":"array"}},"required":["outcome"],"title":"BehaviorDecision","type":"object"},"DynamicBehaviorOutcome":{"enum":["applied","kept","held","none","below_floor","failed","skipped","superseded"],"type":"string"},"FailureReason":{"enum":["refusal","out_of_set","malformed","http_4xx","http_retryable","connection","timeout","breaker_open","options_exceeded"],"type":"string"},"DynamicBehaviorSkip":{"enum":["emergency_floor","person_request","empathy_hold","suspended","no_candidates"],"type":"string"},"NameString":{"maxLength":256,"minLength":1,"type":"string"},"AppliedBehavior":{"description":"The dynamic behavior an agent reply was rendered with.","properties":{"id":{"format":"uuid","title":"Id","type":"string"},"version":{"anyOf":[{"maximum":2147483647,"minimum":1,"type":"integer"},{"type":"null"}],"default":null,"description":"The version of the behavior this reply ran with. Null on a reply recorded before behaviors were versioned.","title":"Version"},"name":{"maxLength":120,"title":"Name","type":"string"},"mode":{"$ref":"#/components/schemas/DynamicBehaviorMode"}},"required":["id","name","mode"],"title":"AppliedBehavior","type":"object"},"DynamicBehaviorMode":{"enum":["add","replace"],"type":"string"}}}}
```

## The DisclosurePlayedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"DisclosurePlayedEvent":{"description":"One play of the call's AI and recording notice, or an attempt none of which could play.\n\nIts fields keep the ``voice.disclosure.*`` keys the call's trace records them under.","properties":{"type":{"const":"disclosure_played","default":"disclosure_played","title":"Type","type":"string"},"voice.disclosure.path":{"description":"What played it: the cascade (``direct``, ``speaker``), the realtime model, or the safe exit.","enum":["direct","speaker","realtime","minimal_risk"],"title":"Voice.Disclosure.Path","type":"string"},"voice.disclosure.completed":{"description":"Every chunk of the notice reached the line.","title":"Voice.Disclosure.Completed","type":"boolean"},"voice.disclosure.region":{"title":"Voice.Disclosure.Region","type":"string"},"voice.disclosure.language":{"enum":["en","es"],"title":"Voice.Disclosure.Language","type":"string"},"voice.disclosure.text":{"description":"The authored notice text.","title":"Voice.Disclosure.Text","type":"string"},"voice.disclosure.variant":{"enum":["full","demo"],"title":"Voice.Disclosure.Variant","type":"string"},"voice.disclosure.started_at":{"description":"ISO 8601 time the first chunk was sent, or the attempt began when none was.","title":"Voice.Disclosure.Started At","type":"string"},"voice.disclosure.duration_ms":{"description":"Milliseconds of the notice's audio that went out.","title":"Voice.Disclosure.Duration Ms","type":"integer"},"voice.disclosure.failure":{"anyOf":[{"enum":["error","timeout","no_audio","no_script"],"type":"string"},{"type":"null"}],"description":"Why none of it could play, or null when it played.","title":"Voice.Disclosure.Failure"},"voice.disclosure.verbatim":{"description":"False when a model-spoken play said other words than the authored text.","title":"Voice.Disclosure.Verbatim","type":"boolean"},"voice.disclosure.outcome":{"anyOf":[{"enum":["verbatim","replayed","missed","clip","failed_closed"],"type":"string"},{"type":"null"}],"description":"What a model-spoken play came to. Null for a play cut off and for every other path.","title":"Voice.Disclosure.Outcome"}},"required":["voice.disclosure.path","voice.disclosure.completed","voice.disclosure.region","voice.disclosure.language","voice.disclosure.text","voice.disclosure.variant","voice.disclosure.started_at","voice.disclosure.duration_ms","voice.disclosure.failure","voice.disclosure.verbatim","voice.disclosure.outcome"],"title":"DisclosurePlayedEvent","type":"object"}}}}
```

## The AgentTranscriptEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentTranscriptEvent":{"properties":{"type":{"const":"agent_transcript","default":"agent_transcript","title":"Type","type":"string"},"transcript":{"title":"Transcript","type":"string"},"action":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Action"},"interrupted":{"default":false,"title":"Interrupted","type":"boolean"},"filler_type":{"anyOf":[{"enum":["empathy","receipt","working"],"type":"string"},{"type":"null"}],"default":null,"title":"Filler Type"},"speaker_id":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Speaker Id"},"speaker_role":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"title":"Speaker Role"},"streaming":{"anyOf":[{"type":"boolean"},{"type":"null"}],"default":null,"title":"Streaming"}},"required":["transcript"],"title":"AgentTranscriptEvent","type":"object"}}}}
```

## The AgentTranscriptDeltaEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"AgentTranscriptDeltaEvent":{"properties":{"type":{"const":"agent_transcript_delta","default":"agent_transcript_delta","title":"Type","type":"string"},"delta":{"title":"Delta","type":"string"}},"required":["delta"],"title":"AgentTranscriptDeltaEvent","type":"object"}}}}
```

## The ActorShutdownEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ActorShutdownEvent":{"description":"The call's GameServer was reaped (Allocated GameServers are deploy-immune).\n\nToday only ``reason=call_ended`` is produced (normal call-end teardown).\n``orphan_no_media`` is reserved in the contract for the orphan reaper — a pod that\nwent Allocated but never received media — but that emit is not yet wired: at reap\ntime the reaper pod has no call identity (allocation is cross-pod), so plumbing the\ncall_sid to it is a follow-up. The value is pre-declared so adding it later is a\nnon-breaking widening for SDK consumers, not a breaking enum change.","properties":{"type":{"const":"actor_shutdown","default":"actor_shutdown","title":"Type","type":"string"},"reason":{"default":"call_ended","enum":["call_ended","orphan_no_media"],"title":"Reason","type":"string"},"lifetime_s":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Lifetime S"}},"title":"ActorShutdownEvent","type":"object"}}}}
```

## The ActorAllocatedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"ActorAllocatedEvent":{"description":"The call was bound to its isolated runtime — one call = one Agones GameServer.\n\nEmitted by the dispatcher the moment it allocates a warm GameServer for the call,\nso an observer can see WHICH pod/node powers this call and how long allocation took.","properties":{"type":{"const":"actor_allocated","default":"actor_allocated","title":"Type","type":"string"},"gameserver":{"maxLength":256,"title":"Gameserver","type":"string"},"node":{"anyOf":[{"maxLength":256,"type":"string"},{"type":"null"}],"default":null,"title":"Node"},"alloc_latency_ms":{"anyOf":[{"type":"number"},{"type":"null"}],"default":null,"title":"Alloc Latency Ms"}},"required":["gameserver"],"title":"ActorAllocatedEvent","type":"object"}}}}
```

## The TurnStreamEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnStreamEvent":{"discriminator":{"mapping":{"artifact":"#/components/schemas/TurnArtifactEvent","done":"#/components/schemas/TurnDoneEvent","error":"#/components/schemas/TurnErrorEvent","message":"#/components/schemas/TurnMessageEvent","state":"#/components/schemas/TurnStateEvent","state_transition":"#/components/schemas/TurnStateTransitionEvent","thinking":"#/components/schemas/TurnThinkingEvent","token":"#/components/schemas/TurnTokenEvent","tool_call_completed":"#/components/schemas/TurnToolCallCompletedEvent","tool_call_started":"#/components/schemas/TurnToolCallStartedEvent"},"propertyName":"event"},"oneOf":[{"$ref":"#/components/schemas/TurnTokenEvent"},{"$ref":"#/components/schemas/TurnArtifactEvent"},{"$ref":"#/components/schemas/TurnToolCallStartedEvent"},{"$ref":"#/components/schemas/TurnToolCallCompletedEvent"},{"$ref":"#/components/schemas/TurnThinkingEvent"},{"$ref":"#/components/schemas/TurnMessageEvent"},{"$ref":"#/components/schemas/TurnStateTransitionEvent"},{"$ref":"#/components/schemas/TurnStateEvent"},{"$ref":"#/components/schemas/TurnDoneEvent"},{"$ref":"#/components/schemas/TurnErrorEvent"}]},"TurnTokenEvent":{"properties":{"event":{"const":"token","default":"token","title":"Event","type":"string"},"text":{"title":"Text","type":"string"}},"required":["text"],"title":"TurnTokenEvent","type":"object"},"TurnArtifactEvent":{"properties":{"event":{"const":"artifact","default":"artifact","title":"Event","type":"string"},"type":{"maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type","type":"string"},"schema_version":{"maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version","type":"string"},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"items":{},"type":"array"}],"title":"Payload"}},"required":["type","schema_version","payload"],"title":"TurnArtifactEvent","type":"object"},"TurnToolCallStartedEvent":{"properties":{"event":{"const":"tool_call_started","default":"tool_call_started","title":"Event","type":"string"},"tool_name":{"maxLength":256,"title":"Tool Name","type":"string"},"call_id":{"maxLength":256,"title":"Call Id","type":"string"},"input":{"title":"Input","type":"string"}},"required":["tool_name","call_id","input"],"title":"TurnToolCallStartedEvent","type":"object"},"TurnToolCallCompletedEvent":{"properties":{"event":{"const":"tool_call_completed","default":"tool_call_completed","title":"Event","type":"string"},"tool_name":{"maxLength":256,"title":"Tool Name","type":"string"},"call_id":{"maxLength":256,"title":"Call Id","type":"string"},"result":{"title":"Result","type":"string"},"succeeded":{"title":"Succeeded","type":"boolean"},"duration_ms":{"anyOf":[{"maximum":3600000,"minimum":0,"type":"number"},{"type":"null"}],"default":null,"description":"Wall-clock tool execution time in milliseconds, measured at the engage_step call site. Null when the upstream did not report timing (legacy/test paths).","title":"Duration Ms"}},"required":["tool_name","call_id","result","succeeded"],"title":"TurnToolCallCompletedEvent","type":"object"},"TurnThinkingEvent":{"properties":{"event":{"const":"thinking","default":"thinking","title":"Event","type":"string"},"tier":{"title":"Tier","type":"integer"},"tier_name":{"title":"Tier Name","type":"string"}},"required":["tier","tier_name"],"title":"TurnThinkingEvent","type":"object"},"TurnMessageEvent":{"properties":{"event":{"const":"message","default":"message","title":"Event","type":"string"},"role":{"title":"Role","type":"string"},"text":{"title":"Text","type":"string"}},"required":["role","text"],"title":"TurnMessageEvent","type":"object"},"TurnStateTransitionEvent":{"description":"One context-graph hop the turn took.\n\nOne frame per hop, in the order the turn took them, after the turn's ``message``\nframes. These are the hops ``POST /turns`` returns on ``output[0].state_transitions``.","properties":{"event":{"const":"state_transition","default":"state_transition","title":"Event","type":"string"},"from_state":{"title":"From State","type":"string"},"to_state":{"title":"To State","type":"string"},"exit_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"description":"The exit condition the agent took out of ``from_state``, as the context graph words it. Null on a hop out of an annotation state, which has no exit conditions.","title":"Exit Condition"}},"required":["from_state","to_state"],"title":"TurnStateTransitionEvent","type":"object"},"TurnStateEvent":{"description":"The conversation's context-graph state after the turn.\n\nSent on every turn, after any ``state_transition`` frames and before ``done``. It is\nthe state ``POST /turns`` returns on ``conversation.context_graph_state``.","properties":{"event":{"const":"state","default":"state","title":"Event","type":"string"},"context_graph_state":{"$ref":"#/components/schemas/ContextGraphState-Output"}},"required":["context_graph_state"],"title":"TurnStateEvent","type":"object"},"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."},"TurnDoneEvent":{"properties":{"event":{"const":"done","default":"done","title":"Event","type":"string"},"conversation_id":{"format":"uuid","title":"Conversation Id","type":"string"},"status":{"title":"Status","type":"string"},"turn_count":{"title":"Turn Count","type":"integer"},"background_pending":{"default":false,"description":"True when the streamed response is only an acknowledgement and the final assistant answer must be collected with the durable background-delivery protocol.","title":"Background Pending","type":"boolean"},"delivery_protocol_version":{"anyOf":[{"const":2,"type":"integer"},{"type":"null"}],"default":null,"description":"Version of the durable background-delivery protocol supported by the serving agent. Clients may retry receipt-backed polls only after observing version 2.","title":"Delivery Protocol Version"},"turn_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"Identifier of the user exchange this turn belongs to — identical to the ``turn_id`` on the non-streaming ``POST /turns`` response and on this conversation's history turns, so a streaming client can anchor durable per-turn artifacts (e.g. feedback) without a follow-up read. Stamped by platform-api at the proxy boundary (agent-engine frames do not carry it). Null when the conversation has no user exchange yet (a greeting kickoff stream on a fresh conversation).","title":"Turn Id"},"turn_index":{"anyOf":[{"minimum":0,"type":"integer"},{"type":"null"}],"default":null,"description":"Zero-based ordinal of the user exchange (0 = first user turn). Derived server-side; null exactly when ``turn_id`` is null.","title":"Turn Index"}},"required":["conversation_id","status","turn_count"],"title":"TurnDoneEvent","type":"object"},"TurnErrorEvent":{"description":"Terminal error frame on the turn stream.\n\nCarries a stable ``code`` so SDK consumers can branch deterministically\nwithout parsing free-form ``message`` text. ``retryable`` tells the\nconsumer whether issuing the same turn again is likely to succeed.\n``status_code`` is the upstream HTTP status when the error originated\nfrom a downstream service (agent-engine), and is otherwise omitted.","properties":{"event":{"const":"error","default":"error","title":"Event","type":"string"},"message":{"title":"Message","type":"string"},"code":{"default":"unknown","enum":["upstream_error","stream_interrupted","client_error","unknown"],"title":"Code","type":"string"},"retryable":{"default":false,"title":"Retryable","type":"boolean"},"status_code":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Status Code"}},"required":["message"],"title":"TurnErrorEvent","type":"object"}}}}
```

## The TurnErrorEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnErrorEvent":{"description":"Terminal error frame on the turn stream.\n\nCarries a stable ``code`` so SDK consumers can branch deterministically\nwithout parsing free-form ``message`` text. ``retryable`` tells the\nconsumer whether issuing the same turn again is likely to succeed.\n``status_code`` is the upstream HTTP status when the error originated\nfrom a downstream service (agent-engine), and is otherwise omitted.","properties":{"event":{"const":"error","default":"error","title":"Event","type":"string"},"message":{"title":"Message","type":"string"},"code":{"default":"unknown","enum":["upstream_error","stream_interrupted","client_error","unknown"],"title":"Code","type":"string"},"retryable":{"default":false,"title":"Retryable","type":"boolean"},"status_code":{"anyOf":[{"type":"integer"},{"type":"null"}],"default":null,"title":"Status Code"}},"required":["message"],"title":"TurnErrorEvent","type":"object"}}}}
```

## The TurnDoneEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnDoneEvent":{"properties":{"event":{"const":"done","default":"done","title":"Event","type":"string"},"conversation_id":{"format":"uuid","title":"Conversation Id","type":"string"},"status":{"title":"Status","type":"string"},"turn_count":{"title":"Turn Count","type":"integer"},"background_pending":{"default":false,"description":"True when the streamed response is only an acknowledgement and the final assistant answer must be collected with the durable background-delivery protocol.","title":"Background Pending","type":"boolean"},"delivery_protocol_version":{"anyOf":[{"const":2,"type":"integer"},{"type":"null"}],"default":null,"description":"Version of the durable background-delivery protocol supported by the serving agent. Clients may retry receipt-backed polls only after observing version 2.","title":"Delivery Protocol Version"},"turn_id":{"anyOf":[{"format":"uuid","type":"string"},{"type":"null"}],"default":null,"description":"Identifier of the user exchange this turn belongs to — identical to the ``turn_id`` on the non-streaming ``POST /turns`` response and on this conversation's history turns, so a streaming client can anchor durable per-turn artifacts (e.g. feedback) without a follow-up read. Stamped by platform-api at the proxy boundary (agent-engine frames do not carry it). Null when the conversation has no user exchange yet (a greeting kickoff stream on a fresh conversation).","title":"Turn Id"},"turn_index":{"anyOf":[{"minimum":0,"type":"integer"},{"type":"null"}],"default":null,"description":"Zero-based ordinal of the user exchange (0 = first user turn). Derived server-side; null exactly when ``turn_id`` is null.","title":"Turn Index"}},"required":["conversation_id","status","turn_count"],"title":"TurnDoneEvent","type":"object"}}}}
```

## The TurnStateEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnStateEvent":{"description":"The conversation's context-graph state after the turn.\n\nSent on every turn, after any ``state_transition`` frames and before ``done``. It is\nthe state ``POST /turns`` returns on ``conversation.context_graph_state``.","properties":{"event":{"const":"state","default":"state","title":"Event","type":"string"},"context_graph_state":{"$ref":"#/components/schemas/ContextGraphState-Output"}},"required":["context_graph_state"],"title":"TurnStateEvent","type":"object"},"ContextGraphState-Output":{"oneOf":[{"$ref":"#/components/schemas/ActionState-Output"},{"$ref":"#/components/schemas/DecisionState-Output"},{"$ref":"#/components/schemas/AnnotationState"},{"$ref":"#/components/schemas/DataCollectionState-Output"}],"discriminator":{"propertyName":"type","mapping":{"action":"#/components/schemas/ActionState-Output","annotation":"#/components/schemas/AnnotationState","data_collection":"#/components/schemas/DataCollectionState-Output","decision":"#/components/schemas/DecisionState-Output"}}},"ActionState-Output":{"properties":{"type":{"type":"string","const":"action","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"actions":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Actions"},"intra_state_navigation_guidelines":{"items":{"type":"string"},"type":"array","title":"Intra State Navigation Guidelines"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines"},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"action_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Action Tool Call Specs","default":[]},"exit_condition_tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Exit Condition Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"surface_spec_template":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Surface Spec Template"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","actions","intra_state_navigation_guidelines","action_guidelines","boundary_constraints","exit_conditions"],"title":"ActionState","description":"User-facing engagement state with actions and exit conditions."},"Action":{"properties":{"description":{"type":"string","title":"Description"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description"],"title":"Action","description":"A single action the agent can take within a state."},"ExitCondition":{"properties":{"description":{"type":"string","title":"Description"},"next_state":{"type":"string","title":"Next State"},"filler_hint":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Filler Hint"}},"type":"object","required":["description","next_state"],"title":"ExitCondition"},"ToolCallSpec":{"properties":{"tool_id":{"type":"string","title":"Tool Id"},"additional_instruction":{"type":"string","title":"Additional Instruction","default":""},"navigate_on_completion":{"type":"boolean","title":"Navigate On Completion","default":false},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]},"result_persistence":{"type":"string","enum":["accumulate","override","ephemeral"],"title":"Result Persistence","description":"How this tool call's arguments and result are retained. 'ephemeral' is fail-closed: Platform API authoring must be enabled for the workspace, and Agent Engine honors it only on the inline text/simulation path — voice, background, and external-realtime sessions reject an ephemeral graph at init rather than journal it.","default":"accumulate"},"expects_code":{"type":"boolean","title":"Expects Code","default":false},"delivery":{"type":"string","enum":["interrupt","queue"],"title":"Delivery","default":"interrupt"},"failure_delivery":{"anyOf":[{"type":"string","enum":["interrupt","queue"]},{"type":"null"}],"title":"Failure Delivery"},"failure_delivery_by_class":{"anyOf":[{"additionalProperties":{"type":"string","enum":["interrupt","queue"]},"propertyNames":{"$ref":"#/components/schemas/FailureClass"},"type":"object"},{"type":"null"}],"title":"Failure Delivery By Class"},"execution":{"type":"string","enum":["blocking","background"],"title":"Execution","default":"blocking"},"lifecycle":{"type":"string","enum":["coupled","independent"],"title":"Lifecycle","default":"independent"},"context_bindings":{"items":{"type":"string"},"type":"array","title":"Context Bindings"},"context_binding_aliases":{"additionalProperties":{"$ref":"#/components/schemas/SlugString"},"propertyNames":{"maxLength":128,"minLength":1},"type":"object","title":"Context Binding Aliases"},"audio_fillers":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Audio Fillers"},"audio_filler_triggered_after":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Audio Filler Triggered After"}},"type":"object","required":["tool_id"],"title":"ToolCallSpec","description":"A tool call that the agent can make in a state."},"ProgressHint":{"properties":{"deterministic":{"type":"boolean","title":"Deterministic","default":false},"phrases":{"anyOf":[{"items":{"type":"string"},"type":"array","maxItems":10,"minItems":1,"description":"Filler phrases. deterministic=true: played verbatim in order. deterministic=false: used as hints for early attempts."},{"type":"null"}],"title":"Phrases"},"trigger_delay_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":0},{"type":"null"}],"title":"Trigger Delay Ms"},"interval_ms":{"anyOf":[{"type":"integer","maximum":30000,"minimum":100},{"type":"null"}],"title":"Interval Ms"},"mode":{"type":"string","enum":["auto","silent","backchannel","verbal"],"title":"Mode","default":"auto"},"progress_class":{"anyOf":[{"type":"string","enum":["lookup","write","external_call","compute","multi_step"]},{"type":"null"}],"title":"Progress Class"},"expected_latency_ms":{"anyOf":[{"type":"integer","maximum":60000,"minimum":0},{"type":"null"}],"title":"Expected Latency Ms"},"custom_phrase":{"anyOf":[{"type":"string","maxLength":500,"description":"Legacy: use phrases instead."},{"type":"null"}],"title":"Custom Phrase"}},"additionalProperties":false,"type":"object","title":"ProgressHint","description":"How the agent narrates waiting on a tool.\n\n``deterministic=true``: scripted — ``phrases`` play verbatim in order.\n``deterministic=false``: engine picks — ``phrases`` are hints.\n``trigger_delay_ms``: milliseconds before first filler (0 = immediate).\n``interval_ms``: milliseconds between subsequent fillers."},"FailureClass":{"type":"string","enum":["timeout","input_rejected","rounds_exhausted","generic"],"title":"FailureClass","description":"Why a tool result is a failure — produced by the executor at RUN time.\n\nUnlike ``ResultDelivery`` (a fixed config-time axis), this is a runtime\nclassification the executor knows at the moment of failure. It flavors the\nagent-facing failure wording and the world-event / status-tool observability,\nand it is ALSO an optional routing key: a state x tool binding may set\n``ToolCallSpec.failure_delivery_by_class`` to deliver differently per class\n(e.g. interrupt on timeout, queue on a generic error). With no per-class map\n(the default), failed results route by the ``failure_delivery`` floor,\nunchanged. Add a member only in the same change that wires a producer for it —\nadding one also widens the per-class routing surface, so it must be a\ndeliberate, produced class."},"SlugString":{"type":"string","maxLength":63,"minLength":2,"pattern":"^[a-z0-9][a-z0-9-]*[a-z0-9]$"},"Guardrail":{"properties":{"name":{"type":"string","maxLength":128,"title":"Name"},"description":{"type":"string","maxLength":1000,"title":"Description"},"enforcement":{"type":"string","enum":["hard","soft"],"title":"Enforcement","default":"hard"}},"type":"object","required":["name","description"],"title":"Guardrail","description":"Typed safety rule enforced per-state (not just global freetext guidelines)."},"ChannelOverride":{"properties":{"objective":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Objective"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"progress":{"anyOf":[{"$ref":"#/components/schemas/ProgressHint"},{"type":"null"}]}},"type":"object","title":"ChannelOverride","description":"Per-channel behavior override for a state."},"TurnPolicy":{"properties":{"barge_in_enabled":{"type":"boolean","title":"Barge In Enabled","default":true},"context_strategy":{"type":"string","enum":["full","compact"],"title":"Context Strategy","default":"full"},"degradation_threshold":{"type":"integer","minimum":-1,"title":"Degradation Threshold","default":-1},"block_forward_call":{"type":"boolean","title":"Block Forward Call","default":false},"block_forward_call_after_turns":{"type":"integer","minimum":-1,"title":"Block Forward Call After Turns","default":-1},"stt_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eot Threshold"},"stt_eager_eot_threshold":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Stt Eager Eot Threshold"},"stt_eot_timeout_ms":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Stt Eot Timeout Ms"}},"type":"object","title":"TurnPolicy","description":"Voice pipeline parameters declared per HSM state.\n\nLives on ActionState/DecisionState alongside guardrails, wait_for, and\nchannel_overrides.  The HSM state IS the policy — no shadow state machine.\nAll fields optional with safe defaults (production behavior unchanged\nwhen no turn_policy is set)."},"DecisionState-Output":{"properties":{"type":{"type":"string","const":"decision","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"exit_conditions":{"items":{"$ref":"#/components/schemas/ExitCondition"},"type":"array","title":"Exit Conditions"},"decision_guidelines":{"items":{"type":"string"},"type":"array","title":"Decision Guidelines","default":[]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]},"wait_for":{"anyOf":[{"type":"string","enum":["surface_submission","human_approval"]},{"type":"null"}],"title":"Wait For"},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]}},"type":"object","required":["type","name","objective","exit_conditions"],"title":"DecisionState","description":"Passthrough routing state — Agent picks an exit condition, no user interaction."},"AnnotationState":{"properties":{"type":{"type":"string","const":"annotation","title":"Type"},"name":{"type":"string","title":"Name"},"inner_thought":{"type":"string","title":"Inner Thought"},"next_state":{"type":"string","title":"Next State"}},"type":"object","required":["type","name","inner_thought","next_state"],"title":"AnnotationState","description":"Injects a hardcoded inner thought (no LLM call)."},"DataCollectionState-Output":{"properties":{"type":{"type":"string","const":"data_collection","title":"Type"},"name":{"type":"string","title":"Name"},"objective":{"type":"string","title":"Objective"},"fields":{"items":{"$ref":"#/components/schemas/CollectionField"},"type":"array","title":"Fields"},"on_complete":{"type":"string","title":"On Complete"},"action_guidelines":{"items":{"type":"string"},"type":"array","title":"Action Guidelines","default":[]},"boundary_constraints":{"items":{"type":"string"},"type":"array","title":"Boundary Constraints","default":[]},"surface_fallback":{"type":"boolean","title":"Surface Fallback","default":false},"surface_fallback_after_turns":{"type":"integer","title":"Surface Fallback After Turns","default":6},"max_turns":{"type":"integer","title":"Max Turns","default":10},"guardrails":{"items":{"$ref":"#/components/schemas/Guardrail"},"type":"array","title":"Guardrails","default":[]},"channel_overrides":{"additionalProperties":{"$ref":"#/components/schemas/ChannelOverride"},"type":"object","title":"Channel Overrides"},"turn_policy":{"anyOf":[{"$ref":"#/components/schemas/TurnPolicy"},{"type":"null"}]},"tool_call_specs":{"items":{"$ref":"#/components/schemas/ToolCallSpec"},"type":"array","title":"Tool Call Specs","default":[]}},"type":"object","required":["type","name","objective","fields","on_complete"],"title":"DataCollectionState","description":"Structured voice/text data collection with field tracking.\n\nThe engine presents fields conversationally, tracks completion, and\noptionally falls back to a Surface form after N turns. Each collected\nfield produces a world event with confidence 0.5."},"CollectionField":{"properties":{"key":{"type":"string","title":"Key"},"type":{"type":"string","title":"Type"},"label":{"type":"string","title":"Label"},"required":{"type":"boolean","title":"Required","default":true},"options":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Options"},"validation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Validation"},"ask_prompt":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Ask Prompt"},"fhir_path":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Fhir Path"}},"type":"object","required":["key","type","label"],"title":"CollectionField","description":"A single field to collect during a data collection state."}}}}
```

## The TurnStateTransitionEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnStateTransitionEvent":{"description":"One context-graph hop the turn took.\n\nOne frame per hop, in the order the turn took them, after the turn's ``message``\nframes. These are the hops ``POST /turns`` returns on ``output[0].state_transitions``.","properties":{"event":{"const":"state_transition","default":"state_transition","title":"Event","type":"string"},"from_state":{"title":"From State","type":"string"},"to_state":{"title":"To State","type":"string"},"exit_condition":{"anyOf":[{"type":"string"},{"type":"null"}],"default":null,"description":"The exit condition the agent took out of ``from_state``, as the context graph words it. Null on a hop out of an annotation state, which has no exit conditions.","title":"Exit Condition"}},"required":["from_state","to_state"],"title":"TurnStateTransitionEvent","type":"object"}}}}
```

## The TurnMessageEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnMessageEvent":{"properties":{"event":{"const":"message","default":"message","title":"Event","type":"string"},"role":{"title":"Role","type":"string"},"text":{"title":"Text","type":"string"}},"required":["role","text"],"title":"TurnMessageEvent","type":"object"}}}}
```

## The TurnThinkingEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnThinkingEvent":{"properties":{"event":{"const":"thinking","default":"thinking","title":"Event","type":"string"},"tier":{"title":"Tier","type":"integer"},"tier_name":{"title":"Tier Name","type":"string"}},"required":["tier","tier_name"],"title":"TurnThinkingEvent","type":"object"}}}}
```

## The TurnToolCallCompletedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnToolCallCompletedEvent":{"properties":{"event":{"const":"tool_call_completed","default":"tool_call_completed","title":"Event","type":"string"},"tool_name":{"maxLength":256,"title":"Tool Name","type":"string"},"call_id":{"maxLength":256,"title":"Call Id","type":"string"},"result":{"title":"Result","type":"string"},"succeeded":{"title":"Succeeded","type":"boolean"},"duration_ms":{"anyOf":[{"maximum":3600000,"minimum":0,"type":"number"},{"type":"null"}],"default":null,"description":"Wall-clock tool execution time in milliseconds, measured at the engage_step call site. Null when the upstream did not report timing (legacy/test paths).","title":"Duration Ms"}},"required":["tool_name","call_id","result","succeeded"],"title":"TurnToolCallCompletedEvent","type":"object"}}}}
```

## The TurnToolCallStartedEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnToolCallStartedEvent":{"properties":{"event":{"const":"tool_call_started","default":"tool_call_started","title":"Event","type":"string"},"tool_name":{"maxLength":256,"title":"Tool Name","type":"string"},"call_id":{"maxLength":256,"title":"Call Id","type":"string"},"input":{"title":"Input","type":"string"}},"required":["tool_name","call_id","input"],"title":"TurnToolCallStartedEvent","type":"object"}}}}
```

## The TurnArtifactEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnArtifactEvent":{"properties":{"event":{"const":"artifact","default":"artifact","title":"Event","type":"string"},"type":{"maxLength":128,"minLength":1,"pattern":"^[a-z][a-z0-9_.-]*$","title":"Type","type":"string"},"schema_version":{"maxLength":64,"minLength":1,"pattern":"^[A-Za-z0-9][A-Za-z0-9_.-]*$","title":"Schema Version","type":"string"},"payload":{"anyOf":[{"additionalProperties":true,"type":"object"},{"items":{},"type":"array"}],"title":"Payload"}},"required":["type","schema_version","payload"],"title":"TurnArtifactEvent","type":"object"}}}}
```

## The TurnTokenEvent object

```json
{"openapi":"3.1.0","info":{"title":"Platform API","version":"1.0.0"},"components":{"schemas":{"TurnTokenEvent":{"properties":{"event":{"const":"token","default":"token","title":"Event","type":"string"},"text":{"title":"Text","type":"string"}},"required":["text"],"title":"TurnTokenEvent","type":"object"}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.concurrence.com/api-reference/readme/platform/models-1.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
