{"openapi":"3.1.0","info":{"title":"Core API","version":"1.0.0","summary":"Events in, actions out, for plugins that run beside a gaming platform.","description":"The platform sends **events** (`POST /v1/events`) and the core API sends **actions** to\nan endpoint the platform exposes (see `webhooks.hostAction`). Plugins read the events\nand decide; the platform stays the owner of money and players.\n\nEvery keyed request carries `Authorization: Bearer <API key>` and a request signature:\n\n```\nRequest-Timestamp: <unix seconds>\nRequest-Nonce: <8 to 128 of A-Z a-z 0-9 . _ : ->\nRequest-Signature: v1=<hex HMAC-SHA256(signing secret, canonical string)>\n```\n\nThe canonical string is `<timestamp>.<nonce>.<METHOD>.<path>?<canonical query>.<hex sha256(raw body)>`.\n`path` is the full request path (base path included), repeated `/` squeezed and no\ntrailing `/`. The canonical query is the raw query split on `&`, empty parts dropped,\nsorted bytewise and joined with `&`, never decoded. The timestamp must be within 300\nseconds and each nonce is accepted once, so every retry is signed again.\n\nEvery non-GET carries an `Idempotency-Key`. On `POST /v1/events` it equals the event id.\n\nMoney is `{\"minor\":\"<digits>\",\"currency\":\"<code>\"}` in minor units, with the exponent of\neach currency from `GET /v1/currencies`. Personal identifiers travel as salted digests.\n\nErrors are `application/problem+json` documents with a stable `code`.\n\nPublic, keyless endpoints: health, currencies, manifest, the AI prompt kit, this document\nand the JSON Schemas.\n","license":{"name":"Proprietary","identifier":"LicenseRef-Proprietary"}},"servers":[{"url":"{coreApiBase}","description":"The core API base URL the operator gives you.","variables":{"coreApiBase":{"default":"https://core.octolit.com/api/engines/core","description":"Base URL of the core API, including its path."}}}],"security":[{"bearerAuth":[],"requestSignature":[]}],"tags":[{"name":"Meta","description":"Liveness, key check and the capability catalogue."},{"name":"Events","description":"Canonical events the platform sends."},{"name":"Actions","description":"Actions for the platform, pull mode and results."},{"name":"Webhooks","description":"Webhook subscriptions and the delivery log."},{"name":"Conformance","description":"Conformance runs of the key's own source and their results."},{"name":"Statements","description":"Provider and payment statements uploaded for reconciliation."},{"name":"Dev kit","description":"Public documents for host developers, no key needed."},{"name":"Widget","description":"The browser widget. Your server mints a player token; the page calls the plugin widget routes with it."}],"paths":{"/v1/health":{"get":{"tags":["Meta"],"operationId":"getHealth","summary":"Liveness","description":"Answers `{\"ok\":true}` and nothing else. No key.","security":[],"responses":{"200":{"description":"The core API is up.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Health"}}}},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/hosts":{"get":{"tags":["Meta"],"operationId":"getHosts","summary":"Platform hosts","description":"The public hosts of the platform: the core API base URL (`CORE_API_BASE`), where SDK files and developer docs are served, and the console. Read them here instead of writing a host into code. No key; cacheable for 5 minutes.","security":[],"responses":{"200":{"description":"The hosts.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Hosts"}}}},"304":{"description":"Not modified since the ETag you sent."},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/ping":{"get":{"tags":["Meta"],"operationId":"getPing","summary":"Who am I","description":"The key's company, source, environment, scopes, plugins and rate limit. Any key, any scope.","parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"}],"responses":{"200":{"description":"The key is valid and the signature verified.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Ping"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"post":{"tags":["Meta"],"operationId":"postPing","summary":"Signature echo","description":"The same as `GET /v1/ping` plus `echo`, what the server computed from your request (path, canonical query, body hash, Idempotency-Key). Use it to debug signing.","parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object"}}}},"responses":{"200":{"description":"The key is valid and the signature verified.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PingEchoed"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/catalogue":{"get":{"tags":["Meta"],"operationId":"getCatalogue","summary":"Capability catalogue","description":"Every plugin with what it requires (events, actions, host calls, statements, scopes, conformance tests). The key needs a read scope.","parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"}],"responses":{"200":{"description":"The catalogue.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Catalogue"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/events":{"post":{"tags":["Events"],"operationId":"sendEvent","summary":"Send one event","description":"One canonical event. Scope `events:write`. The `Idempotency-Key` must equal the event id.\nA new event answers 202 `queued`; the same id and body again answers 200 `duplicate`;\nthe same id with another body answers 409 `event_id_conflict`. At most 64 KB.\n","security":[{"bearerAuth":["events:write"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"},{"$ref":"#/components/parameters/Sync"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"responses":{"200":{"description":"Seen before with the same body; nothing is applied twice.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventDuplicate"}}}},"202":{"description":"Accepted and queued.","headers":{"Location":{"description":"URL of the event's status.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventQueued"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"413":{"$ref":"#/components/responses/PayloadTooLarge"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"get":{"tags":["Events"],"operationId":"listEvents","summary":"List events","description":"Events this key sent, newest first, with their processing status. Scope `events:read`.","security":[{"bearerAuth":["events:read"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"name":"status","in":"query","description":"Comma separated statuses.","schema":{"type":"string","examples":["failed,dead"]}},{"name":"type","in":"query","description":"Comma separated event types.","schema":{"type":"string"}},{"name":"since","in":"query","description":"Only events received at or after this time (RFC 3339).","schema":{"type":"string","format":"date-time"}},{"name":"cursor","in":"query","description":"The `next_cursor` of the previous page.","schema":{"type":"string"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":200,"default":50}},{"name":"test","in":"query","description":"With a live key, list the sandbox rows of events sent with `\"test\": true`.","schema":{"type":"boolean"}}],"responses":{"200":{"description":"One page.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventList"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/events/batch":{"post":{"tags":["Events"],"operationId":"sendEventBatch","summary":"Send up to 500 events","description":"A JSON array of events or `{\"events\":[...]}`, at most 500 and 1 MB. Always 207 with one result per item, in the order sent. Scope `events:write`.","security":[{"bearerAuth":["events:write"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"},{"$ref":"#/components/parameters/Sync"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventBatch"}}}},"responses":{"207":{"description":"One result per event.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResult"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"413":{"$ref":"#/components/responses/PayloadTooLarge"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/events/{event_id}":{"get":{"tags":["Events"],"operationId":"getEvent","summary":"Event status","description":"Processing status and error of one event. Scope `events:read`.","security":[{"bearerAuth":["events:read"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/EventId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"}],"responses":{"200":{"description":"The event.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventStatus"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/events/{event_id}/replay":{"post":{"tags":["Events"],"operationId":"replayEvent","summary":"Replay a failed event","description":"Puts a `failed`, `dead` or `orphaned` event back in the queue. Scope `events:write`.","security":[{"bearerAuth":["events:write"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/EventId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"responses":{"202":{"description":"Queued again.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventReplayed"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/inbound/{host_event}":{"post":{"tags":["Events"],"operationId":"sendHostPayload","summary":"Send a payload in the platform's own shape","description":"The platform's own payload for `host_event`. The source's active field mapping turns it\ninto one canonical event, which then follows the `POST /v1/events` path. A JSON array is a\nbatch (up to 500, 1 MB) and answers 207. A mapping whose `when` does not match answers 200\n`ignored`. Scope `events:write`.\n","security":[{"bearerAuth":["events:write"],"requestSignature":[]}],"parameters":[{"name":"host_event","in":"path","required":true,"description":"The platform's own event name, as the field mapping names it.","schema":{"type":"string","pattern":"^[A-Za-z0-9_.:-]{1,128}$"}},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"},{"$ref":"#/components/parameters/Sync"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"oneOf":[{"type":"object"},{"type":"array","maxItems":500,"items":{"type":"object"}}]}}}},"responses":{"200":{"description":"A duplicate, or ignored by the mapping's condition.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundResult"}}}},"202":{"description":"Translated and queued.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InboundResult"}}}},"207":{"description":"One result per payload of an array body.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResult"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"413":{"$ref":"#/components/responses/PayloadTooLarge"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/currencies":{"get":{"tags":["Events"],"operationId":"listCurrencies","summary":"Currencies and minor unit exponents","description":"The exponent of every currency code the API accepts. Public, cacheable.","security":[],"parameters":[{"name":"kind","in":"query","schema":{"type":"string","enum":["fiat","crypto"]}}],"responses":{"200":{"description":"The table.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Currencies"}}}},"304":{"description":"Not modified since the ETag you sent."},"400":{"$ref":"#/components/responses/BadRequest"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/actions":{"get":{"tags":["Actions"],"operationId":"pullActions","summary":"Pull pending actions","description":"Pull mode for a platform that cannot receive requests. Leases each returned action for 60 seconds; report each with `POST /v1/actions/{id}/result`. Live keys only, scope `actions:read`.","security":[{"bearerAuth":["actions:read"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"name":"status","in":"query","schema":{"type":"string","enum":["pending"],"default":"pending"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1}}],"responses":{"200":{"description":"Leased actions, oldest first.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionPull"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/actions/{id}":{"get":{"tags":["Actions"],"operationId":"getAction","summary":"One action","description":"An action and its state, without a lease. Live keys only, scope `actions:read`.","security":[{"bearerAuth":["actions:read"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/ActionId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"}],"responses":{"200":{"description":"The action.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionState"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/actions/{id}/result":{"post":{"tags":["Actions"],"operationId":"reportActionResult","summary":"Report an action's outcome","description":"`applied` or `rejected` closes the action (the same report again is a no-op, another\nfinal status is 409 `action_already_resolved`). `pending` parks it until you report\nagain. Live keys only, scope `actions:write`.\n","security":[{"bearerAuth":["actions:write"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/ActionId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionResult"}}}},"responses":{"200":{"description":"The action after the report.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActionState"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/webhooks/endpoints":{"get":{"tags":["Webhooks"],"operationId":"listWebhookEndpoints","summary":"List webhook endpoints","description":"The company's webhook subscriptions. Live keys only, scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"}],"responses":{"200":{"description":"The endpoints.","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/WebhookEndpoint"}}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"post":{"tags":["Webhooks"],"operationId":"createWebhookEndpoint","summary":"Create a webhook endpoint","description":"An https URL whose every address is public. The answer carries the signing secret, shown once. Scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointCreate"}}}},"responses":{"201":{"description":"Created; `secret` is shown only now.","headers":{"Location":{"description":"URL of the new endpoint.","schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointWithSecret"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/webhooks/endpoints/{id}":{"get":{"tags":["Webhooks"],"operationId":"getWebhookEndpoint","summary":"One webhook endpoint","description":"Scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/EndpointId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"}],"responses":{"200":{"description":"The endpoint.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpoint"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"patch":{"tags":["Webhooks"],"operationId":"updateWebhookEndpoint","summary":"Change a webhook endpoint","description":"Any of url, event_types, description, active. Scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/EndpointId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointUpdate"}}}},"responses":{"200":{"description":"The endpoint after the change.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpoint"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"delete":{"tags":["Webhooks"],"operationId":"deleteWebhookEndpoint","summary":"Delete a webhook endpoint","description":"Pending deliveries are cancelled; the delivery history is kept. Scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/EndpointId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"responses":{"200":{"description":"Deleted.","content":{"application/json":{"schema":{"type":"object","required":["id","deleted"],"properties":{"id":{"type":"string"},"deleted":{"type":"boolean","const":true}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/webhooks/endpoints/{id}/test":{"post":{"tags":["Webhooks"],"operationId":"testWebhookEndpoint","summary":"Send a test delivery","description":"Sends `core.endpoint_test` to the endpoint now and answers with the outcome. A failed test is not retried. Scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/EndpointId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"responses":{"200":{"description":"The outcome of the test delivery.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookTestResult"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/webhooks/endpoints/{id}/rotate_secret":{"post":{"tags":["Webhooks"],"operationId":"rotateWebhookSecret","summary":"Rotate the signing secret","description":"A new secret, shown once. The old one keeps signing for 24 hours, so deliveries carry both signatures meanwhile. Scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/EndpointId"},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"responses":{"200":{"description":"The endpoint with its new secret.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEndpointWithSecret"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/webhooks/deliveries":{"get":{"tags":["Webhooks"],"operationId":"listWebhookDeliveries","summary":"Delivery log","description":"Newest first. Scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"name":"endpoint_id","in":"query","schema":{"type":"string"}},{"name":"status","in":"query","schema":{"$ref":"#/components/schemas/DeliveryStatus"}},{"name":"event_type","in":"query","schema":{"type":"string"}},{"name":"before","in":"query","description":"The `next_before` of the previous page.","schema":{"type":"string","pattern":"^[0-9]{1,19}$"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":200,"default":50}}],"responses":{"200":{"description":"One page.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeliveryList"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/webhooks/deliveries/{id}/redeliver":{"post":{"tags":["Webhooks"],"operationId":"redeliverWebhook","summary":"Deliver a message again","description":"The same message id with fresh attempts. `endpoint_id` narrows a message that went to several endpoints. Scope `webhooks:manage`.","security":[{"bearerAuth":["webhooks:manage"],"requestSignature":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"The message id (`id` of a delivery).","schema":{"type":"string"}},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"type":"object","properties":{"endpoint_id":{"type":"string"}}}}}},"responses":{"200":{"description":"The deliveries queued again.","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDelivery"}}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/conformance/runs":{"post":{"tags":["Conformance"],"operationId":"startConformanceRun","summary":"Queue a conformance run","description":"Queues a conformance run of the key's own source. `full` sends the active probes and\nreads the recorded traffic, `active` only sends the probes, `passive` only reads the\ntraffic. With no `plugin_keys` the run covers the source's plugins. A run never moves\nvalue on a live source. Test keys may call it. Scope `conformance:run`.\n","security":[{"bearerAuth":["conformance:run"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":false,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConformanceRunRequest"}}}},"responses":{"202":{"description":"The run, queued.","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/ConformanceRun"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/conformance/runs/{id}":{"get":{"tags":["Conformance"],"operationId":"getConformanceRun","summary":"One conformance run","description":"A run of the key's own source with every result and the per plugin view. Any other id is a 404. Scope `conformance:run`.","security":[{"bearerAuth":["conformance:run"],"requestSignature":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"The run id.","schema":{"type":"string","pattern":"^[0-9]{1,18}$"}},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"}],"responses":{"200":{"description":"The run with its results.","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/ConformanceRunDetail"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/statements":{"post":{"tags":["Statements"],"operationId":"uploadStatement","summary":"Upload a statement","description":"Uploads one provider or payment statement for reconciliation. Send `multipart/form-data`\nwith a `file` part (CSV, JSON lines or a JSON statement) and the options as form fields,\nor the body itself as `text/csv`, `application/x-ndjson` or `application/json` with the\noptions in the query string. Options: `kind` (payments or games), `provider`,\n`period_from` and `period_to` (both or neither), `adapter` (`canonical`,\n`aggregator_rounds` or `psp_settlement`; sniffed from the CSV header when absent), `decimal_separator`,\n`timezone`, `delimiter`, `format`. A statement with any problem is refused whole (422\n`statement_invalid` with `row_errors` and `errors`) and nothing is stored. The same file\nagain from the same source answers 200 with the first statement and `duplicate: true`.\nTest keys upload into the sandbox. The reconciliation plugin must be enabled for the\ncompany (403 `plugin_not_entitled` otherwise). Scope `statements:write`.\n","security":[{"bearerAuth":["statements:write"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["file"],"properties":{"file":{"type":"string","contentMediaType":"application/octet-stream"}}}},"text/csv":{"schema":{"type":"string"}},"application/x-ndjson":{"schema":{"type":"string"}},"application/json":{"schema":{"type":"object"}}}},"responses":{"200":{"description":"The same statement was uploaded before; the first one, `duplicate` true.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatementSummary"}}}},"202":{"description":"Parsed and stored. `Location` points at the statement.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatementSummary"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"413":{"$ref":"#/components/responses/PayloadTooLarge"},"415":{"description":"The body is not one of the accepted media types.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/statements/{id}":{"get":{"tags":["Statements"],"operationId":"getStatement","summary":"One statement","description":"The parse summary of a statement this source uploaded, with the match counts so far. Test keys read only sandbox statements. Scope `statements:write`.","security":[{"bearerAuth":["statements:write"],"requestSignature":[]}],"parameters":[{"name":"id","in":"path","required":true,"description":"The `statement_id` from the upload.","schema":{"type":"string"}},{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"}],"responses":{"200":{"description":"The statement.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StatementSummary"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/manifest":{"get":{"tags":["Dev kit"],"operationId":"getManifest","summary":"Integration manifest","description":"Everything a platform builds for a set of plugins, merged: the events to send (each with the\nplugins that need it and the fields they read), the actions to implement, the APIs to call,\nstatements, scopes and the conformance tests. Per plugin, a **Required** section (with why)\nand a **Recommended** section (with what the operator gains). Public. `format=md` answers Markdown.\n","security":[],"parameters":[{"$ref":"#/components/parameters/Plugins"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","md"],"default":"json"}}],"responses":{"200":{"description":"The manifest.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Manifest"}},"text/markdown":{"schema":{"type":"string"}}}},"304":{"description":"Not modified since the ETag you sent."},"400":{"$ref":"#/components/responses/BadRequest"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/devkit/prompt":{"get":{"tags":["Dev kit"],"operationId":"getPromptKit","summary":"AI developer prompt kit","description":"One Markdown brief to paste into an AI coding assistant: role and goal, configuration,\nRequired and Recommended data with the gain of each line, signing code in the chosen\nlanguage, every schema and example, the action endpoint contract, retries and the test\nplan. Placeholders only, never a secret. Public. `format=json` wraps it with its fingerprint.\n","security":[],"parameters":[{"$ref":"#/components/parameters/Plugins"},{"name":"lang","in":"query","schema":{"type":"string","enum":["node","python","php","java","go","ruby"],"default":"node"}},{"name":"platform","in":"query","description":"The platform the brief is written for; `inhouse` is one the operator built.","schema":{"type":"string","pattern":"^[a-z0-9][a-z0-9_-]{0,63}$","default":"inhouse"}},{"name":"format","in":"query","schema":{"type":"string","enum":["md","json"],"default":"md"}}],"responses":{"200":{"description":"The brief.","content":{"text/markdown":{"schema":{"type":"string"}},"application/json":{"schema":{"$ref":"#/components/schemas/PromptKit"}}}},"304":{"description":"Not modified since the ETag you sent."},"400":{"$ref":"#/components/responses/BadRequest"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/openapi.json":{"get":{"tags":["Dev kit"],"operationId":"getOpenApi","summary":"This document","description":"The OpenAPI 3.1 description of the core API. Public.","security":[],"responses":{"200":{"description":"The document.","content":{"application/json":{"schema":{"type":"object"}}}},"304":{"description":"Not modified since the ETag you sent."},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/schemas":{"get":{"tags":["Dev kit"],"operationId":"listSchemas","summary":"Schema index","description":"The downloadable JSON Schemas, per kind. Public.","security":[],"responses":{"200":{"description":"Type names per kind, with the URL of each.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SchemaIndex"}}}},"304":{"description":"Not modified since the ETag you sent."},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/schemas/{kind}/{type}.json":{"get":{"tags":["Dev kit"],"operationId":"getSchema","summary":"One JSON Schema","description":"A self contained JSON Schema (draft 2020-12) with every definition it uses under `$defs`. Event and action schemas describe `data`. Public.","security":[],"parameters":[{"name":"kind","in":"path","required":true,"schema":{"type":"string","enum":["events","actions","statements","defs"]}},{"name":"type","in":"path","required":true,"description":"For example `deposit.completed`, `withdrawal.hold`, `payments` or `money`.","schema":{"type":"string","pattern":"^[a-z0-9_]+(\\.[a-z0-9_]+)?$"}}],"responses":{"200":{"description":"The schema.","content":{"application/schema+json":{"schema":{"type":"object"}}}},"304":{"description":"Not modified since the ETag you sent."},"400":{"$ref":"#/components/responses/BadRequest"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/devkit/docs":{"get":{"tags":["Dev kit"],"operationId":"listPluginDocs","summary":"Plugin developer docs index","description":"Every plugin with its scopes, events, host actions, server API routes and player widget routes, plus a link to its page. Public. `format=md` (default), `html` or `json`, or the `.md` / `.html` / `.json` extension.","security":[],"parameters":[{"$ref":"#/components/parameters/DocFormat"}],"responses":{"200":{"description":"The index.","content":{"text/markdown":{"schema":{"type":"string"}},"text/html":{"schema":{"type":"string"}},"application/json":{"schema":{"$ref":"#/components/schemas/PluginDocsIndex"}}}},"304":{"description":"Not modified since the ETag you sent."},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/devkit/docs/{plugin}":{"get":{"tags":["Dev kit"],"operationId":"getPluginDoc","summary":"One plugin's developer docs","description":"How the plugin works, the Node and PHP quickstart on the SDK, its server API and player widget routes, the integration contract, the sandbox and the signature checks. Public.","security":[],"parameters":[{"name":"plugin","in":"path","required":true,"description":"The plugin key, as the catalogue lists it.","schema":{"type":"string","pattern":"^[a-z0-9_-]+$"}},{"$ref":"#/components/parameters/DocFormat"}],"responses":{"200":{"description":"The page.","content":{"text/markdown":{"schema":{"type":"string"}},"text/html":{"schema":{"type":"string"}},"application/json":{"schema":{"$ref":"#/components/schemas/PluginDoc"}}}},"304":{"description":"Not modified since the ETag you sent."},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/widget_tokens":{"post":{"tags":["Widget"],"operationId":"createWidgetToken","summary":"Mint a player widget token","description":"Your SERVER mints a short lived token for one player and hands it to the page; the page\nnever sees the API key. The token opens only the listed plugins' widget routes, only for\nthat player, and, when `origin` is set, only from that page origin. Live keys only (a\ntest key gets `test_key_not_allowed`); the key needs `plugin:<key>:read` or `:write` for\neach plugin. `player_not_found` means `player.registered` was not sent yet.\n","security":[{"bearerAuth":["plugin:<key>:read"],"requestSignature":[]},{"bearerAuth":["plugin:<key>:write"],"requestSignature":[]}],"parameters":[{"$ref":"#/components/parameters/RequestTimestamp"},{"$ref":"#/components/parameters/RequestNonce"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WidgetTokenRequest"}}}},"responses":{"201":{"description":"The token.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WidgetToken"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/widget/loader.js":{"get":{"tags":["Widget"],"operationId":"getWidgetLoader","summary":"Widget loader script","description":"The browser widget (`window.PluginsWidget`). Load it on the page and pass it the token your server minted. Public, cacheable.","security":[],"responses":{"200":{"description":"The script.","content":{"text/javascript":{"schema":{"type":"string"}}}},"304":{"description":"Not modified since the ETag you sent."},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/widget/points-rewards-store/summary":{"get":{"tags":["Widget"],"operationId":"getPointsWidgetSummary","summary":"Points widget, the player's summary","description":"Balance, pending points, tier, next tier and the programme basics of the token's player.","security":[{"widgetToken":[]}],"parameters":[{"$ref":"#/components/parameters/WidgetLang"}],"responses":{"200":{"description":"The summary.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PointsSummary"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/widget/points-rewards-store/program":{"get":{"tags":["Widget"],"operationId":"getPointsWidgetProgram","summary":"Points widget, tiers and ways to earn","description":"The programme the player sees, tiers and the active earn rules, in `lang`.","security":[{"widgetToken":[]}],"parameters":[{"$ref":"#/components/parameters/WidgetLang"}],"responses":{"200":{"description":"The programme.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PointsProgram"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/widget/points-rewards-store/ledger":{"get":{"tags":["Widget"],"operationId":"getPointsWidgetLedger","summary":"Points widget, ledger","description":"The player's points ledger, newest first. Pass `next_cursor` as `before` for the next page.","security":[{"widgetToken":[]}],"parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":50}},{"name":"before","in":"query","schema":{"type":"string"}},{"$ref":"#/components/parameters/WidgetLang"}],"responses":{"200":{"description":"One page.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PointsLedgerPage"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/widget/points-rewards-store/quote":{"post":{"tags":["Widget"],"operationId":"quotePointsWidget","summary":"Points widget, quote a redemption","description":"What `points` would pay the player now, in the player's currency. Moves nothing.","security":[{"widgetToken":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PointsAmount"}}}},"responses":{"200":{"description":"The quote.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PointsQuote"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/v1/widget/points-rewards-store/redemptions":{"get":{"tags":["Widget"],"operationId":"listPointsWidgetRedemptions","summary":"Points widget, the player's redemptions","description":"Newest first.","security":[{"widgetToken":[]}],"parameters":[{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":100,"default":20}}],"responses":{"200":{"description":"The redemptions.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PointsRedemptionList"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"post":{"tags":["Widget"],"operationId":"redeemPointsWidget","summary":"Points widget, redeem points","description":"Reserves `points` and sends your platform a `wallet.credit` action for the cash; the\nredemption completes when you report the action applied. Send an `Idempotency-Key`\n(8 to 80 printable characters): the same key answers the first redemption again. A\nrefusal is 422 `redeem_refused` with a `reason` (too_few, too_small, insufficient,\ndaily_limit, cash_off, unavailable, no_wallet, fx_unavailable).\n","security":[{"widgetToken":[]}],"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"schema":{"type":"string","pattern":"^[!-~]{8,80}$"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PointsAmount"}}}},"responses":{"201":{"description":"The redemption (a replay answers the first one).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PointsRedemption"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}}},"webhooks":{"hostAction":{"post":{"tags":["Actions"],"operationId":"receiveHostAction","summary":"An action sent to the platform","description":"Sent to the action endpoint the platform exposes (push mode). Verify `webhook-signature`\nover the raw body with the action secret used as raw bytes, look the action `id` up and\nanswer a repeat with the stored outcome, otherwise apply it once and answer within 10\nseconds. `408`, `429`, `5xx` and timeouts are retried with the same id.\n","security":[],"parameters":[{"$ref":"#/components/parameters/WebhookId"},{"$ref":"#/components/parameters/WebhookTimestamp"},{"$ref":"#/components/parameters/WebhookSignature"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HostAction"}}}},"responses":{"200":{"description":"Applied or rejected.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HostActionOutcome"}}}},"202":{"description":"Will finish later; report with `POST /v1/actions/{id}/result`.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HostActionOutcome"}}}},"401":{"description":"The signature did not verify or the timestamp is older than 5 minutes."},"409":{"description":"A repeat of an action already applied.","content":{"application/json":{"schema":{"type":"object","properties":{"duplicate":{"type":"boolean","const":true},"host_ref":{"type":"string"}}}}}}}}},"coreEvent":{"post":{"tags":["Webhooks"],"operationId":"receiveCoreEvent","summary":"A webhook delivery","description":"Sent to each subscribed webhook endpoint (Standard Webhooks). Verify `webhook-signature`\nwith the base64 decoded part of the `whsec_` secret; during a rotation it carries one\nsignature per secret, separated by spaces. Answer 2xx within 10 seconds; anything else is\nretried with the same `webhook-id`. A `410` disables the endpoint.\n","security":[],"parameters":[{"$ref":"#/components/parameters/WebhookId"},{"$ref":"#/components/parameters/WebhookTimestamp"},{"$ref":"#/components/parameters/WebhookSignature"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookMessage"}}}},"responses":{"200":{"description":"Received."},"410":{"description":"Gone; the endpoint is disabled."}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","bearerFormat":"okp_<env>_<prefix>_<secret>","description":"The API key. Test keys (`okp_test_`) read and write test data only. The list on each operation is the scope the key needs."},"requestSignature":{"type":"apiKey","in":"header","name":"Request-Signature","description":"`v1=<hex HMAC-SHA256(signing secret, canonical string)>`, together with Request-Timestamp and Request-Nonce. See the description at the top."},"widgetToken":{"type":"apiKey","in":"header","name":"X-Widget-Token","description":"The player token your server minted with `POST /v1/widget_tokens`. No API key and no signature on widget routes."}},"parameters":{"DocFormat":{"name":"format","in":"query","schema":{"type":"string","enum":["md","html","json"],"default":"md"}},"WidgetLang":{"name":"lang","in":"query","description":"Language of the player facing texts, e.g. `en` or `pt-BR`.","schema":{"type":"string","pattern":"^[a-z]{2}(-[A-Za-z]{2})?$","default":"en"}},"RequestTimestamp":{"name":"Request-Timestamp","in":"header","required":true,"description":"Unix seconds; within 300 seconds of the server clock.","schema":{"type":"string","pattern":"^[0-9]{1,12}$"}},"RequestNonce":{"name":"Request-Nonce","in":"header","required":true,"description":"Unique per request; accepted once.","schema":{"type":"string","pattern":"^[A-Za-z0-9._:-]{8,128}$"}},"IdempotencyKey":{"name":"Idempotency-Key","in":"header","required":true,"description":"1 to 255 printable ASCII characters. On `POST /v1/events` it equals the event id. A repeat within 24 hours gets the first answer.","schema":{"type":"string","minLength":1,"maxLength":255}},"Sync":{"name":"sync","in":"query","description":"Test keys only. `1` processes the event inline (sandbox and conformance).","schema":{"type":"string","enum":["1","true"]}},"EventId":{"name":"event_id","in":"path","required":true,"description":"Your event id.","schema":{"type":"string","minLength":1,"maxLength":128}},"ActionId":{"name":"id","in":"path","required":true,"description":"The action id.","schema":{"type":"string","pattern":"^act_[A-Za-z0-9]{1,64}$"}},"EndpointId":{"name":"id","in":"path","required":true,"description":"The webhook endpoint id.","schema":{"type":"string"}},"Plugins":{"name":"plugins","in":"query","required":true,"description":"Comma separated plugin keys, as the catalogue lists them (at most 40).","schema":{"type":"string","examples":["withdrawal-risk-engine,ledger-reconciliation"]}},"WebhookId":{"name":"webhook-id","in":"header","required":true,"description":"The message id; for an action, the action id. Deduplicate on it.","schema":{"type":"string"}},"WebhookTimestamp":{"name":"webhook-timestamp","in":"header","required":true,"description":"Unix seconds when the message was signed.","schema":{"type":"string"}},"WebhookSignature":{"name":"webhook-signature","in":"header","required":true,"description":"`v1,<base64 HMAC-SHA256(key, \"<webhook-id>.<webhook-timestamp>.<raw body>\")>`, one or more separated by spaces.","schema":{"type":"string"}}},"headers":{"RequestId":{"description":"The request id; quote it when you report a problem.","schema":{"type":"string"}},"RetryAfter":{"description":"Seconds to wait before retrying.","schema":{"type":"integer"}}},"responses":{"BadRequest":{"description":"The request is malformed (`invalid_request`, `invalid_json`, `idempotency_key_required`, `idempotency_key_invalid`).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"Unauthorized":{"description":"The key or the signature failed (`unauthenticated`, `key_revoked`, `key_expired`, `signature_invalid`, `timestamp_out_of_window`, `replayed`).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"Forbidden":{"description":"The key may not do this (`insufficient_scope`, `plugin_not_entitled`, `ip_not_allowed`, `source_paused`, `test_key_not_allowed`).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"NotFound":{"description":"Nothing with this id for this key (`not_found`, `mapping_not_found`).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"Conflict":{"description":"A conflicting state (`event_id_conflict`, `event_not_replayable`, `action_already_resolved`, `idempotency_key_reused`, `idempotency_key_in_progress`).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"PayloadTooLarge":{"description":"The body is too large (`payload_too_large`).","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"Unprocessable":{"description":"Valid JSON that breaks a rule (`schema_invalid`, `illegal_transition`, `mapping_failed`, `invalid_endpoint`); `errors` points at each field.","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"TooManyRequests":{"description":"A rate limit was hit (`rate_limited`, `ip_blocked`). Wait `Retry-After` seconds.","headers":{"Retry-After":{"$ref":"#/components/headers/RetryAfter"},"Request-Id":{"$ref":"#/components/headers/RequestId"}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}},"schemas":{"ActionData.bonus.grant":{"title":"bonus.grant","description":"`data` of a bonus.grant action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","additionalProperties":false,"properties":{"template_ref":{"type":"string","maxLength":128},"custom":{"type":"object","required":["kind"],"additionalProperties":false,"properties":{"kind":{"enum":["deposit_match","cash","free_spins","freebet","cashback","points","other"]},"amount":{"$ref":"#/components/schemas/Money"},"wagering_multiplier":{"type":"number","minimum":0,"maximum":1000},"expires_at":{"type":"string","format":"date-time"},"free_spins":{"type":"object","required":["count"],"additionalProperties":false,"properties":{"count":{"type":"integer","minimum":1,"maximum":10000},"game_ids":{"type":"array","maxItems":500,"items":{"type":"string","minLength":1,"maxLength":128}},"bet_value":{"$ref":"#/components/schemas/Money"}}}}},"reason":{"type":"string","maxLength":500},"campaign_ref":{"type":"string","maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"oneOf":[{"required":["template_ref"]},{"required":["custom"]}],"x-player":"required"},"ActionData.bonus.revoke":{"title":"bonus.revoke","description":"`data` of a bonus.revoke action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["bonus_id","reason"],"additionalProperties":false,"properties":{"bonus_id":{"type":"string","minLength":1,"maxLength":128},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.freespins.grant":{"title":"freespins.grant","description":"`data` of a freespins.grant action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["game_ids","count","bet_value","expires_at"],"additionalProperties":false,"properties":{"game_ids":{"type":"array","minItems":1,"maxItems":500,"items":{"type":"string","minLength":1,"maxLength":128}},"count":{"type":"integer","minimum":1,"maximum":10000},"bet_value":{"$ref":"#/components/schemas/Money"},"expires_at":{"type":"string","format":"date-time"},"wagering_multiplier":{"type":"number","minimum":0,"maximum":1000},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.game.disable":{"title":"game.disable","description":"`data` of a game.disable action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["game_id","scope","reason"],"additionalProperties":false,"properties":{"game_id":{"type":"string","minLength":1,"maxLength":128},"scope":{"enum":["brand","country"]},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"none"},"ActionData.game.enable":{"title":"game.enable","description":"`data` of a game.enable action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["game_id","scope","reason"],"additionalProperties":false,"properties":{"game_id":{"type":"string","minLength":1,"maxLength":128},"scope":{"enum":["brand","country"]},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"none"},"ActionData.kyc.request":{"title":"kyc.request","description":"`data` of a kyc.request action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["doc_types","reason"],"additionalProperties":false,"properties":{"doc_types":{"type":"array","minItems":1,"maxItems":8,"items":{"enum":["id_card","passport","driver_licence","proof_of_address","selfie","payment_proof","source_of_funds","other"]}},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.message.send":{"title":"message.send","description":"`data` of a message.send action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["channel","locale"],"additionalProperties":false,"properties":{"channel":{"enum":["email","sms","push","inbox","popup"]},"template_ref":{"type":"string","maxLength":128},"content":{"type":"object","additionalProperties":false,"minProperties":1,"properties":{"subject":{"type":"string","maxLength":256},"body_html":{"type":"string","maxLength":65536},"body_text":{"type":"string","maxLength":16384}}},"locale":{"type":"string","maxLength":35,"pattern":"^[A-Za-z]{2,3}(-[A-Za-z0-9]{1,8})*$"},"cta_url":{"type":"string","maxLength":2048,"format":"uri"},"meta":{"$ref":"#/components/schemas/Meta"}},"oneOf":[{"required":["template_ref"]},{"required":["content"]}],"x-player":"required"},"ActionData.player.block":{"title":"player.block","description":"`data` of a player.block action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["scope","reason"],"additionalProperties":false,"properties":{"scope":{"enum":["login","deposit","withdrawal","bonus","all"]},"reason":{"type":"string","maxLength":500},"until":{"type":"string","format":"date-time"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.player.flag":{"title":"player.flag","description":"`data` of a player.flag action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["detector","severity","summary"],"additionalProperties":false,"properties":{"detector":{"type":"string","pattern":"^[a-z0-9_]{1,64}$"},"severity":{"enum":["low","medium","high","critical"]},"summary":{"type":"string","maxLength":1000},"evidence":{"$ref":"#/components/schemas/Meta"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.player.limit_set":{"title":"player.limit_set","description":"`data` of a player.limit_set action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["kind","period"],"additionalProperties":false,"properties":{"kind":{"enum":["deposit","loss","wager","session"]},"amount":{"$ref":"#/components/schemas/Money"},"minutes":{"type":"integer","minimum":1,"maximum":525600},"period":{"enum":["day","week","month","session"]},"meta":{"$ref":"#/components/schemas/Meta"}},"oneOf":[{"required":["amount"]},{"required":["minutes"]}],"x-player":"required"},"ActionData.player.unblock":{"title":"player.unblock","description":"`data` of a player.unblock action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["scope","reason"],"additionalProperties":false,"properties":{"scope":{"enum":["login","deposit","withdrawal","bonus","all"]},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.points.credit":{"title":"points.credit","description":"`data` of a points.credit action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["points","reason"],"additionalProperties":false,"properties":{"points":{"type":"integer","minimum":1,"maximum":1000000000},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.wallet.credit":{"title":"wallet.credit","description":"`data` of a wallet.credit action (version 1). The whole action follows defs/v1/action_envelope.json. Reason `deposit`: a payment the platform took from a PSP for the player (cashier plugin), credited once to the player's real wallet. Reason `game_win`: the win of a game round an aggregator plugin settled for the player (aggregator_wallet), credited once to the real wallet; `reference` names the round and `meta` carries the provider, round_id, bet_id and transaction_id.","type":"object","required":["amount","wallet","reason","reference"],"additionalProperties":false,"properties":{"amount":{"$ref":"#/components/schemas/Money"},"wallet":{"enum":["real","bonus"]},"reason":{"enum":["cashback","points_conversion","jackpot","mission","adjustment","deposit","game_win"]},"reference":{"type":"string","maxLength":128},"play_through_multiplier":{"type":"number","minimum":0,"maximum":1000},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.wallet.debit":{"title":"wallet.debit","description":"`data` of a wallet.debit action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["amount","round_id","bet_id"],"additionalProperties":false,"properties":{"amount":{"$ref":"#/components/schemas/Money"},"round_id":{"type":"string","minLength":1,"maxLength":128},"bet_id":{"type":"string","minLength":1,"maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.wallet.rollback":{"title":"wallet.rollback","description":"`data` of a wallet.rollback action (version 1). Undoes a wallet.debit (debit timeout, cancelled round) or a wallet.credit. The core sends it through the outbox under the key \"<original idempotency_key>:rollback\" and copies round_id, bet_id, amount and transaction_id of the original, so the host can match it even when it never saw the original; a host answers a rollback for a transaction it never saw with idempotent success (conformance rollback_unknown_ok). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["original_type","original_idempotency_key"],"additionalProperties":false,"properties":{"original_type":{"enum":["wallet.debit","wallet.credit"]},"original_idempotency_key":{"type":"string","minLength":1,"maxLength":128},"original_action_id":{"type":"string","minLength":1,"maxLength":64},"reason":{"type":"string","maxLength":255},"amount":{"$ref":"#/components/schemas/Money"},"round_id":{"type":"string","minLength":1,"maxLength":128},"bet_id":{"type":"string","minLength":1,"maxLength":128},"transaction_id":{"type":"string","minLength":1,"maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.withdrawal.approve":{"title":"withdrawal.approve","description":"`data` of a withdrawal.approve action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["withdrawal_id","decision_ref"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"decision_ref":{"type":"string","maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.withdrawal.hold":{"title":"withdrawal.hold","description":"`data` of a withdrawal.hold action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["withdrawal_id","reason_code","decision_ref"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"reason_code":{"type":"string","pattern":"^[a-z0-9_]{1,64}$"},"decision_ref":{"type":"string","maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.withdrawal.reject":{"title":"withdrawal.reject","description":"`data` of a withdrawal.reject action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["withdrawal_id","decision_ref","reason_code"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"decision_ref":{"type":"string","maxLength":128},"reason_code":{"type":"string","pattern":"^[a-z0-9_]{1,64}$"},"player_message":{"type":"string","maxLength":1000},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionData.withdrawal.release":{"title":"withdrawal.release","description":"`data` of a withdrawal.release action (version 1). The whole action follows defs/v1/action_envelope.json.","type":"object","required":["withdrawal_id","reason_code","decision_ref"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"reason_code":{"type":"string","pattern":"^[a-z0-9_]{1,64}$"},"decision_ref":{"type":"string","maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"ActionEnvelope":{"title":"Outbound action envelope","description":"Body of every action Core sends to the host (and of GET /v1/actions in pull mode). `data` follows actions/v1/<type>.json.","type":"object","required":["id","type","version","created_at","data"],"additionalProperties":false,"properties":{"id":{"type":"string","pattern":"^act_[A-Za-z0-9]{1,64}$"},"type":{"type":"string","pattern":"^[a-z_]+\\.[a-z_]+$"},"version":{"type":"integer","minimum":1},"created_at":{"type":"string","format":"date-time"},"player":{"$ref":"#/components/schemas/PlayerRef"},"idempotency_key":{"type":"string","minLength":1,"maxLength":256},"data":{"type":"object"}}},"ActionPull":{"type":"object","required":["data","lease_seconds"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ActionState"}},"lease_seconds":{"type":"integer"}}},"ActionResult":{"type":"object","required":["status"],"properties":{"status":{"type":"string","enum":["applied","rejected","pending"]},"host_ref":{"type":"string","maxLength":191},"reason_code":{"type":"string","maxLength":191}}},"ActionState":{"type":"object","description":"An action envelope plus its state.","required":["id","type","version","created_at","data","status"],"properties":{"id":{"type":"string"},"type":{"type":"string"},"version":{"type":"integer"},"created_at":{"type":"string","format":"date-time"},"player":{"$ref":"#/components/schemas/PlayerRef"},"idempotency_key":{"type":"string"},"data":{"type":"object","description":"Follows the action type's schema (`HostAction`)."},"status":{"type":"string"},"money_bearing":{"type":"boolean"},"attempt":{"type":"integer"},"lease_expires_at":{"type":["string","null"],"format":"date-time"},"host_ref":{"type":["string","null"]},"reason_code":{"type":["string","null"]},"resolved_at":{"type":["string","null"],"format":"date-time"}}},"BatchResult":{"type":"object","required":["results"],"properties":{"batch_id":{"type":"string"},"accepted":{"type":"integer"},"duplicates":{"type":"integer"},"rejected":{"type":"integer"},"results":{"type":"array","items":{"type":"object","required":["index","status"],"properties":{"index":{"type":"integer"},"id":{"type":"string"},"status":{"type":"string","enum":["queued","duplicate","rejected","ignored"]},"error":{"type":"object","properties":{"code":{"type":"string"},"detail":{"type":"string"},"errors":{"type":"array","items":{"type":"object"}}}}}}}}},"Catalogue":{"type":"object","description":"The capability catalogue; `plugins` lists every plugin with what it requires.","required":["plugins"],"properties":{"plugins":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"name":{"type":"string"},"category":{"type":"string"},"requires":{"type":"object"},"scopes":{"type":"array","items":{"type":"string"}},"conformance":{"type":"array","items":{"type":"string"}}}}}}},"ConformanceCheckBrief":{"type":"object","required":["test_key","status"],"properties":{"test_key":{"type":"string"},"status":{"type":"string","enum":["pass","fail","warn","skip"]},"detail":{"type":"string"},"gain":{"type":"string"}}},"ConformancePluginView":{"type":"object","required":["plugin_key","required","boost","go_live_ready"],"properties":{"plugin_key":{"type":["string","null"]},"name":{"type":["string","null"]},"run_id":{"type":"integer"},"run_status":{"type":"string"},"finished_at":{"type":["string","null"],"format":"date-time"},"required":{"type":"object","properties":{"total":{"type":"integer"},"green":{"type":"integer"},"failing":{"type":"array","items":{"$ref":"#/components/schemas/ConformanceCheckBrief"}}}},"boost":{"type":"object","properties":{"total":{"type":"integer"},"met":{"type":"integer"},"missed":{"type":"array","items":{"$ref":"#/components/schemas/ConformanceCheckBrief"}}}},"go_live_ready":{"type":"boolean"}}},"ConformanceResult":{"type":"object","required":["test_key","status","class"],"properties":{"id":{"type":"integer"},"test_key":{"type":"string"},"plugin_key":{"type":["string","null"]},"status":{"type":"string","enum":["pass","fail","warn","skip"]},"class":{"type":"string","enum":["required","boost"]},"boost_miss":{"type":"boolean"},"gain":{"type":["string","null"]},"not_applicable":{"type":"boolean"},"carried_from_run":{"type":["integer","null"]},"detail":{"type":["string","null"]},"evidence":{"type":"object"},"duration_ms":{"type":["integer","null"]}}},"ConformanceRun":{"type":"object","required":["id","source_id","mode","status","plugin_keys","go_live_ready"],"properties":{"id":{"type":"integer"},"source_id":{"type":"integer"},"mode":{"type":"string","enum":["full","active","passive"]},"status":{"type":"string","enum":["queued","running","passed","failed","error"]},"plugin_keys":{"type":"array","items":{"type":"string"}},"origin":{"type":["string","null"]},"phase":{"type":["string","null"]},"settle_at":{"type":["string","null"]},"created_at":{"type":["string","null"],"format":"date-time"},"started_at":{"type":["string","null"],"format":"date-time"},"finished_at":{"type":["string","null"],"format":"date-time"},"triggered_by_account_id":{"type":["integer","null"]},"counts":{"type":"object","additionalProperties":{"type":"integer"}},"blocking":{"type":"array","description":"Required checks that failed, or were skipped for a reason other than not applicable.","items":{}},"boost":{"type":"array","description":"Boost checks that were missed, with what sending more would gain. Never blocking.","items":{}},"error":{"type":["string","null"]},"go_live_ready":{"type":"boolean"}}},"ConformanceRunDetail":{"allOf":[{"$ref":"#/components/schemas/ConformanceRun"},{"type":"object","properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/ConformanceResult"}},"plugins":{"type":"array","items":{"$ref":"#/components/schemas/ConformancePluginView"}}}}]},"ConformanceRunRequest":{"type":"object","properties":{"mode":{"type":"string","enum":["full","active","passive"]},"plugin_keys":{"type":"array","items":{"type":"string"}}}},"Currencies":{"type":"object","required":["version","currencies"],"properties":{"version":{"type":"integer"},"currencies":{"type":"object","description":"Keyed by currency code.","additionalProperties":{"type":"object","required":["exponent","kind"],"properties":{"exponent":{"type":"integer","minimum":0},"kind":{"type":"string","enum":["fiat","crypto"]}}}}}},"DeliveryList":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDelivery"}},"next_before":{"type":["string","null"]}}},"DeliveryStatus":{"type":"string","enum":["pending","sending","delivered","retry","dead","cancelled"]},"Digest":{"title":"Salted SHA-256 digest","description":"sha256 of '<per-tenant salt>:<normalised value>', lowercase hex. Raw identifiers are never accepted.","type":"object","required":["alg","value"],"additionalProperties":false,"properties":{"alg":{"const":"sha256-salted"},"value":{"type":"string","pattern":"^[a-f0-9]{64}$"}}},"Envelope":{"title":"Canonical event envelope","description":"Every event sent to POST /v1/events. `data` is validated against events/v1/<type>.json. `player` is required for every type except game.catalogue_synced.","type":"object","required":["id","type","occurred_at","data"],"additionalProperties":false,"properties":{"id":{"type":"string","minLength":1,"maxLength":128},"type":{"type":"string","pattern":"^[a-z_]+\\.[a-z_]+$"},"version":{"type":"integer","minimum":1,"default":1},"occurred_at":{"type":"string","format":"date-time"},"sequence":{"type":"integer","minimum":0,"maximum":9223372036854775807},"brand":{"type":"string","maxLength":64},"test":{"type":"boolean","default":false},"player":{"$ref":"#/components/schemas/PlayerRef"},"data":{"type":"object"}}},"Event":{"description":"Any canonical event; `type` picks the schema of `data`.","oneOf":[{"$ref":"#/components/schemas/Event.balance.changed"},{"$ref":"#/components/schemas/Event.bet.placed"},{"$ref":"#/components/schemas/Event.bet.rolled_back"},{"$ref":"#/components/schemas/Event.bet.settled"},{"$ref":"#/components/schemas/Event.bonus.activated"},{"$ref":"#/components/schemas/Event.bonus.completed"},{"$ref":"#/components/schemas/Event.bonus.expired"},{"$ref":"#/components/schemas/Event.bonus.forfeited"},{"$ref":"#/components/schemas/Event.bonus.granted"},{"$ref":"#/components/schemas/Event.bonus.wagering_progressed"},{"$ref":"#/components/schemas/Event.deposit.chargeback"},{"$ref":"#/components/schemas/Event.deposit.completed"},{"$ref":"#/components/schemas/Event.deposit.failed"},{"$ref":"#/components/schemas/Event.deposit.initiated"},{"$ref":"#/components/schemas/Event.deposit.reversed"},{"$ref":"#/components/schemas/Event.game.catalogue_synced"},{"$ref":"#/components/schemas/Event.game.launched"},{"$ref":"#/components/schemas/Event.kyc.document_uploaded"},{"$ref":"#/components/schemas/Event.kyc.status_changed"},{"$ref":"#/components/schemas/Event.player.consent_changed"},{"$ref":"#/components/schemas/Event.player.erased"},{"$ref":"#/components/schemas/Event.player.registered"},{"$ref":"#/components/schemas/Event.player.status_changed"},{"$ref":"#/components/schemas/Event.player.updated"},{"$ref":"#/components/schemas/Event.session.ended"},{"$ref":"#/components/schemas/Event.session.heartbeat"},{"$ref":"#/components/schemas/Event.session.started"},{"$ref":"#/components/schemas/Event.withdrawal.approved"},{"$ref":"#/components/schemas/Event.withdrawal.cancelled"},{"$ref":"#/components/schemas/Event.withdrawal.failed"},{"$ref":"#/components/schemas/Event.withdrawal.paid"},{"$ref":"#/components/schemas/Event.withdrawal.rejected"},{"$ref":"#/components/schemas/Event.withdrawal.requested"},{"$ref":"#/components/schemas/Event.withdrawal.returned"},{"$ref":"#/components/schemas/Event.withdrawal.reversed"}],"discriminator":{"propertyName":"type","mapping":{"balance.changed":"#/components/schemas/Event.balance.changed","bet.placed":"#/components/schemas/Event.bet.placed","bet.rolled_back":"#/components/schemas/Event.bet.rolled_back","bet.settled":"#/components/schemas/Event.bet.settled","bonus.activated":"#/components/schemas/Event.bonus.activated","bonus.completed":"#/components/schemas/Event.bonus.completed","bonus.expired":"#/components/schemas/Event.bonus.expired","bonus.forfeited":"#/components/schemas/Event.bonus.forfeited","bonus.granted":"#/components/schemas/Event.bonus.granted","bonus.wagering_progressed":"#/components/schemas/Event.bonus.wagering_progressed","deposit.chargeback":"#/components/schemas/Event.deposit.chargeback","deposit.completed":"#/components/schemas/Event.deposit.completed","deposit.failed":"#/components/schemas/Event.deposit.failed","deposit.initiated":"#/components/schemas/Event.deposit.initiated","deposit.reversed":"#/components/schemas/Event.deposit.reversed","game.catalogue_synced":"#/components/schemas/Event.game.catalogue_synced","game.launched":"#/components/schemas/Event.game.launched","kyc.document_uploaded":"#/components/schemas/Event.kyc.document_uploaded","kyc.status_changed":"#/components/schemas/Event.kyc.status_changed","player.consent_changed":"#/components/schemas/Event.player.consent_changed","player.erased":"#/components/schemas/Event.player.erased","player.registered":"#/components/schemas/Event.player.registered","player.status_changed":"#/components/schemas/Event.player.status_changed","player.updated":"#/components/schemas/Event.player.updated","session.ended":"#/components/schemas/Event.session.ended","session.heartbeat":"#/components/schemas/Event.session.heartbeat","session.started":"#/components/schemas/Event.session.started","withdrawal.approved":"#/components/schemas/Event.withdrawal.approved","withdrawal.cancelled":"#/components/schemas/Event.withdrawal.cancelled","withdrawal.failed":"#/components/schemas/Event.withdrawal.failed","withdrawal.paid":"#/components/schemas/Event.withdrawal.paid","withdrawal.rejected":"#/components/schemas/Event.withdrawal.rejected","withdrawal.requested":"#/components/schemas/Event.withdrawal.requested","withdrawal.returned":"#/components/schemas/Event.withdrawal.returned","withdrawal.reversed":"#/components/schemas/Event.withdrawal.reversed"}}},"Event.balance.changed":{"description":"A balance.changed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"balance.changed"},"data":{"$ref":"#/components/schemas/EventData.balance.changed"}}}]},"Event.bet.placed":{"description":"A bet.placed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bet.placed"},"data":{"$ref":"#/components/schemas/EventData.bet.placed"}}}]},"Event.bet.rolled_back":{"description":"A bet.rolled_back event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bet.rolled_back"},"data":{"$ref":"#/components/schemas/EventData.bet.rolled_back"}}}]},"Event.bet.settled":{"description":"A bet.settled event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bet.settled"},"data":{"$ref":"#/components/schemas/EventData.bet.settled"}}}]},"Event.bonus.activated":{"description":"A bonus.activated event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bonus.activated"},"data":{"$ref":"#/components/schemas/EventData.bonus.activated"}}}]},"Event.bonus.completed":{"description":"A bonus.completed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bonus.completed"},"data":{"$ref":"#/components/schemas/EventData.bonus.completed"}}}]},"Event.bonus.expired":{"description":"A bonus.expired event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bonus.expired"},"data":{"$ref":"#/components/schemas/EventData.bonus.expired"}}}]},"Event.bonus.forfeited":{"description":"A bonus.forfeited event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bonus.forfeited"},"data":{"$ref":"#/components/schemas/EventData.bonus.forfeited"}}}]},"Event.bonus.granted":{"description":"A bonus.granted event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bonus.granted"},"data":{"$ref":"#/components/schemas/EventData.bonus.granted"}}}]},"Event.bonus.wagering_progressed":{"description":"A bonus.wagering_progressed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bonus.wagering_progressed"},"data":{"$ref":"#/components/schemas/EventData.bonus.wagering_progressed"}}}]},"Event.deposit.chargeback":{"description":"A deposit.chargeback event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"deposit.chargeback"},"data":{"$ref":"#/components/schemas/EventData.deposit.chargeback"}}}]},"Event.deposit.completed":{"description":"A deposit.completed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"deposit.completed"},"data":{"$ref":"#/components/schemas/EventData.deposit.completed"}}}]},"Event.deposit.failed":{"description":"A deposit.failed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"deposit.failed"},"data":{"$ref":"#/components/schemas/EventData.deposit.failed"}}}]},"Event.deposit.initiated":{"description":"A deposit.initiated event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"deposit.initiated"},"data":{"$ref":"#/components/schemas/EventData.deposit.initiated"}}}]},"Event.deposit.reversed":{"description":"A deposit.reversed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"deposit.reversed"},"data":{"$ref":"#/components/schemas/EventData.deposit.reversed"}}}]},"Event.game.catalogue_synced":{"description":"A game.catalogue_synced event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"game.catalogue_synced"},"data":{"$ref":"#/components/schemas/EventData.game.catalogue_synced"}}}]},"Event.game.launched":{"description":"A game.launched event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"game.launched"},"data":{"$ref":"#/components/schemas/EventData.game.launched"}}}]},"Event.kyc.document_uploaded":{"description":"A kyc.document_uploaded event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"kyc.document_uploaded"},"data":{"$ref":"#/components/schemas/EventData.kyc.document_uploaded"}}}]},"Event.kyc.status_changed":{"description":"A kyc.status_changed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"kyc.status_changed"},"data":{"$ref":"#/components/schemas/EventData.kyc.status_changed"}}}]},"Event.player.consent_changed":{"description":"A player.consent_changed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.consent_changed"},"data":{"$ref":"#/components/schemas/EventData.player.consent_changed"}}}]},"Event.player.erased":{"description":"A player.erased event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.erased"},"data":{"$ref":"#/components/schemas/EventData.player.erased"}}}]},"Event.player.registered":{"description":"A player.registered event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.registered"},"data":{"$ref":"#/components/schemas/EventData.player.registered"}}}]},"Event.player.status_changed":{"description":"A player.status_changed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.status_changed"},"data":{"$ref":"#/components/schemas/EventData.player.status_changed"}}}]},"Event.player.updated":{"description":"A player.updated event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.updated"},"data":{"$ref":"#/components/schemas/EventData.player.updated"}}}]},"Event.session.ended":{"description":"A session.ended event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"session.ended"},"data":{"$ref":"#/components/schemas/EventData.session.ended"}}}]},"Event.session.heartbeat":{"description":"A session.heartbeat event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"session.heartbeat"},"data":{"$ref":"#/components/schemas/EventData.session.heartbeat"}}}]},"Event.session.started":{"description":"A session.started event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"session.started"},"data":{"$ref":"#/components/schemas/EventData.session.started"}}}]},"Event.withdrawal.approved":{"description":"A withdrawal.approved event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.approved"},"data":{"$ref":"#/components/schemas/EventData.withdrawal.approved"}}}]},"Event.withdrawal.cancelled":{"description":"A withdrawal.cancelled event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.cancelled"},"data":{"$ref":"#/components/schemas/EventData.withdrawal.cancelled"}}}]},"Event.withdrawal.failed":{"description":"A withdrawal.failed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.failed"},"data":{"$ref":"#/components/schemas/EventData.withdrawal.failed"}}}]},"Event.withdrawal.paid":{"description":"A withdrawal.paid event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.paid"},"data":{"$ref":"#/components/schemas/EventData.withdrawal.paid"}}}]},"Event.withdrawal.rejected":{"description":"A withdrawal.rejected event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.rejected"},"data":{"$ref":"#/components/schemas/EventData.withdrawal.rejected"}}}]},"Event.withdrawal.requested":{"description":"A withdrawal.requested event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.requested"},"data":{"$ref":"#/components/schemas/EventData.withdrawal.requested"}}}]},"Event.withdrawal.returned":{"description":"A withdrawal.returned event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.returned"},"data":{"$ref":"#/components/schemas/EventData.withdrawal.returned"}}}]},"Event.withdrawal.reversed":{"description":"A withdrawal.reversed event.","allOf":[{"$ref":"#/components/schemas/Envelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.reversed"},"data":{"$ref":"#/components/schemas/EventData.withdrawal.reversed"}}}]},"EventBatch":{"oneOf":[{"type":"array","minItems":1,"maxItems":500,"items":{"$ref":"#/components/schemas/Event"}},{"type":"object","required":["events"],"properties":{"events":{"type":"array","minItems":1,"maxItems":500,"items":{"$ref":"#/components/schemas/Event"}}}}]},"EventData.balance.changed":{"title":"balance.changed","description":"`data` of a balance.changed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["as_of","balances"],"additionalProperties":false,"properties":{"as_of":{"type":"string","format":"date-time"},"balances":{"type":"array","minItems":1,"maxItems":20,"items":{"type":"object","required":["currency","real"],"additionalProperties":false,"properties":{"currency":{"type":"string","pattern":"^[A-Z0-9]{3,10}$","x-currency":true},"real":{"$ref":"#/components/schemas/Money"},"bonus":{"$ref":"#/components/schemas/Money"},"locked":{"$ref":"#/components/schemas/Money"}}}},"reason":{"enum":["bet","win","deposit","withdrawal","bonus","adjustment","snapshot"]},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.bet.placed":{"title":"bet.placed","description":"`data` of a bet.placed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bet_id","game_id","vertical","stake","placed_at"],"additionalProperties":false,"properties":{"bet_id":{"type":"string","minLength":1,"maxLength":128},"game_id":{"type":"string","minLength":1,"maxLength":128},"vertical":{"enum":["casino","live","sport","virtual"]},"stake":{"$ref":"#/components/schemas/Money"},"placed_at":{"type":"string","format":"date-time"},"round_id":{"type":"string","minLength":1,"maxLength":128},"provider":{"type":"string","maxLength":64},"studio":{"type":"string","maxLength":64},"real_stake":{"$ref":"#/components/schemas/Money"},"bonus_stake":{"$ref":"#/components/schemas/Money"},"bonus_ref":{"type":"string","maxLength":128},"free_spin":{"type":"boolean"},"sport":{"type":"object","additionalProperties":false,"properties":{"event_id":{"type":"string","maxLength":128},"market":{"type":"string","maxLength":128},"selection":{"type":"string","maxLength":256},"odds_decimal":{"type":"string","pattern":"^[0-9]{1,6}(\\.[0-9]{1,6})?$"},"live":{"type":"boolean"},"legs":{"type":"integer","minimum":1,"maximum":100}}},"meta":{"$ref":"#/components/schemas/Meta"}},"x-same-currency":["stake","real_stake","bonus_stake"],"x-player":"required"},"EventData.bet.rolled_back":{"title":"bet.rolled_back","description":"`data` of a bet.rolled_back event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bet_id","amount"],"additionalProperties":false,"properties":{"bet_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"reason":{"type":"string","maxLength":500},"round_id":{"type":"string","minLength":1,"maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.bet.settled":{"title":"bet.settled","description":"`data` of a bet.settled event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bet_id","game_id","vertical","stake","win","result","settled_at"],"additionalProperties":false,"properties":{"bet_id":{"type":"string","minLength":1,"maxLength":128},"game_id":{"type":"string","minLength":1,"maxLength":128},"vertical":{"enum":["casino","live","sport","virtual"]},"stake":{"$ref":"#/components/schemas/Money"},"placed_at":{"type":"string","format":"date-time"},"round_id":{"type":"string","minLength":1,"maxLength":128},"provider":{"type":"string","maxLength":64},"studio":{"type":"string","maxLength":64},"real_stake":{"$ref":"#/components/schemas/Money"},"bonus_stake":{"$ref":"#/components/schemas/Money"},"bonus_ref":{"type":"string","maxLength":128},"free_spin":{"type":"boolean"},"sport":{"type":"object","additionalProperties":false,"properties":{"event_id":{"type":"string","maxLength":128},"market":{"type":"string","maxLength":128},"selection":{"type":"string","maxLength":256},"odds_decimal":{"type":"string","pattern":"^[0-9]{1,6}(\\.[0-9]{1,6})?$"},"live":{"type":"boolean"},"legs":{"type":"integer","minimum":1,"maximum":100}}},"win":{"$ref":"#/components/schemas/Money"},"result":{"enum":["win","loss","push","cashout","void"]},"settled_at":{"type":"string","format":"date-time"},"real_win":{"$ref":"#/components/schemas/Money"},"bonus_win":{"$ref":"#/components/schemas/Money"},"jackpot_win":{"$ref":"#/components/schemas/Money"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-same-currency":["stake","win","real_stake","bonus_stake","real_win","bonus_win","jackpot_win"],"x-player":"required"},"EventData.bonus.activated":{"title":"bonus.activated","description":"`data` of a bonus.activated event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bonus_id"],"additionalProperties":false,"properties":{"bonus_id":{"type":"string","minLength":1,"maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.bonus.completed":{"title":"bonus.completed","description":"`data` of a bonus.completed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bonus_id"],"additionalProperties":false,"properties":{"bonus_id":{"type":"string","minLength":1,"maxLength":128},"converted":{"$ref":"#/components/schemas/Money"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.bonus.expired":{"title":"bonus.expired","description":"`data` of a bonus.expired event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bonus_id"],"additionalProperties":false,"properties":{"bonus_id":{"type":"string","minLength":1,"maxLength":128},"forfeited":{"$ref":"#/components/schemas/Money"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.bonus.forfeited":{"title":"bonus.forfeited","description":"`data` of a bonus.forfeited event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bonus_id"],"additionalProperties":false,"properties":{"bonus_id":{"type":"string","minLength":1,"maxLength":128},"forfeited":{"$ref":"#/components/schemas/Money"},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.bonus.granted":{"title":"bonus.granted","description":"`data` of a bonus.granted event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bonus_id","kind"],"additionalProperties":false,"properties":{"bonus_id":{"type":"string","minLength":1,"maxLength":128},"kind":{"enum":["deposit_match","cash","free_spins","freebet","cashback","points","other"]},"template_ref":{"type":"string","maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"free_spins":{"type":"object","required":["count"],"additionalProperties":false,"properties":{"count":{"type":"integer","minimum":1,"maximum":10000},"game_ids":{"type":"array","maxItems":500,"items":{"type":"string","minLength":1,"maxLength":128}},"bet_value":{"$ref":"#/components/schemas/Money"}}},"wagering_multiplier":{"type":"number","minimum":0,"maximum":1000},"wagering_required":{"$ref":"#/components/schemas/Money"},"expires_at":{"type":"string","format":"date-time"},"granted_by":{"enum":["host","plugin"]},"action_id":{"type":"string","pattern":"^act_[A-Za-z0-9]{1,64}$"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.bonus.wagering_progressed":{"title":"bonus.wagering_progressed","description":"`data` of a bonus.wagering_progressed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["bonus_id","wagered","required"],"additionalProperties":false,"properties":{"bonus_id":{"type":"string","minLength":1,"maxLength":128},"wagered":{"$ref":"#/components/schemas/Money"},"required":{"$ref":"#/components/schemas/Money"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-same-currency":["wagered","required"],"x-player":"required"},"EventData.deposit.chargeback":{"title":"deposit.chargeback","description":"`data` of a deposit.chargeback event (version 1). Validate the whole event against defs/v1/envelope.json first. Reversal type from DESIGN 2.4 (security M7): allowed after a terminal state, writes a new linked row.","type":"object","required":["deposit_id","amount"],"additionalProperties":false,"properties":{"deposit_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"chargeback_at":{"type":"string","format":"date-time"},"reason_code":{"type":"string","pattern":"^[a-z0-9_]{1,64}$"},"reason":{"type":"string","maxLength":500},"dispute_ref":{"type":"string","maxLength":128},"provider":{"type":"string","maxLength":64},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.deposit.completed":{"title":"deposit.completed","description":"`data` of a deposit.completed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["deposit_id","amount","completed_at"],"additionalProperties":false,"properties":{"deposit_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"completed_at":{"type":"string","format":"date-time"},"credited_amount":{"$ref":"#/components/schemas/Money"},"fee":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"provider":{"type":"string","maxLength":64},"psp_ref":{"type":"string","maxLength":128},"instrument":{"$ref":"#/components/schemas/Instrument"},"bonus_code":{"type":"string","maxLength":64},"host_first_deposit":{"type":"boolean"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.deposit.failed":{"title":"deposit.failed","description":"`data` of a deposit.failed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["deposit_id","amount","reason_code"],"additionalProperties":false,"properties":{"deposit_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"reason_code":{"enum":["declined","insufficient_funds","fraud","expired","cancelled","limit","technical","other"]},"reason":{"type":"string","maxLength":500},"provider":{"type":"string","maxLength":64},"instrument":{"$ref":"#/components/schemas/Instrument"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.deposit.initiated":{"title":"deposit.initiated","description":"`data` of a deposit.initiated event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["deposit_id","amount"],"additionalProperties":false,"properties":{"deposit_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"provider":{"type":"string","maxLength":64},"psp_ref":{"type":"string","maxLength":128},"instrument":{"$ref":"#/components/schemas/Instrument"},"ip":{"$ref":"#/components/schemas/Ip"},"bonus_code":{"type":"string","maxLength":64},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.deposit.reversed":{"title":"deposit.reversed","description":"`data` of a deposit.reversed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["deposit_id","amount","kind"],"additionalProperties":false,"properties":{"deposit_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"kind":{"enum":["chargeback","refund","reversal"]},"reason":{"type":"string","maxLength":500},"reversed_at":{"type":"string","format":"date-time"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.game.catalogue_synced":{"title":"game.catalogue_synced","description":"`data` of a game.catalogue_synced event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["games","full"],"additionalProperties":false,"properties":{"games":{"type":"array","minItems":1,"maxItems":500,"items":{"type":"object","required":["game_id","name","provider","vertical","enabled"],"additionalProperties":false,"properties":{"game_id":{"type":"string","minLength":1,"maxLength":128},"name":{"type":"string","maxLength":256},"provider":{"type":"string","maxLength":64},"vertical":{"enum":["casino","live","sport","virtual"]},"enabled":{"type":"boolean"},"studio":{"type":"string","maxLength":64},"rtp":{"type":"number","minimum":0,"maximum":100},"themes":{"type":"array","maxItems":20,"items":{"type":"string","maxLength":64}},"launch_url_template":{"type":"string","maxLength":2048}}}},"full":{"type":"boolean"},"sync_id":{"type":"string","minLength":1,"maxLength":128,"pattern":"^[A-Za-z0-9._:-]+$","description":"Groups the batches of one catalogue sync. Send sync_id, batch_index and batch_total together. With full: true, games the sync does not name are disabled only once every batch 1..batch_total has arrived."},"batch_index":{"type":"integer","minimum":1,"maximum":10000,"description":"1-based position of this batch in the sync (requires sync_id and batch_total)."},"batch_total":{"type":"integer","minimum":1,"maximum":10000,"description":"How many batches the sync has (requires sync_id and batch_index). Every batch of a sync sends the same full and batch_total."},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"none"},"EventData.game.launched":{"title":"game.launched","description":"`data` of a game.launched event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["game_id","launched_at"],"additionalProperties":false,"properties":{"game_id":{"type":"string","minLength":1,"maxLength":128},"launched_at":{"type":"string","format":"date-time"},"session_id":{"type":"string","minLength":1,"maxLength":128},"mode":{"enum":["real","demo"]},"device":{"type":"string","maxLength":64},"provider":{"type":"string","maxLength":64},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.kyc.document_uploaded":{"title":"kyc.document_uploaded","description":"`data` of a kyc.document_uploaded event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["document_id","doc_type","uploaded_at"],"additionalProperties":false,"properties":{"document_id":{"type":"string","minLength":1,"maxLength":128},"doc_type":{"enum":["id_card","passport","driver_licence","proof_of_address","selfie","payment_proof","source_of_funds","other"]},"uploaded_at":{"type":"string","format":"date-time"},"file":{"type":"object","required":["url","expires_at"],"additionalProperties":false,"properties":{"url":{"type":"string","maxLength":2048,"format":"uri"},"expires_at":{"type":"string","format":"date-time"},"sha256":{"type":"string","pattern":"^[a-f0-9]{64}$"},"mime":{"type":"string","maxLength":128},"size":{"type":"integer","minimum":0,"maximum":104857600}}},"side":{"enum":["front","back"]},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.kyc.status_changed":{"title":"kyc.status_changed","description":"`data` of a kyc.status_changed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["level"],"additionalProperties":false,"properties":{"level":{"enum":["none","pending","partially_verified","fully_verified","rejected"]},"per_type":{"type":"object","additionalProperties":false,"properties":{"id_card":{"enum":["pending","approved","rejected"]},"passport":{"enum":["pending","approved","rejected"]},"driver_licence":{"enum":["pending","approved","rejected"]},"proof_of_address":{"enum":["pending","approved","rejected"]},"selfie":{"enum":["pending","approved","rejected"]},"payment_proof":{"enum":["pending","approved","rejected"]},"source_of_funds":{"enum":["pending","approved","rejected"]},"other":{"enum":["pending","approved","rejected"]}}},"reviewed_by":{"enum":["host","plugin","vendor"]},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.player.consent_changed":{"title":"player.consent_changed","description":"`data` of a player.consent_changed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["channel","granted"],"additionalProperties":false,"properties":{"channel":{"enum":["email","sms","push","phone","whatsapp","telegram"]},"granted":{"type":"boolean"},"source":{"type":"string","maxLength":64},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.player.erased":{"title":"player.erased","description":"`data` of a player.erased event (version 1): the player asked to be forgotten (DESIGN 11 Erasure). The core records a core_erasure_requests row, scrubs the player's core rows within 24 hours (digests kept only where an enabled plugin's PII manifest says fraud needs them) and fans the player.erased webhook out. The event itself carries no personal value. Validate the whole event against defs/v1/envelope.json first.","type":"object","additionalProperties":false,"properties":{"requested_at":{"type":"string","format":"date-time"},"reason":{"type":"string","maxLength":500},"by":{"enum":["player","staff","regulator","system"]},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.player.registered":{"title":"player.registered","description":"`data` of a player.registered event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["registered_at","currency"],"additionalProperties":false,"properties":{"registered_at":{"type":"string","format":"date-time"},"currency":{"type":"string","pattern":"^[A-Z0-9]{3,10}$","x-currency":true},"email":{"type":"string","maxLength":254,"format":"email"},"email_verified":{"type":"boolean"},"phone":{"type":"string","pattern":"^\\+[1-9][0-9]{6,14}$"},"phone_verified":{"type":"boolean"},"first_name":{"type":"string","maxLength":100},"last_name":{"type":"string","maxLength":100},"birth_date":{"type":"string","format":"date"},"gender":{"enum":["m","f","x"]},"country":{"type":"string","pattern":"^[A-Z]{2}$"},"language":{"type":"string","maxLength":35,"pattern":"^[A-Za-z]{2,3}(-[A-Za-z0-9]{1,8})*$"},"city":{"type":"string","maxLength":100},"registration_ip":{"$ref":"#/components/schemas/Ip"},"user_agent":{"type":"string","maxLength":512},"device_id_digest":{"$ref":"#/components/schemas/Digest"},"tax_id_digest":{"$ref":"#/components/schemas/Digest"},"affiliate":{"type":"object","additionalProperties":false,"properties":{"affiliate_ref":{"type":"string","maxLength":128},"tracking_link_id":{"type":"string","maxLength":128},"click_id":{"type":"string","maxLength":256},"stid":{"type":"string","maxLength":128},"tlid":{"type":"string","maxLength":128},"campaign":{"type":"string","maxLength":128},"landing_url":{"type":"string","maxLength":2048,"format":"uri"},"sub_ids":{"type":"object","maxProperties":20,"additionalProperties":{"type":"string","maxLength":256}}}},"consents":{"type":"object","additionalProperties":false,"properties":{"email":{"type":"boolean"},"sms":{"type":"boolean"},"push":{"type":"boolean"},"phone":{"type":"boolean"},"whatsapp":{"type":"boolean"},"telegram":{"type":"boolean"}}},"segment_ref":{"type":"string","maxLength":128},"vip_level":{"type":"string","maxLength":64},"is_test":{"type":"boolean"},"check_ref":{"type":"string","maxLength":64,"pattern":"^rcc_[0-9A-Za-z]{1,60}$","description":"The check_id a registration-check /check answer returned for this sign-up (rcc_...). Links the player to that check instead of matching by external id."},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.player.status_changed":{"title":"player.status_changed","description":"`data` of a player.status_changed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["status"],"additionalProperties":false,"properties":{"status":{"enum":["active","blocked","frozen","self_excluded","cooling_off","closed"]},"reason":{"type":"string","maxLength":500},"until":{"type":"string","format":"date-time"},"by":{"enum":["player","staff","system"]},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.player.updated":{"title":"player.updated","description":"`data` of a player.updated event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["changes"],"additionalProperties":false,"properties":{"changes":{"$ref":"#/components/schemas/PlayerProfile","minProperties":1},"snapshot":{"$ref":"#/components/schemas/PlayerProfile"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.session.ended":{"title":"session.ended","description":"`data` of a session.ended event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["session_id","ended_at"],"additionalProperties":false,"properties":{"session_id":{"type":"string","minLength":1,"maxLength":128},"ended_at":{"type":"string","format":"date-time"},"reason":{"enum":["logout","timeout","kicked","other"]},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.session.heartbeat":{"title":"session.heartbeat","description":"`data` of a session.heartbeat event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["session_id","at"],"additionalProperties":false,"properties":{"session_id":{"type":"string","minLength":1,"maxLength":128},"at":{"type":"string","format":"date-time"},"page":{"type":"string","maxLength":512},"game_id":{"type":"string","minLength":1,"maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.session.started":{"title":"session.started","description":"`data` of a session.started event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["session_id","started_at"],"additionalProperties":false,"properties":{"session_id":{"type":"string","minLength":1,"maxLength":128},"started_at":{"type":"string","format":"date-time"},"ip":{"$ref":"#/components/schemas/Ip"},"country":{"type":"string","pattern":"^[A-Z]{2}$"},"channel":{"enum":["web","mobile_web","ios","android","desktop"]},"user_agent":{"type":"string","maxLength":512},"device_id_digest":{"$ref":"#/components/schemas/Digest"},"login_method":{"enum":["password","otp","social","token"]},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.withdrawal.approved":{"title":"withdrawal.approved","description":"`data` of a withdrawal.approved event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["withdrawal_id","amount"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"approved_by":{"enum":["auto","staff"]},"rule":{"type":"string","maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.withdrawal.cancelled":{"title":"withdrawal.cancelled","description":"`data` of a withdrawal.cancelled event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["withdrawal_id","amount","by"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"by":{"enum":["player","staff","system"]},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.withdrawal.failed":{"title":"withdrawal.failed","description":"`data` of a withdrawal.failed event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["withdrawal_id","amount","reason_code","refunded"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"reason_code":{"type":"string","pattern":"^[a-z0-9_]{1,64}$"},"refunded":{"type":"boolean"},"reason":{"type":"string","maxLength":500},"provider":{"type":"string","maxLength":64},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.withdrawal.paid":{"title":"withdrawal.paid","description":"`data` of a withdrawal.paid event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["withdrawal_id","amount","paid_at"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"paid_at":{"type":"string","format":"date-time"},"fee":{"$ref":"#/components/schemas/Money"},"psp_ref":{"type":"string","maxLength":128},"provider":{"type":"string","maxLength":64},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.withdrawal.rejected":{"title":"withdrawal.rejected","description":"`data` of a withdrawal.rejected event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["withdrawal_id","amount","reason_code","refunded"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"reason_code":{"type":"string","pattern":"^[a-z0-9_]{1,64}$"},"refunded":{"type":"boolean"},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.withdrawal.requested":{"title":"withdrawal.requested","description":"`data` of a withdrawal.requested event (version 1). Validate the whole event against defs/v1/envelope.json first.","type":"object","required":["withdrawal_id","amount","requested_at"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"requested_at":{"type":"string","format":"date-time"},"provider":{"type":"string","maxLength":64},"destination":{"type":"object","required":["kind"],"additionalProperties":false,"properties":{"kind":{"enum":["card","bank","ewallet","crypto","pix","voucher","mobile","other"]},"digest":{"$ref":"#/components/schemas/Digest"}}},"balance_after":{"$ref":"#/components/schemas/Money"},"decision_ref":{"type":"string","maxLength":128},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.withdrawal.returned":{"title":"withdrawal.returned","description":"`data` of a withdrawal.returned event (version 1). Validate the whole event against defs/v1/envelope.json first. Reversal type from DESIGN 2.4 (security M7): allowed after a terminal state, writes a new linked row.","type":"object","required":["withdrawal_id","amount","returned_at"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"returned_at":{"type":"string","format":"date-time"},"reason":{"type":"string","maxLength":500},"psp_ref":{"type":"string","maxLength":128},"provider":{"type":"string","maxLength":64},"refunded":{"type":"boolean"},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventData.withdrawal.reversed":{"title":"withdrawal.reversed","description":"`data` of a withdrawal.reversed event (version 1). Validate the whole event against defs/v1/envelope.json first. Reversal type from DESIGN 2.4 (security M7): allowed after a terminal state, writes a new linked row.","type":"object","required":["withdrawal_id","amount"],"additionalProperties":false,"properties":{"withdrawal_id":{"type":"string","minLength":1,"maxLength":128},"amount":{"$ref":"#/components/schemas/Money"},"method":{"type":"string","maxLength":64},"reversed_at":{"type":"string","format":"date-time"},"reason":{"type":"string","maxLength":500},"meta":{"$ref":"#/components/schemas/Meta"}},"x-player":"required"},"EventDuplicate":{"type":"object","required":["status","original_status"],"properties":{"status":{"type":"string","const":"duplicate"},"original_status":{"$ref":"#/components/schemas/EventStatusName"},"event_id":{"type":"string"}}},"EventList":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/EventStatus"}},"next_cursor":{"type":"string"},"request_id":{"type":"string"}}},"EventQueued":{"type":"object","required":["status","event_id"],"properties":{"status":{"type":"string","const":"queued"},"event_id":{"type":"string"}}},"EventReplayed":{"type":"object","required":["status","event_id","previous_status"],"properties":{"status":{"type":"string","const":"queued"},"event_id":{"type":"string"},"previous_status":{"$ref":"#/components/schemas/EventStatusName"},"request_id":{"type":"string"}}},"EventStatus":{"type":"object","required":["event_id","type","status"],"properties":{"event_id":{"type":"string"},"type":{"type":"string"},"version":{"type":"integer"},"status":{"$ref":"#/components/schemas/EventStatusName"},"occurred_at":{"type":"string","format":"date-time"},"received_at":{"type":"string","format":"date-time"},"processed_at":{"type":"string","format":"date-time"},"attempts":{"type":"integer"},"next_attempt_at":{"type":"string","format":"date-time"},"sequence":{"type":"integer"},"batch_id":{"type":"string"},"test":{"type":"boolean"},"replayable":{"type":"boolean"},"error":{"type":"object","properties":{"code":{"type":"string"},"detail":{"type":"string"}}},"alias_of":{"type":"string"},"payload_retained":{"type":"boolean"},"request_id":{"type":"string"}}},"EventStatusName":{"type":"string","enum":["received","queued","processing","applied","applied_stale","deferred","failed","dead","orphaned"]},"Health":{"type":"object","required":["ok"],"properties":{"ok":{"type":"boolean","const":true}}},"HostAction":{"description":"Any action sent to the platform; `type` picks the schema of `data`.","oneOf":[{"$ref":"#/components/schemas/HostAction.bonus.grant"},{"$ref":"#/components/schemas/HostAction.bonus.revoke"},{"$ref":"#/components/schemas/HostAction.freespins.grant"},{"$ref":"#/components/schemas/HostAction.game.disable"},{"$ref":"#/components/schemas/HostAction.game.enable"},{"$ref":"#/components/schemas/HostAction.kyc.request"},{"$ref":"#/components/schemas/HostAction.message.send"},{"$ref":"#/components/schemas/HostAction.player.block"},{"$ref":"#/components/schemas/HostAction.player.flag"},{"$ref":"#/components/schemas/HostAction.player.limit_set"},{"$ref":"#/components/schemas/HostAction.player.unblock"},{"$ref":"#/components/schemas/HostAction.points.credit"},{"$ref":"#/components/schemas/HostAction.wallet.credit"},{"$ref":"#/components/schemas/HostAction.wallet.debit"},{"$ref":"#/components/schemas/HostAction.wallet.rollback"},{"$ref":"#/components/schemas/HostAction.withdrawal.approve"},{"$ref":"#/components/schemas/HostAction.withdrawal.hold"},{"$ref":"#/components/schemas/HostAction.withdrawal.reject"},{"$ref":"#/components/schemas/HostAction.withdrawal.release"}],"discriminator":{"propertyName":"type","mapping":{"bonus.grant":"#/components/schemas/HostAction.bonus.grant","bonus.revoke":"#/components/schemas/HostAction.bonus.revoke","freespins.grant":"#/components/schemas/HostAction.freespins.grant","game.disable":"#/components/schemas/HostAction.game.disable","game.enable":"#/components/schemas/HostAction.game.enable","kyc.request":"#/components/schemas/HostAction.kyc.request","message.send":"#/components/schemas/HostAction.message.send","player.block":"#/components/schemas/HostAction.player.block","player.flag":"#/components/schemas/HostAction.player.flag","player.limit_set":"#/components/schemas/HostAction.player.limit_set","player.unblock":"#/components/schemas/HostAction.player.unblock","points.credit":"#/components/schemas/HostAction.points.credit","wallet.credit":"#/components/schemas/HostAction.wallet.credit","wallet.debit":"#/components/schemas/HostAction.wallet.debit","wallet.rollback":"#/components/schemas/HostAction.wallet.rollback","withdrawal.approve":"#/components/schemas/HostAction.withdrawal.approve","withdrawal.hold":"#/components/schemas/HostAction.withdrawal.hold","withdrawal.reject":"#/components/schemas/HostAction.withdrawal.reject","withdrawal.release":"#/components/schemas/HostAction.withdrawal.release"}}},"HostAction.bonus.grant":{"description":"A bonus.grant action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bonus.grant"},"data":{"$ref":"#/components/schemas/ActionData.bonus.grant"}}}]},"HostAction.bonus.revoke":{"description":"A bonus.revoke action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"bonus.revoke"},"data":{"$ref":"#/components/schemas/ActionData.bonus.revoke"}}}]},"HostAction.freespins.grant":{"description":"A freespins.grant action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"freespins.grant"},"data":{"$ref":"#/components/schemas/ActionData.freespins.grant"}}}]},"HostAction.game.disable":{"description":"A game.disable action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"game.disable"},"data":{"$ref":"#/components/schemas/ActionData.game.disable"}}}]},"HostAction.game.enable":{"description":"A game.enable action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"game.enable"},"data":{"$ref":"#/components/schemas/ActionData.game.enable"}}}]},"HostAction.kyc.request":{"description":"A kyc.request action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"kyc.request"},"data":{"$ref":"#/components/schemas/ActionData.kyc.request"}}}]},"HostAction.message.send":{"description":"A message.send action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"message.send"},"data":{"$ref":"#/components/schemas/ActionData.message.send"}}}]},"HostAction.player.block":{"description":"A player.block action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.block"},"data":{"$ref":"#/components/schemas/ActionData.player.block"}}}]},"HostAction.player.flag":{"description":"A player.flag action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.flag"},"data":{"$ref":"#/components/schemas/ActionData.player.flag"}}}]},"HostAction.player.limit_set":{"description":"A player.limit_set action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.limit_set"},"data":{"$ref":"#/components/schemas/ActionData.player.limit_set"}}}]},"HostAction.player.unblock":{"description":"A player.unblock action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"player.unblock"},"data":{"$ref":"#/components/schemas/ActionData.player.unblock"}}}]},"HostAction.points.credit":{"description":"A points.credit action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"points.credit"},"data":{"$ref":"#/components/schemas/ActionData.points.credit"}}}]},"HostAction.wallet.credit":{"description":"A wallet.credit action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"wallet.credit"},"data":{"$ref":"#/components/schemas/ActionData.wallet.credit"}}}]},"HostAction.wallet.debit":{"description":"A wallet.debit action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"wallet.debit"},"data":{"$ref":"#/components/schemas/ActionData.wallet.debit"}}}]},"HostAction.wallet.rollback":{"description":"A wallet.rollback action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"wallet.rollback"},"data":{"$ref":"#/components/schemas/ActionData.wallet.rollback"}}}]},"HostAction.withdrawal.approve":{"description":"A withdrawal.approve action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.approve"},"data":{"$ref":"#/components/schemas/ActionData.withdrawal.approve"}}}]},"HostAction.withdrawal.hold":{"description":"A withdrawal.hold action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.hold"},"data":{"$ref":"#/components/schemas/ActionData.withdrawal.hold"}}}]},"HostAction.withdrawal.reject":{"description":"A withdrawal.reject action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.reject"},"data":{"$ref":"#/components/schemas/ActionData.withdrawal.reject"}}}]},"HostAction.withdrawal.release":{"description":"A withdrawal.release action.","allOf":[{"$ref":"#/components/schemas/ActionEnvelope"},{"type":"object","required":["type","data"],"properties":{"type":{"const":"withdrawal.release"},"data":{"$ref":"#/components/schemas/ActionData.withdrawal.release"}}}]},"HostActionOutcome":{"type":"object","required":["status"],"properties":{"status":{"type":"string","enum":["applied","rejected","pending"]},"host_ref":{"type":"string"},"reason_code":{"type":"string"},"message":{"type":"string"}}},"Hosts":{"type":"object","required":["api_base","api_origin","api_path","sdk_base","cdn_origin","docs_origin","plugin_docs_base","problems_base","console_origin","tools_origin"],"properties":{"api_base":{"type":"string","format":"uri","description":"Base URL of the core API (`CORE_API_BASE`); every `/v1/...` path is relative to it."},"api_origin":{"type":"string","format":"uri"},"api_path":{"type":"string","description":"Path part of `api_base`; request signatures cover it."},"sdk_base":{"type":"string","format":"uri","description":"SDK and widget files, `<sdk_base>/<sdk-name>/<version>/<file>`."},"cdn_origin":{"type":"string","format":"uri"},"docs_origin":{"type":"string","format":"uri"},"plugin_docs_base":{"type":"string","format":"uri","description":"Developer docs per plugin, `<plugin_docs_base>/<plugin-key>/`."},"problems_base":{"type":"string","format":"uri","description":"Base of every problem `type` URL, `<problems_base>/<code>`."},"console_origin":{"type":"string","format":"uri"},"tools_origin":{"type":"string","format":"uri"}}},"InboundResult":{"type":"object","required":["status"],"properties":{"status":{"type":"string","enum":["queued","duplicate","ignored"]},"event_id":{"type":"string"},"original_status":{"$ref":"#/components/schemas/EventStatusName"},"reason":{"type":"string"},"host_event":{"type":"string"},"mapping_version":{"type":"integer"}}},"Instrument":{"type":"object","required":["kind"],"additionalProperties":false,"properties":{"kind":{"enum":["card","bank","ewallet","crypto","pix","voucher","mobile","other"]},"digest":{"$ref":"#/components/schemas/Digest"},"last4":{"type":"string","pattern":"^[0-9]{4}$"},"bin":{"type":"string","pattern":"^[0-9]{6,8}$"},"issuer_country":{"type":"string","pattern":"^[A-Z]{2}$"},"holder_name_digest":{"$ref":"#/components/schemas/Digest"},"network":{"type":"string","maxLength":32}}},"Ip":{"description":"must be an ipv4 or ipv6 address","type":"string","maxLength":45,"anyOf":[{"format":"ipv4"},{"format":"ipv6"}]},"Manifest":{"type":"object","description":"The merged manifest of the selected plugins.","required":["schema","plugins","events","host_actions","host_calls","statements","scopes","conformance","fingerprint"],"properties":{"schema":{"type":"string","const":"core.manifest.v1"},"selection":{"type":"object"},"plugins":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"name":{"type":"string"},"required":{"type":"array","items":{"$ref":"#/components/schemas/ManifestTierLine"}},"recommended":{"type":"array","items":{"$ref":"#/components/schemas/ManifestTierLine"}}}}},"events":{"type":"object","properties":{"required":{"type":"array","items":{"type":"object"}},"recommended":{"type":"array","items":{"type":"object"}}}},"host_actions":{"type":"object","properties":{"required":{"type":"array","items":{"type":"object"}},"optional":{"type":"array","items":{"type":"object"}}}},"host_calls":{"type":"array","items":{"type":"object"}},"statements":{"type":"object"},"captured":{"type":"array","items":{"type":"object"}},"scopes":{"type":"array","items":{"type":"string"}},"conformance":{"type":"object"},"requires_ai_key":{"type":"array","items":{"type":"string"}},"contract":{"type":"object"},"fingerprint":{"type":"string"}}},"ManifestTierLine":{"type":"object","required":["source","name","fields"],"properties":{"source":{"type":"string","enum":["event","statement","captured"]},"name":{"type":"string"},"fields":{"type":"array","items":{"type":"string"}},"why":{"type":"string","description":"Required lines only."},"gain":{"type":"string","description":"Recommended lines only; what the operator gains."},"check":{"type":"string"},"schema":{"type":"string"}}},"Meta":{"title":"Free metadata","description":"Free object, at most 4096 bytes as compact JSON. Stored, never used for logic.","type":"object","x-max-bytes":4096},"Money":{"title":"Money (non-negative)","description":"Minor units as a digit string (1 to 18 digits, no sign, no decimal point). The exponent comes from GET /v1/currencies.","type":"object","required":["minor","currency"],"additionalProperties":false,"properties":{"minor":{"type":"string","pattern":"^[0-9]{1,18}$"},"currency":{"type":"string","pattern":"^[A-Z0-9]{3,10}$","x-currency":true}},"x-money":true},"Ping":{"type":"object","required":["ok","company","source","key","env","sandbox","scopes","plugins","rate_limit","server_time"],"properties":{"ok":{"type":"boolean"},"company":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":["string","null"]}}},"source":{"type":"object","properties":{"key":{"type":"string"},"kind":{"type":"string"},"name":{"type":["string","null"]},"status":{"type":"string"}}},"key":{"type":"object","properties":{"prefix":{"type":"string"},"name":{"type":["string","null"]},"env":{"type":"string","enum":["live","test"]},"expires_at":{"type":["string","null"],"format":"date-time"}}},"env":{"type":"string","enum":["live","test"]},"sandbox":{"type":"boolean"},"scopes":{"type":"array","items":{"type":"string"}},"plugins":{"type":"array","items":{"type":"string"}},"rate_limit":{"type":"object","properties":{"rps":{"type":"integer"},"burst":{"type":"integer"},"burst_seconds":{"type":"integer"}}},"server_time":{"type":"integer","description":"Server clock, unix seconds; compare with yours."},"request_id":{"type":"string"}}},"PingEchoed":{"allOf":[{"$ref":"#/components/schemas/Ping"},{"type":"object","required":["echo"],"properties":{"echo":{"type":"object","description":"What the server signed over.","properties":{"method":{"type":"string"},"path":{"type":"string"},"query":{"type":"string","description":"The canonical query."},"body_bytes":{"type":"integer"},"body_sha256":{"type":"string"},"idempotency_key":{"type":"string"}}}}}]},"PlayerProfile":{"title":"Player profile keys","description":"Every player.registered key except registered_at. Used by player.updated `changes` and `snapshot`.","type":"object","additionalProperties":false,"properties":{"currency":{"type":"string","pattern":"^[A-Z0-9]{3,10}$","x-currency":true},"email":{"type":"string","maxLength":254,"format":"email"},"email_verified":{"type":"boolean"},"phone":{"type":"string","pattern":"^\\+[1-9][0-9]{6,14}$"},"phone_verified":{"type":"boolean"},"first_name":{"type":"string","maxLength":100},"last_name":{"type":"string","maxLength":100},"birth_date":{"type":"string","format":"date"},"gender":{"enum":["m","f","x"]},"country":{"type":"string","pattern":"^[A-Z]{2}$"},"language":{"type":"string","maxLength":35,"pattern":"^[A-Za-z]{2,3}(-[A-Za-z0-9]{1,8})*$"},"city":{"type":"string","maxLength":100},"registration_ip":{"$ref":"#/components/schemas/Ip"},"user_agent":{"type":"string","maxLength":512},"device_id_digest":{"$ref":"#/components/schemas/Digest"},"tax_id_digest":{"$ref":"#/components/schemas/Digest"},"affiliate":{"type":"object","additionalProperties":false,"properties":{"affiliate_ref":{"type":"string","maxLength":128},"tracking_link_id":{"type":"string","maxLength":128},"click_id":{"type":"string","maxLength":256},"stid":{"type":"string","maxLength":128},"tlid":{"type":"string","maxLength":128},"campaign":{"type":"string","maxLength":128},"landing_url":{"type":"string","maxLength":2048,"format":"uri"},"sub_ids":{"type":"object","maxProperties":20,"additionalProperties":{"type":"string","maxLength":256}}}},"consents":{"type":"object","additionalProperties":false,"properties":{"email":{"type":"boolean"},"sms":{"type":"boolean"},"push":{"type":"boolean"},"phone":{"type":"boolean"},"whatsapp":{"type":"boolean"},"telegram":{"type":"boolean"}}},"segment_ref":{"type":"string","maxLength":128},"vip_level":{"type":"string","maxLength":64},"is_test":{"type":"boolean"},"meta":{"$ref":"#/components/schemas/Meta"}}},"PlayerRef":{"type":"object","required":["external_id"],"additionalProperties":false,"properties":{"external_id":{"type":"string","minLength":1,"maxLength":128},"brand":{"type":"string","maxLength":64}}},"PluginDoc":{"allOf":[{"$ref":"#/components/schemas/PluginDocSummary"},{"type":"object","required":["markdown"],"properties":{"markdown":{"type":"string"}}}]},"PluginDocSummary":{"type":"object","required":["key","name","status","scopes","events","host_actions","api_routes","widget","widget_routes"],"properties":{"key":{"type":"string"},"name":{"type":"string"},"status":{"type":"string"},"scopes":{"type":"array","items":{"type":"string"}},"events":{"type":"array","items":{"type":"string"}},"host_actions":{"type":"array","items":{"type":"string"}},"api_routes":{"type":"array","items":{"$ref":"#/components/schemas/RouteRef"}},"widget":{"type":"boolean","description":"True when the plugin has a player widget."},"widget_routes":{"type":"array","items":{"$ref":"#/components/schemas/RouteRef"}}}},"PluginDocsIndex":{"type":"object","required":["plugins"],"properties":{"plugins":{"type":"array","items":{"$ref":"#/components/schemas/PluginDocSummary"}}}},"PointsAmount":{"type":"object","required":["points"],"properties":{"points":{"type":"integer","minimum":1,"maximum":1000000000}}},"PointsLedgerPage":{"type":"object","required":["data","next_cursor"],"properties":{"data":{"type":"array","items":{"type":"object","properties":{"id":{"type":"integer"},"kind":{"type":"string"},"status":{"type":"string"},"points":{"type":"integer"},"available_at":{"type":["string","null"]},"posted_at":{"type":["string","null"]},"created_at":{"type":"string"}}}},"next_cursor":{"type":["string","null"]}}},"PointsProgram":{"type":"object","required":["points_per_usd","min_redeem_points","cash_enabled","tiers","rules"],"properties":{"label":{"type":["string","null"]},"points_per_usd":{"type":"number"},"min_redeem_points":{"type":"integer"},"cash_enabled":{"type":"boolean"},"playthrough_multiplier":{"type":"number"},"max_redeem_usd_per_day":{"type":"number"},"pending_hours":{"type":"integer"},"tiers":{"type":"array","items":{"$ref":"#/components/schemas/PointsTier"}},"rules":{"type":"array","items":{"type":"object"}}}},"PointsQuote":{"type":"object","required":["points","amount","currency","usd_value","balance"],"properties":{"points":{"type":"integer"},"amount":{"type":"number","description":"What the player would get, in `currency`."},"currency":{"type":"string"},"usd_value":{"type":"number"},"tier_bonus_pct":{"type":"number"},"playthrough_required_usd":{"type":"number"},"min_points":{"type":"integer"},"today_left":{"type":["number","null"]},"limit_currency":{"type":["string","null"]},"balance":{"type":"integer"}}},"PointsRedemption":{"type":"object","required":["id","points","currency","amount","status"],"properties":{"id":{"type":"integer"},"points":{"type":"integer"},"usd_value":{"type":"number"},"currency":{"type":"string"},"amount":{"type":"number"},"status":{"type":"string","description":"`pending` until your platform reports the wallet.credit action, then `completed` or `failed`."},"playthrough_required_usd":{"type":"number"},"cleared":{"type":"boolean"},"created_at":{"type":"string","format":"date-time"},"failure_reason":{"type":["string","null"]}}},"PointsRedemptionList":{"type":"object","required":["data"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/PointsRedemption"}}}},"PointsSummary":{"type":"object","required":["player","program","balance","pending_points","lifetime_points","redeemed_points","pending_redemptions"],"properties":{"player":{"type":"object","properties":{"external_id":{"type":"string"}}},"program":{"type":"object","properties":{"label":{"type":["string","null"]},"points_per_usd":{"type":"number"},"min_redeem_points":{"type":"integer"},"cash_enabled":{"type":"boolean"}}},"balance":{"type":"integer"},"pending_points":{"type":"integer"},"lifetime_points":{"type":"integer"},"redeemed_points":{"type":"integer"},"tier":{"oneOf":[{"$ref":"#/components/schemas/PointsTier"},{"type":"null"}]},"next_tier":{"oneOf":[{"$ref":"#/components/schemas/PointsTier"},{"type":"null"}]},"pending_redemptions":{"type":"integer"},"last_earn_at":{"type":["string","null"],"format":"date-time"}}},"PointsTier":{"type":"object","properties":{"id":{"type":"integer"},"name":{"type":"string"},"position":{"type":"integer"},"min_points":{"type":"integer"},"multiplier":{"type":"number"},"cash_bonus_pct":{"type":"number"},"color":{"type":["string","null"]},"icon":{"type":["string","null"]},"perks":{"type":"array","items":{}}}},"Problem":{"type":"object","description":"RFC 9457 problem details with a stable `code`.","required":["type","title","status","code"],"properties":{"type":{"type":"string","format":"uri"},"title":{"type":"string"},"status":{"type":"integer"},"code":{"type":"string"},"detail":{"type":"string"},"request_id":{"type":"string"},"event_id":{"type":"string"},"errors":{"type":"array","description":"One entry per failed rule (validation problems).","items":{"type":"object"}}}},"PromptKit":{"type":"object","required":["plugins","lang","platform","fingerprint","markdown"],"properties":{"plugins":{"type":"array","items":{"type":"string"}},"lang":{"type":"string"},"platform":{"type":"string"},"fingerprint":{"type":"string"},"markdown":{"type":"string"}}},"RouteRef":{"type":"object","required":["method","path"],"properties":{"method":{"type":"string"},"path":{"type":"string"}}},"SchemaIndex":{"type":"object","required":["kinds"],"properties":{"kinds":{"type":"object","additionalProperties":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"url":{"type":"string"}}}}}}},"StatementSummary":{"type":"object","required":["statement_id","status","kind","rows","row_errors","duplicate"],"properties":{"statement_id":{"type":"string"},"status":{"type":"string"},"kind":{"type":"string","enum":["payments","games"]},"provider":{"type":["string","null"]},"adapter":{"type":["string","null"]},"format":{"type":["string","null"]},"period":{"type":"object","properties":{"from":{"type":["string","null"],"format":"date-time"},"to":{"type":["string","null"],"format":"date-time"}}},"period_derived":{"type":["boolean","null"]},"rows":{"type":"integer"},"parsed":{"type":"integer"},"row_errors":{"type":"integer"},"errors":{"type":"array","items":{"type":"object"}},"sandbox":{"type":"boolean"},"filename":{"type":["string","null"]},"byte_size":{"type":["integer","null"]},"received_at":{"type":["string","null"],"format":"date-time"},"match":{"type":"object","description":"Rows per match status (`unmatched` until the matcher runs).","additionalProperties":{"type":"integer"}},"duplicate":{"type":"boolean"}}},"WebhookDelivery":{"type":"object","required":["id","status"],"properties":{"id":{"type":"string"},"endpoint_id":{"type":["string","null"]},"event_type":{"type":"string"},"status":{"$ref":"#/components/schemas/DeliveryStatus"},"attempts":{"type":"integer"},"last_http_status":{"type":["integer","null"]},"last_error":{"type":["string","null"]},"next_attempt_at":{"type":["string","null"],"format":"date-time"},"delivered_at":{"type":["string","null"],"format":"date-time"},"dead_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"}}},"WebhookEndpoint":{"type":"object","required":["id","url","event_types","active"],"properties":{"id":{"type":"string"},"url":{"type":"string","format":"uri"},"event_types":{"type":"array","items":{"type":"string"}},"description":{"type":["string","null"]},"active":{"type":"boolean"},"disabled_reason":{"type":["string","null"]},"previous_secret_expires_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":"string","format":"date-time"},"updated_at":{"type":"string","format":"date-time"}}},"WebhookEndpointCreate":{"type":"object","required":["url"],"properties":{"url":{"type":"string","format":"uri"},"event_types":{"type":"array","description":"Event names or patterns like `flag.*`.","items":{"$ref":"#/components/schemas/WebhookEventPattern"}},"description":{"type":"string","maxLength":255}}},"WebhookEndpointUpdate":{"type":"object","properties":{"url":{"type":"string","format":"uri"},"event_types":{"type":"array","items":{"$ref":"#/components/schemas/WebhookEventPattern"}},"description":{"type":["string","null"],"maxLength":255},"active":{"type":"boolean"}}},"WebhookEndpointWithSecret":{"allOf":[{"$ref":"#/components/schemas/WebhookEndpoint"},{"type":"object","required":["secret"],"properties":{"secret":{"type":"string","description":"`whsec_...`, shown once."}}}]},"WebhookEventPattern":{"type":"string","description":"A webhook event type (see `WebhookMessage`) or a prefix pattern like `flag.*`."},"WebhookMessage":{"type":"object","required":["id","type","created_at","data"],"properties":{"id":{"type":"string"},"type":{"type":"string","description":"Filled from the list of webhook event types by OpenApi.","enum":["flag.raised","flag.resolved","withdrawal_risk.decided","withdrawal_risk.hold","withdrawal_risk.release","registration.checked","kyc.verification_changed","kyc.document_rejected","bonus_decision.made","segment.changed","retention.suggestion_created","campaign.message_sent","points.awarded","cashback.calculated","jackpot.won","recon.break_found","recon.run_completed","action.needs_review","core.event_failed","core.connection_degraded","usage.limit_near","player.erased","core.endpoint_test"]},"created_at":{"type":"string","format":"date-time"},"data":{"type":"object"}}},"WebhookTestResult":{"type":"object","required":["delivered","delivery"],"properties":{"delivered":{"type":"boolean"},"http_status":{"type":["integer","null"]},"error":{"type":["string","null"]},"delivery":{"$ref":"#/components/schemas/WebhookDelivery"}}},"WidgetToken":{"type":"object","required":["token","header","expires_at","plugins","player","api_base","loader_url"],"properties":{"token":{"type":"string","description":"Send it as `X-Widget-Token`. Starts with `pwt_`."},"header":{"type":"string","const":"X-Widget-Token"},"expires_at":{"type":"string","format":"date-time"},"plugins":{"type":"array","items":{"type":"string"}},"player":{"type":"object","properties":{"external_id":{"type":"string"}}},"origin":{"type":["string","null"]},"api_base":{"type":"string","format":"uri"},"loader_url":{"type":"string","format":"uri"}}},"WidgetTokenRequest":{"type":"object","required":["player","plugins"],"additionalProperties":false,"properties":{"player":{"type":"object","required":["external_id"],"properties":{"external_id":{"type":"string","minLength":1,"maxLength":191}}},"plugins":{"type":"array","minItems":1,"items":{"type":"string"},"examples":[["points-rewards-store"]]},"origin":{"type":"string","description":"The page origin the token is bound to, e.g. `https://casino.example`."},"ttl_seconds":{"type":"integer","description":"Lifetime of the token; the default is 900."}}}}}}