{"openapi":"3.1.0","info":{"title":"telipot API","version":"0.0.1"},"paths":{"/health":{"get":{"tags":["system"],"operationId":"health","parameters":[],"security":[],"responses":{"204":{"description":"<No Content>"},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/me":{"get":{"tags":["caller"],"operationId":"me","parameters":[],"security":[],"responses":{"200":{"description":"Caller","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallerEncoded"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/tasks":{"get":{"tags":["tasks"],"operationId":"tasks.list","parameters":[{"name":"telipot-principal","in":"header","schema":{"$ref":"#/components/schemas/Principal"},"required":false},{"name":"cursor","in":"query","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"provider","in":"query","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"capability","in":"query","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"kind","in":"query","schema":{"type":"string","enum":["data","action","account","utility"]},"required":false},{"name":"q","in":"query","schema":{"type":"string","maxLength":200,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false}],"security":[],"responses":{"200":{"description":"TaskPage","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TaskPage"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"principal_forbidden | no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/tasks/{id}":{"get":{"tags":["tasks"],"operationId":"tasks.inspect","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true},{"name":"telipot-principal","in":"header","schema":{"$ref":"#/components/schemas/Principal"},"required":false}],"security":[],"responses":{"200":{"description":"Task","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Task"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"principal_forbidden | no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"task_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"410":{"description":"task_retired | task_broken","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/tasks/{id}/run":{"post":{"tags":["tasks"],"operationId":"tasks.run","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true},{"name":"telipot-principal","in":"header","schema":{"$ref":"#/components/schemas/Principal"},"required":false},{"name":"telipot-connection","in":"header","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"telipot-account","in":"header","schema":{"type":"string","maxLength":320,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"telipot-credential","in":"header","schema":{"type":"string","maxLength":8192,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate.","minLength":4},"required":false},{"name":"telipot-max-cost","in":"header","schema":{"type":"string"},"required":false},{"name":"telipot-fallback","in":"header","schema":{"type":"string","enum":["platform"]},"required":false},{"name":"telipot-tag","in":"header","schema":{"type":"string","maxLength":200,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"telipot-order","in":"header","schema":{"type":"string"},"required":false},{"name":"telipot-only","in":"header","schema":{"type":"string"},"required":false},{"name":"telipot-sort","in":"header","schema":{"type":"string","enum":["cost","latency","reliability"]},"required":false},{"name":"telipot-zero-retention","in":"header","schema":{"type":"string","enum":["true","false"]},"required":false},{"name":"telipot-version","in":"header","schema":{"$ref":"#/components/schemas/CatalogVersion"},"required":false},{"name":"idempotency-key","in":"header","schema":{"type":"string","maxLength":255,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false}],"security":[],"responses":{"200":{"description":"Run","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Run"}}}},"400":{"description":"principal_required | invalid_input","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"401":{"description":"connection_invalid | unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"402":{"description":"no_credential","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"403":{"description":"principal_forbidden | grant_required | connection_required | scope_required | connection_forbidden | no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"task_not_found | connection_not_found | miss","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"409":{"description":"catalog_version_mismatch | connection_ambiguous | idempotency_in_flight","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"410":{"description":"task_retired | task_broken","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"429":{"description":"rate_limited","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"502":{"description":"upstream_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RunBody"}}},"required":true}}},"/v1/capabilities/{id}":{"get":{"tags":["capabilities"],"operationId":"capabilities.get","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true},{"name":"telipot-principal","in":"header","schema":{"$ref":"#/components/schemas/Principal"},"required":false}],"security":[],"responses":{"200":{"description":"Capability","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Capability"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"principal_forbidden | no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"capability_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/discover":{"post":{"tags":["discover"],"operationId":"discover.discover","parameters":[{"name":"telipot-principal","in":"header","schema":{"$ref":"#/components/schemas/Principal"},"required":false}],"security":[],"responses":{"200":{"description":"Discovery","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Discovery"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"principal_forbidden | no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Discover"}}},"required":true}}},"/v1/calls":{"get":{"tags":["audit"],"operationId":"audit.list","parameters":[{"name":"cursor","in":"query","schema":{"type":"string"},"required":false},{"name":"task","in":"query","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"provider","in":"query","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"principal","in":"query","schema":{"$ref":"#/components/schemas/Principal"},"required":false},{"name":"outcome","in":"query","schema":{"type":"string","enum":["hit","miss","fault","pending"]},"required":false},{"name":"token","in":"query","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false},{"name":"connection","in":"query","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false}],"security":[],"responses":{"200":{"description":"CallList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CallList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/usage":{"get":{"tags":["audit"],"operationId":"audit.usage","parameters":[{"name":"days","in":"query","schema":{"type":"string","enum":["1","7","30"],"description":"How many UTC days to count, today's so far among them; 7 unless given."},"required":false},{"name":"token","in":"query","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false}],"security":[],"responses":{"200":{"description":"Usage","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Usage"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/captures":{"get":{"tags":["audit"],"operationId":"audit.captures","parameters":[{"name":"cursor","in":"query","schema":{"type":"string"},"required":false}],"security":[],"responses":{"200":{"description":"CaptureList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CaptureList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/calls/{id}":{"get":{"tags":["audit"],"operationId":"audit.call","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"Call","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Call"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"call_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/calls/{id}/capture":{"get":{"tags":["audit"],"operationId":"audit.capture","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"Capture","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Capture"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"capture_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/connections":{"post":{"tags":["connections"],"operationId":"connections.add","parameters":[],"security":[],"responses":{"200":{"description":"Connection","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Connection"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"422":{"description":"credential_refused","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"429":{"description":"rate_limited","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"503":{"description":"probe_unavailable","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewConnection"}}},"required":true}},"get":{"tags":["connections"],"operationId":"connections.list","parameters":[{"name":"principal","in":"query","schema":{"$ref":"#/components/schemas/Principal"},"required":false}],"security":[],"responses":{"200":{"description":"ConnectionList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"principal_forbidden | no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/connections/{id}":{"get":{"tags":["connections"],"operationId":"connections.get","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"ConnectionDetail","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionDetail"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"connection_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}},"patch":{"tags":["connections"],"operationId":"connections.update","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"Connection","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Connection"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"connection_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionChange"}}},"required":true}},"delete":{"tags":["connections"],"operationId":"connections.revoke","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"Connection","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Connection"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"connection_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/grants":{"get":{"tags":["grants"],"operationId":"grants.list","parameters":[{"name":"cursor","in":"query","schema":{"type":"string"},"required":false},{"name":"principal","in":"query","schema":{"$ref":"#/components/schemas/Principal"},"required":false},{"name":"state","in":"query","schema":{"type":"string","enum":["active","revoked"]},"required":false}],"security":[],"responses":{"200":{"description":"GrantList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/GrantList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/principals":{"get":{"tags":["principals"],"operationId":"principals.list","parameters":[{"name":"cursor","in":"query","schema":{"type":"string"},"required":false},{"name":"q","in":"query","schema":{"type":"string","maxLength":140,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":false}],"security":[],"responses":{"200":{"description":"PrincipalList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PrincipalList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/connect/sessions":{"post":{"tags":["connect"],"operationId":"connect.start","parameters":[],"security":[],"responses":{"201":{"description":"ConnectSessionCreated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectSessionCreated"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | principal_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"409":{"description":"oauth_app_required","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"429":{"description":"rate_limited","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewConnectSession"}}},"required":true}},"get":{"tags":["connect"],"operationId":"connect.list","parameters":[{"name":"cursor","in":"query","schema":{"type":"string"},"required":false},{"name":"principal","in":"query","schema":{"$ref":"#/components/schemas/Principal"},"required":false},{"name":"status","in":"query","schema":{"type":"string","enum":["pending","completed","expired"]},"required":false}],"security":[],"responses":{"200":{"description":"ConnectSessionList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectSessionList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/connect/sessions/{id}":{"get":{"tags":["connect"],"operationId":"connect.session","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"ConnectSession","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectSession"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"connect_session_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/connect/connections-pages":{"post":{"tags":["connect"],"operationId":"connect.connectionsPage","parameters":[],"security":[],"responses":{"201":{"description":"ConnectionsPageCreated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConnectionsPageCreated"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewConnectionsPage"}}},"required":true}}},"/v1/connect/redirect-uris":{"get":{"tags":["connect"],"operationId":"connect.redirectUris","parameters":[],"security":[],"responses":{"200":{"description":"RedirectAllowlist","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RedirectAllowlist"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}},"put":{"tags":["connect"],"operationId":"connect.replaceRedirectUris","parameters":[],"security":[],"responses":{"200":{"description":"RedirectAllowlist","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RedirectAllowlist"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RedirectAllowlist"}}},"required":true}}},"/v1/providers":{"get":{"tags":["providers"],"operationId":"providers.list","parameters":[],"security":[],"responses":{"200":{"description":"ProviderList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/providers/{slug}":{"get":{"tags":["providers"],"operationId":"providers.get","parameters":[{"name":"slug","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"ProviderSummary","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProviderSummary"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"provider_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/providers/{slug}/oauth-app":{"get":{"tags":["providers"],"operationId":"providers.getOAuthApp","parameters":[{"name":"slug","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"OAuthApp","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OAuthApp"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"no_active_organization | untrusted_origin | role_forbidden","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"provider_not_found | oauth_app_not_found","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}},"put":{"tags":["providers"],"operationId":"providers.setOAuthApp","parameters":[{"name":"slug","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"OAuthApp","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OAuthApp"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewOAuthApp"}}},"required":true}},"delete":{"tags":["providers"],"operationId":"providers.removeOAuthApp","parameters":[{"name":"slug","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"204":{"description":"<No Content>"},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"provider_not_found | oauth_app_not_found","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/webhooks":{"post":{"tags":["webhooks"],"operationId":"webhooks.create","parameters":[],"security":[],"responses":{"200":{"description":"WebhookCreated","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookCreated"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"409":{"description":"webhook_limit_reached","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"422":{"description":"webhook_target_refused","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"429":{"description":"rate_limited","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewWebhook"}}},"required":true}},"get":{"tags":["webhooks"],"operationId":"webhooks.list","parameters":[],"security":[],"responses":{"200":{"description":"WebhookList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/webhooks/{id}":{"delete":{"tags":["webhooks"],"operationId":"webhooks.remove","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"Webhook","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Webhook"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"webhook_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/webhooks/{id}/deliveries":{"get":{"tags":["webhooks"],"operationId":"webhooks.deliveries","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"200":{"description":"WebhookDeliveryList","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookDeliveryList"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"webhook_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/tokens":{"post":{"tags":["tokens"],"operationId":"tokens.issue","parameters":[],"security":[],"responses":{"201":{"description":"UserBoundToken","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserBoundToken"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"429":{"description":"rate_limited","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}},"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/NewUserBoundToken"}}},"required":true}},"get":{"tags":["tokens"],"operationId":"tokens.list","parameters":[{"name":"cursor","in":"query","schema":{"type":"string"},"required":false}],"security":[],"responses":{"200":{"description":"HeldUserBoundTokens","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HeldUserBoundTokens"}}}},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}},"/v1/tokens/{id}":{"delete":{"tags":["tokens"],"operationId":"tokens.revoke","parameters":[{"name":"id","in":"path","schema":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"required":true}],"security":[],"responses":{"204":{"description":"<No Content>"},"400":{"description":"invalid_input","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"401":{"description":"unauthenticated | invalid_token","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"403":{"description":"role_forbidden | no_active_organization | untrusted_origin","content":{"application/problem+json":{"schema":{"anyOf":[{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"},{"$ref":"#/components/schemas/ProblemDetails"}]}}}},"404":{"description":"token_not_found","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"413":{"description":"payload_too_large","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}},"500":{"description":"internal_error","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"ProblemDetails":{"type":"object","properties":{"type":{"type":"string"},"title":{"type":"string"},"status":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"detail":{"type":"string"},"code":{"type":"string"}},"required":["type","title","status","detail","code"],"allOf":[{"type":"object","additionalProperties":{}}]},"HeldUserBoundTokens":{"type":"object","properties":{"tokens":{"type":"array","items":{"$ref":"#/components/schemas/HeldUserBoundToken"}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["tokens","next_cursor"],"additionalProperties":false},"HeldUserBoundToken":{"type":"object","properties":{"id":{"type":"string"},"principal":{"type":"string"},"expires_at":{"type":"string"},"issued_by":{"type":"string"}},"required":["id","principal","expires_at","issued_by"],"additionalProperties":false},"UserBoundToken":{"type":"object","properties":{"id":{"type":"string"},"token":{"type":"string"},"principal":{"type":"string"},"expires_at":{"type":"string"}},"required":["id","token","principal","expires_at"],"additionalProperties":false},"NewUserBoundToken":{"type":"object","properties":{"principal":{"type":"string"},"expires_in":{"type":"integer","minimum":60,"maximum":86400,"description":"Seconds the token lasts, 3600 unless given and 86400 at most."}},"required":["principal"],"additionalProperties":false},"WebhookDeliveryList":{"type":"object","properties":{"deliveries":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDelivery"}}},"required":["deliveries"],"additionalProperties":false},"WebhookDelivery":{"type":"object","properties":{"id":{"type":"string"},"event_id":{"type":"string"},"event":{"type":"string","enum":["connection.created","connection.needs_reauth","connection.revoked","connection.restored","connection.expiring"]},"state":{"type":"string","enum":["pending","delivered","failed"]},"attempts":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"last_status":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"last_error":{"anyOf":[{"type":"string"},{"type":"null"}]},"created_at":{"type":"string"},"updated_at":{"type":"string"}},"required":["id","event_id","event","state","attempts","last_status","last_error","created_at","updated_at"],"additionalProperties":false},"Webhook":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string"},"created_at":{"type":"string"}},"required":["id","url","created_at"],"additionalProperties":false},"WebhookList":{"type":"object","properties":{"webhooks":{"type":"array","items":{"$ref":"#/components/schemas/Webhook"}}},"required":["webhooks"],"additionalProperties":false},"WebhookCreated":{"type":"object","properties":{"id":{"type":"string"},"url":{"type":"string"},"created_at":{"type":"string"},"secret":{"type":"string"}},"required":["id","url","created_at","secret"],"additionalProperties":false},"NewWebhook":{"type":"object","properties":{"url":{"type":"string","maxLength":2000,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."}},"required":["url"],"additionalProperties":false},"OAuthApp":{"type":"object","properties":{"provider":{"type":"string"},"client_id":{"type":"string"}},"required":["provider","client_id"],"additionalProperties":false},"NewOAuthApp":{"type":"object","properties":{"client_id":{"type":"string","maxLength":512,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"client_secret":{"type":"string","maxLength":1024,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."}},"required":["client_id","client_secret"],"additionalProperties":false},"ProviderSummary":{"type":"object","properties":{"slug":{"type":"string"},"name":{"type":"string"},"docs_url":{"type":"string"},"retention":{"type":"string","enum":["zero","standard"]},"auth":{"type":"array","items":{"type":"string","enum":["api_key","oauth2","basic","bearer"]}},"connects":{"type":"object","properties":{"organization_key":{"type":"boolean"},"organization_oauth":{"type":"boolean"},"user_key":{"type":"boolean"},"user_oauth":{"type":"boolean"}},"required":["organization_key","organization_oauth","user_key","user_oauth"],"additionalProperties":false},"oauth_app":{"type":"object","properties":{"managed":{"type":"boolean"},"byo":{"type":"boolean"},"own_required":{"type":"boolean"},"client_id":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["managed","byo","own_required","client_id"],"additionalProperties":false},"callback_url":{"anyOf":[{"type":"string"},{"type":"null"}]},"scopes":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string"},"description":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["name","description"],"additionalProperties":false}},"tasks":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"identity_task":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["slug","name","docs_url","retention","auth","connects","oauth_app","callback_url","scopes","tasks","identity_task"],"additionalProperties":false},"ProviderList":{"type":"object","properties":{"providers":{"type":"array","items":{"$ref":"#/components/schemas/ProviderSummary"}}},"required":["providers"],"additionalProperties":false},"RedirectAllowlist":{"type":"object","properties":{"redirect_uris":{"type":"array","items":{"type":"string","maxLength":2000,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"maxItems":50}},"required":["redirect_uris"],"additionalProperties":false},"ConnectionsPageCreated":{"type":"object","properties":{"url":{"type":"string"},"expires_at":{"type":"string"}},"required":["url","expires_at"],"additionalProperties":false},"NewConnectionsPage":{"type":"object","properties":{"principal":{"type":"string"}},"required":["principal"],"additionalProperties":false},"ConnectSession":{"type":"object","properties":{"session_id":{"type":"string"},"provider":{"type":"string"},"principal":{"type":"string"},"status":{"type":"string","enum":["pending","completed","expired"]},"connection_id":{"anyOf":[{"type":"string"},{"type":"null"}]},"expires_at":{"type":"string"}},"required":["session_id","provider","principal","status","connection_id","expires_at"],"additionalProperties":false},"ConnectSessionList":{"type":"object","properties":{"sessions":{"type":"array","items":{"$ref":"#/components/schemas/ConnectSessionRecord"}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["sessions","next_cursor"],"additionalProperties":false},"ConnectSessionRecord":{"type":"object","properties":{"session_id":{"type":"string"},"provider":{"type":"string"},"principal":{"type":"string"},"status":{"type":"string","enum":["pending","completed","expired"]},"connection_id":{"anyOf":[{"type":"string"},{"type":"null"}]},"expires_at":{"type":"string"},"created_at":{"type":"string"},"label":{"anyOf":[{"type":"string"},{"type":"null"}]},"scopes":{"type":"array","items":{"type":"string"}},"redirect_uri":{"type":"string"},"adds_to":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["session_id","provider","principal","status","connection_id","expires_at","created_at","label","scopes","redirect_uri","adds_to"],"additionalProperties":false},"Principal":{"type":"string"},"ConnectSessionCreated":{"type":"object","properties":{"session_id":{"type":"string"},"url":{"type":"string"},"expires_at":{"type":"string"}},"required":["session_id","url","expires_at"],"additionalProperties":false},"NewConnectSession":{"type":"object","properties":{"provider":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"principal":{"$ref":"#/components/schemas/Principal"},"scopes":{"type":"array","items":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"maxItems":100},"redirect_uri":{"type":"string","maxLength":2000,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"label":{"type":"string","maxLength":200,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."}},"required":["provider","principal","redirect_uri"],"additionalProperties":false},"PrincipalList":{"type":"object","properties":{"principals":{"type":"array","items":{"$ref":"#/components/schemas/PrincipalSummary"}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["principals","next_cursor"],"additionalProperties":false},"PrincipalSummary":{"type":"object","properties":{"principal":{"type":"string"},"created_at":{"type":"string"},"connections":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"needs_reauth":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"providers":{"type":"array","items":{"type":"string"}}},"required":["principal","created_at","connections","needs_reauth","providers"],"additionalProperties":false},"GrantList":{"type":"object","properties":{"grants":{"type":"array","items":{"$ref":"#/components/schemas/Grant"}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["grants","next_cursor"],"additionalProperties":false},"Grant":{"type":"object","properties":{"id":{"type":"string"},"connection_id":{"type":"string"},"provider":{"type":"string"},"principal":{"type":"string"},"account":{"anyOf":[{"type":"string"},{"type":"null"}]},"scopes":{"type":"array","items":{"type":"string"}},"created_at":{"type":"string"},"revoked_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"revoked_by":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["id","connection_id","provider","principal","account","scopes","created_at","revoked_at","revoked_by"],"additionalProperties":false},"Connection":{"type":"object","properties":{"id":{"type":"string"},"provider":{"type":"string"},"principal":{"type":"string"},"account":{"anyOf":[{"type":"string"},{"type":"null"}]},"label":{"anyOf":[{"type":"string"},{"type":"null"}]},"state":{"type":"string","enum":["active","needs_reauth","revoked","expired"]},"default":{"type":"boolean"},"scopes":{"type":"array","items":{"type":"string"}}},"required":["id","provider","principal","account","label","state","default","scopes"],"additionalProperties":false},"ConnectionChange":{"type":"object","properties":{"default":{"type":"boolean"},"label":{"anyOf":[{"type":"string","maxLength":200,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},{"type":"null"}]}},"additionalProperties":false},"ConnectionDetail":{"type":"object","properties":{"id":{"type":"string"},"provider":{"type":"string"},"principal":{"type":"string"},"account":{"anyOf":[{"type":"string"},{"type":"null"}]},"label":{"anyOf":[{"type":"string"},{"type":"null"}]},"state":{"type":"string","enum":["active","needs_reauth","revoked","expired"]},"default":{"type":"boolean"},"scopes":{"type":"array","items":{"type":"string"}},"created_at":{"type":"string"},"expires_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"grant":{"type":"object","properties":{"id":{"type":"string"},"scopes":{"type":"array","items":{"type":"string"}},"created_at":{"type":"string"},"revoked_at":{"anyOf":[{"type":"string"},{"type":"null"}]},"revoked_by":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["id","scopes","created_at","revoked_at","revoked_by"],"additionalProperties":false}},"required":["id","provider","principal","account","label","state","default","scopes","created_at","expires_at","grant"],"additionalProperties":false},"ConnectionList":{"type":"object","properties":{"connections":{"type":"array","items":{"$ref":"#/components/schemas/Connection"}}},"required":["connections"],"additionalProperties":false},"NewConnection":{"type":"object","properties":{"provider":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"principal":{"type":"string","enum":["organization"]},"credential":{"type":"string","maxLength":8192,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate.","minLength":4},"label":{"type":"string","maxLength":200,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."}},"required":["provider","principal","credential"],"additionalProperties":false},"Capture":{"type":"object","properties":{"call_id":{"type":"string"},"task":{"type":"string"},"at":{"type":"string"},"expires_at":{"type":"string"},"request":{},"response_status":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"response":{"anyOf":[{},{"type":"null"}]}},"required":["call_id","task","at","expires_at","request","response_status","response"],"additionalProperties":false},"Call":{"type":"object","properties":{"call_id":{"type":"string"},"task":{"type":"string"},"identity":{"type":"string","enum":["user","organization","platform","anonymous"]},"principal":{"anyOf":[{"type":"string"},{"type":"null"}]},"account":{"anyOf":[{"type":"string"},{"type":"null"}]},"credential_source":{"type":"string","enum":["none","byoc","managed"]},"quoted_usd":{"type":"string"},"charged_usd":{"type":"string"},"latency_ms":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"at":{"type":"string"},"connection_id":{"anyOf":[{"type":"string"},{"type":"null"}]},"organization_id":{"type":"string"},"token_id":{"anyOf":[{"type":"string"},{"type":"null"}]},"principal_bound":{"type":"boolean"},"provider":{"type":"string"},"kind":{"type":"string","enum":["data","action","account","utility"]},"outcome":{"type":"string","enum":["hit","miss","fault","pending"]},"upstream_status":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"tag":{"anyOf":[{"type":"string"},{"type":"null"}]},"idempotency_key":{"anyOf":[{"type":"string"},{"type":"null"}]},"request_hash":{"type":"string"}},"required":["call_id","task","identity","principal","account","credential_source","quoted_usd","charged_usd","latency_ms","at","connection_id","organization_id","token_id","principal_bound","provider","kind","outcome","upstream_status","tag","idempotency_key","request_hash"],"additionalProperties":false},"CaptureList":{"type":"object","properties":{"captures":{"type":"array","items":{"$ref":"#/components/schemas/CaptureSummary"}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["captures","next_cursor"],"additionalProperties":false},"CaptureSummary":{"type":"object","properties":{"call_id":{"type":"string"},"task":{"type":"string"},"at":{"type":"string"},"expires_at":{"type":"string"},"response_status":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["call_id","task","at","expires_at","response_status"],"additionalProperties":false},"Usage":{"type":"object","properties":{"from":{"type":"string"},"to":{"type":"string"},"calls":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"outcomes":{"type":"object","properties":{"hit":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"miss":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"fault":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"pending":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["hit","miss","fault","pending"],"additionalProperties":false},"by_day":{"type":"array","items":{"type":"object","properties":{"day":{"type":"string"},"calls":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"hit":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"miss":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"fault":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"pending":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"by_identity":{"type":"object","properties":{"user":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"organization":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"platform":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"anonymous":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["user","organization","platform","anonymous"],"additionalProperties":false}},"required":["day","calls","hit","miss","fault","pending","by_identity"],"additionalProperties":false}},"by_identity":{"type":"array","items":{"type":"object","properties":{"identity":{"type":"string","enum":["user","organization","platform","anonymous"]},"calls":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["identity","calls"],"additionalProperties":false}},"by_task":{"type":"array","items":{"type":"object","properties":{"task":{"type":"string"},"provider":{"type":"string"},"calls":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"hits":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"faults":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["task","provider","calls","hits","faults"],"additionalProperties":false}},"by_principal":{"type":"array","items":{"type":"object","properties":{"principal":{"type":"string"},"calls":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["principal","calls"],"additionalProperties":false}},"end_users":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"charged_usd":{"type":"string"}},"required":["from","to","calls","outcomes","by_day","by_identity","by_task","by_principal","end_users","charged_usd"],"additionalProperties":false},"CallList":{"type":"object","properties":{"calls":{"type":"array","items":{"$ref":"#/components/schemas/Call"}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["calls","next_cursor"],"additionalProperties":false},"Discovery":{"type":"object","properties":{"candidates":{"type":"array","items":{"$ref":"#/components/schemas/Task"}},"near_misses":{"type":"array","items":{"$ref":"#/components/schemas/NearMiss"}}},"required":["candidates"],"additionalProperties":false},"NearMiss":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"matched":{"type":"array","items":{"type":"string"}},"missed":{"type":"array","items":{"type":"string"}}},"required":["id","name","matched","missed"],"additionalProperties":false},"Task":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"summary":{"type":"string"},"provider":{"type":"string"},"version":{"$ref":"#/components/schemas/CatalogVersion"},"capability":{"anyOf":[{"type":"string"},{"type":"null"}]},"tier":{"type":"string","enum":["core","extended"]},"kind":{"type":"string","enum":["data","action","account","utility"]},"auth":{"type":"string","enum":["public","api_key","oauth2","basic","bearer"]},"scope":{"anyOf":[{"type":"string","enum":["any_account","own_account"]},{"type":"null"}]},"principal":{"anyOf":[{"type":"string","enum":["organization","user"]},{"type":"null"}]},"required_scopes":{"type":"array","items":{"type":"string"}},"input":{"type":"object"},"output":{"anyOf":[{"type":"object"},{"type":"null"}]},"price":{"anyOf":[{"$ref":"#/components/schemas/Price"},{"type":"null"}]},"example":{},"terms":{"anyOf":[{"type":"object","properties":{"url":{"type":"string"},"note":{"type":"string"}},"required":["url","note"],"additionalProperties":false},{"type":"null"}]},"verification":{"anyOf":[{"anyOf":[{"type":"object","properties":{"source":{"type":"string","enum":["catalog"]},"state":{"type":"string","enum":["verified"]},"date":{"type":"string"}},"required":["source","state","date"],"additionalProperties":false},{"type":"object","properties":{"source":{"type":"string","enum":["catalog"]},"state":{"type":"string","enum":["unverified","untestable","skipped"]},"reason":{"type":"string"}},"required":["source","state","reason"],"additionalProperties":false}]},{"type":"null"}]},"identity":{"anyOf":[{"type":"string","enum":["user","organization","platform","anonymous"]},{"type":"null"}]},"credential_in_place":{"type":"boolean"}},"required":["id","name","summary","provider","version","capability","tier","kind","auth","scope","principal","required_scopes","input","output","price","example","terms","verification","identity","credential_in_place"],"additionalProperties":false},"Price":{"anyOf":[{"type":"object","properties":{"type":{"type":"string","enum":["free"]}},"required":["type"],"additionalProperties":false},{"type":"object","properties":{"type":{"type":"string","enum":["per_call","per_success","per_result"]},"usd":{"anyOf":[{"type":"object","properties":{"floor":{"type":"string"},"ceiling":{"type":"string"}},"required":["floor","ceiling"],"additionalProperties":false},{"type":"null"}]},"native":{"anyOf":[{"type":"object","properties":{"floor":{"type":"string"},"ceiling":{"type":"string"},"currency":{"type":"string"}},"required":["floor","ceiling","currency"],"additionalProperties":false},{"type":"null"}]},"per":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"unit":{"type":"string"},"source":{"anyOf":[{"type":"string"},{"type":"null"}]},"source_url":{"anyOf":[{"type":"string"},{"type":"null"}]},"checked":{"type":"string"},"confidence":{"type":"string","enum":["verified","documented","inferred","unknown"]}},"required":["type","usd","native","per","unit","source","source_url","checked","confidence"],"additionalProperties":false}]},"CatalogVersion":{"type":"string"},"Discover":{"type":"object","properties":{"task":{"type":"string","maxLength":500,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate.","minLength":1},"limit":{"type":"integer","minimum":1,"maximum":50,"description":"How many candidates at most, or near misses when there is none; 8 unless given."},"filters":{"$ref":"#/components/schemas/Filters"}},"required":["task"],"additionalProperties":false},"Filters":{"type":"object","properties":{"provider":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"tier":{"type":"string","enum":["core","extended"]},"kind":{"type":"string","enum":["data","action","account","utility"]}},"additionalProperties":false},"Capability":{"type":"object","properties":{"id":{"type":"string"},"description":{"type":"string"},"tasks":{"type":"array","items":{"$ref":"#/components/schemas/Task"}}},"required":["id","description","tasks"],"additionalProperties":false},"Run":{"type":"object","properties":{"output":{},"receipt":{"$ref":"#/components/schemas/Receipt"}},"required":["output","receipt"],"additionalProperties":false},"Receipt":{"type":"object","properties":{"call_id":{"type":"string"},"task":{"type":"string"},"identity":{"type":"string","enum":["user","organization","platform","anonymous"]},"principal":{"anyOf":[{"type":"string"},{"type":"null"}]},"connection":{"anyOf":[{"type":"string"},{"type":"null"}]},"account":{"anyOf":[{"type":"string"},{"type":"null"}]},"credential_source":{"type":"string","enum":["none","byoc","managed"]},"quoted_usd":{"type":"string"},"charged_usd":{"type":"string"},"latency_ms":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["call_id","task","identity","principal","connection","account","credential_source","quoted_usd","charged_usd","latency_ms"],"additionalProperties":false},"RunBody":{"type":"object","properties":{"receipt":{"$ref":"#/components/schemas/ReceiptOptions"}},"allOf":[{"type":"object","additionalProperties":{}}]},"ReceiptOptions":{"type":"object","properties":{"principal":{"$ref":"#/components/schemas/Principal"},"connection":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"account":{"type":"string","maxLength":320,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"credential":{"type":"string","maxLength":8192,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate.","minLength":4},"max_cost":{"type":"string"},"fallback":{"type":"string","enum":["platform"]},"tag":{"type":"string","maxLength":200,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"order":{"type":"array","items":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"maxItems":50},"only":{"type":"array","items":{"type":"string","maxLength":100,"pattern":"^[^\\x00]*$","description":"Text without a NUL or a lone surrogate."},"maxItems":50},"sort":{"type":"string","enum":["cost","latency","reliability"]},"zero_retention":{"type":"boolean"},"version":{"$ref":"#/components/schemas/CatalogVersion"}},"additionalProperties":false},"TaskPage":{"type":"object","properties":{"tasks":{"type":"array","items":{"$ref":"#/components/schemas/TaskSummary"}},"next_cursor":{"anyOf":[{"type":"string"},{"type":"null"}]},"total":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991}},"required":["tasks","next_cursor","total"],"additionalProperties":false},"TaskSummary":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"summary":{"type":"string"},"provider":{"type":"string"},"version":{"$ref":"#/components/schemas/CatalogVersion"},"capability":{"anyOf":[{"type":"string"},{"type":"null"}]},"tier":{"type":"string","enum":["core","extended"]},"kind":{"type":"string","enum":["data","action","account","utility"]},"auth":{"type":"string","enum":["public","api_key","oauth2","basic","bearer"]},"scope":{"anyOf":[{"type":"string","enum":["any_account","own_account"]},{"type":"null"}]},"principal":{"anyOf":[{"type":"string","enum":["organization","user"]},{"type":"null"}]},"required_scopes":{"type":"array","items":{"type":"string"}},"price":{"anyOf":[{"$ref":"#/components/schemas/Price"},{"type":"null"}]},"terms":{"anyOf":[{"type":"object","properties":{"url":{"type":"string"},"note":{"type":"string"}},"required":["url","note"],"additionalProperties":false},{"type":"null"}]},"verification":{"anyOf":[{"anyOf":[{"type":"object","properties":{"source":{"type":"string","enum":["catalog"]},"state":{"type":"string","enum":["verified"]},"date":{"type":"string"}},"required":["source","state","date"],"additionalProperties":false},{"type":"object","properties":{"source":{"type":"string","enum":["catalog"]},"state":{"type":"string","enum":["unverified","untestable","skipped"]},"reason":{"type":"string"}},"required":["source","state","reason"],"additionalProperties":false}]},{"type":"null"}]},"identity":{"anyOf":[{"type":"string","enum":["user","organization","platform","anonymous"]},{"type":"null"}]},"credential_in_place":{"type":"boolean"}},"required":["id","name","summary","provider","version","capability","tier","kind","auth","scope","principal","required_scopes","price","terms","verification","identity","credential_in_place"],"additionalProperties":false},"CallerEncoded":{"type":"object","properties":{"organizationId":{"type":"string"},"credential":{"anyOf":[{"type":"object","properties":{"_tag":{"type":"string","enum":["Session"]},"userId":{"type":"string"}},"required":["_tag","userId"],"additionalProperties":false},{"type":"object","properties":{"_tag":{"type":"string","enum":["Token"]},"tokenId":{"type":"string"},"debugCapture":{"type":"boolean"},"backendOnly":{"type":"boolean"},"principal":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["_tag","tokenId","debugCapture","backendOnly","principal"],"additionalProperties":false}]}},"required":["organizationId","credential"],"additionalProperties":false}},"securitySchemes":{}},"security":[],"tags":[{"name":"system"},{"name":"caller"},{"name":"tasks"},{"name":"capabilities"},{"name":"discover"},{"name":"audit"},{"name":"connections"},{"name":"grants"},{"name":"principals"},{"name":"connect"},{"name":"providers"},{"name":"webhooks"},{"name":"tokens"}]}