{"openapi":"3.1.0","info":{"title":"Ogen REST","version":"2026-09-26","description":"A REST door onto the same tools Ogen's MCP server exposes — one endpoint per tool, plus confirm for releasing a held action."},"servers":[{"url":"https://us.ogenhq.com"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"An ogen_sk_ runtime key, or a signed-in access token."}}},"paths":{"/v1/rest/recall_live_fact":{"post":{"operationId":"recall_live_fact","summary":"Read the live value bound to a key, right now — one key, or up to 25 in one call.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"key":{"description":"One bound key to recall, e.g. 'customer.acme.address'.","type":"string"},"keys":{"description":"Instead of key: 1 to 25 bound keys to recall in one call. Duplicates are read once.","minItems":1,"maxItems":25,"type":"array","items":{"type":"string"}}},"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/commit_gated_action":{"post":{"operationId":"commit_gated_action","summary":"Commit an action by kind.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"kind":{"description":"An action kind, e.g. one registered with register_action.","type":"string"},"args":{"description":"Optional: the arguments you will run the action with. Ogen keeps only their fingerprint, for the release ticket a confirmation issues.","type":"object","propertyNames":{"type":"string"},"additionalProperties":{}},"principal":{"description":"THE HOSTED REQUESTER: required when the kind was registered with approver \"principal\" (waits for the person THIS ask names, not a registered approver); refused otherwise. Nothing but the address.","type":"object","properties":{"email":{"description":"The address of the person the agent is acting for.","type":"string","format":"email","pattern":"^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"}},"required":["email"],"additionalProperties":false}},"required":["kind"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"found":{"type":"boolean"},"committed":{"type":"boolean"},"disposition":{"type":"string"},"treatment":{"type":"string"},"status":{"type":"string"},"action_id":{"type":"string"},"kind":{"type":"string"},"key":{"type":"string"},"reason":{"type":"string"},"guidance":{"type":"string"},"confirm_url":{"type":"string"},"approver":{"type":"string"},"notified":{"type":"boolean"},"held_since":{"type":"string"},"decision":{"type":["string","null"]},"decided_by":{"type":["string","null"]},"decided_at":{"type":["string","null"]},"decide_with":{"type":"string","enum":["token_or_passkey","passkey_only"]},"decided_via":{"type":["string","null"],"enum":["token","passkey","name","policy",null]},"released_under":{"type":"object","description":"Present when a release dial released the action without a person: the limit that applied and whose dial it was.","properties":{"field":{"type":"string"},"value":{"type":"number"},"currency":{"type":["string","null"]},"limit_from":{"type":"string","enum":["kind","key"]},"set_by":{"type":"string"}}},"fact":{"type":"object","properties":{"status":{"type":"string","enum":["resolved","ambiguous","unavailable"]},"value":{},"candidates":{"type":"array","items":{"type":"object","properties":{"value":{},"source_label":{"type":["string","null"]}}}}}},"fix_proposal":{"type":["object","null"]},"holds":{"type":"array","items":{"type":"object"}},"note":{"type":"string"},"id":{"type":"string"},"ok":{"type":"boolean"}},"additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/register_action":{"post":{"operationId":"register_action","summary":"Tell Ogen which fact an action kind depends on, and how costly it is to undo.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"kind":{"description":"The action kind commit_gated_action will be called with.","type":"string"},"key":{"description":"The bound key this kind depends on.","type":"string"},"cost":{"description":"How costly this kind of action is to undo.","type":"string","enum":["read","reversible","expensive"]},"approver":{"description":"Optional: the name of the person who confirms a hold on this kind, or the reserved word \"principal\" — the kind then waits for whoever commit_gated_action's own ask names (principal: { email }), never a registered approver. Omit to leave unchanged; pass null to clear.","anyOf":[{"type":"string"},{"type":"null"}]},"decide_with":{"description":"Optional: which door may decide this kind's holds. Omit to leave unchanged; defaults to \"token_or_passkey\".","type":"string","enum":["token_or_passkey","passkey_only"]},"fallback_approver":{"description":"Optional: a second registered approver who is handed a hold once half its life has passed with no decision. Omit to leave unchanged; pass null to clear.","anyOf":[{"type":"string"},{"type":"null"}]},"hold_ttl_hours":{"description":"Optional: how long a hold on this kind waits for a person, in whole hours (1-168, default 24). Omit to leave unchanged.","type":"integer","minimum":1,"maximum":168},"hold_ttl_skip_weekends":{"description":"Optional: count only working days toward hold_ttl_hours — the account's weekend (Saturday-Sunday unless set otherwise with the settings tool, action contact), in its timezone. Refused until the timezone is set. Default false.","type":"boolean"},"auto_release_under":{"description":"Optional: release this kind without a person when its fact is settled and the arguments' amount is under a limit. A disagreement between systems still waits for a person. Only on a cost \"expensive\" kind; at most auto_release_per_day releases in any 24 hours (default 20), past which a person decides. Owner key only. Omit to leave unchanged; pass null to clear.","anyOf":[{"type":"object","properties":{"field":{"description":"The argument that carries the amount, e.g. \"amount\".","type":"string"},"value":{"description":"Release without a person only when that argument is a number strictly under this.","type":"number"},"currency":{"description":"Optional: a three-letter code. The arguments' \"currency\" must match it.","type":"string"}},"required":["field","value"],"additionalProperties":false},{"type":"null"}]},"auto_release_per_day":{"description":"Optional: how many times a day this kind may be released without a person — a count, 1-200, over any 24 hours (default 20). Ogen keeps no amount. Only on a cost \"expensive\" kind. Owner key only. Omit to leave unchanged; pass null to go back to the default.","anyOf":[{"type":"integer","minimum":1,"maximum":200},{"type":"null"}]},"release_when":{"description":"Optional: release this kind without a person when its own bound fact resolves and satisfies exactly one rule (fact_equals or fact_at_least, never both). A fact that disagrees between systems, or can't be read, always waits for a person. Shares the same daily count as auto_release_under. Applies to a caller's ask too. Only on a cost \"expensive\" kind; never with decide_with \"passkey_only\". Owner key only. Omit to leave unchanged; pass null to clear.","anyOf":[{"anyOf":[{"type":"object","properties":{"fact_equals":{"description":"Release when this kind's own bound fact resolves and equals this string exactly.","type":"string"}},"required":["fact_equals"],"additionalProperties":false},{"type":"object","properties":{"fact_at_least":{"description":"Release when this kind's own bound fact resolves to a number at least as large as this argument.","type":"string"}},"required":["fact_at_least"],"additionalProperties":false}]},{"type":"null"}]}},"required":["kind","key","cost"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/register_approver":{"post":{"operationId":"register_approver","summary":"Tell Ogen where to reach a person by name, so a held action can be sent to them.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"name":{"description":"The approver's name — must match a register_action approver value exactly.","type":"string"},"email":{"description":"The approver's email address.","type":"string","format":"email","pattern":"^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"},"replace":{"description":"Required (true) to repoint an existing name onto a different email.","type":"boolean"},"revoke_passkeys":{"description":"true to turn off every passkey this approver has set up.","type":"boolean"}},"required":["name","email"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/bind_source":{"post":{"operationId":"bind_source","summary":"Bind a key to a live, read-only source.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"key":{"description":"The key to bind.","type":"string"},"url":{"description":"For a plain JSON endpoint: an https:// URL. Omit when using `source`.","type":"string","format":"uri"},"headers":{"description":"For a plain JSON endpoint only: optional request headers, up to 16.","type":"object","propertyNames":{"type":"string"},"additionalProperties":{"type":"string"}},"field":{"description":"For a plain JSON endpoint only: a dotted path to one value in the response, e.g. \"status\" or \"data.items.0.total\". Omit for the whole body.","type":"string"},"source":{"description":"Instead of a plain endpoint: a source config. Fields depend on kind — see docs/ops/rest-door.md.","type":"object","properties":{"kind":{"description":"Which kind of source this is.","type":"string","enum":["postgrest","airtable","gsheets","hubspot","mcp","salesforce","netsuite","postgres","priority"]},"connection":{"description":"A named connection (see the connections tool) instead of inline credentials.","type":"string"}},"required":["kind"],"additionalProperties":{}},"alongside":{"description":"Bind a SECOND (or third, or fourth) live source to this key instead of replacing the one it already has. When the bound systems disagree, the act holds and whoever decides sees every reading, labelled by system. Omit this (the default) to replace the key's one source, removing any other source already bound alongside it.","type":"boolean"}},"required":["key"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/teach_fix":{"post":{"operationId":"teach_fix","summary":"Record a person's correction, so nobody is asked the same thing twice.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"key":{"description":"The bound key this fix applies to.","type":"string"},"raw":{"description":"The raw value that was wrong.","type":"string"},"canonical":{"description":"What it actually means.","type":"string"},"taught_by":{"description":"The named person recording this fix.","type":"string"}},"required":["key","raw","canonical","taught_by"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/reverse":{"post":{"operationId":"reverse","summary":"Mark an action as reversed, so what went wrong is not repeated, or put a correction that was set aside back into force.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","anyOf":[{"type":"object","properties":{"action":{"type":"string","const":"reverse"},"action_id":{"description":"The action_id returned by commit_gated_action.","type":"string"},"reversed_by":{"description":"The named person recording this reversal.","type":"string"},"reason":{"description":"Optional note for the record.","type":"string"}},"required":["action","action_id","reversed_by"],"additionalProperties":false},{"type":"object","properties":{"action":{"type":"string","const":"restore"},"rule_id":{"description":"The id of a correction that was set aside.","type":"string"},"restored_by":{"description":"The named person recording this restore.","type":"string"}},"required":["action","rule_id","restored_by"],"additionalProperties":false}]}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/webhook":{"post":{"operationId":"webhook","summary":"Get a signed HTTP POST whenever an action is held or escalated, or stop sending it.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","anyOf":[{"type":"object","properties":{"action":{"type":"string","const":"set"},"url":{"description":"https:// only — where Ogen POSTs the held-action event.","type":"string","format":"uri"},"secret":{"description":"Optional signing secret. Omit it and Ogen generates one, returned once in the result.","type":"string"}},"required":["action","url"],"additionalProperties":false},{"type":"object","properties":{"action":{"type":"string","const":"remove"}},"required":["action"],"additionalProperties":false}]}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/audit_log":{"post":{"operationId":"audit_log","summary":"Paste a log of past reads and actions and see how many would have acted on stale or uncertain data.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"events":{"description":"Up to 2,000 past events, oldest or newest first.","maxItems":2000,"type":"array","items":{"type":"object","properties":{"at":{"description":"ISO timestamp of the event.","type":"string"},"kind":{"type":"string","enum":["read","act"]},"key":{"type":"string"},"value":{},"candidates":{"description":"Candidates present at the time, if more than one.","type":"array","items":{}},"acted":{"description":"Set on a read that led to an action being taken on its value.","type":"boolean"},"later_corrected":{"description":"Set when a later correction shows this event was wrong.","type":"boolean"}},"required":["at","kind"],"additionalProperties":{}}}},"required":["events"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/what_it_caught":{"post":{"operationId":"what_it_caught","summary":"A short report of what Ogen did over a window.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"days":{"description":"Window size in days, default 7.","type":"integer","exclusiveMinimum":0,"maximum":90}},"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/explain_hold":{"post":{"operationId":"explain_hold","summary":"Everything about one held action, for a person or their assistant to look at.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"action_id":{"description":"The action_id returned by commit_gated_action.","type":"string"}},"required":["action_id"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"found":{"type":"boolean"},"committed":{"type":"boolean"},"disposition":{"type":"string"},"treatment":{"type":"string"},"status":{"type":"string"},"action_id":{"type":"string"},"kind":{"type":"string"},"key":{"type":"string"},"reason":{"type":"string"},"guidance":{"type":"string"},"confirm_url":{"type":"string"},"approver":{"type":"string"},"notified":{"type":"boolean"},"held_since":{"type":"string"},"decision":{"type":["string","null"]},"decided_by":{"type":["string","null"]},"decided_at":{"type":["string","null"]},"decide_with":{"type":"string","enum":["token_or_passkey","passkey_only"]},"decided_via":{"type":["string","null"],"enum":["token","passkey","name","policy",null]},"released_under":{"type":"object","description":"Present when a release dial released the action without a person: the limit that applied and whose dial it was.","properties":{"field":{"type":"string"},"value":{"type":"number"},"currency":{"type":["string","null"]},"limit_from":{"type":"string","enum":["kind","key"]},"set_by":{"type":"string"}}},"fact":{"type":"object","properties":{"status":{"type":"string","enum":["resolved","ambiguous","unavailable"]},"value":{},"candidates":{"type":"array","items":{"type":"object","properties":{"value":{},"source_label":{"type":["string","null"]}}}}}},"fix_proposal":{"type":["object","null"]},"holds":{"type":"array","items":{"type":"object"}},"note":{"type":"string"},"id":{"type":"string"},"ok":{"type":"boolean"}},"additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/list_holds":{"post":{"operationId":"list_holds","summary":"List this tenant's held actions, newest first.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"status":{"description":"Only open or only decided holds. Omit for both.","type":"string","enum":["open","decided"]},"limit":{"description":"Max rows to return, default and cap 100.","type":"integer","exclusiveMinimum":0,"maximum":100},"include":{"description":"\"expired\" also lists holds that expired with nobody deciding.","type":"string","enum":["expired"]}},"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","properties":{"found":{"type":"boolean"},"committed":{"type":"boolean"},"disposition":{"type":"string"},"treatment":{"type":"string"},"status":{"type":"string"},"action_id":{"type":"string"},"kind":{"type":"string"},"key":{"type":"string"},"reason":{"type":"string"},"guidance":{"type":"string"},"confirm_url":{"type":"string"},"approver":{"type":"string"},"notified":{"type":"boolean"},"held_since":{"type":"string"},"decision":{"type":["string","null"]},"decided_by":{"type":["string","null"]},"decided_at":{"type":["string","null"]},"decide_with":{"type":"string","enum":["token_or_passkey","passkey_only"]},"decided_via":{"type":["string","null"],"enum":["token","passkey","name","policy",null]},"released_under":{"type":"object","description":"Present when a release dial released the action without a person: the limit that applied and whose dial it was.","properties":{"field":{"type":"string"},"value":{"type":"number"},"currency":{"type":["string","null"]},"limit_from":{"type":"string","enum":["kind","key"]},"set_by":{"type":"string"}}},"fact":{"type":"object","properties":{"status":{"type":"string","enum":["resolved","ambiguous","unavailable"]},"value":{},"candidates":{"type":"array","items":{"type":"object","properties":{"value":{},"source_label":{"type":["string","null"]}}}}}},"fix_proposal":{"type":["object","null"]},"holds":{"type":"array","items":{"type":"object"}},"note":{"type":"string"},"id":{"type":"string"},"ok":{"type":"boolean"}},"additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/report_outcome":{"post":{"operationId":"report_outcome","summary":"Report whether a confirmed action ran, with its release ticket.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"ticket":{"description":"The release_ticket a confirmation issued.","type":"string","maxLength":4096},"outcome":{"description":"Whether your system ran the action.","type":"string","enum":["ran","failed"]},"reference":{"description":"Your system's own id for what it did, e.g. a refund id: 1 to 120 letters, digits, or _ . : -. Never an address or a value.","type":"string","maxLength":120},"error":{"description":"Why it did not run. Checked, never stored.","type":"string","maxLength":500}},"required":["ticket","outcome"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"allOf":[{"type":"object","additionalProperties":true},{"type":"object","properties":{"isError":{"type":"boolean"}}}]}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include this tool.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/confirm":{"post":{"operationId":"confirm","summary":"Record a decision on one held action, and release it when the decision is confirm.","security":[{"bearerAuth":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"id":{"description":"The held action's id (from commit_gated_action's confirm_url, or explain_hold/list_holds' action_id).","type":"string"},"decision":{"type":"string","enum":["confirm","reject"]},"decided_by":{"description":"A named person — required when this hold's kind has no routable registered approver.","type":"string"},"approver_token":{"description":"A one-time sign-in token — required when this hold's kind has a routable registered approver.","type":"string"}},"required":["id","decision"],"additionalProperties":false}}}},"responses":{"200":{"description":"Result.","content":{"application/json":{"schema":{"type":"object","properties":{"found":{"type":"boolean"},"committed":{"type":"boolean"},"disposition":{"type":"string"},"treatment":{"type":"string"},"status":{"type":"string"},"action_id":{"type":"string"},"kind":{"type":"string"},"key":{"type":"string"},"reason":{"type":"string"},"guidance":{"type":"string"},"confirm_url":{"type":"string"},"approver":{"type":"string"},"notified":{"type":"boolean"},"held_since":{"type":"string"},"decision":{"type":["string","null"]},"decided_by":{"type":["string","null"]},"decided_at":{"type":["string","null"]},"decide_with":{"type":"string","enum":["token_or_passkey","passkey_only"]},"decided_via":{"type":["string","null"],"enum":["token","passkey","name","policy",null]},"released_under":{"type":"object","description":"Present when a release dial released the action without a person: the limit that applied and whose dial it was.","properties":{"field":{"type":"string"},"value":{"type":"number"},"currency":{"type":["string","null"]},"limit_from":{"type":"string","enum":["kind","key"]},"set_by":{"type":"string"}}},"fact":{"type":"object","properties":{"status":{"type":"string","enum":["resolved","ambiguous","unavailable"]},"value":{},"candidates":{"type":"array","items":{"type":"object","properties":{"value":{},"source_label":{"type":["string","null"]}}}}}},"fix_proposal":{"type":["object","null"]},"holds":{"type":"array","items":{"type":"object"}},"note":{"type":"string"},"id":{"type":"string"},"ok":{"type":"boolean"}},"additionalProperties":true}}}},"400":{"description":"The request body failed validation.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"401":{"description":"Missing or invalid credential.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"403":{"description":"This key's role or plan does not include deciding holds.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}},"429":{"description":"Rate limited, or the daily call cap was reached.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string"},"message":{"type":"string"}},"required":["error"]}}}}}}},"/v1/rest/openapi.json":{"get":{"operationId":"openapi","summary":"This document.","responses":{"200":{"description":"This OpenAPI 3.1 document."}}}}}}