Decisions
Try a conversation gate
Evaluates a draft By decision gate against a sample (history lines with sender ids and a current message) on the daemon serving the conversation's consumer agent, then applies the draft condition. Writes nothing: no observation, verdict, or session, and the sample is never stored. Off, unsupported, and Needs review gates return not_applied without a model call. Returns 503 when no serving daemon is connected; a provider failure returns unavailable, which continues to the target and never means skip.
Authorization
bearerAuth AuthorizationBearer <token>
In: header
Path Parameters
orgId*string
id*string
Match
^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$Format
uuidchannelId*string
Length
1 <= length <= 512Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/v1/orgs/string/integrations/497f6eca-6276-4993-bfeb-53cbbbba6f08/channels/string/decision-preview" \ -H "Content-Type: application/json" \ -d '{ "decisionBinding": { "decisionId": "string", "when": { "type": "choice", "thresholds": { "property1": 0, "property2": 0 } }, "type": "gate" }, "state": { "history": [ { "sender": "string", "text": "string" } ], "currentMessage": { "text": "string" } } }'{ "mode": "live", "readiness": { "status": "ready" }, "evaluation": { "status": "answered", "answer": { "type": "boolean", "value": true, "probability": 0 }, "model": "string", "usage": { "inputTokens": 0, "outputTokens": 0 } }, "chain": [ { "stepId": "string", "decisionId": "string", "evaluation": { "status": "answered", "answer": { "type": "boolean", "value": true, "probability": 0 }, "model": "string", "usage": { "inputTokens": 0, "outputTokens": 0 } } } ], "detail": { "seq": 0, "at": "string", "messageId": "string", "title": "string", "decisionId": "string", "outcome": "triggered", "reason": "string", "answer": { "type": "boolean", "value": true, "probability": 0 }, "matchedKeys": [ "string" ], "latencyMs": 0, "requestedModel": "string", "actualModel": "string", "usage": { "inputTokens": 0, "outputTokens": 0 }, "detailsExpired": true, "snapshot": { "decisionId": "string", "providerId": "string", "model": "string", "question": { "type": "choice", "instructions": "string", "criteria": { "property1": "string", "property2": "string" } }, "condition": { "type": "choice", "thresholds": { "property1": 0, "property2": 0 } }, "sessionMode": "string" }, "input": { "agent": { "name": "string", "description": "string" }, "currentMessage": { "id": "string", "sender": { "id": "string" }, "text": "string", "quote": { "sender": "string", "text": "string" }, "threadId": "string", "time": "string", "truncated": true }, "history": [ { "id": "string", "sender": { "id": "string" }, "text": "string", "quote": { "sender": "string", "text": "string" }, "threadId": "string", "time": "string", "truncated": true } ], "historyOmitted": 0, "context": { "partial": true, "reasons": [ "string" ], "omittedMessages": 0 } }, "fullAnswer": { "type": "boolean", "value": true, "probability": 0 }, "chain": [ { "stepId": "string", "decisionId": "string", "evaluation": { "status": "answered", "answer": { "type": "boolean", "value": true, "probability": 0 }, "model": "string", "usage": { "inputTokens": 0, "outputTokens": 0 } } } ], "steps": [ { "stepId": "string", "decisionId": "string", "providerId": "string", "model": "string", "question": { "type": "choice", "instructions": "string", "criteria": { "property1": "string", "property2": "string" } }, "condition": { "type": "choice", "thresholds": { "property1": 0, "property2": 0 } }, "rawRequest": { "text": "string", "truncated": true }, "rawResponse": { "text": "string", "truncated": true } } ], "rawRequest": { "text": "string", "truncated": true }, "rawResponse": { "text": "string", "truncated": true }, "evidence": { "snapshotSeq": 0, "suppliedBackground": 0 } }, "consumer": { "type": "gate", "outcome": "trigger", "notAppliedReason": "off", "reason": "string", "matched": true, "matchedKeys": [ "string" ], "target": { "agentId": "string", "name": "string" } }}