{"openapi":"3.1.0","jsonSchemaDialect":"http://json-schema.org/draft-07/schema#","info":{"title":"AdBuyMCP API","version":"0.1.0","description":"AdBuyMCP media buying REST API. All amounts are integer minor currency units. Sandbox execution is deterministic and requires no supplier credentials. Live buying requires approved supplier access, funding and reviewed creative evidence. Request schemas come from runtime validators; unmodeled success payloads are explicitly identified. API version is carried in /api/v1."},"servers":[{"url":"https://app.adbuymcp.com","description":"Configured public API origin"}],"externalDocs":{"description":"Public API and MCP guides","url":"https://app.adbuymcp.com/docs"},"paths":{"/api/v1/agent/actions":{"get":{"operationId":"get_api_v1_agent_actions","summary":"Read consequential agent action contracts","description":"Returns exact action names, REST routes, parameter contracts and budget policies. These are approval contracts, not independently selectable OAuth scopes.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/actions/prepare":{"post":{"operationId":"post_api_v1_agent_actions_prepare","summary":"Prepare an exact agent action for review","description":"Normalizes real parameters and returns the action digest and commitment required for human review. Secrets and large sensitive payloads are represented by digests rather than copied into the mission journal.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"parameters":{"type":"object","additionalProperties":{}},"budgetMinor":{"type":"integer","minimum":0,"maximum":1900000000},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["name","parameters","budgetMinor","currency"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/approvals/{id}/abandon":{"post":{"operationId":"post_api_v1_agent_approvals_id_abandon","summary":"Run agent / approvals / abandon","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with agent:approve permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedActionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"note":{"type":"string","minLength":1,"maxLength":2000}},"required":["expectedActionDigest","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["agent:approve"]}},"/api/v1/agent/approvals/{id}/resolve":{"post":{"operationId":"post_api_v1_agent_approvals_id_resolve","summary":"Resolve an exact agent approval","description":"A human with agent:approve permission accepts or rejects the specific action and commitment. Approval does not grant blanket authority over future changed requests.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with agent:approve permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedActionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"resolution":{"type":"string","enum":["approved","rejected"]},"note":{"type":"string","minLength":1,"maxLength":2000}},"required":["expectedActionDigest","resolution","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["agent:approve"]}},"/api/v1/agent/exceptions":{"get":{"operationId":"get_api_v1_agent_exceptions","summary":"Read agent / exceptions","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":200,"default":50},"style":"form","explode":true},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0},"style":"form","explode":true},{"name":"missionId","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":128},"style":"form","explode":true},{"name":"runId","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":128},"style":"form","explode":true},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["open","resolved"]},"style":"form","explode":true},{"name":"severity","in":"query","required":false,"schema":{"type":"string","enum":["info","warning","critical"]},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/exceptions/{id}/resolve":{"post":{"operationId":"post_api_v1_agent_exceptions_id_resolve","summary":"Run agent / exceptions / resolve","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"resolution":{"type":"string","minLength":1,"maxLength":4000}},"required":["resolution"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/mandates/{id}/revoke":{"post":{"operationId":"post_api_v1_agent_mandates_id_revoke","summary":"Run agent / mandates / revoke","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with agent:approve permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":1},"note":{"type":"string","minLength":1,"maxLength":2000}},"required":["expectedVersion","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["agent:approve"]}},"/api/v1/agent/missions":{"get":{"operationId":"get_api_v1_agent_missions","summary":"Read agent / missions","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":200,"default":50},"style":"form","explode":true},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0},"style":"form","explode":true},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["active","completed","cancelled"]},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_agent_missions","summary":"Run agent / missions","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"title":{"type":"string","minLength":1,"maxLength":160},"objectives":{"type":"array","items":{"type":"object","properties":{"description":{"type":"string","minLength":1,"maxLength":2000},"successCriteria":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"minItems":1,"maxItems":20}},"required":["description","successCriteria"],"additionalProperties":false},"minItems":1,"maxItems":20},"mandate":{"type":"object","properties":{"mode":{"type":"string","enum":["observe","recommend","execute"],"default":"observe"},"allowedActions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$"},"maxItems":50,"default":[]},"maxBudgetMinor":{"type":"integer","minimum":0,"maximum":1900000000},"currency":{"type":"string","enum":["GBP","USD","EUR"]},"validUntil":{"type":"string","format":"date-time"}},"additionalProperties":false,"default":{"mode":"observe","allowedActions":[]}}},"required":["title","objectives"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/missions/{id}":{"get":{"operationId":"get_api_v1_agent_missions_id","summary":"Read agent / missions","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/missions/{id}/close":{"post":{"operationId":"post_api_v1_agent_missions_id_close","summary":"Run agent / missions / close","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with agent:approve permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"outcome":{"type":"string","enum":["completed","cancelled"]},"note":{"type":"string","minLength":1,"maxLength":2000}},"required":["outcome","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["agent:approve"]}},"/api/v1/agent/missions/{id}/mandates":{"post":{"operationId":"post_api_v1_agent_missions_id_mandates","summary":"Run agent / missions / mandates","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with agent:approve permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":1},"note":{"type":"string","minLength":1,"maxLength":2000},"mandate":{"type":"object","properties":{"mode":{"type":"string","enum":["observe","recommend","execute"],"default":"observe"},"allowedActions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$"},"maxItems":50,"default":[]},"maxBudgetMinor":{"type":"integer","minimum":0,"maximum":1900000000},"currency":{"type":"string","enum":["GBP","USD","EUR"]},"validUntil":{"type":"string","format":"date-time"}},"additionalProperties":false}},"required":["expectedVersion","note","mandate"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["agent:approve"]}},"/api/v1/agent/missions/{id}/runs":{"get":{"operationId":"get_api_v1_agent_missions_id_runs","summary":"Read agent / missions / runs","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":200,"default":50},"style":"form","explode":true},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0},"style":"form","explode":true},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["running","waiting_approval","blocked","succeeded","failed","cancelled"]},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_agent_missions_id_runs","summary":"Run agent / missions / runs","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"mandateId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}":{"get":{"operationId":"get_api_v1_agent_runs_id","summary":"Read agent / runs","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}},{"name":"detailLimit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":500,"default":100},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}/advance":{"post":{"operationId":"post_api_v1_agent_runs_id_advance","summary":"Run agent / runs / advance","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedPhase":{"type":"string","enum":["observe","plan","approve","execute","verify"]},"nextPhase":{"type":"string","enum":["observe","plan","approve","execute","verify"]},"approvalId":{"type":"string","minLength":1,"maxLength":128},"expectedActionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["expectedPhase","nextPhase"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}/approvals":{"post":{"operationId":"post_api_v1_agent_runs_id_approvals","summary":"Run agent / runs / approvals","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"type":"string","enum":["external_action","policy","creative","measurement","other"]},"reason":{"type":"string","minLength":1,"maxLength":2000},"action":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$"},"parameters":{"type":"object","additionalProperties":{},"default":{}},"budgetMinor":{"type":"integer","minimum":0,"maximum":1900000000},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["name"],"additionalProperties":false},"stepId":{"type":"string","minLength":1,"maxLength":128},"expiresAt":{"type":"string","format":"date-time"}},"required":["kind","reason","action"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}/approvals/resolve":{"post":{"operationId":"post_api_v1_agent_runs_id_approvals_resolve","summary":"Resolve explicitly selected agent approvals","description":"A human with agent:approve permission resolves a batch atomically against every selected expected action digest. No implicit approval of unselected actions; changed or stale items fail the batch.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with agent:approve permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"resolution":{"type":"string","enum":["approved","rejected"]},"note":{"type":"string","minLength":1,"maxLength":2000},"approvals":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":128},"expectedActionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["id","expectedActionDigest"],"additionalProperties":false},"minItems":1,"maxItems":20}},"required":["resolution","note","approvals"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["agent:approve"]}},"/api/v1/agent/runs/{id}/decisions":{"post":{"operationId":"post_api_v1_agent_runs_id_decisions","summary":"Run agent / runs / decisions","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$"},"outcome":{"type":"object","additionalProperties":{}},"rationale":{"type":"string","minLength":1,"maxLength":4000},"stepId":{"type":"string","minLength":1,"maxLength":128},"evidence":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$"},"source":{"type":"string","minLength":1,"maxLength":500},"content":{"type":"object","additionalProperties":{}},"observedAt":{"type":"string","format":"date-time"}},"required":["kind","source","content"],"additionalProperties":false},"maxItems":20,"default":[]}},"required":["kind","outcome","rationale"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}/evidence":{"post":{"operationId":"post_api_v1_agent_runs_id_evidence","summary":"Run agent / runs / evidence","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$"},"source":{"type":"string","minLength":1,"maxLength":500},"content":{"type":"object","additionalProperties":{}},"observedAt":{"type":"string","format":"date-time"},"stepId":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","source","content"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}/exceptions":{"post":{"operationId":"post_api_v1_agent_runs_id_exceptions","summary":"Run agent / runs / exceptions","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"category":{"type":"string","minLength":1,"maxLength":120,"pattern":"^[a-z][a-z0-9]*(?:[._:-][a-z0-9]+)*$"},"severity":{"type":"string","enum":["info","warning","critical"]},"message":{"type":"string","minLength":1,"maxLength":2000},"detail":{"type":"object","additionalProperties":{},"default":{}},"stepId":{"type":"string","minLength":1,"maxLength":128}},"required":["category","severity","message"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}/finish":{"post":{"operationId":"post_api_v1_agent_runs_id_finish","summary":"Run agent / runs / finish","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"outcome":{"type":"string","enum":["succeeded","failed","cancelled"]},"expectedPhase":{"type":"string","enum":["observe","plan","approve","execute","verify"]},"summary":{"type":"string","minLength":1,"maxLength":4000}},"required":["outcome","expectedPhase","summary"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}/resume":{"post":{"operationId":"post_api_v1_agent_runs_id_resume","summary":"Run agent / runs / resume","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/runs/{id}/steps":{"post":{"operationId":"post_api_v1_agent_runs_id_steps","summary":"Run agent / runs / steps","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedPhase":{"type":"string","enum":["observe","plan","approve","execute","verify"]},"kind":{"type":"string","enum":["observe","plan","approve","execute","verify","other"]},"label":{"type":"string","minLength":1,"maxLength":240},"input":{"type":"object","additionalProperties":{},"default":{}},"approvalId":{"type":"string","minLength":1,"maxLength":128},"expectedActionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["expectedPhase","kind","label"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/steps/{id}/complete":{"post":{"operationId":"post_api_v1_agent_steps_id_complete","summary":"Run agent / steps / complete","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["completed","failed"]},"output":{"type":"object","additionalProperties":{}},"error":{"type":"string","minLength":1,"maxLength":4000}},"required":["status"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/agent/steps/{id}/execution/resolve":{"post":{"operationId":"post_api_v1_agent_steps_id_execution_resolve","summary":"Run agent / steps / execution / resolve","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Agent"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedActionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"outcome":{"type":"string","enum":["applied","not-applied"]},"note":{"type":"string","minLength":1,"maxLength":2000}},"required":["expectedActionDigest","outcome","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/assets/{jobId}":{"get":{"operationId":"get_api_v1_assets_jobId","summary":"Read asset job status","description":"Inspect queued, running, completed, failed or reconciliation-required production and charge state. A provider timeout is not proof of failure.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Assets"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"jobId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/assets/{jobId}/resolve":{"post":{"operationId":"post_api_v1_assets_jobId_resolve","summary":"Resolve an uncertain asset production job","description":"An attributed human operator records actual provider completion or non-application. Resolution updates the job and its separate charge without inventing an outcome.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Assets"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"jobId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"outcome":{"type":"string","enum":["produced","not-produced"]},"providerRef":{"type":"string","minLength":1},"note":{"type":"string","maxLength":500}},"required":["outcome"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/assets/{jobId}/retry":{"post":{"operationId":"post_api_v1_assets_jobId_retry","summary":"Run assets / retry","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Assets"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"jobId","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/assets/pricing":{"get":{"operationId":"get_api_v1_assets_pricing","summary":"Read asset pricing and model licensing","description":"Returns production prices, cost basis, configured margin, model commercial-use evidence and provider terms. Asset charges are separate from media management fees.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Assets"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/audit":{"get":{"operationId":"get_api_v1_audit","summary":"Read audit","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Audit"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":200,"default":50},"style":"form","explode":true},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0},"style":"form","explode":true},{"name":"action","in":"query","required":false,"schema":{"type":"string"},"style":"form","explode":true},{"name":"entity","in":"query","required":false,"schema":{"type":"string"},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/auth/context":{"get":{"operationId":"get_api_v1_auth_context","summary":"Read the verified request identity","description":"Returns advertiser, actor, source, client identity, product/channel scope and verified human permissions. Never derive authority from unsigned caller headers.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Auth"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/billing/spend-locks":{"get":{"operationId":"get_api_v1_billing_spend_locks","summary":"Read billing / spend locks","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/billing/spend-locks/{lockId}/resolve":{"post":{"operationId":"post_api_v1_billing_spend_locks_lockId_resolve","summary":"Run billing / spend locks / resolve","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"lockId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"note":{"type":"string","minLength":1,"maxLength":1000}},"required":["note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/billing/spend-locks/{lockId}/stops/{stopId}/resolve":{"post":{"operationId":"post_api_v1_billing_spend_locks_lockId_stops_stopId_resolve","summary":"Run billing / spend locks / stops / resolve","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"lockId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"stopId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"outcome":{"type":"string","enum":["stopped","still-spending"]},"note":{"type":"string","minLength":1,"maxLength":1000},"providerReference":{"type":"string","minLength":1,"maxLength":255}},"required":["outcome","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/billing/statements":{"get":{"operationId":"get_api_v1_billing_statements","summary":"Read or download billing statements","description":"Returns a period statement in the requested format, separating media spend, platform fees and asset charges.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"period","in":"query","required":true,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}$"},"style":"form","explode":true},{"name":"format","in":"query","required":false,"schema":{"type":"string","enum":["json","csv"],"default":"json"},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}},"text/csv":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/billing/summary":{"get":{"operationId":"get_api_v1_billing_summary","summary":"Read spend, fees and wallet balances","description":"Returns media spend, accrued management fees, separate asset charges and wallet balances. Media fees are 10%; the scale tier applies 5% plus £749 per month under the configured trailing-spend rule.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"period","in":"query","required":false,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}$"},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/billing/topup":{"post":{"operationId":"post_api_v1_billing_topup","summary":"Fund the advertiser wallet","description":"Sandbox top-ups credit immediately; live mode creates Stripe checkout and credits only after verified settlement. Retain idempotencyKey; otherwise repeated requests may create repeated funding operations. Agents bind the key in the approved body, not a header.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: billing.topup. { amountMinor, idempotencyKey, poNumber?, returnTo? } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","minLength":8,"maxLength":200}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"amountMinor":{"type":"integer","minimum":10000,"maximum":2147483647},"returnTo":{"type":"string","maxLength":2048},"idempotencyKey":{"type":"string","minLength":8,"maxLength":200,"description":"Retain the exact key for retries. New live or Stripe-test funding intents require funding-v2: followed by a unique opaque value. Legacy unrecorded keys require operator reconciliation. Header and body keys must match."},"poNumber":{"type":"string","minLength":1,"maxLength":64}},"required":["amountMinor"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"optional","bodyField":"idempotencyKey","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"billing.topup","budgetPolicy":"exact-request","parameterContract":"{ amountMinor, idempotencyKey, poNumber?, returnTo? }","exactApprovalRequired":true}}},"/api/v1/billing/topup/requests/{requestId}":{"get":{"operationId":"get_api_v1_billing_topup_requests_requestId","summary":"Inspect a committed funding request","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"requestId","in":"path","required":true,"schema":{"type":"string","pattern":"^wtr-[a-f0-9]{64}$"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/billing/topup/requests/{requestId}/reconcile":{"post":{"operationId":"post_api_v1_billing_topup_requests_requestId_reconcile","summary":"Recover a funding Checkout reference","description":"Retrieves and matches the exact Stripe session; this never credits the wallet. Signed settlement remains required.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"requestId","in":"path","required":true,"schema":{"type":"string","pattern":"^wtr-[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"sessionId":{"type":"string","pattern":"^cs_[A-Za-z0-9_]+$","maxLength":255}},"required":["sessionId"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/billing/topup/status":{"get":{"operationId":"get_api_v1_billing_topup_status","summary":"Read wallet funding status","description":"Read settlement status for the returned checkout session. A browser return alone is not proof of paid funds.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Billing"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"sessionId","in":"query","required":true,"schema":{"type":"string","pattern":"^cs_[A-Za-z0-9_]+$","maxLength":255},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/billing/webhook":{"post":{"operationId":"post_api_v1_billing_webhook","summary":"Receive signed Stripe settlement events","description":"Inbound Stripe integration endpoint. Requires the raw request body and stripe-signature header verified against STRIPE_WEBHOOK_SECRET. This is not an outbound customer webhook subscription API.\n\nPublic endpoint; tenant data is not exposed by discovery endpoints.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Billing"],"security":[],"parameters":[{"name":"stripe-signature","in":"header","required":true,"description":"Stripe-generated signature over the exact raw request bytes.","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/brand-lift-studies/{studyId}":{"get":{"operationId":"get_api_v1_brand_lift_studies_studyId","summary":"Read brand lift studies","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"patch":{"operationId":"patch_api_v1_brand_lift_studies_studyId","summary":"Update brand lift studies","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: study.update. { studyId, expectedRevision, spec, retainResultsUntil } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"spec":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":300},"advertiserName":{"type":"string","minLength":1,"maxLength":300},"startDate":{"type":"string","format":"date-time"},"endDate":{"type":"string","format":"date-time"},"countryLanguageId":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"industryId":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"channels":{"type":"array","items":{"type":"string","enum":["digital","linear_tv","social"]},"minItems":1,"maxItems":3},"expectedImpressionsCount":{"type":"object","properties":{"digital":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"linear_tv":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"social":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991}},"additionalProperties":false},"dataPartners":{"type":"array","items":{"type":"string","minLength":1,"maxLength":100},"maxItems":20},"templateSelections":{"type":"array","items":{"type":"object","properties":{"usage":{"type":"string","enum":["lift","baseline"]},"questionName":{"type":"string","minLength":1,"maxLength":300},"kpiType":{"type":"string","minLength":1,"maxLength":100},"definitionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"order":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"fieldValues":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"value":{"type":"string","minLength":1,"maxLength":500}},"required":["name","value"],"additionalProperties":false},"maxItems":20}},"required":["usage","questionName","kpiType","definitionDigest","order","fieldValues"],"additionalProperties":false},"minItems":2,"maxItems":55},"brand":{"type":"string","minLength":1,"maxLength":300},"competitors":{"type":"array","items":{"type":"string","minLength":1,"maxLength":300},"minItems":2,"maxItems":10},"allowIp":{"type":"boolean"}},"required":["name","advertiserName","startDate","endDate","countryLanguageId","industryId","channels","expectedImpressionsCount","dataPartners","templateSelections","brand","competitors","allowIp"],"additionalProperties":false},"retainResultsUntil":{"type":"string","format":"date-time"},"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647}},"required":["spec","retainResultsUntil","expectedRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"study.update","budgetPolicy":"zero","parameterContract":"{ studyId, expectedRevision, spec, retainResultsUntil }","exactApprovalRequired":true}}},"/api/v1/brand-lift-studies/{studyId}/approvals":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_approvals","summary":"Run brand lift studies / approvals","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with agent:approve permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0},"quoteId":{"type":"string","format":"uuid"},"purpose":{"type":"string","enum":["purchase","draft","launch"]},"expectedQuoteDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"expectedSpecDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"expectedProviderDefinitionDigest":{"anyOf":[{"type":"string","pattern":"^[a-f0-9]{64}$"},{"type":"null"}]},"expectedTrackingDigest":{"anyOf":[{"type":"string","pattern":"^[a-f0-9]{64}$"},{"type":"null"}]},"previewAttemptId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"expiresAt":{"type":"string","format":"date-time"}},"required":["expectedRevision","quoteId","purpose","expectedQuoteDigest","expectedSpecDigest","expectedProviderDefinitionDigest","expectedTrackingDigest","previewAttemptId","expiresAt"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["agent:approve"]}},"/api/v1/brand-lift-studies/{studyId}/artifacts":{"get":{"operationId":"get_api_v1_brand_lift_studies_studyId_artifacts","summary":"Read brand lift studies / artifacts","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string","format":"uuid"},"style":"form","explode":true},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","exclusiveMinimum":0,"maximum":100},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_artifacts","summary":"Run brand lift studies / artifacts","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"purpose":{"type":"string","enum":["supplier-quote","contract","account-entitlement","tracking-installation","supplier-tracking-acceptance","privacy-notice","consent","processing-terms","foreign-currency-coverage","settlement","reconciliation"]},"mediaType":{"type":"string","enum":["application/pdf","text/csv","application/json","text/plain","image/png","image/jpeg","application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"]},"contentBase64":{"type":"string","minLength":1,"maxLength":2796204},"retainUntil":{"type":"string","format":"date-time"}},"required":["purpose","mediaType","contentBase64","retainUntil"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-body-limit-bytes":2800300}},"/api/v1/brand-lift-studies/{studyId}/artifacts/{artifactId}/content":{"get":{"operationId":"get_api_v1_brand_lift_studies_studyId_artifacts_artifactId_content","summary":"Read brand lift studies / artifacts / content","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human. Delegated agents cannot perform this operator action.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"artifactId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"*/*":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[]}},"/api/v1/brand-lift-studies/{studyId}/attempts/{attemptId}/resolve":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_attempts_attemptId_resolve","summary":"Run brand lift studies / attempts / resolve","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"attemptId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647},"outcome":{"type":"string","enum":["created-draft","launch-confirmed","draft-deleted","confirmed-no-effect","supplier-handled-cancellation"]},"providerStudyId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"evidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false}},"required":["expectedRevision","outcome","providerStudyId","evidence"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/brand-lift-studies/{studyId}/cancellation-request":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_cancellation_request","summary":"Run brand lift studies / cancellation request","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: study.cancellation.request. { studyId, expectedRevision }; requests human supplier handling, without cancellation or refund claims Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647}},"required":["expectedRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"study.cancellation.request","budgetPolicy":"zero","parameterContract":"{ studyId, expectedRevision }; requests human supplier handling, without cancellation or refund claims","exactApprovalRequired":true}}},"/api/v1/brand-lift-studies/{studyId}/cancellation-resolution":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_cancellation_resolution","summary":"Run brand lift studies / cancellation resolution","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647},"providerStudyId":{"type":"string","format":"uuid"},"evidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},"outcome":{"type":"string","const":"supplier-confirmed-cancellation"}},"required":["expectedRevision","providerStudyId","evidence","outcome"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/brand-lift-studies/{studyId}/close-local":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_close_local","summary":"Run brand lift studies / close local","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647},"evidence":{"anyOf":[{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},{"type":"null"}]}},"required":["expectedRevision","evidence"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/brand-lift-studies/{studyId}/draft":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_draft","summary":"Run brand lift studies / draft","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: study.draft. { studyId, expectedRevision, expectedConnectionRevision, quoteId, approvalId }; requires an unused explicit human study approval and its already funded full GBP commitment as budgetMinor. Incremental reservation is 0; generic agent approval cannot purchase or fund a study. Idempotency-Key UUID required. Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647},"expectedConnectionRevision":{"anyOf":[{"type":"integer","minimum":0,"maximum":2147483647},{"type":"null"}]},"quoteId":{"type":"string","format":"uuid"},"approvalId":{"type":"string","format":"uuid"}},"required":["expectedRevision","expectedConnectionRevision","quoteId","approvalId"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"study.draft","budgetPolicy":"study-commitment","parameterContract":"{ studyId, expectedRevision, expectedConnectionRevision, quoteId, approvalId }; requires an unused explicit human study approval and its already funded full GBP commitment as budgetMinor. Incremental reservation is 0; generic agent approval cannot purchase or fund a study. Idempotency-Key UUID required.","exactApprovalRequired":true}}},"/api/v1/brand-lift-studies/{studyId}/launch":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_launch","summary":"Run brand lift studies / launch","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: study.launch. { studyId, expectedRevision, expectedConnectionRevision, quoteId, approvalId }; requires an unused explicit human study approval and its already funded full GBP commitment as budgetMinor. Incremental reservation is 0; generic agent approval cannot purchase or fund a study. Idempotency-Key UUID required. Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647},"expectedConnectionRevision":{"anyOf":[{"type":"integer","minimum":0,"maximum":2147483647},{"type":"null"}]},"quoteId":{"type":"string","format":"uuid"},"approvalId":{"type":"string","format":"uuid"}},"required":["expectedRevision","expectedConnectionRevision","quoteId","approvalId"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"study.launch","budgetPolicy":"study-commitment","parameterContract":"{ studyId, expectedRevision, expectedConnectionRevision, quoteId, approvalId }; requires an unused explicit human study approval and its already funded full GBP commitment as budgetMinor. Incremental reservation is 0; generic agent approval cannot purchase or fund a study. Idempotency-Key UUID required.","exactApprovalRequired":true}}},"/api/v1/brand-lift-studies/{studyId}/preview":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_preview","summary":"Run brand lift studies / preview","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: study.preview. { studyId, expectedRevision }; reads reviewed supplier templates and records exact draft preview Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647}},"required":["expectedRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"study.preview","budgetPolicy":"zero","parameterContract":"{ studyId, expectedRevision }; reads reviewed supplier templates and records exact draft preview","exactApprovalRequired":true}}},"/api/v1/brand-lift-studies/{studyId}/quote-request":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_quote_request","summary":"Run brand lift studies / quote request","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: study.quote.request. { studyId, expectedRevision }; creates a local supplier task, without claiming a quote or price Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647}},"required":["expectedRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"study.quote.request","budgetPolicy":"zero","parameterContract":"{ studyId, expectedRevision }; creates a local supplier task, without claiming a quote or price","exactApprovalRequired":true}}},"/api/v1/brand-lift-studies/{studyId}/quotes":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_quotes","summary":"Run brand lift studies / quotes","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with supplier:authorize permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0},"quote":{"type":"object","properties":{"source":{"type":"string","enum":["operator-recorded-supplier-quote","sandbox-fixture"]},"specDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"providerAccountId":{"type":"string","format":"uuid"},"connectionRevision":{"anyOf":[{"type":"integer","minimum":0,"maximum":2147483647},{"type":"null"}]},"configuredIdentityDigest":{"anyOf":[{"type":"string","pattern":"^[a-f0-9]{64}$"},{"type":"null"}]},"dossierRevision":{"anyOf":[{"type":"integer","minimum":0,"maximum":2147483647},{"type":"null"}]},"dossierDigest":{"anyOf":[{"type":"string","pattern":"^[a-f0-9]{64}$"},{"type":"null"}]},"issuedAt":{"type":"string","format":"date-time"},"expiresAt":{"type":"string","format":"date-time"},"supplier":{"type":"object","properties":{"quoteReference":{"type":"string","minLength":1,"maxLength":200,"pattern":"^[A-Za-z0-9][A-Za-z0-9._:/-]*$"},"evidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},"contractEvidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},"currency":{"type":"string","enum":["GBP","USD","EUR"]},"subtotalMinor":{"type":"integer","minimum":0,"maximum":2147483647},"taxMinor":{"type":"integer","minimum":0,"maximum":2147483647},"totalMinor":{"type":"integer","minimum":0,"maximum":2147483647},"maximumLiabilityMinor":{"type":"integer","minimum":0,"maximum":2147483647},"maximumCancellationLiabilityMinor":{"type":"integer","minimum":0,"maximum":2147483647},"billingTrigger":{"type":"string","enum":["order-acceptance","draft-creation","tracking-setup","launch","invoice"]},"includedScope":{"type":"string","minLength":1,"maxLength":2000}},"required":["quoteReference","evidence","contractEvidence","currency","subtotalMinor","taxMinor","totalMinor","maximumLiabilityMinor","maximumCancellationLiabilityMinor","billingTrigger","includedScope"],"additionalProperties":false},"customer":{"type":"object","properties":{"currency":{"type":"string","const":"GBP"},"subtotalMinor":{"type":"integer","minimum":0,"maximum":2147483647},"taxMinor":{"type":"integer","minimum":0,"maximum":2147483647},"totalMinor":{"type":"integer","minimum":0,"maximum":2147483647},"maximumCommitmentMinor":{"type":"integer","minimum":0,"maximum":2147483647},"cancellationMaximumMinor":{"type":"integer","minimum":0,"maximum":2147483647},"refundTerms":{"type":"string","minLength":1,"maxLength":2000}},"required":["currency","subtotalMinor","taxMinor","totalMinor","maximumCommitmentMinor","cancellationMaximumMinor","refundTerms"],"additionalProperties":false},"foreignCurrencyCoverageEvidence":{"anyOf":[{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},{"type":"null"}]}},"required":["source","specDigest","providerAccountId","connectionRevision","configuredIdentityDigest","dossierRevision","dossierDigest","issuedAt","expiresAt","supplier","customer","foreignCurrencyCoverageEvidence"],"additionalProperties":false}},"required":["expectedRevision","quote"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["supplier:authorize"]}},"/api/v1/brand-lift-studies/{studyId}/results":{"get":{"operationId":"get_api_v1_brand_lift_studies_studyId_results","summary":"Read brand lift studies / results","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/brand-lift-studies/{studyId}/results/refresh":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_results_refresh","summary":"Run brand lift studies / results / refresh","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: study.results.refresh. { studyId, expectedRevision, confidenceLevel, targetAudience, retryParked?: false }; parked result reads require a human operator Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0},"confidenceLevel":{"type":"number","enum":[0.8,0.85,0.9,0.95]},"targetAudience":{"type":"string","enum":["all","campaign-default"]},"retryParked":{"type":"boolean"}},"required":["expectedRevision","confidenceLevel","targetAudience"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"study.results.refresh","budgetPolicy":"zero","parameterContract":"{ studyId, expectedRevision, confidenceLevel, targetAudience, retryParked?: false }; parked result reads require a human operator","exactApprovalRequired":true}}},"/api/v1/brand-lift-studies/{studyId}/settlements":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_settlements","summary":"Run brand lift studies / settlements","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"maximum":2147483647},"quoteId":{"type":"string","format":"uuid"},"kind":{"type":"string","enum":["charge","credit","final-no-charge"]},"amountMinor":{"type":"integer","minimum":-2147483647,"maximum":2147483647},"originalSettlementKey":{"anyOf":[{"type":"string","minLength":1,"maxLength":200,"pattern":"^[A-Za-z0-9][A-Za-z0-9._:/-]*$"},{"type":"null"}]},"description":{"type":"string","minLength":1,"maxLength":1000},"evidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},"final":{"type":"boolean"}},"required":["expectedRevision","quoteId","kind","amountMinor","originalSettlementKey","description","evidence","final"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/brand-lift-studies/{studyId}/tracking":{"post":{"operationId":"post_api_v1_brand_lift_studies_studyId_tracking","summary":"Run brand lift studies / tracking","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with supplier:authorize permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Brand lift studies"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"studyId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0},"tracking":{"type":"object","properties":{"providerAccountId":{"type":"string","format":"uuid"},"providerStudyId":{"type":"string","format":"uuid"},"channels":{"type":"array","items":{"type":"string","enum":["digital","linear_tv","social"]},"minItems":1,"maxItems":3},"placements":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","enum":["digital","linear_tv","social"]},"campaignLineIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":200},"minItems":1,"maxItems":100},"method":{"type":"string","enum":["provider-confirmed-s2s","provider-approved-pixel","provider-approved-data-partner","sandbox-fixture"]},"installationEvidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},"supplierAcceptanceEvidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false}},"required":["channel","campaignLineIds","method","installationEvidence","supplierAcceptanceEvidence"],"additionalProperties":false},"minItems":1,"maxItems":100},"provenance":{"type":"object","properties":{"source":{"type":"string","enum":["operator-attested","sandbox-fixture"]},"assertedBy":{"type":"string","minLength":1,"maxLength":200},"assertedAt":{"type":"string","format":"date-time"}},"required":["source","assertedBy","assertedAt"],"additionalProperties":false},"installedAt":{"type":"string","format":"date-time"},"validUntil":{"type":"string","format":"date-time"},"privacy":{"type":"object","properties":{"lawfulBasis":{"type":"string","const":"consent"},"purpose":{"type":"string","const":"brand-lift-measurement"},"noticeEvidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},"consentEvidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},"processingTermsEvidence":{"type":"object","properties":{"artifactId":{"type":"string","format":"uuid"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["artifactId","sha256"],"additionalProperties":false},"obtainedAt":{"type":"string","format":"date-time"},"expiresAt":{"type":"string","format":"date-time"},"includesMeasurementSharing":{"type":"boolean","const":true},"includesIp":{"type":"boolean"}},"required":["lawfulBasis","purpose","noticeEvidence","consentEvidence","processingTermsEvidence","obtainedAt","expiresAt","includesMeasurementSharing","includesIp"],"additionalProperties":false}},"required":["providerAccountId","providerStudyId","channels","placements","provenance","installedAt","validUntil","privacy"],"additionalProperties":false}},"required":["expectedRevision","tracking"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["supplier:authorize"]}},"/api/v1/buyer/context":{"get":{"operationId":"get_api_v1_buyer_context","summary":"Prepare evidence and next actions for an MCP media buyer","description":"Read-only, tenant-scoped guidance for briefing, creative direction, campaign review and launch assistance. References existing canonical tools and the existing human approval flow; performs no provider calls or commercial actions.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"workflow","in":"query","required":true,"schema":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"style":"form","explode":true},{"name":"campaignId","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":128},"style":"form","explode":true},{"name":"planId","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":128},"style":"form","explode":true},{"name":"personaId","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":128},"style":"form","explode":true},{"name":"creativeId","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":128},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"buyerContext":{"type":"object","properties":{"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"selected":{"type":"object","properties":{"campaign":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"name":{"type":"string"},"status":{"type":"string"},"startDate":{"type":"string"},"endDate":{"type":"string"},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"lineItemId":{"type":"string"},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string"},"status":{"type":"string"},"executionMode":{"type":"string"},"budget":{"type":"object","properties":{"amountMinor":{"type":"integer"},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["amountMinor","currency"],"additionalProperties":true}},"required":["id","lineItemId","channel","adapterKey","status","executionMode","budget"],"additionalProperties":false}}},"required":["id","planId","name","status","startDate","endDate","lines"],"additionalProperties":false},"plan":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":128},"personaId":{"anyOf":[{"type":"string","minLength":1,"maxLength":128},{"type":"null"}]},"status":{"type":"string"},"staleReason":{"type":["string","null"]},"planKind":{"type":"string"},"executionMode":{"type":"string"},"budget":{"type":"object","properties":{"amountMinor":{"type":"integer"},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["amountMinor","currency"],"additionalProperties":true},"goal":{"type":"string"},"startDate":{"type":"string"},"endDate":{"type":"string"},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]}},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string"},"budget":{"type":"object","properties":{"amountMinor":{"type":"integer"},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["amountMinor","currency"],"additionalProperties":true}},"required":["id","channel","adapterKey","budget"],"additionalProperties":false}}},"required":["id","personaId","status","staleReason","planKind","executionMode","budget","goal","startDate","endDate","channels","lines"],"additionalProperties":false},"persona":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":128},"version":{"type":"integer"},"name":{"type":"string"},"nlDescription":{"type":"string"},"compiled":{"anyOf":[{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"spec":{"anyOf":[{"type":"object","properties":{"channel":{"type":"string","const":"ctv"},"euidAudienceIds":{"type":"array","items":{"type":"string"},"default":[]},"marketplaceSegmentIds":{"type":"array","items":{"type":"string"},"default":[]},"geoCities":{"type":"array","items":{"type":"string"},"default":[]},"frequencyCapPerWeek":{"type":"integer","minimum":1},"dealIds":{"type":"array","items":{"type":"string"},"default":[]},"ageMin":{"type":"integer","minimum":16},"ageMax":{"type":"integer","maximum":99},"gender":{"type":"string","enum":["any","male","female"],"default":"any"}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"audio"},"showAllowlist":{"type":"array","items":{"type":"string"},"default":[]},"genres":{"type":"array","items":{"type":"string"},"default":[]},"publisherSegments":{"type":"array","items":{"type":"string"},"default":[]},"geoCities":{"type":"array","items":{"type":"string"},"default":[]},"dayparts":{"type":"array","items":{"type":"string","enum":["breakfast","commute-am","daytime","commute-pm","evening"]},"default":[]},"pmpDealSpecs":{"type":"array","items":{"type":"string"},"default":[]}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"tv"},"adsmartAttributes":{"type":"array","items":{"type":"string"},"default":[]},"postcodeDistricts":{"type":"array","items":{"type":"string"},"default":[]},"universalAdsAudience":{"type":"string","enum":["custom-csv","pixel-lookalike","none"],"default":"none"},"tvRegions":{"type":"array","items":{"type":"string"},"default":[]}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"cinema"},"agpPacks":{"type":"array","items":{"type":"string"},"default":[]},"venueIds":{"type":"array","items":{"type":"string"},"default":[]},"filmGenres":{"type":"array","items":{"type":"string"},"default":[]},"weeks":{"type":"integer","minimum":1,"default":2}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"dooh"},"audienceSegmentIds":{"type":"array","items":{"type":"string"},"default":[]},"venueTypes":{"type":"array","items":{"type":"string"},"default":[]},"geoPolygonRefs":{"type":"array","items":{"type":"string"},"default":[]},"dayparts":{"type":"array","items":{"type":"string"},"default":[]},"screenRankings":{"type":"array","items":{"type":"object","properties":{"screenId":{"type":"string"},"overIndex":{"type":"number"}},"required":["screenId","overIndex"],"additionalProperties":true},"default":[]}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"search"},"seedKeywords":{"type":"array","items":{"type":"string","minLength":1,"maxLength":80},"maxItems":20,"default":[]},"negativeKeywords":{"type":"array","items":{"type":"string","minLength":1,"maxLength":80},"maxItems":50,"default":[]},"geoCities":{"type":"array","items":{"type":"string"},"default":[]},"language":{"type":"string","default":"en"},"matchTypes":{"type":"array","items":{"type":"string","enum":["exact","phrase","broad"]},"minItems":1,"default":["exact","phrase"]},"network":{"type":"string","enum":["search-only","search-partners"],"default":"search-only"}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"social"},"interestTerms":{"type":"array","items":{"type":"string","minLength":1},"maxItems":50,"default":[]},"geoCities":{"type":"array","items":{"type":"string"},"default":[]},"ageMin":{"type":"integer","minimum":16,"maximum":99},"ageMax":{"type":"integer","minimum":16,"maximum":99},"gender":{"type":"string","enum":["any","male","female"],"default":"any"},"placements":{"type":"array","items":{"type":"string","enum":["feed","stories","reels","search","video"]},"default":["feed","stories","reels"]},"optimizationGoal":{"type":"string","enum":["unset","reach","traffic","conversions"],"default":"unset"}},"required":["channel"],"additionalProperties":true}]},"fidelity":{"type":"object","properties":{"score":{"type":"number","minimum":0,"maximum":100},"grade":{"type":"string","enum":["person","household","content","venue","geo-cohort"]},"rationale":{"type":"string"}},"required":["score","grade","rationale"],"additionalProperties":true},"lawfulBasisManifest":{"type":"array","items":{"type":"object","properties":{"element":{"type":"string"},"basis":{"type":"string","enum":["consent-chained","legitimate-interest","outside-scope"]},"source":{"type":"string"},"note":{"type":"string"}},"required":["element","basis","source"],"additionalProperties":true}},"warnings":{"type":"array","items":{"type":"string"},"default":[]},"coverage":{"type":"object","properties":{"requested":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string","enum":["country","city","postcode","tv-region","age","gender","income","industry","seniority","company-size","interest","intent","audience-exclusion","search-negative","unresolved"]},"value":{"type":"string"}},"required":["field","value"],"additionalProperties":true}},"supported":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string","enum":["country","city","postcode","tv-region","age","gender","income","industry","seniority","company-size","interest","intent","audience-exclusion","search-negative","unresolved"]},"value":{"type":"string"},"representation":{"type":"string"},"evidence":{"type":"string","enum":["semantic","modeled","provider-catalogue"]},"sourceIds":{"type":"array","items":{"type":"string"}}},"required":["field","value","representation","evidence","sourceIds"],"additionalProperties":true}},"unsupported":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string","enum":["country","city","postcode","tv-region","age","gender","income","industry","seniority","company-size","interest","intent","audience-exclusion","search-negative","unresolved"]},"value":{"type":"string"},"reason":{"type":"string"}},"required":["field","value","reason"],"additionalProperties":true}},"requiresProviderValidation":{"type":"boolean"}},"required":["requested","supported","unsupported","requiresProviderValidation"],"additionalProperties":true}},"required":["channel","spec","fidelity","lawfulBasisManifest"],"additionalProperties":true}},{"type":"null"}]}},"required":["id","version","name","nlDescription","compiled"],"additionalProperties":false},"creative":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":128},"revision":{"type":"integer"},"name":{"type":"string"},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"format":{"type":"string"},"copyText":{"type":"string"},"hasVerifiedAssetBytes":{"type":"boolean"},"hasPrecheck":{"type":"boolean"}},"required":["id","revision","name","channel","format","copyText","hasVerifiedAssetBytes","hasPrecheck"],"additionalProperties":false}},"additionalProperties":false},"instructions":{"type":"array","items":{"type":"string"}},"evidenceRequests":{"type":"array","items":{"type":"object","properties":{"tool":{"type":"string","minLength":1},"arguments":{"type":"object","additionalProperties":{}},"reason":{"type":"string","minLength":1}},"required":["tool","arguments","reason"],"additionalProperties":false}},"nextActions":{"type":"array","items":{"type":"object","properties":{"tool":{"type":"string","minLength":1},"arguments":{"type":"object","additionalProperties":{}},"reason":{"type":"string","minLength":1},"requiresInputs":{"type":"array","items":{"type":"string"}}},"required":["tool","arguments","reason","requiresInputs"],"additionalProperties":false}},"missingInputs":{"type":"array","items":{"type":"string"}},"approvalPolicy":{"type":"object","properties":{"execution":{"type":"string","const":"existing-agent-approval-flow"},"humanApprovalRequired":{"type":"boolean","const":true},"instructions":{"type":"array","items":{"type":"string"}}},"required":["execution","humanApprovalRequired","instructions"],"additionalProperties":false}},"required":["workflow","selected","instructions","evidenceRequests","nextActions","missingInputs","approvalPolicy"],"additionalProperties":false}},"required":["buyerContext"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/buyer/sessions":{"get":{"operationId":"get_api_v1_buyer_sessions","summary":"List this agent client’s buyer conversations","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":20},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"sessions":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"context":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"personaId":{"type":"string","minLength":1,"maxLength":128},"creativeId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false},"revision":{"type":"integer","exclusiveMinimum":0},"activeTurnId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"status":{"type":"string","enum":["running","idle"]},"productScope":{"type":"object","properties":{"product":{"type":"string","enum":["adbuymcp","doohmcp","ctvmcp"]},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1,"maxItems":7}},"required":["product","channels"],"additionalProperties":false},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["id","workflow","context","revision","activeTurnId","status","productScope","references","createdAt","updatedAt"],"additionalProperties":false}}},"required":["sessions"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_buyer_sessions","summary":"Create an agent-owned buyer conversation","description":"Persists a workflow and scoped resource references for the authenticated agent client. This grants no commercial authority and starts no provider operation.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"context":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"personaId":{"type":"string","minLength":1,"maxLength":128},"creativeId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false,"default":{}}},"required":["workflow"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"session":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"context":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"personaId":{"type":"string","minLength":1,"maxLength":128},"creativeId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false},"revision":{"type":"integer","exclusiveMinimum":0},"activeTurnId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"status":{"type":"string","enum":["running","idle"]},"messages":{"type":"array","items":{"type":"object","properties":{"role":{"type":"string","enum":["user","assistant"]},"message":{"type":"string"},"requestId":{"type":"string","format":"uuid"}},"required":["role","message","requestId"],"additionalProperties":false},"maxItems":40},"history":{"type":"array","items":{"type":"object","additionalProperties":{}},"maxItems":128},"productScope":{"type":"object","properties":{"product":{"type":"string","enum":["adbuymcp","doohmcp","ctvmcp"]},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1,"maxItems":7}},"required":["product","channels"],"additionalProperties":false},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["id","workflow","context","revision","activeTurnId","status","messages","history","productScope","references","createdAt","updatedAt"],"additionalProperties":false}},"required":["session"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/buyer/sessions/{id}":{"get":{"operationId":"get_api_v1_buyer_sessions_id","summary":"Read the durable buyer session and current turn fence","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"session":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"context":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"personaId":{"type":"string","minLength":1,"maxLength":128},"creativeId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false},"revision":{"type":"integer","exclusiveMinimum":0},"activeTurnId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"status":{"type":"string","enum":["running","idle"]},"messages":{"type":"array","items":{"type":"object","properties":{"role":{"type":"string","enum":["user","assistant"]},"message":{"type":"string"},"requestId":{"type":"string","format":"uuid"}},"required":["role","message","requestId"],"additionalProperties":false},"maxItems":40},"history":{"type":"array","items":{"type":"object","additionalProperties":{}},"maxItems":128},"productScope":{"type":"object","properties":{"product":{"type":"string","enum":["adbuymcp","doohmcp","ctvmcp"]},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1,"maxItems":7}},"required":["product","channels"],"additionalProperties":false},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["id","workflow","context","revision","activeTurnId","status","messages","history","productScope","references","createdAt","updatedAt"],"additionalProperties":false}},"required":["session"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/buyer/sessions/{id}/cancel":{"post":{"operationId":"post_api_v1_buyer_sessions_id_cancel","summary":"Cancel buyer reasoning and invalidate stale tool dispatch","description":"Advances the session revision and marks its running turn cancelled. Provider operations already dispatched remain governed by their durable attempt and human reconciliation records.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0}},"required":["expectedRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"session":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"context":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"personaId":{"type":"string","minLength":1,"maxLength":128},"creativeId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false},"revision":{"type":"integer","exclusiveMinimum":0},"activeTurnId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"status":{"type":"string","enum":["running","idle"]},"messages":{"type":"array","items":{"type":"object","properties":{"role":{"type":"string","enum":["user","assistant"]},"message":{"type":"string"},"requestId":{"type":"string","format":"uuid"}},"required":["role","message","requestId"],"additionalProperties":false},"maxItems":40},"history":{"type":"array","items":{"type":"object","additionalProperties":{}},"maxItems":128},"productScope":{"type":"object","properties":{"product":{"type":"string","enum":["adbuymcp","doohmcp","ctvmcp"]},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1,"maxItems":7}},"required":["product","channels"],"additionalProperties":false},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["id","workflow","context","revision","activeTurnId","status","messages","history","productScope","references","createdAt","updatedAt"],"additionalProperties":false},"cancelledTurnId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"note":{"type":"string"}},"required":["session","cancelledTurnId","note"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/buyer/sessions/{id}/erase":{"post":{"operationId":"post_api_v1_buyer_sessions_id_erase","summary":"Erase this conversation’s text and resource links","description":"Requires an idle conversation at its current revision. Erases conversation content while retaining request replay commitments, voice-attempt metadata and independent campaign, approval and provider audit evidence.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0}},"required":["expectedRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"session":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"context":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"personaId":{"type":"string","minLength":1,"maxLength":128},"creativeId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false},"revision":{"type":"integer","exclusiveMinimum":0},"activeTurnId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"status":{"type":"string","enum":["running","idle"]},"messages":{"type":"array","items":{"type":"object","properties":{"role":{"type":"string","enum":["user","assistant"]},"message":{"type":"string"},"requestId":{"type":"string","format":"uuid"}},"required":["role","message","requestId"],"additionalProperties":false},"maxItems":40},"history":{"type":"array","items":{"type":"object","additionalProperties":{}},"maxItems":128},"productScope":{"type":"object","properties":{"product":{"type":"string","enum":["adbuymcp","doohmcp","ctvmcp"]},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1,"maxItems":7}},"required":["product","channels"],"additionalProperties":false},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["id","workflow","context","revision","activeTurnId","status","messages","history","productScope","references","createdAt","updatedAt"],"additionalProperties":false}},"required":["session"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/buyer/sessions/{id}/turns":{"post":{"operationId":"post_api_v1_buyer_sessions_id_turns","summary":"Claim one idempotent buyer turn","description":"Claims one active reasoning turn using an expected revision and request UUID. Exact retries return the original turn and must never execute it again. A stale or competing request fails closed.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"requestId":{"type":"string","format":"uuid"},"expectedRevision":{"type":"integer","exclusiveMinimum":0},"message":{"type":"string","minLength":1,"maxLength":16000}},"required":["requestId","expectedRevision","message"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"session":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"context":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"personaId":{"type":"string","minLength":1,"maxLength":128},"creativeId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false},"revision":{"type":"integer","exclusiveMinimum":0},"activeTurnId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"status":{"type":"string","enum":["running","idle"]},"messages":{"type":"array","items":{"type":"object","properties":{"role":{"type":"string","enum":["user","assistant"]},"message":{"type":"string"},"requestId":{"type":"string","format":"uuid"}},"required":["role","message","requestId"],"additionalProperties":false},"maxItems":40},"history":{"type":"array","items":{"type":"object","additionalProperties":{}},"maxItems":128},"productScope":{"type":"object","properties":{"product":{"type":"string","enum":["adbuymcp","doohmcp","ctvmcp"]},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1,"maxItems":7}},"required":["product","channels"],"additionalProperties":false},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["id","workflow","context","revision","activeTurnId","status","messages","history","productScope","references","createdAt","updatedAt"],"additionalProperties":false},"turn":{"type":"object","properties":{"sessionId":{"type":"string","format":"uuid"},"requestId":{"type":"string","format":"uuid"},"inputRevision":{"type":"integer","exclusiveMinimum":0},"revision":{"type":"integer","exclusiveMinimum":0},"status":{"type":"string","enum":["running","completed","failed","cancelled"]},"message":{"type":"string"},"responseMessage":{"type":["string","null"]},"toolCalls":{"type":"array","items":{"type":"object","properties":{"tool":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,119}$"},"status":{"type":"string","enum":["completed","failed"]}},"required":["tool","status"],"additionalProperties":false},"maxItems":64},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["sessionId","requestId","inputRevision","revision","status","message","responseMessage","toolCalls","references","createdAt","updatedAt"],"additionalProperties":false},"replay":{"type":"boolean"}},"required":["session","turn","replay"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/buyer/sessions/{id}/turns/{requestId}/complete":{"post":{"operationId":"post_api_v1_buyer_sessions_id_turns_requestId_complete","summary":"Settle the current buyer reasoning turn","description":"Stores bounded conversation state only if the turn revision remains active. Cancellation prevents late completion. Completion does not settle provider attempts or approve commercial actions.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"requestId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0},"status":{"type":"string","enum":["completed","failed"]},"message":{"type":"string","minLength":1,"maxLength":16000},"history":{"type":"array","items":{"type":"object","additionalProperties":{}},"maxItems":128},"toolCalls":{"type":"array","items":{"type":"object","properties":{"tool":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,119}$"},"status":{"type":"string","enum":["completed","failed"]}},"required":["tool","status"],"additionalProperties":false},"maxItems":64,"default":[]},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32,"default":[]}},"required":["expectedRevision","status","message"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"session":{"type":"object","properties":{"id":{"type":"string","format":"uuid"},"workflow":{"type":"string","enum":["brief_to_plan","creative_direction","campaign_review","launch_assistance"]},"context":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1,"maxLength":128},"planId":{"type":"string","minLength":1,"maxLength":128},"personaId":{"type":"string","minLength":1,"maxLength":128},"creativeId":{"type":"string","minLength":1,"maxLength":128}},"additionalProperties":false},"revision":{"type":"integer","exclusiveMinimum":0},"activeTurnId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"status":{"type":"string","enum":["running","idle"]},"messages":{"type":"array","items":{"type":"object","properties":{"role":{"type":"string","enum":["user","assistant"]},"message":{"type":"string"},"requestId":{"type":"string","format":"uuid"}},"required":["role","message","requestId"],"additionalProperties":false},"maxItems":40},"history":{"type":"array","items":{"type":"object","additionalProperties":{}},"maxItems":128},"productScope":{"type":"object","properties":{"product":{"type":"string","enum":["adbuymcp","doohmcp","ctvmcp"]},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1,"maxItems":7}},"required":["product","channels"],"additionalProperties":false},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["id","workflow","context","revision","activeTurnId","status","messages","history","productScope","references","createdAt","updatedAt"],"additionalProperties":false},"turn":{"type":"object","properties":{"sessionId":{"type":"string","format":"uuid"},"requestId":{"type":"string","format":"uuid"},"inputRevision":{"type":"integer","exclusiveMinimum":0},"revision":{"type":"integer","exclusiveMinimum":0},"status":{"type":"string","enum":["running","completed","failed","cancelled"]},"message":{"type":"string"},"responseMessage":{"type":["string","null"]},"toolCalls":{"type":"array","items":{"type":"object","properties":{"tool":{"type":"string","pattern":"^[a-z][a-z0-9_]{0,119}$"},"status":{"type":"string","enum":["completed","failed"]}},"required":["tool","status"],"additionalProperties":false},"maxItems":64},"references":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string","enum":["persona","plan","campaign","creative","asset","mission","run"]},"id":{"type":"string","minLength":1,"maxLength":128}},"required":["kind","id"],"additionalProperties":false},"maxItems":32},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["sessionId","requestId","inputRevision","revision","status","message","responseMessage","toolCalls","references","createdAt","updatedAt"],"additionalProperties":false},"replay":{"type":"boolean"}},"required":["session","turn","replay"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/buyer/sessions/{id}/voice-attempts":{"post":{"operationId":"post_api_v1_buyer_sessions_id_voice_attempts","summary":"Record an idempotent outbound voice bootstrap attempt","description":"Commits a digest before contacting the voice provider. Exact retries return the existing attempt and must not call the provider again, including after uncertain outcomes. SDP and credentials are never stored.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"requestId":{"type":"string","format":"uuid"},"sdpDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["requestId","sdpDigest"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"attempt":{"type":"object","properties":{"sessionId":{"type":"string","format":"uuid"},"requestId":{"type":"string","format":"uuid"},"sdpDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"status":{"type":"string","enum":["running","succeeded","failed","unknown"]},"externalSessionId":{"type":["string","null"]},"detail":{"type":["string","null"]},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["sessionId","requestId","sdpDigest","status","externalSessionId","detail","createdAt","updatedAt"],"additionalProperties":false},"replay":{"type":"boolean"}},"required":["attempt","replay"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/buyer/sessions/{id}/voice-attempts/{requestId}/complete":{"post":{"operationId":"post_api_v1_buyer_sessions_id_voice_attempts_requestId_complete","summary":"Record the observed outcome of a voice bootstrap","description":"Settles the attempt without storing provider credentials or SDP. An uncertain response is recorded unknown, never assumed failed or retried. Exact completion replay is read-only.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Buyer"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","format":"uuid"}},{"name":"requestId","in":"path","required":true,"schema":{"type":"string","format":"uuid"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["succeeded","failed","unknown"]},"externalSessionId":{"type":"string","pattern":"^[A-Za-z0-9_-]{1,200}$"},"detail":{"type":"string","minLength":1,"maxLength":16000}},"required":["status"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"attempt":{"type":"object","properties":{"sessionId":{"type":"string","format":"uuid"},"requestId":{"type":"string","format":"uuid"},"sdpDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"status":{"type":"string","enum":["running","succeeded","failed","unknown"]},"externalSessionId":{"type":["string","null"]},"detail":{"type":["string","null"]},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"}},"required":["sessionId","requestId","sdpDigest","status","externalSessionId","detail","createdAt","updatedAt"],"additionalProperties":false},"replay":{"type":"boolean"}},"required":["attempt","replay"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns":{"get":{"operationId":"get_api_v1_campaigns","summary":"Read campaigns","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"campaigns":{"type":"array","items":{"type":"object","properties":{},"additionalProperties":true}}},"required":["campaigns"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}":{"get":{"operationId":"get_api_v1_campaigns_id","summary":"Read campaigns","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"campaign":{"type":"object","properties":{},"additionalProperties":true}},"required":["campaign"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/attempts":{"get":{"operationId":"get_api_v1_campaigns_id_attempts","summary":"Inspect durable provider attempts","description":"Inspect committed outbound attempt status before retrying an uncertain operation. In-flight live attempts left by a crash require human reconciliation.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/attempts/{attemptId}/resolve":{"post":{"operationId":"post_api_v1_campaigns_id_attempts_attemptId_resolve","summary":"Resolve an uncertain provider attempt","description":"A human operator records what the supplier actually did, with evidence. Resolution cannot bypass current creative verification, supplier configuration or financial reconciliation gates.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"attemptId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"outcome":{"type":"string","enum":["applied","not-applied"]},"externalRef":{"type":"string","minLength":1},"stagedManifest":{"type":"object","properties":{"campaign":{"type":"string","minLength":1},"providerAccountRef":{"type":"string","minLength":1},"providerAccountRefAuthority":{"type":"string","enum":["provider-validated","operator-attested"]},"budget":{"type":"string","minLength":1},"adGroups":{"type":"array","items":{"type":"string","minLength":1},"default":[]},"adSets":{"type":"array","items":{"type":"string","minLength":1},"default":[]},"ads":{"type":"array","items":{"type":"string","minLength":1},"default":[]},"keywords":{"type":"array","items":{"type":"string","minLength":1},"default":[]},"negativeKeywords":{"type":"array","items":{"type":"string","minLength":1},"default":[]},"targetingCriteria":{"type":"array","items":{"type":"string","minLength":1},"default":[]},"configurationDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"conversionGoalBinding":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":200},"revision":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"channelCampaignId":{"type":"string","minLength":1,"maxLength":200},"connectionConfigurationRevision":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"approvedObjectiveDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"providerAccountRef":{"type":"string","minLength":1,"maxLength":500},"goal":{"type":"object","properties":{"adapterKey":{"type":"string","enum":["google-ads","microsoft-ads","tiktok-ads","meta-ads"]},"providerAccountRef":{"type":"string","minLength":1,"maxLength":500},"goalRef":{"type":"string","minLength":1,"maxLength":500},"name":{"type":"string","minLength":1,"maxLength":2000},"definition":{"anyOf":[{"type":"object","properties":{"provider":{"type":"string","const":"google-ads"},"conversionCustomerRef":{"type":"string","minLength":1,"maxLength":500},"customGoalRef":{"type":"string","minLength":1,"maxLength":500},"customGoalName":{"type":"string","maxLength":2000},"customGoalStatus":{"type":"string","maxLength":2000},"conversionActionRefs":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"actions":{"type":"array","items":{"type":"object","properties":{"resourceName":{"type":"string","minLength":1,"maxLength":500},"ownerCustomer":{"type":"string","minLength":1,"maxLength":500},"name":{"type":"string","maxLength":2000},"status":{"type":"string","maxLength":2000},"type":{"type":"string","maxLength":2000},"origin":{"type":"string","maxLength":2000},"category":{"type":"string","maxLength":2000},"countingType":{"type":"string","maxLength":2000},"primaryForGoal":{"type":"boolean"},"clickThroughLookbackWindowDays":{"type":"integer","minimum":0},"viewThroughLookbackWindowDays":{"type":"integer","minimum":0},"attributionModel":{"type":"string","maxLength":2000},"valueSettings":{"type":"object","properties":{"alwaysUseDefaultValue":{"type":"boolean"},"defaultCurrencyCode":{"type":"string","maxLength":2000},"defaultValue":{"type":"string","pattern":"^-?\\d+(?:\\.\\d+)?(?:[eE][+-]?\\d+)?$"}},"required":["alwaysUseDefaultValue","defaultCurrencyCode","defaultValue"],"additionalProperties":false}},"required":["resourceName","ownerCustomer","name","status","type","origin","category","countingType","primaryForGoal","clickThroughLookbackWindowDays","viewThroughLookbackWindowDays","attributionModel","valueSettings"],"additionalProperties":false},"maxItems":100}},"required":["provider","conversionCustomerRef","customGoalRef","customGoalName","customGoalStatus","conversionActionRefs","actions"],"additionalProperties":false},{"type":"object","properties":{"provider":{"type":"string","const":"microsoft-ads"},"goalId":{"type":"string","pattern":"^\\d+$"},"type":{"type":"string","enum":["Url","Event"]},"name":{"type":"string","maxLength":2000},"status":{"type":"string","maxLength":2000},"scope":{"type":"string","maxLength":2000},"tagId":{"type":"string","pattern":"^\\d+$"},"countType":{"type":"string","maxLength":2000},"excludeFromBidding":{"type":"boolean"},"goalCategory":{"type":"string","maxLength":2000},"conversionWindowInMinutes":{"type":"integer","minimum":0},"viewThroughConversionWindowInMinutes":{"type":"integer","minimum":0},"attributionModelType":{"type":"string","maxLength":2000},"isEnhancedConversionsEnabled":{"type":"boolean"},"isAutoGoal":{"type":"boolean"},"accountTracking":{"type":"object","properties":{"msclkidAutoTaggingEnabled":{"type":"boolean"},"includeViewThroughConversions":{"type":"boolean"},"includeAutoBiddingViewThroughConversions":{"type":"boolean"}},"required":["msclkidAutoTaggingEnabled","includeViewThroughConversions","includeAutoBiddingViewThroughConversions"],"additionalProperties":false},"revenue":{"type":"object","properties":{"type":{"type":"string","maxLength":2000},"currencyCode":{"type":"string","maxLength":2000},"value":{"type":"string","maxLength":2000}},"required":["type","currencyCode","value"],"additionalProperties":false},"url":{"anyOf":[{"type":"object","properties":{"expression":{"type":"string","maxLength":2000},"operator":{"type":"string","maxLength":2000}},"required":["expression","operator"],"additionalProperties":false},{"type":"null"}]},"event":{"anyOf":[{"type":"object","properties":{"actionExpression":{"type":"string","maxLength":2000},"actionOperator":{"type":"string","maxLength":2000},"categoryExpression":{"type":"string","maxLength":2000},"categoryOperator":{"type":"string","maxLength":2000},"labelExpression":{"type":"string","maxLength":2000},"labelOperator":{"type":"string","maxLength":2000},"value":{"type":"string","maxLength":2000},"valueOperator":{"type":"string","maxLength":2000}},"required":["actionExpression","actionOperator","categoryExpression","categoryOperator","labelExpression","labelOperator","value","valueOperator"],"additionalProperties":false},{"type":"null"}]}},"required":["provider","goalId","type","name","status","scope","tagId","countType","excludeFromBidding","goalCategory","conversionWindowInMinutes","viewThroughConversionWindowInMinutes","attributionModelType","isEnhancedConversionsEnabled","isAutoGoal","accountTracking","revenue","url","event"],"additionalProperties":false},{"type":"object","properties":{"provider":{"type":"string","const":"tiktok-ads"},"pixel":{"type":"object","properties":{"id":{"type":"string","pattern":"^\\d+$"},"code":{"type":"string","minLength":1,"maxLength":500},"name":{"type":"string","maxLength":2000},"setupMode":{"type":"string","enum":["STANDARD","DEVELOPER"]},"ownership":{"type":"object","properties":{"relation":{"anyOf":[{"type":"string","enum":["TRANSFERRED","SHARED","UNBOUND"]},{"type":"null"}]},"ownedByAdvertiser":{"type":"boolean"},"ownerBusinessCenterId":{"anyOf":[{"type":"string","pattern":"^\\d+$"},{"type":"null"}]}},"required":["relation","ownedByAdvertiser","ownerBusinessCenterId"],"additionalProperties":false},"manualMatching":{"type":"object","properties":{"email":{"type":["boolean","null"]},"phoneNumber":{"type":["boolean","null"]}},"required":["email","phoneNumber"],"additionalProperties":false},"automaticMatching":{"type":"object","properties":{"email":{"type":["boolean","null"]},"phoneNumber":{"type":["boolean","null"]},"name":{"type":["boolean","null"]},"address":{"type":["boolean","null"]},"externalId":{"type":["boolean","null"]}},"required":["email","phoneNumber","name","address","externalId"],"additionalProperties":false},"firstPartyCookies":{"type":["boolean","null"]},"expandedDataSharing":{"type":["boolean","null"]}},"required":["id","code","name","setupMode","ownership","manualMatching","automaticMatching","firstPartyCookies","expandedDataSharing"],"additionalProperties":false},"optimizationEvent":{"type":"string","maxLength":2000},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^\\d+$"},"code":{"type":"string","minLength":1,"maxLength":500},"name":{"type":"string","maxLength":2000},"eventType":{"type":"string","maxLength":2000},"optimizationEvent":{"type":"string","maxLength":2000},"deprecated":{"type":"boolean"},"statisticType":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"currency":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"currencyValue":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"rules":{"type":"array","items":{"type":"object","properties":{"operator":{"type":"string","maxLength":2000},"trigger":{"type":"string","maxLength":2000},"variable":{"type":"string","maxLength":2000},"value":{"type":"string","maxLength":2000}},"required":["operator","trigger","variable","value"],"additionalProperties":false},"maxItems":100}},"required":["id","code","name","eventType","optimizationEvent","deprecated","statisticType","currency","currencyValue","rules"],"additionalProperties":false},"maxItems":1000},"customConversion":{"anyOf":[{"type":"object","properties":{"id":{"type":"string","pattern":"^\\d+$"},"name":{"type":"string","maxLength":2000},"description":{"type":"string","maxLength":2000},"eventSourceType":{"type":"string","const":"PIXEL"},"eventSourceId":{"type":"string","pattern":"^\\d+$"},"optimizationEvent":{"type":"string","maxLength":2000},"rules":{"type":"array","items":{"type":"object","properties":{"parameter":{"type":"string","maxLength":2000},"operator":{"type":"string","maxLength":2000},"values":{"anyOf":[{"type":"array","items":{"type":"string","maxLength":100},"minItems":1,"maxItems":100},{"type":"number","minimum":0,"maximum":1000000000}]}},"required":["parameter","operator","values"],"additionalProperties":false},"minItems":1,"maxItems":100},"createdAt":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"updatedAt":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]}},"required":["id","name","description","eventSourceType","eventSourceId","optimizationEvent","rules","createdAt","updatedAt"],"additionalProperties":false},{"type":"null"}]}},"required":["provider","pixel","optimizationEvent","events","customConversion"],"additionalProperties":false},{"type":"object","properties":{"provider":{"type":"string","const":"meta-ads"},"accountBusinessId":{"anyOf":[{"type":"string","pattern":"^\\d+$"},{"type":"null"}]},"pixel":{"anyOf":[{"type":"object","properties":{"id":{"type":"string","pattern":"^\\d+$"},"name":{"type":"string","maxLength":2000},"ownerAdAccountId":{"anyOf":[{"type":"string","pattern":"^\\d+$"},{"type":"null"}]},"ownerBusinessId":{"anyOf":[{"type":"string","pattern":"^\\d+$"},{"type":"null"}]},"ownership":{"type":"string","enum":["ad-account","business","shared","unknown"]},"automaticMatchingFields":{"anyOf":[{"type":"array","items":{"type":"string","maxLength":2000},"maxItems":100},{"type":"null"}]},"automaticMatchingEnabled":{"type":["boolean","null"]},"firstPartyCookieStatus":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"dataUseSetting":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"unavailable":{"type":["boolean","null"]},"restrictedToLift":{"type":["boolean","null"]},"restrictedToMta":{"type":["boolean","null"]},"containsCrmSource":{"type":["boolean","null"]},"consolidatedContainer":{"type":["boolean","null"]},"configuration":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"autoAssignToAccounts":{"type":["boolean","null"]}},"required":["id","name","ownerAdAccountId","ownerBusinessId","ownership","automaticMatchingFields","automaticMatchingEnabled","firstPartyCookieStatus","dataUseSetting","unavailable","restrictedToLift","restrictedToMta","containsCrmSource","consolidatedContainer","configuration","autoAssignToAccounts"],"additionalProperties":false},{"type":"null"}]},"customConversion":{"type":"object","properties":{"id":{"type":"string","pattern":"^\\d+$"},"accountId":{"type":"string","pattern":"^\\d+$"},"businessId":{"anyOf":[{"type":"string","pattern":"^\\d+$"},{"type":"null"}]},"name":{"type":"string","maxLength":2000},"description":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"pixelId":{"anyOf":[{"type":"string","pattern":"^\\d+$"},{"type":"null"}]},"eventSourceId":{"anyOf":[{"type":"string","pattern":"^\\d+$"},{"type":"null"}]},"eventSourceType":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"actionSourceType":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"dataSources":{"anyOf":[{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","pattern":"^\\d+$"},"name":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"sourceType":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]}},"required":["id","name","sourceType"],"additionalProperties":false},"maxItems":100},{"type":"null"}]},"eventCategory":{"type":"string","maxLength":2000},"rule":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"advancedRule":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"aggregationRule":{"anyOf":[{"type":"string","maxLength":50000},{"type":"null"}]},"retentionDays":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]},"defaultConversionValue":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"createdAt":{"anyOf":[{"type":"string","maxLength":2000},{"type":"null"}]},"archived":{"type":["boolean","null"]},"unavailable":{"type":["boolean","null"]},"offlineDataSetId":{"anyOf":[{"type":"string","pattern":"^\\d+$"},{"type":"null"}]}},"required":["id","accountId","businessId","name","description","pixelId","eventSourceId","eventSourceType","actionSourceType","dataSources","eventCategory","rule","advancedRule","aggregationRule","retentionDays","defaultConversionValue","createdAt","archived","unavailable","offlineDataSetId"],"additionalProperties":false}},"required":["provider","accountBusinessId","pixel","customConversion"],"additionalProperties":false}]},"definitionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"availability":{"type":"string","enum":["available","unavailable"]},"blockers":{"type":"array","items":{"type":"string","minLength":1},"maxItems":100},"activity":{"type":"object","properties":{"status":{"type":"string","enum":["unknown","active","inactive"]},"detail":{"type":"string","minLength":1}},"required":["status","detail"],"additionalProperties":false},"evidenceSource":{"type":"string","enum":["provider-read","sandbox"]}},"required":["adapterKey","providerAccountRef","goalRef","name","definition","definitionDigest","availability","blockers","activity","evidenceSource"],"additionalProperties":false},"observedAt":{"type":"string","format":"date-time"},"evidenceSource":{"type":"string","enum":["provider-read","sandbox"]},"tiktokSettings":{"type":"object","properties":{"clickAttributionWindow":{"type":"string","enum":["ONE_DAY","SEVEN_DAYS","FOURTEEN_DAYS","TWENTY_EIGHT_DAYS"]},"viewAttributionWindow":{"type":"string","enum":["OFF","ONE_DAY","SEVEN_DAYS"]},"attributionEventCount":{"type":"string","enum":["ONCE","EVERY"]}},"required":["clickAttributionWindow","viewAttributionWindow","attributionEventCount"],"additionalProperties":false},"metaSettings":{"type":"object","properties":{"clickAttributionWindow":{"type":"string","enum":["ONE_DAY","SEVEN_DAYS"]},"viewAttributionWindow":{"type":"string","enum":["OFF","ONE_DAY"]},"attributionCountType":{"type":"string","enum":["ALL_CONVERSIONS","FIRST_CONVERSION"]}},"required":["clickAttributionWindow","viewAttributionWindow","attributionCountType"],"additionalProperties":false}},"required":["id","revision","channelCampaignId","connectionConfigurationRevision","approvedObjectiveDigest","providerAccountRef","goal","observedAt","evidenceSource"],"additionalProperties":false}},"required":["campaign"],"additionalProperties":false},"creativeRefs":{"type":"array","items":{"type":"object","properties":{"creativeId":{"type":"string","minLength":1},"externalCreativeRef":{"type":"string","minLength":1}},"required":["creativeId","externalCreativeRef"],"additionalProperties":false},"minItems":1,"maxItems":100},"note":{"type":"string","maxLength":500}},"required":["outcome"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/campaigns/{id}/bookings":{"get":{"operationId":"get_api_v1_campaigns_id_bookings","summary":"Read or request managed supplier bookings","description":"Managed bookings bind the exact campaign snapshot and approved creative bytes. A request reserves funds and enters the operator queue; only attributed supplier evidence can confirm activation or stopping.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_campaigns_id_bookings","summary":"Read or request managed supplier bookings","description":"Managed bookings bind the exact campaign snapshot and approved creative bytes. A request reserves funds and enters the operator queue; only attributed supplier evidence can confirm activation or stopping.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: campaign.booking.request. { campaignId, idempotencyKey, expectedSnapshotDigest, approvalConfirmed: true } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"idempotencyKey":{"type":"string","minLength":8,"maxLength":128},"expectedSnapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvalConfirmed":{"type":"boolean","const":true}},"required":["idempotencyKey","expectedSnapshotDigest","approvalConfirmed"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"body-key","bodyField":"idempotencyKey","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"campaign.booking.request","budgetPolicy":"campaign-commitment","parameterContract":"{ campaignId, idempotencyKey, expectedSnapshotDigest, approvalConfirmed: true }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/brand-lift-studies":{"get":{"operationId":"get_api_v1_campaigns_id_brand_lift_studies","summary":"Read campaigns / brand lift studies","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"cursor","in":"query","required":false,"schema":{"type":"string","format":"uuid"},"style":"form","explode":true},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","exclusiveMinimum":0,"maximum":100},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_campaigns_id_brand_lift_studies","summary":"Run campaigns / brand lift studies","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: study.create. { campaignId, mode, spec, retainResultsUntil } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"mode":{"type":"string","enum":["sandbox","live"]},"spec":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":300},"advertiserName":{"type":"string","minLength":1,"maxLength":300},"startDate":{"type":"string","format":"date-time"},"endDate":{"type":"string","format":"date-time"},"countryLanguageId":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"industryId":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"channels":{"type":"array","items":{"type":"string","enum":["digital","linear_tv","social"]},"minItems":1,"maxItems":3},"expectedImpressionsCount":{"type":"object","properties":{"digital":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"linear_tv":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"social":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991}},"additionalProperties":false},"dataPartners":{"type":"array","items":{"type":"string","minLength":1,"maxLength":100},"maxItems":20},"templateSelections":{"type":"array","items":{"type":"object","properties":{"usage":{"type":"string","enum":["lift","baseline"]},"questionName":{"type":"string","minLength":1,"maxLength":300},"kpiType":{"type":"string","minLength":1,"maxLength":100},"definitionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"order":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"fieldValues":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":100},"value":{"type":"string","minLength":1,"maxLength":500}},"required":["name","value"],"additionalProperties":false},"maxItems":20}},"required":["usage","questionName","kpiType","definitionDigest","order","fieldValues"],"additionalProperties":false},"minItems":2,"maxItems":55},"brand":{"type":"string","minLength":1,"maxLength":300},"competitors":{"type":"array","items":{"type":"string","minLength":1,"maxLength":300},"minItems":2,"maxItems":10},"allowIp":{"type":"boolean"}},"required":["name","advertiserName","startDate","endDate","countryLanguageId","industryId","channels","expectedImpressionsCount","dataPartners","templateSelections","brand","competitors","allowIp"],"additionalProperties":false},"retainResultsUntil":{"type":"string","format":"date-time"}},"required":["mode","spec","retainResultsUntil"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"study.create","budgetPolicy":"zero","parameterContract":"{ campaignId, mode, spec, retainResultsUntil }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/brand-lift-study-catalogs":{"get":{"operationId":"get_api_v1_campaigns_id_brand_lift_study_catalogs","summary":"Read campaigns / brand lift study catalogs","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"mode","in":"query","required":true,"schema":{"type":"string","enum":["sandbox","live"]},"style":"form","explode":true},{"name":"countryLanguageId","in":"query","required":false,"schema":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"style":"form","explode":true},{"name":"industryId","in":"query","required":false,"schema":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"style":"form","explode":true},{"name":"page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":10000,"default":1},"style":"form","explode":true},{"name":"pageSize","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":100},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/creatives":{"patch":{"operationId":"patch_api_v1_campaigns_id_creatives","summary":"Update campaigns / creatives","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: campaign.creatives.update. { campaignId, creativeIds } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"creativeIds":{"type":"array","items":{"type":"string"},"maxItems":100}},"required":["creativeIds"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"campaign.creatives.update","budgetPolicy":"zero","parameterContract":"{ campaignId, creativeIds }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/dead-letters":{"get":{"operationId":"get_api_v1_campaigns_id_dead_letters","summary":"Read campaigns / dead letters","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/dead-letters/{deadLetterId}/resolve":{"post":{"operationId":"post_api_v1_campaigns_id_dead_letters_deadLetterId_resolve","summary":"Run campaigns / dead letters / resolve","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"deadLetterId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"outcome":{"type":"string","const":"requeue"},"note":{"type":"string","minLength":1,"maxLength":500}},"required":["outcome","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/campaigns/{id}/delivery":{"get":{"operationId":"get_api_v1_campaigns_id_delivery","summary":"Read reconciled campaign delivery","description":"Returns persisted supplier delivery, or CSV when format=csv. An empty pull does not advance the durable report cursor.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"format","in":"query","required":false,"schema":{"type":"string","enum":["json","csv"],"default":"json"},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}},"text/csv":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/insights":{"get":{"operationId":"get_api_v1_campaigns_id_insights","summary":"Read campaigns / insights","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/journeys":{"get":{"operationId":"get_api_v1_campaigns_id_journeys","summary":"Read campaigns / journeys","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/launch":{"post":{"operationId":"post_api_v1_campaigns_id_launch","summary":"Launch or stage an approved campaign","description":"Reserves the campaign commitment and executes eligible supplier operations. Native staged providers remain stopped until approved configuration and creative evidence permit enabling. Workflow suppliers return booking steps. Inspect every line status and attempt; HTTP success alone does not mean the campaign is live.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: campaign.launch. { campaignId } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"campaign.launch","budgetPolicy":"campaign-commitment","parameterContract":"{ campaignId }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/lines/{lineId}/conversion-goal":{"patch":{"operationId":"patch_api_v1_campaigns_id_lines_lineId_conversion_goal","summary":"Update campaigns / lines / conversion goal","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: campaign.conversion-goal.update. { campaignId, lineId, goalRef, expectedDefinitionDigest, expectedConnectionRevision, expectedBindingId, tiktokSettings?, metaSettings? }; TikTok requires clickAttributionWindow, viewAttributionWindow and attributionEventCount; Meta requires clickAttributionWindow, viewAttributionWindow and attributionCountType Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"goalRef":{"type":"string","minLength":1,"maxLength":500},"expectedDefinitionDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"expectedConnectionRevision":{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},"expectedBindingId":{"anyOf":[{"type":"string","minLength":1,"maxLength":200},{"type":"null"}]},"tiktokSettings":{"type":"object","properties":{"clickAttributionWindow":{"type":"string","enum":["ONE_DAY","SEVEN_DAYS","FOURTEEN_DAYS","TWENTY_EIGHT_DAYS"]},"viewAttributionWindow":{"type":"string","enum":["OFF","ONE_DAY","SEVEN_DAYS"]},"attributionEventCount":{"type":"string","enum":["ONCE","EVERY"]}},"required":["clickAttributionWindow","viewAttributionWindow","attributionEventCount"],"additionalProperties":false},"metaSettings":{"type":"object","properties":{"clickAttributionWindow":{"type":"string","enum":["ONE_DAY","SEVEN_DAYS"]},"viewAttributionWindow":{"type":"string","enum":["OFF","ONE_DAY"]},"attributionCountType":{"type":"string","enum":["ALL_CONVERSIONS","FIRST_CONVERSION"]}},"required":["clickAttributionWindow","viewAttributionWindow","attributionCountType"],"additionalProperties":false}},"required":["goalRef","expectedDefinitionDigest","expectedConnectionRevision","expectedBindingId"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"campaign.conversion-goal.update","budgetPolicy":"zero","parameterContract":"{ campaignId, lineId, goalRef, expectedDefinitionDigest, expectedConnectionRevision, expectedBindingId, tiktokSettings?, metaSettings? }; TikTok requires clickAttributionWindow, viewAttributionWindow and attributionEventCount; Meta requires clickAttributionWindow, viewAttributionWindow and attributionCountType","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/lines/{lineId}/conversion-goals":{"get":{"operationId":"get_api_v1_campaigns_id_lines_lineId_conversion_goals","summary":"Read campaigns / lines / conversion goals","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/lines/{lineId}/creatives/{creativeId}/approval":{"post":{"operationId":"post_api_v1_campaigns_id_lines_lineId_creatives_creativeId_approval","summary":"Run campaigns / lines / creatives / approval","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string"}},{"name":"creativeId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"externalCreativeRef":{"type":"string","minLength":1,"maxLength":500},"note":{"type":"string","minLength":1,"maxLength":500},"confirmation":{"type":"object","properties":{"confirmed":{"type":"boolean","const":true},"adapterKey":{"type":"string","minLength":1,"maxLength":120},"providerAccountRef":{"type":"string","minLength":1,"maxLength":500},"providerAccountRefAuthority":{"type":"string","enum":["provider-validated","operator-attested"]},"providerCampaignRef":{"type":"string","minLength":1,"maxLength":500},"externalCreativeRef":{"type":"string","minLength":1,"maxLength":500},"destinationUrl":{"anyOf":[{"type":"string","format":"uri"},{"type":"null"}]},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"},"configurationDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["confirmed","adapterKey","providerAccountRef","providerAccountRefAuthority","providerCampaignRef","externalCreativeRef","destinationUrl","assetFingerprint","configurationDigest"],"additionalProperties":false},"outcome":{"type":"string","const":"approved"},"providerStatus":{"type":"string","const":"APPROVED"}},"required":["note","confirmation","outcome","providerStatus"],"additionalProperties":false},{"type":"object","properties":{"externalCreativeRef":{"type":"string","minLength":1,"maxLength":500},"note":{"type":"string","minLength":1,"maxLength":500},"confirmation":{"type":"object","properties":{"confirmed":{"type":"boolean","const":true},"adapterKey":{"type":"string","minLength":1,"maxLength":120},"providerAccountRef":{"type":"string","minLength":1,"maxLength":500},"providerAccountRefAuthority":{"type":"string","enum":["provider-validated","operator-attested"]},"providerCampaignRef":{"type":"string","minLength":1,"maxLength":500},"externalCreativeRef":{"type":"string","minLength":1,"maxLength":500},"destinationUrl":{"anyOf":[{"type":"string","format":"uri"},{"type":"null"}]},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"},"configurationDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["confirmed","adapterKey","providerAccountRef","providerAccountRefAuthority","providerCampaignRef","externalCreativeRef","destinationUrl","assetFingerprint","configurationDigest"],"additionalProperties":false},"outcome":{"type":"string","const":"rejected"},"providerStatus":{"type":"string","const":"REJECTED"}},"required":["note","confirmation","outcome","providerStatus"],"additionalProperties":false}]}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/campaigns/{id}/lines/{lineId}/provider-spend-artifacts/{artifactId}":{"get":{"operationId":"get_api_v1_campaigns_id_lines_lineId_provider_spend_artifacts_artifactId","summary":"Read campaigns / lines / provider spend artifacts","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string"}},{"name":"artifactId","in":"path","required":true,"schema":{"type":"string","pattern":"^psa-[a-f0-9]{64}$"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"*/*":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/campaigns/{id}/lines/{lineId}/provider-spend-reconciliations":{"post":{"operationId":"post_api_v1_campaigns_id_lines_lineId_provider_spend_reconciliations","summary":"Run campaigns / lines / provider spend reconciliations","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"providerAccountRef":{"type":"string","minLength":1,"maxLength":500},"evidenceKind":{"type":"string","enum":["invoice","account-export"]},"evidenceRef":{"type":"string","minLength":1,"maxLength":500},"evidenceArtifactId":{"type":"string","pattern":"^psa-[a-f0-9]{64}$"},"note":{"type":"string","minLength":1,"maxLength":2000},"providerTotalMinor":{"type":"integer","minimum":0,"maximum":2147483647},"expectedDeliveryDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["providerAccountRef","evidenceKind","evidenceRef","evidenceArtifactId","note","providerTotalMinor","expectedDeliveryDigest"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/campaigns/{id}/live-test-grants":{"get":{"operationId":"get_api_v1_campaigns_id_live_test_grants","summary":"Read campaigns / live test grants","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_campaigns_id_live_test_grants","summary":"Run campaigns / live test grants","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with supplier:authorize permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"adapterKey":{"type":"string","minLength":1},"maxBudgetMinor":{"type":"integer","exclusiveMinimum":0},"currency":{"type":"string","enum":["GBP","USD","EUR"]},"reason":{"type":"string","minLength":1,"maxLength":4000},"validFrom":{"type":"string","format":"date-time"},"expiresAt":{"type":"string","format":"date-time"}},"required":["adapterKey","maxBudgetMinor","currency","reason","expiresAt"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["supplier:authorize"]}},"/api/v1/campaigns/{id}/live-test-grants/{grantId}/revoke":{"post":{"operationId":"post_api_v1_campaigns_id_live_test_grants_grantId_revoke","summary":"Run campaigns / live test grants / revoke","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with supplier:authorize permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"grantId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"note":{"type":"string","minLength":1,"maxLength":4000}},"required":["note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["supplier:authorize"]}},"/api/v1/campaigns/{id}/measurement":{"get":{"operationId":"get_api_v1_campaigns_id_measurement","summary":"Read campaign measurement and evidence quality","description":"Returns delivery-derived reach and frequency, modeled ranges, uncertainty and outcome evidence. Unknown population yields an upper bound; modeled reach is not an observed unique audience count.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/optimize":{"post":{"operationId":"post_api_v1_campaigns_id_optimize","summary":"Run campaigns / optimize","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/outcomes/health":{"get":{"operationId":"get_api_v1_campaigns_id_outcomes_health","summary":"Read campaigns / outcomes / health","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":200}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/outcomes/import":{"post":{"operationId":"post_api_v1_campaigns_id_outcomes_import","summary":"Run campaigns / outcomes / import","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: outcome.import. { campaignId, source, privacy, eventCount, eventsDigest }; prepare with { campaignId, source, privacy, events } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":200}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"source":{"type":"object","properties":{"key":{"type":"string","minLength":2,"maxLength":64,"pattern":"^[a-z0-9][a-z0-9_-]*$"},"kind":{"type":"string","enum":["analytics","commerce","crm","offline","other"]},"reference":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9._:/-]+$"}},"required":["key","kind"],"additionalProperties":false},"privacy":{"type":"object","properties":{"lawfulBasis":{"type":"string","enum":["consent","legitimate-interest"]},"consentConfirmed":{"type":"boolean"},"identityMode":{"type":"string","enum":["none","household-sha256"]},"rawIdentifiersRemoved":{"type":"boolean","const":true}},"required":["lawfulBasis","consentConfirmed","identityMode","rawIdentifiersRemoved"],"additionalProperties":false},"events":{"type":"array","items":{"type":"object","properties":{"eventId":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9._:-]+$"},"ts":{"type":"string","format":"date-time"},"kind":{"type":"string","enum":["pageview","conversion"]},"valueMinor":{"type":"integer","minimum":0,"maximum":2147483647},"promoCode":{"type":"string","maxLength":64,"pattern":"^CHORUS-[A-Z]{2,3}-[0-9A-F]{4}$"},"market":{"type":"string","minLength":2,"maxLength":64,"pattern":"^[a-z0-9][a-z0-9_-]*$"},"householdKeyHash":{"type":"string","pattern":"^[0-9a-f]{64}$"}},"required":["eventId","ts","kind"],"additionalProperties":false},"minItems":1,"maxItems":500}},"required":["source","privacy","events"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"outcome.import","budgetPolicy":"zero","parameterContract":"{ campaignId, source, privacy, eventCount, eventsDigest }; prepare with { campaignId, source, privacy, events }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/pause":{"post":{"operationId":"post_api_v1_campaigns_id_pause","summary":"Pause or request stopping a campaign","description":"Attempts provider stopping or requests a managed supplier stop. Funds remain held until stop evidence and delivery reconciliation support release. Inspect line status; a buyer pause request alone is not proof that spending stopped.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: campaign.pause. { campaignId } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"campaign.pause","budgetPolicy":"zero","parameterContract":"{ campaignId }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/prove-it":{"post":{"operationId":"post_api_v1_campaigns_id_prove_it","summary":"Evaluate geo-lift evidence","description":"Evaluates causal lift under the configured statistical design. Underpowered studies are refused instead of producing a causal claim.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"testMarket":{"type":"string","default":"london"},"expectedLiftPct":{"type":"number","exclusiveMinimum":0,"default":15},"exposureStart":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"}},"additionalProperties":false,"default":{}}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/provider-spend-artifacts":{"post":{"operationId":"post_api_v1_campaigns_id_provider_spend_artifacts","summary":"Run campaigns / provider spend artifacts","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"fileName":{"type":"string","minLength":1,"maxLength":200},"mediaType":{"type":"string","enum":["application/pdf","text/csv","application/json","application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"]},"contentBase64":{"type":"string","minLength":1,"maxLength":2796204}},"required":["fileName","mediaType","contentBase64"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"],"x-body-limit-bytes":2800300}},"/api/v1/campaigns/{id}/provider-spend-reconciliations":{"get":{"operationId":"get_api_v1_campaigns_id_provider_spend_reconciliations","summary":"Read campaigns / provider spend reconciliations","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/campaigns/{id}/readiness":{"get":{"operationId":"get_api_v1_campaigns_id_readiness","summary":"Inspect campaign readiness and buying blockers","description":"Returns funding, creative, targeting, supplier authority, live grants and activation blockers. Resolve blockers before requesting execution; readiness does not prove delivery.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/report":{"get":{"operationId":"get_api_v1_campaigns_id_report","summary":"Download the campaign report","description":"Returns a human-readable HTML report with delivery, fees, targeting fidelity and explicitly modeled measurement.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"text/html":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/resume":{"post":{"operationId":"post_api_v1_campaigns_id_resume","summary":"Resume an eligible campaign","description":"Revalidates funding, supplier authority, targeting, approved creative identity and configuration before resuming. An unresolved provider outcome blocks blind retry.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: campaign.resume. { campaignId } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"campaign.resume","budgetPolicy":"campaign-commitment","parameterContract":"{ campaignId }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/staged-cancellation":{"post":{"operationId":"post_api_v1_campaigns_id_staged_cancellation","summary":"Run campaigns / staged cancellation","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"outcome":{"type":"string","const":"confirmed-zero-delivery"},"lines":{"type":"array","items":{"type":"object","properties":{"channelCampaignId":{"type":"string","minLength":1},"providerCampaignRef":{"type":"string","minLength":1,"maxLength":500},"providerStatus":{"type":"string","minLength":1,"maxLength":120},"providerReportRef":{"type":"string","minLength":1,"maxLength":500}},"required":["channelCampaignId","providerCampaignRef","providerStatus","providerReportRef"],"additionalProperties":false},"minItems":1,"maxItems":50},"reportFromDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"reportThroughDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"note":{"type":"string","minLength":1,"maxLength":500}},"required":["outcome","lines","reportFromDate","reportThroughDate","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/campaigns/{id}/sync-audience":{"post":{"operationId":"post_api_v1_campaigns_id_sync_audience","summary":"Run campaigns / sync audience","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: audience.sync. { campaignId, exposedOn, notExposedOn, channel, purpose, adapterKey, executionMode } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"exposedOn":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1},"notExposedOn":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"default":[]},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"purpose":{"type":"string","enum":["inclusion","suppression"]},"adapterKey":{"type":"string","minLength":1},"executionMode":{"type":"string","enum":["sandbox","live"]}},"required":["exposedOn","channel","purpose","adapterKey","executionMode"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"audience.sync","budgetPolicy":"zero","parameterContract":"{ campaignId, exposedOn, notExposedOn, channel, purpose, adapterKey, executionMode }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/tracking":{"get":{"operationId":"get_api_v1_campaigns_id_tracking","summary":"Read campaigns / tracking","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/campaigns/{id}/tracking/{channel}":{"patch":{"operationId":"patch_api_v1_campaigns_id_tracking_channel","summary":"Update campaigns / tracking","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: campaign.tracking.update. { campaignId, channel, destinationUrl } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"channel","in":"path","required":true,"schema":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"destinationUrl":{"anyOf":[{"type":"string"},{"type":"null"}]}},"required":["destinationUrl"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"campaign.tracking.update","budgetPolicy":"zero","parameterContract":"{ campaignId, channel, destinationUrl }","exactApprovalRequired":true}}},"/api/v1/campaigns/{id}/workflow/{runId}/acknowledge":{"post":{"operationId":"post_api_v1_campaigns_id_workflow_runId_acknowledge","summary":"Run campaigns / workflow / acknowledge","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Campaigns"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"runId","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"stepKey":{"type":"string","minLength":1},"outcome":{"type":"string","enum":["done","blocked"],"default":"done"},"reference":{"type":"string","minLength":1,"maxLength":200},"note":{"type":"string","maxLength":500}},"required":["stepKey"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/connections":{"get":{"operationId":"get_api_v1_connections","summary":"Read configured suppliers and capability evidence","description":"Returns tenant-scoped execution modes, credential requirements and adapter operation support. A connector count is not a claim that every supplier is approved for live buying.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Connections"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/connections/{key}":{"patch":{"operationId":"patch_api_v1_connections_key","summary":"Update connections","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: connection.update. { key, mode, credentialFields?, credentialsDigest? }; prepare with { key, mode, credentials? } so secrets are never journalled Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Connections"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"key","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"mode":{"type":"string","enum":["sandbox","live"]},"credentials":{"type":"object","additionalProperties":{"type":"string"}}},"required":["mode"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"connection.update","budgetPolicy":"zero","parameterContract":"{ key, mode, credentialFields?, credentialsDigest? }; prepare with { key, mode, credentials? } so secrets are never journalled","exactApprovalRequired":true}}},"/api/v1/connections/{key}/dossier":{"get":{"operationId":"get_api_v1_connections_key_dossier","summary":"Read or maintain supplier access evidence","description":"Supplier dossiers record account identity, commercial access, supported operations and reviewed provenance. Saving a draft is not verification; authorized human review is required.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Connections"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"key","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"put":{"operationId":"put_api_v1_connections_key_dossier","summary":"Read or maintain supplier access evidence","description":"Supplier dossiers record account identity, commercial access, supported operations and reviewed provenance. Saving a draft is not verification; authorized human review is required.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with supplier:authorize permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Connections"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"key","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","enum":["draft","blocked"],"default":"draft"},"accessClass":{"type":"string","enum":["open","own-account","approved","contract","infrastructure"]},"content":{"type":"object","properties":{"schemaVersion":{"type":"number","const":1},"summary":{"type":"string","minLength":1,"maxLength":4000},"identity":{"type":"object","properties":{"supplierName":{"type":"string","minLength":1,"maxLength":500},"productName":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"officialWebsiteUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"developerDocsUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"termsUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"privacyUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"supportUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"maxItems":7},"availableMarkets":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["supplierName","productName","officialWebsiteUrl","developerDocsUrl","termsUrl","privacyUrl","supportUrl","channels","availableMarkets","notes"],"additionalProperties":false},"commercialAccess":{"type":"object","properties":{"accessClass":{"type":"string","enum":["open","own-account","approved","contract","infrastructure"]},"accountScope":{"type":"string","enum":["unknown","own-account-only","agency-multi-advertiser","reseller","managed-service"]},"currentState":{"type":"string","enum":["unknown","not-started","application-pending","approved","contracted","suspended","rejected","not-available"]},"signupUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"applicationUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"contractRequired":{"type":["boolean","null"]},"multiAdvertiserUseApproved":{"type":["boolean","null"]},"resaleApproved":{"type":["boolean","null"]},"onboardingLeadTime":{"anyOf":[{"type":"object","properties":{"minimumBusinessDays":{"type":"integer","minimum":0,"maximum":365},"maximumBusinessDays":{"type":"integer","minimum":0,"maximum":365}},"required":["minimumBusinessDays","maximumBusinessDays"],"additionalProperties":false},{"type":"null"}]},"minimumCommitment":{"anyOf":[{"type":"object","properties":{"amountMinor":{"type":"integer","minimum":0},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["amountMinor","currency"],"additionalProperties":false},{"type":"null"}]},"requiredLegalEntities":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"requiredAgreements":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"usageRestrictions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["accessClass","accountScope","currentState","signupUrl","applicationUrl","contractRequired","multiAdvertiserUseApproved","resaleApproved","onboardingLeadTime","minimumCommitment","requiredLegalEntities","requiredAgreements","usageRestrictions","evidenceIds","notes"],"additionalProperties":false},"operations":{"type":"array","items":{"type":"object","properties":{"operation":{"anyOf":[{"type":"string","enum":["forecast","activate","pause","resume","creative","report","audienceSync","deals","keywordSuggestions","analytics","conversionGoals","providerForecast","postcodeClassification","identityMapping","identityOptOut","studyCatalog","studyRead","studyDraft","studyLaunch","studyResults","customerMatchCatalog","customerMatchIngest","customerMatchRemove","customerMatchStatus"]},{"type":"string","const":"inventory"}]},"verificationStatus":{"anyOf":[{"type":"string","const":"unknown"},{"type":"string","enum":["sandbox-only","stub","client-built","contract-tested","spend-tested","report-verified"]}]},"liveAccess":{"type":"string","enum":["unknown","not-approved","approved","suspended","not-applicable"]},"executionMode":{"type":"string","enum":["unknown","rest-api","graphql-api","official-mcp","file-transfer","portal-workflow","email-workflow","managed-service","none"]},"risk":{"type":"string","enum":["read-only","non-spend-write","spend-authorizing","personal-data-transfer"]},"requiredOAuthScopes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"requiredCredentialFields":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"sandboxAvailable":{"type":["boolean","null"]},"supportsIdempotency":{"type":["boolean","null"]},"supportsMultiAdvertiser":{"type":["boolean","null"]},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"blockers":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["operation","verificationStatus","liveAccess","executionMode","risk","requiredOAuthScopes","requiredCredentialFields","sandboxAvailable","supportsIdempotency","supportsMultiAdvertiser","evidenceIds","blockers","notes"],"additionalProperties":false},"maxItems":20},"billing":{"type":"object","properties":{"billingModel":{"type":"string","enum":["unknown","prepaid","card-on-file","postpaid-invoice","platform-billed","managed-service","mixed","not-applicable"]},"supportedCurrencies":{"type":"array","items":{"type":"string","enum":["GBP","USD","EUR"]},"maxItems":3},"requiresPreFunding":{"type":["boolean","null"]},"paymentTermsDays":{"anyOf":[{"type":"integer","minimum":0,"maximum":365},{"type":"null"}]},"spendCapBehavior":{"type":"string","enum":["unknown","vendor-hard-cap","vendor-soft-cap","platform-only","not-supported","not-applicable"]},"minimumCampaignSpend":{"anyOf":[{"type":"object","properties":{"amountMinor":{"type":"integer","minimum":0},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["amountMinor","currency"],"additionalProperties":false},{"type":"null"}]},"minimumMonthlyCommitment":{"anyOf":[{"type":"object","properties":{"amountMinor":{"type":"integer","minimum":0},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["amountMinor","currency"],"additionalProperties":false},{"type":"null"}]},"invoiceCadence":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"billableMetrics":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"feesAndMarkups":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"taxHandling":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"refundAndCreditTerms":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"reconciliationFields":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["billingModel","supportedCurrencies","requiresPreFunding","paymentTermsDays","spendCapBehavior","minimumCampaignSpend","minimumMonthlyCommitment","invoiceCadence","billableMetrics","feesAndMarkups","taxHandling","refundAndCreditTerms","reconciliationFields","evidenceIds","notes"],"additionalProperties":false},"technical":{"type":"object","properties":{"integrationModes":{"type":"array","items":{"type":"string","enum":["unknown","rest-api","graphql-api","official-mcp","file-transfer","portal-workflow","email-workflow","managed-service","none"]},"maxItems":20},"apiBaseUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"apiVersion":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"authMethod":{"type":"string","enum":["unknown","none","api-key","basic","oauth2-authorization-code","oauth2-client-credentials","rsa-signature","mutual-tls","vendor-session","manual"]},"oauthAuthorizationUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"oauthTokenUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"credentialFields":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":256,"allOf":[{"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},{"pattern":"^[A-Za-z][A-Za-z0-9_.-]*$"}]},"label":{"type":"string","minLength":1,"maxLength":500},"required":{"type":"boolean"},"secret":{"type":"boolean"},"rotates":{"type":["boolean","null"]},"acquisition":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["name","label","required","secret","rotates","acquisition","notes"],"additionalProperties":false},"maxItems":100},"sandboxClass":{"type":"string","enum":["unknown","true-sandbox","test-account","production-test-only","synthetic-only","unavailable"]},"idempotencyClass":{"type":"string","enum":["unknown","native-key","request-header","natural-key-only","not-supported","not-applicable"]},"paginationClass":{"type":"string","enum":["unknown","cursor","page","offset","stream","none"]},"supportsWebhooks":{"type":["boolean","null"]},"usesAsynchronousJobs":{"type":["boolean","null"]},"rateLimitSummary":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"reportingLatencySummary":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"timeoutGuidance":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"versioningPolicy":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"productionTestingRequired":{"type":["boolean","null"]},"mcp":{"type":"object","properties":{"availability":{"type":"string","enum":["unknown","not-offered","supplier-hosted-beta","supplier-hosted-ga","official-self-hosted","third-party-only"]},"endpointUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"signupUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"transports":{"type":"array","items":{"type":"string","enum":["unknown","streamable-http","stdio","sse"]},"maxItems":4},"protocolVersions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":20},"authMethod":{"type":"string","enum":["unknown","none","api-key","basic","oauth2-authorization-code","oauth2-client-credentials","rsa-signature","mutual-tls","vendor-session","manual"]},"tools":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"description":{"type":"string","minLength":1,"maxLength":4000},"risk":{"type":"string","enum":["read-only","non-spend-write","spend-authorizing","personal-data-transfer"]},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100}},"required":["name","description","risk","evidenceIds"],"additionalProperties":false},"maxItems":500},"toolSchemaDigest":{"anyOf":[{"type":"string","pattern":"^[a-f0-9]{64}$"},{"type":"null"}]},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["availability","endpointUrl","signupUrl","transports","protocolVersions","authMethod","tools","toolSchemaDigest","evidenceIds","notes"],"additionalProperties":false},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"blockers":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["integrationModes","apiBaseUrl","apiVersion","authMethod","oauthAuthorizationUrl","oauthTokenUrl","credentialFields","sandboxClass","idempotencyClass","paginationClass","supportsWebhooks","usesAsynchronousJobs","rateLimitSummary","reportingLatencySummary","timeoutGuidance","versioningPolicy","productionTestingRequired","mcp","evidenceIds","blockers","notes"],"additionalProperties":false},"creative":{"type":"object","properties":{"submissionMode":{"type":"string","enum":["unknown","api","portal","email","managed-service","not-applicable"]},"formats":{"type":"array","items":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":500},"mimeTypes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":50},"fileExtensions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":50},"dimensions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"durationsSeconds":{"type":"array","items":{"type":"integer","exclusiveMinimum":0,"maximum":86400},"maxItems":100},"maximumBytes":{"anyOf":[{"type":"integer","exclusiveMinimum":0},{"type":"null"}]},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["name","mimeTypes","fileExtensions","dimensions","durationsSeconds","maximumBytes","notes"],"additionalProperties":false},"maxItems":200},"requiresPreApproval":{"type":["boolean","null"]},"externalCreativeRefReturned":{"type":["boolean","null"]},"approvalStatusReadable":{"type":["boolean","null"]},"approvalBoundToExactBytes":{"type":["boolean","null"]},"reviewSlaBusinessDays":{"anyOf":[{"type":"object","properties":{"minimumBusinessDays":{"type":"integer","minimum":0,"maximum":365},"maximumBusinessDays":{"type":"integer","minimum":0,"maximum":365}},"required":["minimumBusinessDays","maximumBusinessDays"],"additionalProperties":false},{"type":"null"}]},"approvalExpiryDays":{"anyOf":[{"type":"integer","exclusiveMinimum":0,"maximum":3650},{"type":"null"}]},"reusePolicy":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"clearanceRequirements":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"contentRestrictions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"blockers":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["submissionMode","formats","requiresPreApproval","externalCreativeRefReturned","approvalStatusReadable","approvalBoundToExactBytes","reviewSlaBusinessDays","approvalExpiryDays","reusePolicy","clearanceRequirements","contentRestrictions","evidenceIds","blockers","notes"],"additionalProperties":false},"privacy":{"type":"object","properties":{"supplierRole":{"type":"string","enum":["unknown","controller","processor","joint-controller","independent-controller","not-applicable"]},"chorusRole":{"type":"string","enum":["unknown","controller","processor","joint-controller","independent-controller","not-applicable"]},"dpaState":{"type":"string","enum":["unknown","not-reviewed","available","executed","not-offered","not-applicable"]},"dpaUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"personalDataHandled":{"type":["boolean","null"]},"acceptedIdentifierClasses":{"type":"array","items":{"type":"string","enum":["household-key","maid-hash","euid","postcode-sector","full-postcode","email-hash","phone-hash","raw-device-id","other","none"]},"maxItems":20},"rawDeviceIdentifiersRequired":{"type":["boolean","null"]},"retentionDays":{"anyOf":[{"type":"integer","minimum":0,"maximum":36500},{"type":"null"}]},"dataResidencyRegions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"internationalTransferMechanism":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"subprocessorListUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"deletionMechanism":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"consentAndLawfulBasisRequirements":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"purposeRestrictions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"sensitiveCategoryRestrictions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"blockers":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["supplierRole","chorusRole","dpaState","dpaUrl","personalDataHandled","acceptedIdentifierClasses","rawDeviceIdentifiersRequired","retentionDays","dataResidencyRegions","internationalTransferMechanism","subprocessorListUrl","deletionMechanism","consentAndLawfulBasisRequirements","purposeRestrictions","sensitiveCategoryRestrictions","evidenceIds","blockers","notes"],"additionalProperties":false},"support":{"type":"object","properties":{"accessState":{"type":"string","enum":["unknown","not-established","established","unavailable"]},"channels":{"type":"array","items":{"type":"string","enum":["unknown","email","ticket","phone","chat","account-manager","community"]},"maxItems":20},"supportEmail":{"anyOf":[{"type":"string","format":"email","maxLength":320},{"type":"null"}]},"supportPortalUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"statusPageUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"businessHours":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"responseSla":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"escalationProcedure":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"onboardingContact":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"evidenceIds":{"type":"array","items":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"maxItems":100},"blockers":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["accessState","channels","supportEmail","supportPortalUrl","statusPageUrl","businessHours","responseSla","escalationProcedure","onboardingContact","evidenceIds","blockers","notes"],"additionalProperties":false},"evidence":{"type":"object","properties":{"state":{"type":"string","enum":["unverified","partially-verified","verified","stale","disputed"]},"lastReviewedOn":{"anyOf":[{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},{"type":"null"}]},"nextReviewOn":{"anyOf":[{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},{"type":"null"}]},"reviewedBy":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1,"maxLength":256,"pattern":"^[^\\u0000-\\u001f\\u007f]+$"},"kind":{"type":"string","enum":["official-documentation","supplier-terms","supplier-correspondence","signed-contract","credentialed-read","contract-test","test-buy","delivery-report","invoice","support-case","other"]},"title":{"type":"string","minLength":1,"maxLength":500},"publisher":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"sourceUrl":{"anyOf":[{"type":"string","format":"uri","maxLength":2048},{"type":"null"}]},"artifactRef":{"anyOf":[{"type":"string","minLength":1,"maxLength":500},{"type":"null"}]},"observedOn":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"validUntil":{"anyOf":[{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},{"type":"null"}]},"contentDigest":{"anyOf":[{"type":"string","pattern":"^[a-f0-9]{64}$"},{"type":"null"}]},"assertedFacts":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100},"notes":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["id","kind","title","publisher","sourceUrl","artifactRef","observedOn","validUntil","contentDigest","assertedFacts","notes"],"additionalProperties":false},"maxItems":500},"openQuestions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["state","lastReviewedOn","nextReviewOn","reviewedBy","items","openQuestions"],"additionalProperties":false},"readinessBlockers":{"type":"array","items":{"type":"string","minLength":1,"maxLength":500},"maxItems":100}},"required":["schemaVersion","summary","identity","commercialAccess","operations","billing","technical","creative","privacy","support","evidence","readinessBlockers"],"additionalProperties":false}},"required":["accessClass","content"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["supplier:authorize"]}},"/api/v1/connections/{key}/dossier/verify":{"post":{"operationId":"post_api_v1_connections_key_dossier_verify","summary":"Verify a supplier access dossier","description":"Requires supplier:authorize human permission and current exact account/configuration evidence. A dossier does not replace scoped live execution grants.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with supplier:authorize permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Connections"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"key","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["supplier:authorize"]}},"/api/v1/creatives":{"get":{"operationId":"get_api_v1_creatives","summary":"Read creatives","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"campaignId","in":"query","required":false,"schema":{"type":"string"},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"creatives":{"type":"array","items":{"type":"object","properties":{},"additionalProperties":true}}},"required":["creatives"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_creatives","summary":"Run creatives","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string","minLength":1},"copyText":{"type":"string","minLength":1},"audioDelivery":{"type":"object","properties":{"tagline":{"type":"string","minLength":2,"maxLength":40},"destinationUrl":{"type":"string","maxLength":2048,"format":"uri"},"callToAction":{"type":"string","minLength":1,"maxLength":80},"language":{"type":"string","minLength":2,"maxLength":16}},"required":["tagline","destinationUrl","callToAction","language"],"additionalProperties":false},"campaignId":{"type":"string"}},"required":["name","channel","format","assetUrl","copyText"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"creative":{"type":"object","properties":{},"additionalProperties":true}},"required":["creative"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/creatives/{id}/adapt":{"post":{"operationId":"post_api_v1_creatives_id_adapt","summary":"Run creatives / adapt","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"targetChannel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"campaignId":{"type":"string"}},"required":["targetChannel"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/creatives/{id}/assets":{"get":{"operationId":"get_api_v1_creatives_id_assets","summary":"Submit or list creative asset production jobs","description":"Asset production is a separate wallet charge at submit, with a retained idempotencyKey and automatic refund on confirmed provider failure. Inspect pricing and commercial-use status first. Uncertain jobs require reconciliation.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_creatives_id_assets","summary":"Submit or list creative asset production jobs","description":"Asset production is a separate wallet charge at submit, with a retained idempotencyKey and automatic refund on confirmed provider failure. Inspect pricing and commercial-use status first. Uncertain jobs require reconciliation.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: asset.submit. { creativeId, idempotencyKey, kind?, spec? } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"idempotencyKey":{"type":"string","minLength":8,"maxLength":200},"kind":{"type":"string","enum":["video","image","vo","music","motion"]},"spec":{"type":"object","additionalProperties":{}}},"required":["idempotencyKey"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"body-key","bodyField":"idempotencyKey","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"asset.submit","budgetPolicy":"asset-ceiling","parameterContract":"{ creativeId, idempotencyKey, kind?, spec? }","exactApprovalRequired":true}}},"/api/v1/creatives/{id}/precheck":{"post":{"operationId":"post_api_v1_creatives_id_precheck","summary":"Precheck creative for the campaign","description":"Checks format, copy, destination and policy constraints. A platform precheck is separate from supplier creative approval.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"claims":{"type":"array","items":{"type":"string"},"default":[]}},"additionalProperties":false,"default":{}}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/creatives/{id}/renditions/{index}.svg":{"get":{"operationId":"get_api_v1_creatives_id_renditions_index_svg","summary":"Read creatives / renditions","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"index","in":"path","required":true,"schema":{"type":"string","pattern":"^\\d+$"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"image/svg+xml":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/creatives/{id}/revise":{"post":{"operationId":"post_api_v1_creatives_id_revise","summary":"Run creatives / revise","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"headline":{"type":"string","minLength":1,"maxLength":200},"subline":{"type":"string","minLength":1,"maxLength":300},"cta":{"type":"string","minLength":1,"maxLength":100},"mandatories":{"type":"array","items":{"type":"string","minLength":1,"maxLength":60},"maxItems":4}},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/creatives/{id}/submit":{"post":{"operationId":"post_api_v1_creatives_id_submit","summary":"Submit creative for supplier review","description":"Submits the exact selected bytes to the supplier and records its external reference. Approval is valid only for the same asset fingerprint and reviewed delivery metadata.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: creative.submit. { creativeId, adapterKey, channel? } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string"}},"required":["adapterKey"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"creative.submit","budgetPolicy":"zero","parameterContract":"{ creativeId, adapterKey, channel? }","exactApprovalRequired":true}}},"/api/v1/creatives/generate":{"post":{"operationId":"post_api_v1_creatives_generate","summary":"Generate creative concepts and copy","description":"Creates structured creative variants with deterministic sandbox fallback. Generated concepts still need suitable media assets, precheck and supplier approval before live use.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"personaId":{"type":"string"},"campaignId":{"type":"string"},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"brief":{"type":"object","properties":{"product":{"type":"string","minLength":1},"proposition":{"type":"string","minLength":1},"tone":{"type":"string","enum":["bold","premium","friendly","urgent","witty"]},"mandatories":{"type":"array","items":{"type":"string","minLength":1,"maxLength":60},"maxItems":4}},"required":["product","proposition","tone"],"additionalProperties":false}},"required":["channel","brief"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":30,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/creatives/upload":{"post":{"operationId":"post_api_v1_creatives_upload","summary":"Upload supplied creative bytes","description":"Accepts canonical base64 in JSON, verifies declared media type and a 20 MiB decoded limit, fingerprints the bytes, and attaches the creative to the campaign. Audio companion copy, destination and CTA must be reviewed together with the media.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Creatives"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"campaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"name":{"type":"string","minLength":1,"maxLength":200},"format":{"type":"string","minLength":1,"maxLength":100},"copyText":{"type":"string","maxLength":20000,"default":""},"audioDelivery":{"type":"object","properties":{"tagline":{"type":"string","minLength":2,"maxLength":40},"destinationUrl":{"type":"string","maxLength":2048,"format":"uri"},"callToAction":{"type":"string","minLength":1,"maxLength":80},"language":{"type":"string","minLength":2,"maxLength":16}},"required":["tagline","destinationUrl","callToAction","language"],"additionalProperties":false},"fileName":{"type":"string","minLength":1,"maxLength":255},"mediaType":{"type":"string","enum":["image/jpeg","image/png","video/mp4","video/webm","audio/mpeg","audio/wav"]},"base64":{"type":"string","minLength":4,"maxLength":27962028}},"required":["campaignId","channel","name","format","fileName","mediaType","base64"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"creative":{"type":"object","properties":{},"additionalProperties":true}},"required":["creative"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-body-limit-bytes":30408704}},"/api/v1/data/caci-acorn/classify":{"post":{"operationId":"post_api_v1_data_caci_acorn_classify","summary":"Classify postcodes using licensed CACI data","description":"Requires exact expected execution mode and connection revision. Live classification consumes licensed records and requires an Idempotency-Key UUID. Review data authority before use.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: data.postcodes.classify. { requestCount, requestsDigest, expectedExecutionMode, expectedConfigurationRevision }; prepare with { requests: [{ uid, postcode }], expectedExecutionMode, expectedConfigurationRevision }. Consumes licensed CACI records; live execution requires an Idempotency-Key UUID header. Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Data"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":false,"description":"Required for live execution; retain the same UUID for the same request after uncertain outcomes.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"requests":{"type":"array","items":{"type":"object","properties":{"uid":{"type":"string","pattern":"^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}$"},"postcode":{"type":"string","maxLength":12}},"required":["uid","postcode"],"additionalProperties":false},"maxItems":50},"expectedExecutionMode":{"type":"string","enum":["sandbox","live"]},"expectedConfigurationRevision":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["requests","expectedExecutionMode","expectedConfigurationRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"live-required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"data.postcodes.classify","budgetPolicy":"zero","parameterContract":"{ requestCount, requestsDigest, expectedExecutionMode, expectedConfigurationRevision }; prepare with { requests: [{ uid, postcode }], expectedExecutionMode, expectedConfigurationRevision }. Consumes licensed CACI records; live execution requires an Idempotency-Key UUID header.","exactApprovalRequired":true}}},"/api/v1/health":{"get":{"operationId":"get_api_v1_health","summary":"Check API process health","description":"Lightweight liveness only; use /readyz for database, scheduler and production readiness.\n\nPublic endpoint; tenant data is not exposed by discovery endpoints.","tags":["Health"],"security":[],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"status":{"type":"string","const":"ok"},"service":{"type":"string","const":"@adp/api"}},"required":["status","service"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/identity/cohorts":{"get":{"operationId":"get_api_v1_identity_cohorts","summary":"List or import consented identity cohorts","description":"Identity imports and consent assertions require an authenticated human. Agents use cohort metadata, revisions and digests; raw identifiers are not included in approval parameters.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Identity"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"cursor","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":100},"style":"form","explode":true},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"post":{"operationId":"post_api_v1_identity_cohorts","summary":"List or import consented identity cohorts","description":"Identity imports and consent assertions require an authenticated human. Agents use cohort metadata, revisions and digests; raw identifiers are not included in approval parameters.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Identity"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"mode":{"type":"string","enum":["sandbox","live"]},"consent":{"type":"object","properties":{"lawfulBasis":{"type":"string","const":"consent"},"purpose":{"type":"string","const":"euid-advertising-and-measurement"},"sourceReference":{"type":"string","minLength":3,"maxLength":120,"pattern":"^[A-Za-z0-9][A-Za-z0-9._:/-]*$"},"noticeVersion":{"type":"string","minLength":3,"maxLength":120,"pattern":"^[A-Za-z0-9][A-Za-z0-9._:/-]*$"},"obtainedAt":{"type":"string","format":"date-time"},"expiresAt":{"type":"string","format":"date-time"},"includesEuidSharing":{"type":"boolean","const":true}},"required":["lawfulBasis","purpose","sourceReference","noticeVersion","obtainedAt","expiresAt","includesEuidSharing"],"additionalProperties":false},"emailHashes":{"type":"array","items":{"type":"string","pattern":"^[A-Za-z0-9+/]{42}[AEIMQUYcgkosw048]=$"},"minItems":1,"maxItems":5000}},"required":["name","mode","consent","emailHashes"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-body-limit-bytes":512000}},"/api/v1/identity/cohorts/{cohortId}":{"get":{"operationId":"get_api_v1_identity_cohorts_cohortId","summary":"Read identity / cohorts","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Identity"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"cohortId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":100}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/identity/cohorts/{cohortId}/attempts/{attemptId}/resolve":{"post":{"operationId":"post_api_v1_identity_cohorts_cohortId_attempts_attemptId_resolve","summary":"Run identity / cohorts / attempts / resolve","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Identity"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"cohortId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":100}},{"name":"attemptId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":100}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"outcome":{"type":"string","const":"discard-unavailable-result"},"evidenceReference":{"type":"string","minLength":3,"maxLength":120,"pattern":"^[A-Za-z0-9][A-Za-z0-9._:/-]*$"}},"required":["expectedRevision","outcome","evidenceReference"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/identity/cohorts/{cohortId}/delete":{"post":{"operationId":"post_api_v1_identity_cohorts_cohortId_delete","summary":"Run identity / cohorts / delete","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Identity"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"cohortId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":100}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991}},"required":["expectedRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[]}},"/api/v1/identity/cohorts/{cohortId}/map":{"post":{"operationId":"post_api_v1_identity_cohorts_cohortId_map","summary":"Run identity / cohorts / map","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: data.identity.map. { cohortId, expectedRevision, expectedConnectionRevision }; use exact metadata from GET /identity/cohorts/:cohortId. Requires an Idempotency-Key UUID; never pass hashes or EUIDs into the action. Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Identity"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"cohortId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":100}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"expectedConnectionRevision":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["expectedRevision","expectedConnectionRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"data.identity.map","budgetPolicy":"zero","parameterContract":"{ cohortId, expectedRevision, expectedConnectionRevision }; use exact metadata from GET /identity/cohorts/:cohortId. Requires an Idempotency-Key UUID; never pass hashes or EUIDs into the action.","exactApprovalRequired":true}}},"/api/v1/identity/cohorts/{cohortId}/optout":{"post":{"operationId":"post_api_v1_identity_cohorts_cohortId_optout","summary":"Run identity / cohorts / optout","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: data.identity.optout. { cohortId, expectedRevision, expectedConnectionRevision }; use exact metadata from GET /identity/cohorts/:cohortId. Requires an Idempotency-Key UUID; never pass hashes or EUIDs into the action. Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Identity"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"cohortId","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":100}},{"name":"Idempotency-Key","in":"header","required":true,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","format":"uuid"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedRevision":{"type":"integer","exclusiveMinimum":0,"minimum":-9007199254740991,"maximum":9007199254740991},"expectedConnectionRevision":{"anyOf":[{"type":"integer","minimum":-9007199254740991,"maximum":9007199254740991},{"type":"null"}]}},"required":["expectedRevision","expectedConnectionRevision"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"required","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"data.identity.optout","budgetPolicy":"zero","parameterContract":"{ cohortId, expectedRevision, expectedConnectionRevision }; use exact metadata from GET /identity/cohorts/:cohortId. Requires an Idempotency-Key UUID; never pass hashes or EUIDs into the action.","exactApprovalRequired":true}}},"/api/v1/internal/fulfilment/bookings":{"get":{"operationId":"get_api_v1_internal_fulfilment_bookings","summary":"Read assigned-client supplier work queue","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"cursor","in":"query","required":false,"schema":{"type":"string","minLength":1},"style":"form","explode":true},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":50},"style":"form","explode":true},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["active","all"],"default":"active"},"style":"form","explode":true},{"name":"assignee","in":"query","required":false,"schema":{"type":"string","enum":["all","me","unassigned"],"default":"all"},"style":"form","explode":true},{"name":"advertiserId","in":"query","required":false,"schema":{"type":"string","minLength":1},"style":"form","explode":true},{"name":"adapterKey","in":"query","required":false,"schema":{"type":"string","minLength":1},"style":"form","explode":true},{"name":"overdue","in":"query","required":false,"schema":{"type":"string","enum":["true","false"]},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"bookings":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"nextCursor":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]}},"required":["bookings","nextCursor"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}":{"get":{"operationId":"get_api_v1_internal_fulfilment_bookings_bookingId","summary":"Read internal / fulfilment / bookings","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/assign":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_assign","summary":"Assign or transfer supplier work without retrying it","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"note":{"type":"string","minLength":10,"maxLength":20000}},"required":["expectedVersion","assignedToUserId","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/confirm":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_confirm","summary":"Run internal / fulfilment / bookings / lines / confirm","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"providerReference":{"type":"string","minLength":1,"maxLength":500},"evidence":{"type":"string","minLength":10,"maxLength":20000},"creativeReferences":{"type":"array","items":{"type":"object","properties":{"creativeId":{"type":"string","minLength":1},"externalCreativeRef":{"type":"string","minLength":1,"maxLength":500},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["creativeId","externalCreativeRef","assetFingerprint"],"additionalProperties":false},"minItems":1,"maxItems":100}},"required":["expectedVersion","providerReference","evidence","creativeReferences"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/finance":{"get":{"operationId":"get_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_finance","summary":"Review supplier report and invoice closeout","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"artifacts":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"campaignId":{"type":"string"},"sha256":{"type":"string"},"byteSize":{"type":"integer"},"mediaType":{"type":"string"},"fileName":{"type":"string"},"uploadedBy":{"type":"string"},"uploadedActor":{"type":"string"},"uploadedSource":{"type":"string"},"uploadedAt":{"type":"string"},"uploadedClientId":{"type":"string"}},"required":["id","campaignId","sha256","byteSize","mediaType","fileName","uploadedBy","uploadedActor","uploadedSource","uploadedAt"],"additionalProperties":false}},"reports":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"status":{"type":"string"},"digest":{"type":"string"},"revision":{"type":"integer"},"reportRef":{"type":"string"},"providerReference":{"type":"string"},"fromDate":{"type":"string"},"toDate":{"type":"string"},"currency":{"type":"string"},"totalMinor":{"type":"integer"},"evidenceArtifact":{"type":"object","properties":{"id":{"type":"string"},"campaignId":{"type":"string"},"sha256":{"type":"string"},"byteSize":{"type":"integer"},"mediaType":{"type":"string"},"fileName":{"type":"string"},"uploadedBy":{"type":"string"},"uploadedActor":{"type":"string"},"uploadedSource":{"type":"string"},"uploadedAt":{"type":"string"},"uploadedClientId":{"type":"string"}},"required":["id","campaignId","sha256","byteSize","mediaType","fileName","uploadedBy","uploadedActor","uploadedSource","uploadedAt"],"additionalProperties":false},"rows":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string"},"campaignId":{"type":"string"},"lineItemId":{"type":"string"},"impressions":{"type":"integer","minimum":0},"spendMinor":{"type":"integer","minimum":0},"currency":{"type":"string","enum":["GBP","USD","EUR"]},"reach":{"type":"integer","minimum":0},"geo":{"type":"string"},"placement":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string","minLength":1},"kind":{"type":"string","enum":["screen","app-channel","show","venue","attribute-package","network"]},"format":{"type":"string"},"owner":{"type":"string"},"location":{"type":"object","properties":{"city":{"type":"string"},"lat":{"type":"number"},"lng":{"type":"number"},"postcodeDistrict":{"type":"string"}},"required":["city"],"additionalProperties":true},"cpmMinor":{"type":"integer","exclusiveMinimum":0},"audienceMonthly":{"type":"integer","minimum":0},"externalId":{"type":"string"}},"required":["id","name"],"additionalProperties":true},"native":{"type":"object","additionalProperties":{"type":["string","number"]},"default":{}}},"required":["date","channel","adapterKey","campaignId","lineItemId","impressions","spendMinor","currency"],"additionalProperties":true}},"submittedAt":{"type":"string"},"submittedBy":{"type":"string"},"approvedAt":{"type":["string","null"]},"approvedBy":{"type":["string","null"]},"note":{"type":"string"},"approvalNote":{"type":["string","null"]}},"required":["id","status","digest","revision","reportRef","providerReference","fromDate","toDate","currency","totalMinor","evidenceArtifact","rows","submittedAt","submittedBy","approvedAt","approvedBy","note","approvalNote"],"additionalProperties":false}},"providerSpend":{"type":"object","properties":{"required":{"type":"boolean"},"due":{"type":"boolean"},"readyForFundRelease":{"type":"boolean"},"evidenceClosed":{"type":"boolean"},"reportThrough":{"type":"string"},"lines":{"type":"array","items":{"type":"object","properties":{"channelCampaignId":{"type":"string"},"state":{"type":"string"}},"required":["channelCampaignId","state"],"additionalProperties":true}}},"required":["required","due","readyForFundRelease","evidenceClosed","reportThrough","lines"],"additionalProperties":true},"reportWindow":{"anyOf":[{"type":"object","properties":{"fromDate":{"type":"string"},"toDate":{"type":"string"},"currency":{"type":"string"}},"required":["fromDate","toDate","currency"],"additionalProperties":true},{"type":"null"}]},"eligibility":{"type":"object","properties":{"ready":{"type":"boolean"},"blockers":{"type":"array","items":{"type":"string"}}},"required":["ready","blockers"],"additionalProperties":true},"fundsReleased":{"type":"boolean"}},"required":["artifacts","reports","providerSpend","reportWindow","eligibility","fundsReleased"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/finance/artifacts":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_finance_artifacts","summary":"Store immutable supplier report or invoice evidence","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"fileName":{"type":"string","minLength":1,"maxLength":200},"mediaType":{"type":"string","enum":["application/pdf","text/csv","application/json","application/vnd.ms-excel","application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"]},"contentBase64":{"type":"string","minLength":1,"maxLength":2796204}},"required":["fileName","mediaType","contentBase64"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"artifact":{"type":"object","properties":{"id":{"type":"string"},"campaignId":{"type":"string"},"sha256":{"type":"string"},"byteSize":{"type":"integer"},"mediaType":{"type":"string"},"fileName":{"type":"string"},"uploadedBy":{"type":"string"},"uploadedActor":{"type":"string"},"uploadedSource":{"type":"string"},"uploadedAt":{"type":"string"},"uploadedClientId":{"type":"string"}},"required":["id","campaignId","sha256","byteSize","mediaType","fileName","uploadedBy","uploadedActor","uploadedSource","uploadedAt"],"additionalProperties":false},"replayed":{"type":"boolean"}},"required":["artifact","replayed"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments","x-body-limit-bytes":2800300}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/finance/artifacts/{artifactId}":{"get":{"operationId":"get_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_finance_artifacts_artifactId","summary":"Download original campaign-owned supplier evidence","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"artifactId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/pdf":{"schema":{"type":"string"}},"text/csv":{"schema":{"type":"string"}},"application/json":{"schema":{}},"application/vnd.ms-excel":{"schema":{"type":"string"}},"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/finance/reconciliations":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_finance_reconciliations","summary":"Independently compare separate supplier invoice with exact approved delivery","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"providerAccountRef":{"type":"string","minLength":1,"maxLength":500},"evidenceKind":{"type":"string","enum":["invoice","account-export"]},"evidenceRef":{"type":"string","minLength":1,"maxLength":500},"evidenceArtifactId":{"type":"string","pattern":"^psa-[a-f0-9]{64}$"},"note":{"type":"string","minLength":1,"maxLength":2000},"providerTotalMinor":{"type":"integer","minimum":0,"maximum":2147483647},"expectedDeliveryDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"}},"required":["providerAccountRef","evidenceKind","evidenceRef","evidenceArtifactId","note","providerTotalMinor","expectedDeliveryDigest"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"reconciliation":{"type":"object","properties":{"id":{"type":"string"},"campaignId":{"type":"string"},"channelCampaignId":{"type":"string"},"liveExecutionGrantId":{"type":"string"},"adapterKey":{"type":"string"},"providerAccountRef":{"type":"string"},"evidenceKind":{"type":"string"},"evidenceRef":{"type":"string"},"evidenceArtifactId":{"type":"string"},"evidenceArtifactDigest":{"type":"string"},"legacyEvidenceArtifact":{"type":"string"},"evidenceArtifact":{"type":"object","properties":{"id":{"type":"string"},"campaignId":{"type":"string"},"sha256":{"type":"string"},"byteSize":{"type":"integer"},"mediaType":{"type":"string"},"fileName":{"type":"string"},"uploadedBy":{"type":"string"},"uploadedActor":{"type":"string"},"uploadedSource":{"type":"string"},"uploadedAt":{"type":"string"},"uploadedClientId":{"type":"string"}},"required":["id","campaignId","sha256","byteSize","mediaType","fileName","uploadedBy","uploadedActor","uploadedSource","uploadedAt"],"additionalProperties":false},"note":{"type":"string"},"fromDate":{"type":"string"},"toDate":{"type":"string"},"currency":{"type":"string"},"providerTotalMinor":{"type":"integer"},"chorusTotalMinor":{"type":"integer"},"deliveryDigest":{"type":"string"},"outcome":{"type":"string"},"revision":{"type":"integer"},"recordedAt":{"type":"string"},"recordedBy":{"type":"string"},"recordedActor":{"type":"string"},"recordedSource":{"type":"string"},"recordedClientId":{"type":"string"},"providerAccountRefAuthority":{"type":"string"},"deliveryAccountIdentityControl":{"type":"string"}},"required":["id","campaignId","channelCampaignId","liveExecutionGrantId","adapterKey","providerAccountRef","evidenceKind","evidenceRef","note","fromDate","toDate","currency","providerTotalMinor","chorusTotalMinor","deliveryDigest","outcome","revision","recordedAt","recordedBy","recordedActor","recordedSource","providerAccountRefAuthority","deliveryAccountIdentityControl"],"additionalProperties":false},"replayed":{"type":"boolean"},"fundsReleased":{"type":"boolean","const":false}},"required":["reconciliation","replayed","fundsReleased"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/finance/reports":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_finance_reports","summary":"Submit normalized final supplier report for independent review","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"evidenceArtifactId":{"type":"string","pattern":"^psa-[a-f0-9]{64}$"},"reportRef":{"type":"string","minLength":1,"maxLength":500},"providerReference":{"type":"string","minLength":1,"maxLength":500},"fromDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"toDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"rows":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"geo":{"type":"string","maxLength":200},"impressions":{"type":"integer","minimum":0,"maximum":2147483647},"spendMinor":{"type":"integer","minimum":0,"maximum":2147483647},"reach":{"type":"integer","minimum":0,"maximum":2147483647},"placement":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string","minLength":1},"kind":{"type":"string","enum":["screen","app-channel","show","venue","attribute-package","network"]},"format":{"type":"string"},"owner":{"type":"string"},"location":{"type":"object","properties":{"city":{"type":"string"},"lat":{"type":"number"},"lng":{"type":"number"},"postcodeDistrict":{"type":"string"}},"required":["city"],"additionalProperties":false},"cpmMinor":{"type":"integer","exclusiveMinimum":0},"audienceMonthly":{"type":"integer","minimum":0},"externalId":{"type":"string"}},"required":["id","name"],"additionalProperties":false}},"required":["date","impressions","spendMinor"],"additionalProperties":false},"minItems":1,"maxItems":5000},"note":{"type":"string","minLength":10,"maxLength":2000}},"required":["evidenceArtifactId","reportRef","providerReference","fromDate","toDate","rows","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"report":{"type":"object","properties":{"id":{"type":"string"},"status":{"type":"string"},"digest":{"type":"string"},"revision":{"type":"integer"},"reportRef":{"type":"string"},"providerReference":{"type":"string"},"fromDate":{"type":"string"},"toDate":{"type":"string"},"currency":{"type":"string"},"totalMinor":{"type":"integer"},"evidenceArtifact":{"type":"object","properties":{"id":{"type":"string"},"campaignId":{"type":"string"},"sha256":{"type":"string"},"byteSize":{"type":"integer"},"mediaType":{"type":"string"},"fileName":{"type":"string"},"uploadedBy":{"type":"string"},"uploadedActor":{"type":"string"},"uploadedSource":{"type":"string"},"uploadedAt":{"type":"string"},"uploadedClientId":{"type":"string"}},"required":["id","campaignId","sha256","byteSize","mediaType","fileName","uploadedBy","uploadedActor","uploadedSource","uploadedAt"],"additionalProperties":false},"rows":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string"},"campaignId":{"type":"string"},"lineItemId":{"type":"string"},"impressions":{"type":"integer","minimum":0},"spendMinor":{"type":"integer","minimum":0},"currency":{"type":"string","enum":["GBP","USD","EUR"]},"reach":{"type":"integer","minimum":0},"geo":{"type":"string"},"placement":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string","minLength":1},"kind":{"type":"string","enum":["screen","app-channel","show","venue","attribute-package","network"]},"format":{"type":"string"},"owner":{"type":"string"},"location":{"type":"object","properties":{"city":{"type":"string"},"lat":{"type":"number"},"lng":{"type":"number"},"postcodeDistrict":{"type":"string"}},"required":["city"],"additionalProperties":true},"cpmMinor":{"type":"integer","exclusiveMinimum":0},"audienceMonthly":{"type":"integer","minimum":0},"externalId":{"type":"string"}},"required":["id","name"],"additionalProperties":true},"native":{"type":"object","additionalProperties":{"type":["string","number"]},"default":{}}},"required":["date","channel","adapterKey","campaignId","lineItemId","impressions","spendMinor","currency"],"additionalProperties":true}},"submittedAt":{"type":"string"},"submittedBy":{"type":"string"},"approvedAt":{"type":["string","null"]},"approvedBy":{"type":["string","null"]},"note":{"type":"string"},"approvalNote":{"type":["string","null"]}},"required":["id","status","digest","revision","reportRef","providerReference","fromDate","toDate","currency","totalMinor","evidenceArtifact","rows","submittedAt","submittedBy","approvedAt","approvedBy","note","approvalNote"],"additionalProperties":false},"replayed":{"type":"boolean"},"fundsReleased":{"type":"boolean","const":false}},"required":["report","replayed","fundsReleased"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/finance/reports/{reportId}/approve":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_finance_reports_reportId_approve","summary":"Approve exact supplier report and settle actual delivery fees","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"reportId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"note":{"type":"string","minLength":10,"maxLength":2000}},"required":["expectedDigest","note"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"report":{"type":"object","properties":{"id":{"type":"string"},"status":{"type":"string"},"digest":{"type":"string"},"revision":{"type":"integer"},"reportRef":{"type":"string"},"providerReference":{"type":"string"},"fromDate":{"type":"string"},"toDate":{"type":"string"},"currency":{"type":"string"},"totalMinor":{"type":"integer"},"evidenceArtifact":{"type":"object","properties":{"id":{"type":"string"},"campaignId":{"type":"string"},"sha256":{"type":"string"},"byteSize":{"type":"integer"},"mediaType":{"type":"string"},"fileName":{"type":"string"},"uploadedBy":{"type":"string"},"uploadedActor":{"type":"string"},"uploadedSource":{"type":"string"},"uploadedAt":{"type":"string"},"uploadedClientId":{"type":"string"}},"required":["id","campaignId","sha256","byteSize","mediaType","fileName","uploadedBy","uploadedActor","uploadedSource","uploadedAt"],"additionalProperties":false},"rows":{"type":"array","items":{"type":"object","properties":{"date":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string"},"campaignId":{"type":"string"},"lineItemId":{"type":"string"},"impressions":{"type":"integer","minimum":0},"spendMinor":{"type":"integer","minimum":0},"currency":{"type":"string","enum":["GBP","USD","EUR"]},"reach":{"type":"integer","minimum":0},"geo":{"type":"string"},"placement":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string","minLength":1},"kind":{"type":"string","enum":["screen","app-channel","show","venue","attribute-package","network"]},"format":{"type":"string"},"owner":{"type":"string"},"location":{"type":"object","properties":{"city":{"type":"string"},"lat":{"type":"number"},"lng":{"type":"number"},"postcodeDistrict":{"type":"string"}},"required":["city"],"additionalProperties":true},"cpmMinor":{"type":"integer","exclusiveMinimum":0},"audienceMonthly":{"type":"integer","minimum":0},"externalId":{"type":"string"}},"required":["id","name"],"additionalProperties":true},"native":{"type":"object","additionalProperties":{"type":["string","number"]},"default":{}}},"required":["date","channel","adapterKey","campaignId","lineItemId","impressions","spendMinor","currency"],"additionalProperties":true}},"submittedAt":{"type":"string"},"submittedBy":{"type":"string"},"approvedAt":{"type":["string","null"]},"approvedBy":{"type":["string","null"]},"note":{"type":"string"},"approvalNote":{"type":["string","null"]}},"required":["id","status","digest","revision","reportRef","providerReference","fromDate","toDate","currency","totalMinor","evidenceArtifact","rows","submittedAt","submittedBy","approvedAt","approvedBy","note","approvalNote"],"additionalProperties":false},"replayed":{"type":"boolean"},"fundsReleased":{"type":"boolean","const":false}},"required":["report","replayed","fundsReleased"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/reject":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_reject","summary":"Run internal / fulfilment / bookings / lines / reject","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"evidence":{"type":"string","minLength":10,"maxLength":20000},"notAppliedConfirmed":{"type":"boolean","const":true}},"required":["expectedVersion","evidence","notAppliedConfirmed"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/start":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_start","summary":"Run internal / fulfilment / bookings / lines / start","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"executionMethod":{"type":"string","enum":["manual","computer-use"]}},"required":["expectedVersion","executionMethod"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/stop-not-applied":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_stop_not_applied","summary":"Run internal / fulfilment / bookings / lines / stop not applied","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"evidence":{"type":"string","minLength":10,"maxLength":20000},"notAppliedConfirmed":{"type":"boolean","const":true}},"required":["expectedVersion","evidence","notAppliedConfirmed"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/stop-start":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_stop_start","summary":"Run internal / fulfilment / bookings / lines / stop start","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"executionMethod":{"type":"string","enum":["manual","computer-use"]}},"required":["expectedVersion","executionMethod"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/stopped":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_stopped","summary":"Run internal / fulfilment / bookings / lines / stopped","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"providerReference":{"type":"string","minLength":1,"maxLength":500},"evidence":{"type":"string","minLength":10,"maxLength":20000}},"required":["expectedVersion","providerReference","evidence"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/fulfilment/bookings/{bookingId}/lines/{lineId}/uncertain":{"post":{"operationId":"post_api_v1_internal_fulfilment_bookings_bookingId_lines_lineId_uncertain","summary":"Run internal / fulfilment / bookings / lines / uncertain","description":"Internal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"evidence":{"type":"string","minLength":10,"maxLength":20000}},"required":["expectedVersion","evidence"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"booking":{"type":"object","properties":{"id":{"type":"string","minLength":1},"advertiserId":{"type":"string","minLength":1},"campaignId":{"type":"string","minLength":1},"campaignName":{"type":"string"},"client":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false},"campaignStatus":{"type":"string","minLength":1},"closeoutPending":{"type":"boolean"},"flightEnded":{"type":"boolean"},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","partially-confirmed","rejected","stopping","stopped"]},"submittedAt":{"type":"string","format":"date-time"},"confirmationDueAt":{"type":"string","format":"date-time"},"overdue":{"type":"boolean"},"startDate":{"type":"string"},"endDate":{"type":"string"},"executionMode":{"type":"string","enum":["sandbox","live"]},"mediaBudgetMinor":{"type":"integer","minimum":0},"maximumCommitmentMinor":{"type":"integer","minimum":0},"currency":{"type":"string","const":"GBP"},"snapshotDigest":{"type":"string","pattern":"^[a-f0-9]{64}$"},"approvedSnapshot":{},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"channelCampaignId":{"type":"string","minLength":1},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"budgetMinor":{"type":"integer","minimum":0},"executionMode":{"type":"string","enum":["sandbox","live"]},"version":{"type":"integer","minimum":0},"status":{"type":"string","enum":["queued","in-progress","confirmed","rejected","reconciliation-required","stop-requested","stopping","stopped"]},"executionMethod":{"anyOf":[{"type":"string","enum":["manual","computer-use"]},{"type":"null"}]},"providerReference":{"type":["string","null"]},"evidence":{"type":["string","null"]},"claimedBy":{"type":["string","null"]},"assignedToUserId":{"anyOf":[{"type":"string","format":"uuid"},{"type":"null"}]},"assignedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"startedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"confirmedAt":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}]},"providerAttemptId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"creatives":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"},"format":{"type":"string","minLength":1},"assetUrl":{"type":"string"},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["id","name","format","assetUrl","assetFingerprint"],"additionalProperties":true}}},"required":["id","channelCampaignId","channel","adapterKey","budgetMinor","executionMode","version","status","executionMethod","providerReference","evidence","claimedBy","assignedToUserId","assignedAt","startedAt","confirmedAt","providerAttemptId","creatives"],"additionalProperties":true}},"events":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"bookingId":{"type":"string","minLength":1},"lineId":{"anyOf":[{"type":"string","minLength":1},{"type":"null"}]},"action":{"type":"string","minLength":1},"actorId":{"type":"string","minLength":1},"actor":{"type":"string","enum":["human","agent","system"]},"source":{"type":"string","enum":["dev","web","mcp","system"]},"detail":{},"createdAt":{"type":"string","format":"date-time"}},"required":["id","bookingId","lineId","action","actorId","actor","source","createdAt"],"additionalProperties":true}}},"required":["id","advertiserId","campaignId","campaignName","client","campaignStatus","closeoutPending","flightEnded","version","status","submittedAt","confirmationDueAt","overdue","startDate","endDate","executionMode","mediaBudgetMinor","maximumCommitmentMinor","currency","snapshotDigest","lines","events"],"additionalProperties":true}},"required":["booking"],"additionalProperties":false}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/internal/session":{"get":{"operationId":"get_api_v1_internal_session","summary":"Read internal staff access","description":"Returns no staff or client identifiers to ordinary customers. Staff membership and explicit client assignments are server-owned and revocable.\n\nInternal staff surface. Client data is restricted to explicit server-owned customer assignments; inaccessible resources return 404. Product/channel entitlements also apply.\n\nRequires a verified Supabase human web session and active, revocable database-owned staff membership. Customer operator permissions, request headers and delegated agents cannot grant staff access. The session endpoint returns access:false to nonstaff without staff or customer identifiers.","tags":["Internal"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"anyOf":[{"type":"object","properties":{"access":{"type":"boolean","const":false}},"required":["access"],"additionalProperties":false},{"type":"object","properties":{"access":{"type":"boolean","const":true},"staff":{"type":"object","properties":{"id":{"type":"string","minLength":1},"userId":{"type":"string","format":"uuid"},"name":{"type":"string"}},"required":["id","userId","name"],"additionalProperties":false},"clients":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"name":{"type":"string"}},"required":["id","name"],"additionalProperties":false}},"assignees":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string","minLength":1},"userId":{"type":"string","format":"uuid"},"name":{"type":"string"},"advertiserIds":{"type":"array","items":{"type":"string","minLength":1}}},"required":["id","userId","name","advertiserIds"],"additionalProperties":false}},"billing":{"type":"object","properties":{"paidActionsEnabled":{"type":"boolean"},"mode":{"type":"string","enum":["disabled","sandbox","stripe","stripe-test","pilot"]}},"required":["paidActionsEnabled","mode"],"additionalProperties":false}},"required":["access","staff","clients","assignees","billing"],"additionalProperties":false}]}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":[],"x-internal-staff-only":true,"x-staff-authority":"server-owned revocable membership and explicit client assignments"}},"/api/v1/inventory":{"get":{"operationId":"get_api_v1_inventory","summary":"Browse inventory for one channel","description":"Returns inventory from the authenticated advertiser’s configured adapters. Filters combine with AND; comma-separated tags combine with OR. Modeled sandbox inventory does not prove current live availability.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Inventory"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"channel","in":"query","required":true,"schema":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"style":"form","explode":true},{"name":"city","in":"query","required":false,"schema":{"type":"string"},"style":"form","explode":true},{"name":"query","in":"query","required":false,"schema":{"type":"string"},"style":"form","explode":true},{"name":"tags","in":"query","required":false,"schema":{"type":"string"},"style":"form","explode":true},{"name":"maxCpmMinor","in":"query","required":false,"schema":{"type":"integer","exclusiveMinimum":0},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"adapterKey":{"type":"string"},"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"name":{"type":"string"},"kind":{"type":"string","enum":["screen","app-channel","show","venue","attribute-package","network"]},"location":{"type":"object","properties":{"city":{"type":"string"},"lat":{"type":"number"},"lng":{"type":"number"},"postcodeDistrict":{"type":"string"}},"required":["city"],"additionalProperties":true},"format":{"type":"string"},"audienceMonthly":{"type":"integer","minimum":0},"cpmMinor":{"type":"integer","exclusiveMinimum":0},"currency":{"type":"string","enum":["GBP","USD","EUR"]},"owner":{"type":"string"},"tags":{"type":"array","items":{"type":"string"},"default":[]}},"required":["id","adapterKey","channel","name","kind","cpmMinor","currency"],"additionalProperties":true}},"count":{"type":"integer","minimum":0}},"required":["items","count"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/measurement/mmm":{"post":{"operationId":"post_api_v1_measurement_mmm","summary":"Run measurement / mmm","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Measurement"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"grain":{"type":"string","enum":["channel","campaign-channel"],"default":"channel"},"outcome":{"type":"string","enum":["conversion","pageview"],"default":"conversion"}},"additionalProperties":false,"default":{}}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/measurement/mmm/readiness":{"get":{"operationId":"get_api_v1_measurement_mmm_readiness","summary":"Read measurement / mmm / readiness","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Measurement"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"grain","in":"query","required":false,"schema":{"type":"string","enum":["channel","campaign-channel"],"default":"channel"},"style":"form","explode":true},{"name":"outcome","in":"query","required":false,"schema":{"type":"string","enum":["conversion","pageview"],"default":"conversion"},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/meta":{"get":{"operationId":"get_api_v1_meta","summary":"Read product identity and connection metadata","description":"Public product identity, channel scope, sandbox adapter count and configured MCP connection metadata. This is not a live supplier readiness attestation.\n\nPublic endpoint; tenant data is not exposed by discovery endpoints.","tags":["Meta"],"security":[],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string"},"product":{"type":"object","properties":{},"additionalProperties":true},"version":{"type":"string"},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]}},"adapterCount":{"type":"integer","minimum":0},"apiUrl":{"type":"string"},"mcp":{"type":"object","properties":{},"additionalProperties":true}},"required":["name","product","version","channels","adapterCount","mcp"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/openapi.json":{"get":{"operationId":"get_api_v1_openapi_json","summary":"Download the product-scoped OpenAPI specification","description":"Public machine-readable API reference. This document contains no tenant records, credentials or live supplier data.\n\nPublic endpoint; tenant data is not exposed by discovery endpoints.","tags":["Openapi.json"],"security":[],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/operator/bookings":{"get":{"operationId":"get_api_v1_operator_bookings","summary":"Read operator / bookings","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"cursor","in":"query","required":false,"schema":{"type":"string","minLength":1},"style":"form","explode":true},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":50},"style":"form","explode":true},{"name":"status","in":"query","required":false,"schema":{"type":"string","enum":["active","all"],"default":"active"},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/operator/bookings/{bookingId}":{"get":{"operationId":"get_api_v1_operator_bookings_bookingId","summary":"Read operator / bookings","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/operator/bookings/{bookingId}/lines/{lineId}/confirm":{"post":{"operationId":"post_api_v1_operator_bookings_bookingId_lines_lineId_confirm","summary":"Run operator / bookings / lines / confirm","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"providerReference":{"type":"string","minLength":1,"maxLength":500},"evidence":{"type":"string","minLength":10,"maxLength":20000},"creativeReferences":{"type":"array","items":{"type":"object","properties":{"creativeId":{"type":"string","minLength":1},"externalCreativeRef":{"type":"string","minLength":1,"maxLength":500},"assetFingerprint":{"type":"string","pattern":"^sha256:[a-f0-9]{64}$"}},"required":["creativeId","externalCreativeRef","assetFingerprint"],"additionalProperties":false},"minItems":1,"maxItems":100}},"required":["expectedVersion","providerReference","evidence","creativeReferences"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/operator/bookings/{bookingId}/lines/{lineId}/reject":{"post":{"operationId":"post_api_v1_operator_bookings_bookingId_lines_lineId_reject","summary":"Run operator / bookings / lines / reject","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"evidence":{"type":"string","minLength":10,"maxLength":20000},"notAppliedConfirmed":{"type":"boolean","const":true}},"required":["expectedVersion","evidence","notAppliedConfirmed"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/operator/bookings/{bookingId}/lines/{lineId}/start":{"post":{"operationId":"post_api_v1_operator_bookings_bookingId_lines_lineId_start","summary":"Run operator / bookings / lines / start","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"executionMethod":{"type":"string","enum":["manual","computer-use"]}},"required":["expectedVersion","executionMethod"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/operator/bookings/{bookingId}/lines/{lineId}/stop-not-applied":{"post":{"operationId":"post_api_v1_operator_bookings_bookingId_lines_lineId_stop_not_applied","summary":"Run operator / bookings / lines / stop not applied","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"evidence":{"type":"string","minLength":10,"maxLength":20000},"notAppliedConfirmed":{"type":"boolean","const":true}},"required":["expectedVersion","evidence","notAppliedConfirmed"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/operator/bookings/{bookingId}/lines/{lineId}/stop-start":{"post":{"operationId":"post_api_v1_operator_bookings_bookingId_lines_lineId_stop_start","summary":"Run operator / bookings / lines / stop start","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"executionMethod":{"type":"string","enum":["manual","computer-use"]}},"required":["expectedVersion","executionMethod"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/operator/bookings/{bookingId}/lines/{lineId}/stopped":{"post":{"operationId":"post_api_v1_operator_bookings_bookingId_lines_lineId_stopped","summary":"Run operator / bookings / lines / stopped","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"providerReference":{"type":"string","minLength":1,"maxLength":500},"evidence":{"type":"string","minLength":10,"maxLength":20000}},"required":["expectedVersion","providerReference","evidence"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/operator/bookings/{bookingId}/lines/{lineId}/uncertain":{"post":{"operationId":"post_api_v1_operator_bookings_bookingId_lines_lineId_uncertain","summary":"Run operator / bookings / lines / uncertain","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nRequires an authenticated human with operator:reconcile permission. Delegated agents cannot perform this operator action.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Operator"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"bookingId","in":"path","required":true,"schema":{"type":"string","minLength":1}},{"name":"lineId","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedVersion":{"type":"integer","minimum":0},"evidence":{"type":"string","minLength":10,"maxLength":20000}},"required":["expectedVersion","evidence"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-human-only":true,"x-required-human-permissions":["operator:reconcile"]}},"/api/v1/optimizations":{"get":{"operationId":"get_api_v1_optimizations","summary":"Read optimizations","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Optimizations"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"campaignId","in":"query","required":false,"schema":{"type":"string"},"style":"form","explode":true},{"name":"status","in":"query","required":false,"schema":{"type":"string"},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/optimizations/{id}/approve":{"post":{"operationId":"post_api_v1_optimizations_id_approve","summary":"Run optimizations / approve","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: optimization.approve. { optimizationId } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.","tags":["Optimizations"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"optimization.approve","budgetPolicy":"zero","parameterContract":"{ optimizationId }","exactApprovalRequired":true}}},"/api/v1/optimizations/{id}/reject":{"post":{"operationId":"post_api_v1_optimizations_id_reject","summary":"Run optimizations / reject","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: optimization.reject. { optimizationId } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.","tags":["Optimizations"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"optimization.reject","budgetPolicy":"zero","parameterContract":"{ optimizationId }","exactApprovalRequired":true}}},"/api/v1/personas":{"get":{"operationId":"get_api_v1_personas","summary":"Read personas","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Personas"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"personas":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"version":{"type":"integer","minimum":1,"default":1},"name":{"type":"string"},"nlDescription":{"type":"string"},"semanticCore":{"type":"object","properties":{"geo":{"type":"object","properties":{"countries":{"type":"array","items":{"type":"string"},"default":["GB"]},"cities":{"type":"array","items":{"type":"string"},"default":[]},"postcodeDistricts":{"type":"array","items":{"type":"string"},"default":[]},"tvRegions":{"type":"array","items":{"type":"string"},"default":[]}},"additionalProperties":true},"demographics":{"type":"object","properties":{"ageMin":{"type":"integer","minimum":16,"maximum":99},"ageMax":{"type":"integer","minimum":16,"maximum":99},"gender":{"type":"string","enum":["any","male","female"],"default":"any"},"incomeBand":{"type":"string","enum":["any","mid","high"],"default":"any"}},"additionalProperties":true},"firmographics":{"type":"object","properties":{"sicCodes":{"type":"array","items":{"type":"string"},"default":[]},"seniority":{"type":"array","items":{"type":"string","enum":["c-suite","vp","director","manager","ic"]},"default":[]},"companySize":{"type":"string","enum":["any","smb","mid","enterprise"],"default":"any"}},"additionalProperties":true},"intentTopics":{"type":"array","items":{"type":"string"},"default":[]},"interests":{"type":"array","items":{"type":"string"},"default":[]},"exclusions":{"type":"array","items":{"type":"string"},"default":[]},"searchNegativeKeywords":{"type":"array","items":{"type":"string","minLength":1}},"unresolvedConstraints":{"type":"array","items":{"type":"string","minLength":1}}},"required":["geo"],"additionalProperties":true},"confidence":{"type":"object","additionalProperties":{"type":"number","minimum":0,"maximum":1},"default":{}},"createdAt":{"type":"string","format":"date-time"}},"required":["id","name","nlDescription","semanticCore"],"additionalProperties":true}}},"required":["personas"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/personas/{id}":{"delete":{"operationId":"delete_api_v1_personas_id","summary":"Delete personas","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Personas"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"204":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}}},"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"get":{"operationId":"get_api_v1_personas_id","summary":"Read personas","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Personas"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"persona":{"type":"object","properties":{"id":{"type":"string"},"version":{"type":"integer","minimum":1,"default":1},"name":{"type":"string"},"nlDescription":{"type":"string"},"semanticCore":{"type":"object","properties":{"geo":{"type":"object","properties":{"countries":{"type":"array","items":{"type":"string"},"default":["GB"]},"cities":{"type":"array","items":{"type":"string"},"default":[]},"postcodeDistricts":{"type":"array","items":{"type":"string"},"default":[]},"tvRegions":{"type":"array","items":{"type":"string"},"default":[]}},"additionalProperties":true},"demographics":{"type":"object","properties":{"ageMin":{"type":"integer","minimum":16,"maximum":99},"ageMax":{"type":"integer","minimum":16,"maximum":99},"gender":{"type":"string","enum":["any","male","female"],"default":"any"},"incomeBand":{"type":"string","enum":["any","mid","high"],"default":"any"}},"additionalProperties":true},"firmographics":{"type":"object","properties":{"sicCodes":{"type":"array","items":{"type":"string"},"default":[]},"seniority":{"type":"array","items":{"type":"string","enum":["c-suite","vp","director","manager","ic"]},"default":[]},"companySize":{"type":"string","enum":["any","smb","mid","enterprise"],"default":"any"}},"additionalProperties":true},"intentTopics":{"type":"array","items":{"type":"string"},"default":[]},"interests":{"type":"array","items":{"type":"string"},"default":[]},"exclusions":{"type":"array","items":{"type":"string"},"default":[]},"searchNegativeKeywords":{"type":"array","items":{"type":"string","minLength":1}},"unresolvedConstraints":{"type":"array","items":{"type":"string","minLength":1}}},"required":["geo"],"additionalProperties":true},"confidence":{"type":"object","additionalProperties":{"type":"number","minimum":0,"maximum":1},"default":{}},"createdAt":{"type":"string","format":"date-time"}},"required":["id","name","nlDescription","semanticCore"],"additionalProperties":true}},"required":["persona"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"patch":{"operationId":"patch_api_v1_personas_id","summary":"Update personas","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Personas"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1},"nlDescription":{"type":"string","minLength":3},"semanticCore":{"type":"object","properties":{"geo":{"type":"object","properties":{"countries":{"type":"array","items":{"type":"string"},"default":["GB"]},"cities":{"type":"array","items":{"type":"string"},"default":[]},"postcodeDistricts":{"type":"array","items":{"type":"string"},"default":[]},"tvRegions":{"type":"array","items":{"type":"string"},"default":[]}},"additionalProperties":false},"demographics":{"type":"object","properties":{"ageMin":{"type":"integer","minimum":16,"maximum":99},"ageMax":{"type":"integer","minimum":16,"maximum":99},"gender":{"type":"string","enum":["any","male","female"],"default":"any"},"incomeBand":{"type":"string","enum":["any","mid","high"],"default":"any"}},"additionalProperties":false},"firmographics":{"type":"object","properties":{"sicCodes":{"type":"array","items":{"type":"string"},"default":[]},"seniority":{"type":"array","items":{"type":"string","enum":["c-suite","vp","director","manager","ic"]},"default":[]},"companySize":{"type":"string","enum":["any","smb","mid","enterprise"],"default":"any"}},"additionalProperties":false},"intentTopics":{"type":"array","items":{"type":"string"},"default":[]},"interests":{"type":"array","items":{"type":"string"},"default":[]},"exclusions":{"type":"array","items":{"type":"string"},"default":[]},"searchNegativeKeywords":{"type":"array","items":{"type":"string","minLength":1}},"unresolvedConstraints":{"type":"array","items":{"type":"string","minLength":1}}},"required":["geo"],"additionalProperties":false}},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/personas/{id}/compile":{"post":{"operationId":"post_api_v1_personas_id_compile","summary":"Compile persona targeting for the product channels","description":"Returns each permitted channel targeting specification, fidelity, lawful-basis manifest and coverage. Modeled catalogue matches are not supplier-confirmed audiences.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Personas"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"personaId":{"type":"string"},"compiled":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"spec":{"anyOf":[{"type":"object","properties":{"channel":{"type":"string","const":"ctv"},"euidAudienceIds":{"type":"array","items":{"type":"string"},"default":[]},"marketplaceSegmentIds":{"type":"array","items":{"type":"string"},"default":[]},"geoCities":{"type":"array","items":{"type":"string"},"default":[]},"frequencyCapPerWeek":{"type":"integer","minimum":1},"dealIds":{"type":"array","items":{"type":"string"},"default":[]},"ageMin":{"type":"integer","minimum":16},"ageMax":{"type":"integer","maximum":99},"gender":{"type":"string","enum":["any","male","female"],"default":"any"}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"audio"},"showAllowlist":{"type":"array","items":{"type":"string"},"default":[]},"genres":{"type":"array","items":{"type":"string"},"default":[]},"publisherSegments":{"type":"array","items":{"type":"string"},"default":[]},"geoCities":{"type":"array","items":{"type":"string"},"default":[]},"dayparts":{"type":"array","items":{"type":"string","enum":["breakfast","commute-am","daytime","commute-pm","evening"]},"default":[]},"pmpDealSpecs":{"type":"array","items":{"type":"string"},"default":[]}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"tv"},"adsmartAttributes":{"type":"array","items":{"type":"string"},"default":[]},"postcodeDistricts":{"type":"array","items":{"type":"string"},"default":[]},"universalAdsAudience":{"type":"string","enum":["custom-csv","pixel-lookalike","none"],"default":"none"},"tvRegions":{"type":"array","items":{"type":"string"},"default":[]}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"cinema"},"agpPacks":{"type":"array","items":{"type":"string"},"default":[]},"venueIds":{"type":"array","items":{"type":"string"},"default":[]},"filmGenres":{"type":"array","items":{"type":"string"},"default":[]},"weeks":{"type":"integer","minimum":1,"default":2}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"dooh"},"audienceSegmentIds":{"type":"array","items":{"type":"string"},"default":[]},"venueTypes":{"type":"array","items":{"type":"string"},"default":[]},"geoPolygonRefs":{"type":"array","items":{"type":"string"},"default":[]},"dayparts":{"type":"array","items":{"type":"string"},"default":[]},"screenRankings":{"type":"array","items":{"type":"object","properties":{"screenId":{"type":"string"},"overIndex":{"type":"number"}},"required":["screenId","overIndex"],"additionalProperties":true},"default":[]}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"search"},"seedKeywords":{"type":"array","items":{"type":"string","minLength":1,"maxLength":80},"maxItems":20,"default":[]},"negativeKeywords":{"type":"array","items":{"type":"string","minLength":1,"maxLength":80},"maxItems":50,"default":[]},"geoCities":{"type":"array","items":{"type":"string"},"default":[]},"language":{"type":"string","default":"en"},"matchTypes":{"type":"array","items":{"type":"string","enum":["exact","phrase","broad"]},"minItems":1,"default":["exact","phrase"]},"network":{"type":"string","enum":["search-only","search-partners"],"default":"search-only"}},"required":["channel"],"additionalProperties":true},{"type":"object","properties":{"channel":{"type":"string","const":"social"},"interestTerms":{"type":"array","items":{"type":"string","minLength":1},"maxItems":50,"default":[]},"geoCities":{"type":"array","items":{"type":"string"},"default":[]},"ageMin":{"type":"integer","minimum":16,"maximum":99},"ageMax":{"type":"integer","minimum":16,"maximum":99},"gender":{"type":"string","enum":["any","male","female"],"default":"any"},"placements":{"type":"array","items":{"type":"string","enum":["feed","stories","reels","search","video"]},"default":["feed","stories","reels"]},"optimizationGoal":{"type":"string","enum":["unset","reach","traffic","conversions"],"default":"unset"}},"required":["channel"],"additionalProperties":true}]},"fidelity":{"type":"object","properties":{"score":{"type":"number","minimum":0,"maximum":100},"grade":{"type":"string","enum":["person","household","content","venue","geo-cohort"]},"rationale":{"type":"string"}},"required":["score","grade","rationale"],"additionalProperties":true},"lawfulBasisManifest":{"type":"array","items":{"type":"object","properties":{"element":{"type":"string"},"basis":{"type":"string","enum":["consent-chained","legitimate-interest","outside-scope"]},"source":{"type":"string"},"note":{"type":"string"}},"required":["element","basis","source"],"additionalProperties":true}},"warnings":{"type":"array","items":{"type":"string"},"default":[]},"coverage":{"type":"object","properties":{"requested":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string","enum":["country","city","postcode","tv-region","age","gender","income","industry","seniority","company-size","interest","intent","audience-exclusion","search-negative","unresolved"]},"value":{"type":"string"}},"required":["field","value"],"additionalProperties":true}},"supported":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string","enum":["country","city","postcode","tv-region","age","gender","income","industry","seniority","company-size","interest","intent","audience-exclusion","search-negative","unresolved"]},"value":{"type":"string"},"representation":{"type":"string"},"evidence":{"type":"string","enum":["semantic","modeled","provider-catalogue"]},"sourceIds":{"type":"array","items":{"type":"string"}}},"required":["field","value","representation","evidence","sourceIds"],"additionalProperties":true}},"unsupported":{"type":"array","items":{"type":"object","properties":{"field":{"type":"string","enum":["country","city","postcode","tv-region","age","gender","income","industry","seniority","company-size","interest","intent","audience-exclusion","search-negative","unresolved"]},"value":{"type":"string"},"reason":{"type":"string"}},"required":["field","value","reason"],"additionalProperties":true}},"requiresProviderValidation":{"type":"boolean"}},"required":["requested","supported","unsupported","requiresProviderValidation"],"additionalProperties":true}},"required":["channel","spec","fidelity","lawfulBasisManifest"],"additionalProperties":true}},"narration":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"headline":{"type":"string"},"plainEnglish":{"type":"string"},"grade":{"type":"string","enum":["person","household","content","venue","geo-cohort"]},"score":{"type":"number"}},"required":["channel","headline","plainEnglish","grade","score"],"additionalProperties":true}}},"required":["personaId","compiled","narration"],"additionalProperties":true}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/personas/extract":{"post":{"operationId":"post_api_v1_personas_extract","x-codeSamples":[{"lang":"Shell","label":"cURL","source":"curl --fail-with-body -X POST \"$ADBUY_API_URL/api/v1/personas/extract\" -H \"Authorization: Bearer $ADBUY_API_TOKEN\" -H \"Content-Type: application/json\" --data '{\"nlBrief\":\"Adults aged 25 to 44 in London who are interested in cycling.\"}'"}],"summary":"Extract a persona from a natural-language brief","description":"Creates a persona with structured geography, demographics, interests, intent and exclusions. Review low-confidence or unresolved constraints; extraction does not prove supplier audience availability.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Personas"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"nlBrief":{"type":"string","minLength":3}},"required":["nlBrief"],"additionalProperties":false},"example":{"nlBrief":"Adults aged 25 to 44 in London who are interested in cycling."}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"persona":{"type":"object","properties":{"id":{"type":"string"},"version":{"type":"integer","minimum":1,"default":1},"name":{"type":"string"},"nlDescription":{"type":"string"},"semanticCore":{"type":"object","properties":{"geo":{"type":"object","properties":{"countries":{"type":"array","items":{"type":"string"},"default":["GB"]},"cities":{"type":"array","items":{"type":"string"},"default":[]},"postcodeDistricts":{"type":"array","items":{"type":"string"},"default":[]},"tvRegions":{"type":"array","items":{"type":"string"},"default":[]}},"additionalProperties":true},"demographics":{"type":"object","properties":{"ageMin":{"type":"integer","minimum":16,"maximum":99},"ageMax":{"type":"integer","minimum":16,"maximum":99},"gender":{"type":"string","enum":["any","male","female"],"default":"any"},"incomeBand":{"type":"string","enum":["any","mid","high"],"default":"any"}},"additionalProperties":true},"firmographics":{"type":"object","properties":{"sicCodes":{"type":"array","items":{"type":"string"},"default":[]},"seniority":{"type":"array","items":{"type":"string","enum":["c-suite","vp","director","manager","ic"]},"default":[]},"companySize":{"type":"string","enum":["any","smb","mid","enterprise"],"default":"any"}},"additionalProperties":true},"intentTopics":{"type":"array","items":{"type":"string"},"default":[]},"interests":{"type":"array","items":{"type":"string"},"default":[]},"exclusions":{"type":"array","items":{"type":"string"},"default":[]},"searchNegativeKeywords":{"type":"array","items":{"type":"string","minLength":1}},"unresolvedConstraints":{"type":"array","items":{"type":"string","minLength":1}}},"required":["geo"],"additionalProperties":true},"confidence":{"type":"object","additionalProperties":{"type":"number","minimum":0,"maximum":1},"default":{}},"createdAt":{"type":"string","format":"date-time"}},"required":["id","name","nlDescription","semanticCore"],"additionalProperties":true},"generation":{"type":"object","properties":{},"additionalProperties":true}},"required":["persona","generation"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":30,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/planning/provider-forecast":{"post":{"operationId":"post_api_v1_planning_provider_forecast","summary":"Request native provider forecast evidence","description":"Requests provider-owned forecasting where the configured adapter supports it. Unsupported provider contracts fail explicitly; modeled planning forecasts remain separately labeled.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Planning"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"adapterKey":{"type":"string","const":"google-ads"},"budget":{"type":"object","properties":{"amountMinor":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["amountMinor","currency"],"additionalProperties":false},"startDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"endDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"keywords":{"type":"array","items":{"type":"object","properties":{"text":{"type":"string","minLength":1,"maxLength":80},"matchType":{"type":"string","enum":["exact","phrase","broad"]}},"required":["text","matchType"],"additionalProperties":false},"minItems":1,"maxItems":1000},"geoTargetConstants":{"type":"array","items":{"type":"string","pattern":"^geoTargetConstants\\/\\d+$"},"minItems":1,"maxItems":10},"languageConstants":{"type":"array","items":{"type":"string","pattern":"^languageConstants\\/\\d+$"},"minItems":1,"maxItems":20},"bidding":{"anyOf":[{"type":"object","properties":{"strategy":{"type":"string","const":"manual-cpc"},"maxCpcBidMinor":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991}},"required":["strategy","maxCpcBidMinor"],"additionalProperties":false},{"type":"object","properties":{"strategy":{"type":"string","const":"maximize-clicks"},"maxCpcBidMinor":{"type":"integer","exclusiveMinimum":0,"maximum":9007199254740991}},"required":["strategy"],"additionalProperties":false},{"type":"object","properties":{"strategy":{"type":"string","const":"maximize-conversions"}},"required":["strategy"],"additionalProperties":false}]},"acknowledgedLimitations":{"type":"boolean","const":true}},"required":["adapterKey","budget","startDate","endDate","keywords","geoTargetConstants","languageConstants","bidding","acknowledgedLimitations"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":30,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/plans":{"get":{"operationId":"get_api_v1_plans","summary":"Read plans","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Plans"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"plans":{"type":"array","items":{"type":"object","properties":{},"additionalProperties":true}}},"required":["plans"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/plans/{id}":{"get":{"operationId":"get_api_v1_plans_id","summary":"Read plans","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Plans"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"plan":{"type":"object","properties":{},"additionalProperties":true}},"required":["plan"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"patch":{"operationId":"patch_api_v1_plans_id","summary":"Update plans","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: plan.update. { planId, expectedAllocationVersion, lines: [{ id, budgetMinor }] } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Plans"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedAllocationVersion":{"type":"string","pattern":"^[a-f0-9]{64}$"},"lines":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"budgetMinor":{"type":"integer","minimum":0,"maximum":1900000000}},"required":["id","budgetMinor"],"additionalProperties":false},"minItems":1}},"required":["expectedAllocationVersion","lines"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"plan.update","budgetPolicy":"zero","parameterContract":"{ planId, expectedAllocationVersion, lines: [{ id, budgetMinor }] }","exactApprovalRequired":true}}},"/api/v1/plans/{id}/approve":{"post":{"operationId":"post_api_v1_plans_id_approve","summary":"Approve a plan and create its campaign","description":"Creates the campaign from the reviewed plan. This does not itself prove supplier activation. Delegated agents need exact action approval.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: plan.approve. { planId } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.","tags":["Plans"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"plan.approve","budgetPolicy":"zero","parameterContract":"{ planId }","exactApprovalRequired":true}}},"/api/v1/plans/{id}/search-keywords":{"get":{"operationId":"get_api_v1_plans_id_search_keywords","summary":"Read plans / search keywords","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Plans"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"patch":{"operationId":"patch_api_v1_plans_id_search_keywords","summary":"Update plans / search keywords","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nDelegated agent action: plan.search-keywords.update. { planId, expectedSelectionVersion, acknowledgedBuyerPreviewVersion, keywords: string[], negativeKeywords?: string[] } Prepare the action, obtain exact human approval, and bind the execution headers. Uncertain provider outcomes require reconciliation, never blind retries.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Plans"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"}},{"name":"x-chorus-agent-step-id","in":"header","required":false,"description":"Required for a delegated agent mutation: pending execute-step id bound to its approved exact action. Human sessions do not send this header.","schema":{"type":"string","minLength":1}},{"name":"x-chorus-agent-action-digest","in":"header","required":false,"description":"Required with the agent step id. Use the SHA-256 action digest returned by preparation and approved by a human; do not compute money or alter the action.","schema":{"type":"string","pattern":"^[a-f0-9]{64}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"expectedSelectionVersion":{"type":"string","pattern":"^[a-f0-9]{64}$"},"acknowledgedBuyerPreviewVersion":{"type":"string","pattern":"^[a-f0-9]{64}$"},"keywords":{"type":"array","items":{"type":"string","minLength":1,"maxLength":80},"minItems":1,"maxItems":20},"negativeKeywords":{"type":"array","items":{"type":"string","minLength":1,"maxLength":80},"minItems":0,"maxItems":50,"default":[]}},"required":["expectedSelectionVersion","acknowledgedBuyerPreviewVersion","keywords"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"governed-execution-receipt","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."},"x-agent-action":{"name":"plan.search-keywords.update","budgetPolicy":"zero","parameterContract":"{ planId, expectedSelectionVersion, acknowledgedBuyerPreviewVersion, keywords: string[], negativeKeywords?: string[] }","exactApprovalRequired":true}}},"/api/v1/plans/generate":{"post":{"operationId":"post_api_v1_plans_generate","summary":"Generate a forecasted media plan","description":"Generates a draft from a persona and total media budget. Review modeled forecast uncertainty, unsupported targeting, delivery mode, fees and supplier readiness before approval.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Plans"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"personaId":{"type":"string"},"budgetMinor":{"type":"integer","exclusiveMinimum":0,"maximum":1900000000},"currency":{"type":"string","const":"GBP","default":"GBP"},"goal":{"type":"string","enum":["awareness","consideration","performance"]},"startDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"endDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"commercialBrief":{"type":"object","properties":{"productOrOffer":{"type":"string","minLength":1,"maxLength":200},"landingPageUrl":{"type":"string","maxLength":2048,"format":"uri"},"primaryKpi":{"type":"string","enum":["reach","brand-awareness","consideration","site-visits","leads","sales","app-installs","custom"]},"conversionDefinition":{"type":"string","minLength":1,"maxLength":300},"outcomeSource":{"type":"string","enum":["campaign-tracking","analytics","crm","commerce","offline","none"]},"targetValueMinor":{"type":"integer","minimum":0,"maximum":2000000000},"baselineWeeklyConversions":{"type":"integer","minimum":0,"maximum":10000000},"priorMonthlyMediaSpendMinor":{"type":"integer","minimum":0,"maximum":2000000000},"existingMediaMix":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social","display","email","print","other"]},"maxItems":11},"firstPartyDataAvailability":{"type":"string","enum":["none","limited","ready"]},"creativeReadiness":{"type":"string","enum":["needs-production","in-progress","ready"]},"containsEuPoliticalAdvertising":{"type":"boolean"},"containsPoliticalAdvertising":{"type":"boolean"},"containsHfssAdvertising":{"type":"boolean"},"measurementIntent":{"type":"array","items":{"type":"string","enum":["delivered","responded","caused","remembered"]},"minItems":1,"maxItems":4},"exclusions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":300},"maxItems":20},"mandatories":{"type":"array","items":{"type":"string","minLength":1,"maxLength":300},"maxItems":20}},"required":["productOrOffer","primaryKpi","outcomeSource","existingMediaMix","firstPartyDataAvailability","creativeReadiness","measurementIntent","exclusions","mandatories"],"additionalProperties":false},"paidMediaAdapterKeys":{"type":"array","items":{"type":"string","enum":["google-ads","microsoft-ads","meta-ads","tiktok-ads"]},"minItems":1,"maxItems":4},"channels":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"minItems":1,"maxItems":7}},"required":["personaId","budgetMinor","goal","startDate","endDate"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"plan":{"type":"object","properties":{},"additionalProperties":true}},"required":["plan"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":30,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/plans/manual":{"post":{"operationId":"post_api_v1_plans_manual","summary":"Create a plan from selected inventory","description":"Creates a draft plan from exact inventory choices and budget allocations. Availability and prices remain subject to the configured supplier and execution mode.\n\nAuthenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Plans"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"personaId":{"type":"string"},"budgetMinor":{"type":"integer","exclusiveMinimum":0,"maximum":1900000000},"currency":{"type":"string","const":"GBP","default":"GBP"},"goal":{"type":"string","enum":["awareness","consideration","performance"]},"startDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"endDate":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"commercialBrief":{"type":"object","properties":{"productOrOffer":{"type":"string","minLength":1,"maxLength":200},"landingPageUrl":{"type":"string","maxLength":2048,"format":"uri"},"primaryKpi":{"type":"string","enum":["reach","brand-awareness","consideration","site-visits","leads","sales","app-installs","custom"]},"conversionDefinition":{"type":"string","minLength":1,"maxLength":300},"outcomeSource":{"type":"string","enum":["campaign-tracking","analytics","crm","commerce","offline","none"]},"targetValueMinor":{"type":"integer","minimum":0,"maximum":2000000000},"baselineWeeklyConversions":{"type":"integer","minimum":0,"maximum":10000000},"priorMonthlyMediaSpendMinor":{"type":"integer","minimum":0,"maximum":2000000000},"existingMediaMix":{"type":"array","items":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social","display","email","print","other"]},"maxItems":11},"firstPartyDataAvailability":{"type":"string","enum":["none","limited","ready"]},"creativeReadiness":{"type":"string","enum":["needs-production","in-progress","ready"]},"containsEuPoliticalAdvertising":{"type":"boolean"},"containsPoliticalAdvertising":{"type":"boolean"},"containsHfssAdvertising":{"type":"boolean"},"measurementIntent":{"type":"array","items":{"type":"string","enum":["delivered","responded","caused","remembered"]},"minItems":1,"maxItems":4},"exclusions":{"type":"array","items":{"type":"string","minLength":1,"maxLength":300},"maxItems":20},"mandatories":{"type":"array","items":{"type":"string","minLength":1,"maxLength":300},"maxItems":20}},"required":["productOrOffer","primaryKpi","outcomeSource","existingMediaMix","firstPartyDataAvailability","creativeReadiness","measurementIntent","exclusions","mandatories"],"additionalProperties":false},"selections":{"type":"array","items":{"type":"object","properties":{"channel":{"type":"string","enum":["ctv","audio","tv","cinema","dooh","search","social"]},"adapterKey":{"type":"string","minLength":1},"itemIds":{"type":"array","items":{"type":"string","minLength":1},"minItems":1}},"required":["channel","adapterKey","itemIds"],"additionalProperties":false},"minItems":1}},"required":["budgetMinor","goal","startDate","endDate","selections"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: envelope-only. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","properties":{"plan":{"type":"object","properties":{},"additionalProperties":true}},"required":["plan"],"additionalProperties":true}}}}},"x-response-schema-completeness":"envelope-only","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/t/{pixelKey}":{"post":{"operationId":"post_api_v1_t_pixelKey","summary":"Record an anonymous pageview","description":"Public tracking accepts pageviews only and cannot assert conversions, revenue or private identity. Import conversions through the authenticated campaign outcomes endpoint. Optional Idempotency-Key retains the first event for that pixel and key; a changed replay body does not replace it or raise a payload-collision error. Unknown fields are accepted and ignored.\n\nPublic endpoint; tenant data is not exposed by discovery endpoints.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["T"],"security":[],"parameters":[{"name":"pixelKey","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}},{"name":"Idempotency-Key","in":"header","required":false,"description":"Retain the same key when retrying the same request. Replay and collision behavior are endpoint-specific; see this operation’s description.","schema":{"type":"string","minLength":8,"maxLength":200}}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"kind":{"type":"string","maxLength":64},"event":{"type":"string","maxLength":64},"value":{"type":"number","minimum":0,"maximum":21474836.47},"valueMinor":{"type":"integer","minimum":0,"maximum":2147483647},"promoCode":{"type":"string","maxLength":64}},"additionalProperties":true}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"optional","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/workspace":{"get":{"operationId":"get_api_v1_workspace","summary":"Read workspace","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Workspace"],"security":[{"bearerAuth":[]}],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}},"patch":{"operationId":"patch_api_v1_workspace","summary":"Update workspace","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Workspace"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"name":{"type":"string","minLength":1,"maxLength":120},"brandKit":{"anyOf":[{"type":"object","properties":{"name":{"type":"string","minLength":1},"bg":{"type":"string","pattern":"^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"},"fg":{"type":"string","pattern":"^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"},"sub":{"type":"string","pattern":"^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"},"accent":{"type":"string","pattern":"^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"},"onAccent":{"type":"string","pattern":"^#(?:[0-9a-fA-F]{3}|[0-9a-fA-F]{6})$"},"fontFamily":{"type":"string","minLength":1},"logoUrl":{"type":"string","minLength":1,"maxLength":349550}},"required":["bg","fg","sub","accent","onAccent"],"additionalProperties":false},{"type":"null"}]}},"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/workspace/analytics":{"get":{"operationId":"get_api_v1_workspace_analytics","summary":"Read workspace / analytics","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Workspace"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"fromDate","in":"query","required":true,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"style":"form","explode":true},{"name":"toDate","in":"query","required":true,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"style":"form","explode":true},{"name":"goal","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":120},"style":"form","explode":true},{"name":"campaign","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":200},"style":"form","explode":true},{"name":"adapterKey","in":"query","required":false,"schema":{"type":"string","const":"plausible","default":"plausible"},"style":"form","explode":true},{"name":"campaignId","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":100},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/workspace/keywords/suggest":{"post":{"operationId":"post_api_v1_workspace_keywords_suggest","summary":"Run workspace / keywords / suggest","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.\n\nThe request schema is generated from the runtime Zod input validator. Cross-field refinements and state-dependent constraints are additionally enforced by the API.","tags":["Workspace"],"security":[{"bearerAuth":[]}],"parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"seedKeywords":{"type":"array","items":{"type":"string","minLength":1,"maxLength":80},"minItems":1,"maxItems":20},"pageUrl":{"type":"string","maxLength":2048,"format":"uri"},"countries":{"type":"array","items":{"type":"string","minLength":2,"maxLength":2},"minItems":1,"maxItems":10,"default":["GB"]},"language":{"type":"string","minLength":2,"maxLength":10,"default":"en"},"maxResults":{"type":"integer","minimum":1,"maximum":200,"default":50},"adapterKeys":{"type":"array","items":{"type":"string","enum":["google-ads","microsoft-ads"]},"minItems":1,"maxItems":2}},"required":["seedKeywords"],"additionalProperties":false}}}},"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/api/v1/workspace/overview":{"get":{"operationId":"get_api_v1_workspace_overview","summary":"Read workspace / overview","description":"Authenticated and advertiser scoped. Cross-tenant resource access returns 404. Product/channel entitlements also apply.","tags":["Workspace"],"security":[{"bearerAuth":[]}],"parameters":[{"name":"from","in":"query","required":false,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"style":"form","explode":true},{"name":"to","in":"query","required":false,"schema":{"type":"string","pattern":"^\\d{4}-\\d{2}-\\d{2}$"},"style":"form","explode":true},{"name":"campaignId","in":"query","required":false,"schema":{"type":"string","minLength":1,"maxLength":100},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/files/assets/{name}":{"get":{"operationId":"get_files_assets_name","summary":"Read files / assets","description":"Public endpoint; tenant data is not exposed by discovery endpoints.","tags":["Files"],"security":[],"parameters":[{"name":"name","in":"path","required":true,"schema":{"type":"string","minLength":1}}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"*/*":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/go/{vanitySlug}":{"get":{"operationId":"get_go_vanitySlug","summary":"Read go","description":"Public endpoint; tenant data is not exposed by discovery endpoints.","tags":["Go"],"security":[],"parameters":[{"name":"vanitySlug","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":200}}],"responses":{"302":{"description":"Successful response.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"location":{"description":"The configured HTTPS destination.","schema":{"type":"string","format":"uri"}}}},"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"x-response-schema-completeness":"modeled","x-rate-limit":{"requests":3000,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/readyz":{"get":{"operationId":"get_readyz","summary":"Check deployment readiness","description":"Checks database, adapter registry, stored credentials, creative evidence and production scheduler health. Returns 503 when a required check fails. Availability reports runtime and billing mode; service health does not certify public onboarding or live campaign readiness.\n\nPublic endpoint; tenant data is not exposed by discovery endpoints.","tags":["Readyz"],"security":[],"parameters":[],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":300,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}},"/t/{pixelKey}":{"get":{"operationId":"get_t_pixelKey","summary":"Record an anonymous pageview","description":"Public tracking accepts pageviews only and cannot assert conversions, revenue or private identity. Import conversions through the authenticated campaign outcomes endpoint. Optional Idempotency-Key retains the first event for that pixel and key; a changed replay body does not replace it or raise a payload-collision error. Unknown fields are accepted and ignored.\n\nPublic endpoint; tenant data is not exposed by discovery endpoints.","tags":["T"],"security":[],"parameters":[{"name":"pixelKey","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":128}},{"name":"eid","in":"query","required":false,"schema":{"type":"string","minLength":8,"maxLength":200},"style":"form","explode":true}],"responses":{"400":{"description":"Invalid request or unsupported fields","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"description":"Missing or invalid authentication","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"403":{"description":"Permission or product scope refused","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Route or tenant-scoped resource not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"409":{"description":"State, revision, approval, funding or idempotency conflict","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"422":{"description":"Supplier configuration, capability or upstream refusal","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"429":{"description":"Rate limit reached; wait before retrying","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}},"retry-after":{"description":"Minimum seconds to wait before retrying.","schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"500":{"description":"Internal error; inspect state before retrying a mutation","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"503":{"description":"Dependency or authentication verifier unavailable","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"2XX":{"description":"Successful response. Response schema completeness: unmodeled. The request contract is complete; nested service payloads are not yet fully modeled in OpenAPI. Inspect returned fields before generating a typed SDK.","headers":{"x-ratelimit-limit":{"description":"Maximum requests permitted in the current rate-limit window.","schema":{"type":"integer"}},"x-ratelimit-remaining":{"description":"Requests remaining in the current window.","schema":{"type":"integer"}},"x-ratelimit-reset":{"description":"Seconds until the current rate-limit window resets.","schema":{"type":"integer"}}},"content":{"image/gif":{"schema":{"type":"string"}}}}},"x-response-schema-completeness":"unmodeled","x-rate-limit":{"requests":3000,"windowMilliseconds":60000,"key":"request IP","headers":["x-ratelimit-limit","x-ratelimit-remaining","x-ratelimit-reset"]},"x-idempotency":{"policy":"not-generalized","note":"There is no universal Idempotency-Key middleware. Only the documented endpoint mechanisms protect retries."}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Verified identity-provider session JWT for a human (Supabase in the hosted deployment), or an API-audience delegation JWT for an agent acting through MCP. Product/channel claims and human permissions are verified; caller-supplied identity headers cannot grant authority. Local AUTH_MODE=disabled is a development-only exception. Obtain MCP OAuth metadata from that deployment; this API does not advertise fictitious per-operation OAuth scopes."}},"schemas":{"Error":{"type":"object","required":["error"],"additionalProperties":false,"properties":{"error":{"type":"object","required":["code","message"],"additionalProperties":false,"properties":{"code":{"type":"string"},"message":{"type":"string"},"details":{}}}}},"Money":{"type":"object","properties":{"amountMinor":{"type":"integer"},"currency":{"type":"string","enum":["GBP","USD","EUR"]}},"required":["amountMinor","currency"],"additionalProperties":false}}},"x-product":{"id":"adbuymcp","name":"AdBuyMCP","channels":["ctv","audio","tv","cinema","dooh","search","social"],"domain":null},"x-agentic-capabilities":{"outboundCustomerWebhooks":false,"businessEventStream":false,"rateLimitHeaders":true,"generalizedIdempotency":false,"granularOAuthOperationScopes":false,"mcpTransport":"streamable-http","note":"MCP transport streaming is not a replayable business-event feed. Use campaign, asset and agent-run status endpoints; uncertain effects require reconciliation."}}