{"openapi":"3.1.0","info":{"title":"TrustID API","version":"1.0.0","description":"Create identity-verification sessions, send the applicant to the hosted link, then receive the signed webhook and fetch the result. Personal-token API: send `Authorization: Bearer <token>` (Account → API tokens). Tokens act as their owner, carry abilities (`read`/`write` for the account routes; `sessions:read`, `sessions:write`, `flows:read`, `webhooks:read` for verifications) and always expire. A `tid_live_…` token works on real sessions; a `tid_test_…` token only on test sessions (`livemode: false`: a simulator replaces the capture, nothing is reviewed or billed, data is deleted after 24 hours). Every `POST` accepts an `Idempotency-Key` header. Metadata must never hold personal data. Tenant routes take the team from the `X-Team-Id` header, required when the user belongs to more than one team. Errors are RFC 9457 `application/problem+json`. Ids are ULIDs, timestamps ISO-8601 UTC, money integer cents plus a currency, lists cursor-paginated. Requests are rate limited per token by plan (`X-RateLimit-*`, `429` + `Retry-After`)."},"servers":[{"url":"/api/v1"}],"security":[{"bearerAuth":[]}],"tags":[{"name":"Account","description":"The token's owner. No team needed."},{"name":"Team","description":"The team picked by X-Team-Id. Needs a plan with API access."},{"name":"Meta"},{"name":"Flows","description":"The verification flows of the team (read only)."},{"name":"Sessions","description":"Verification sessions. A `test` token creates and sees only test sessions (`livemode: false`); a `live` token only live ones."},{"name":"Usage","description":"Billable verifications of the current month."},{"name":"Webhooks","description":"Delivery status of the webhooks the platform sent you."}],"paths":{"/openapi.json":{"get":{"tags":["Meta"],"operationId":"getOpenApi","summary":"This document","security":[],"responses":{"200":{"description":"The OpenAPI document","content":{"application/json":{"schema":{"type":"object"}}}}}}},"/me":{"get":{"tags":["Account"],"operationId":"getMe","summary":"The token's owner and the token itself","x-abilities":["read"],"responses":{"200":{"description":"Owner and token","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/Me"}}}}}},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/teams":{"get":{"tags":["Account"],"operationId":"listTeams","summary":"Teams the user belongs to (their ids go in X-Team-Id)","x-abilities":["read"],"parameters":[{"$ref":"#/components/parameters/Cursor"}],"responses":{"200":{"description":"A page of teams","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamPage"}}}},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/team":{"get":{"tags":["Team"],"operationId":"getTeam","summary":"The current team, your role and its plan","x-abilities":["read"],"parameters":[{"$ref":"#/components/parameters/TeamId"}],"responses":{"200":{"$ref":"#/components/responses/CurrentTeam"},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"patch":{"tags":["Team"],"operationId":"updateTeam","summary":"Rename the current team (owner or admin role)","x-abilities":["write"],"parameters":[{"$ref":"#/components/parameters/TeamId"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","required":["name"],"properties":{"name":{"type":"string","maxLength":120}}}}}},"responses":{"200":{"$ref":"#/components/responses/CurrentTeam"},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"422":{"$ref":"#/components/responses/ValidationFailed"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/flows":{"get":{"tags":["Flows"],"operationId":"listFlows","summary":"List the flows of the team","x-abilities":["flows:read"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"$ref":"#/components/parameters/Cursor"},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"archived","in":"query","schema":{"type":"boolean"},"description":"`true` only archived, `false` only active; omit for both."}],"responses":{"200":{"description":"A page of flows","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FlowPage"}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationFailed"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/flows/{id}":{"get":{"tags":["Flows"],"operationId":"getFlow","summary":"One flow","x-abilities":["flows:read"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"name":"id","in":"path","required":true,"description":"Flow id (ULID).","schema":{"type":"string"}}],"responses":{"200":{"description":"The flow","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/Flow"}}}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/sessions":{"get":{"tags":["Sessions"],"operationId":"listSessions","summary":"List sessions (newest first, cursor pagination)","x-abilities":["sessions:read"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"$ref":"#/components/parameters/Cursor"},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"status","in":"query","schema":{"type":"string","enum":["created","in_progress","submitted","in_review","approved","rejected","resubmission_requested","expired","cancelled"]}},{"name":"flow_id","in":"query","schema":{"type":"string"}},{"name":"external_reference","in":"query","schema":{"type":"string"}},{"name":"created","in":"query","required":false,"style":"deepObject","explode":true,"description":"Filter on created: `created[gte]` / `created[lte]`, ISO-8601.","schema":{"type":"object","properties":{"gte":{"type":"string","format":"date-time"},"lte":{"type":"string","format":"date-time"}}}},{"name":"decided","in":"query","required":false,"style":"deepObject","explode":true,"description":"Filter on decided: `decided[gte]` / `decided[lte]`, ISO-8601.","schema":{"type":"object","properties":{"gte":{"type":"string","format":"date-time"},"lte":{"type":"string","format":"date-time"}}}}],"responses":{"200":{"description":"A page of sessions","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SessionPage"}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationFailed"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"post":{"tags":["Sessions"],"operationId":"createSession","summary":"Create a session and get its hosted link","x-abilities":["sessions:write"],"description":"Returns `201` with the session plus `url` (the hosted link), `qr_svg_url` (signed, 15 minutes) and `embed`. The link is shown **only** in this response and in `POST /sessions/{id}/link`; only a hash of it is stored. A `test` token creates a test session (simulator, no review, no billing, deleted after 24 h).","parameters":[{"$ref":"#/components/parameters/TeamId"},{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateSession"}}}},"responses":{"201":{"description":"Session created","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/SessionCreated"}}}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationFailed"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/sessions/{id}":{"get":{"tags":["Sessions"],"operationId":"getSession","summary":"One session: status, decision, reason codes, subject fields, checks and timeline (no media)","x-abilities":["sessions:read"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"name":"id","in":"path","required":true,"description":"Session id (ULID).","schema":{"type":"string"}}],"responses":{"200":{"description":"The session","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/SessionDetail"}}}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}},"delete":{"tags":["Sessions"],"operationId":"eraseSession","summary":"Erase the session and its media now (data-subject erasure)","x-abilities":["sessions:write"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"name":"id","in":"path","required":true,"description":"Session id (ULID).","schema":{"type":"string"}}],"responses":{"204":{"description":"Erased"},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/sessions/{id}/cancel":{"post":{"tags":["Sessions"],"operationId":"cancelSession","summary":"Cancel a session that has not been submitted","x-abilities":["sessions:write"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"name":"id","in":"path","required":true,"description":"Session id (ULID).","schema":{"type":"string"}},{"$ref":"#/components/parameters/IdempotencyKey"}],"responses":{"200":{"description":"The cancelled session","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/SessionDetail"}}}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/sessions/{id}/link":{"post":{"tags":["Sessions"],"operationId":"reissueSessionLink","summary":"Issue a new hosted link (the old one stops working)","x-abilities":["sessions:write"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"name":"id","in":"path","required":true,"description":"Session id (ULID).","schema":{"type":"string"}},{"$ref":"#/components/parameters/IdempotencyKey"}],"responses":{"200":{"description":"The session with its new link","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/SessionCreated"}}}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"409":{"$ref":"#/components/responses/Conflict"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/sessions/{id}/export":{"get":{"tags":["Sessions"],"operationId":"exportSession","summary":"Data-subject access export (JSON, no media binaries)","x-abilities":["sessions:read"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"name":"id","in":"path","required":true,"description":"Session id (ULID).","schema":{"type":"string"}}],"responses":{"200":{"description":"Everything held about the session","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"type":"object","additionalProperties":true}}}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/usage":{"get":{"tags":["Usage"],"operationId":"getUsage","summary":"Billable verifications of the current month","x-abilities":["sessions:read"],"parameters":[{"$ref":"#/components/parameters/TeamId"}],"responses":{"200":{"description":"Usage","content":{"application/json":{"schema":{"type":"object","required":["data"],"properties":{"data":{"$ref":"#/components/schemas/Usage"}}}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}},"/webhook-deliveries":{"get":{"tags":["Webhooks"],"operationId":"listWebhookDeliveries","summary":"Delivery status of webhooks, for debugging (no payloads)","x-abilities":["webhooks:read"],"parameters":[{"$ref":"#/components/parameters/TeamId"},{"$ref":"#/components/parameters/Cursor"},{"name":"per_page","in":"query","required":false,"schema":{"type":"integer","minimum":1,"maximum":100,"default":25}},{"name":"session_id","in":"query","schema":{"type":"string"}},{"name":"status","in":"query","schema":{"type":"string","enum":["pending","delivered","failed"]}}],"responses":{"200":{"description":"A page of deliveries","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookDeliveryPage"}}}},"400":{"$ref":"#/components/responses/TeamRequired"},"401":{"$ref":"#/components/responses/Unauthenticated"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/ValidationFailed"},"429":{"$ref":"#/components/responses/TooManyRequests"}}}}},"webhooks":{"sessionEvent":{"post":{"tags":["Webhooks"],"operationId":"receiveSessionEvent","summary":"Event sent to your endpoint (configure it in Developers → Webhooks)","description":"Header `TrustId-Signature: t=<unix>,v1=<hex>` where `v1` = HMAC-SHA256 of `<t>.<raw body>` with your endpoint secret (two values during the 24 h after a rotation). Reject timestamps older than 5 minutes. Other headers: `TrustId-Event`, `TrustId-Delivery`. Answer 2xx within 10 seconds; otherwise it is retried (1 m, 5 m, 30 m, 2 h, 6 h, 12 h, 24 h). Events: `session.created`, `session.started`, `session.submitted`, `session.approved`, `session.rejected`, `session.resubmission_requested`, `session.decision_changed`, `session.expired`, `session.cancelled`, `session.media_purged`, `session.erased` (only `data.session_id` and `data.erased_at`), `webhook.test`. Test-mode sessions send the same events with `livemode: false`.","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WebhookEvent"}}}},"responses":{"200":{"description":"Any 2xx acknowledges the event"}}}}},"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer","description":"Personal access token from Account → API tokens (`tid_live_…` or `tid_test_…`)."}},"parameters":{"TeamId":{"name":"X-Team-Id","in":"header","required":false,"description":"ULID of the team. Required when the user belongs to more than one team; otherwise their only team is used.","schema":{"type":"string","pattern":"^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$"}},"Cursor":{"name":"cursor","in":"query","required":false,"description":"Opaque cursor from `links.next` / `meta.next_cursor`.","schema":{"type":"string"}},"IdempotencyKey":{"name":"Idempotency-Key","in":"header","required":false,"description":"Up to 255 characters. The same key with the same request within 24 hours replays the first response (`Idempotent-Replayed: true`); the same key with a different request is a `422` (`idempotency_key_reused`).","schema":{"type":"string","maxLength":255}}},"schemas":{"WebhookEvent":{"type":"object","required":["id","type","created_at","livemode","data"],"properties":{"id":{"type":"string","example":"evt_01JABCDEF"},"type":{"type":"string","example":"session.approved"},"created_at":{"type":"string","format":"date-time"},"livemode":{"type":"boolean"},"data":{"type":"object","description":"Session id, external_reference, metadata, flow_id, status, decision, reason_codes, round, resubmission_items, age_over_* booleans, timestamps and (full-result flows) `document` and `subject`. Never media, URLs or the applicant's email.","additionalProperties":true}}},"Problem":{"type":"object","description":"RFC 9457 problem details.","required":["type","title","status","detail","code","request_id"],"properties":{"type":{"type":"string","example":"about:blank"},"title":{"type":"string","example":"Not Found"},"status":{"type":"integer","example":404},"detail":{"type":"string"},"code":{"type":"string","description":"Stable machine-readable reason.","example":"not_found"},"request_id":{"type":["string","null"],"description":"Quote it when contacting support."},"errors":{"type":"object","additionalProperties":{"type":"array","items":{"type":"string"}},"description":"Only on 422: field → messages."}}},"Me":{"type":"object","required":["id","name","email","locale","timezone","created_at","token"],"properties":{"id":{"type":"string","description":"ULID"},"name":{"type":"string"},"email":{"type":"string","format":"email"},"locale":{"type":"string","example":"en"},"timezone":{"type":"string","example":"Europe/Tallinn"},"created_at":{"type":"string","format":"date-time"},"token":{"type":["object","null"],"properties":{"name":{"type":"string"},"abilities":{"type":"array","items":{"type":"string"}},"expires_at":{"type":["string","null"],"format":"date-time"}}}}},"Team":{"type":"object","required":["id","name","personal","role","created_at"],"properties":{"id":{"type":"string","description":"ULID"},"name":{"type":"string"},"personal":{"type":"boolean"},"role":{"type":["string","null"],"enum":["owner","admin","member",null]},"created_at":{"type":"string","format":"date-time"}}},"TeamPage":{"type":"object","required":["data","links","meta"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Team"}},"links":{"type":"object","properties":{"first":{"type":["string","null"]},"last":{"type":["string","null"]},"prev":{"type":["string","null"]},"next":{"type":["string","null"]}}},"meta":{"type":"object","properties":{"path":{"type":"string"},"per_page":{"type":"integer"},"next_cursor":{"type":["string","null"]},"prev_cursor":{"type":["string","null"]}}}}},"Flow":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"steps":{"type":"object","additionalProperties":true},"documents":{"type":["object","null"],"additionalProperties":true},"min_age":{"type":["integer","null"]},"result_detail":{"type":"string","enum":["full","minimal"]},"max_resubmissions":{"type":"integer"},"link_ttl_hours":{"type":"integer"},"locale_default":{"type":"string"},"ready":{"type":"boolean","description":"Can create sessions (has a privacy policy URL)."},"archived":{"type":"boolean"},"archived_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":["string","null"],"format":"date-time"}}},"FlowPage":{"type":"object","required":["data","links","meta"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Flow"}},"links":{"type":"object","properties":{"first":{"type":["string","null"]},"last":{"type":["string","null"]},"prev":{"type":["string","null"]},"next":{"type":["string","null"]}}},"meta":{"type":"object","properties":{"path":{"type":"string"},"per_page":{"type":"integer"},"next_cursor":{"type":["string","null"]},"prev_cursor":{"type":["string","null"]}}}}},"CreateSession":{"type":"object","required":["flow_id"],"properties":{"flow_id":{"type":"string","description":"ULID of an active flow that has a privacy policy URL."},"external_reference":{"type":["string","null"],"maxLength":191,"description":"Your own reference (order, booking...). Echoed in every response and webhook."},"applicant":{"type":["object","null"],"properties":{"email":{"type":["string","null"],"format":"email"}}},"locale":{"type":["string","null"],"enum":["en","es",null]},"send_invite":{"type":"boolean","default":false,"description":"Email the link to `applicant.email` (live mode only)."},"redirect_url":{"type":["string","null"],"format":"uri","description":"Where to send the applicant afterwards. Its host must be one of the hosts of the flow's redirect URLs."},"metadata":{"type":["object","null"],"maxProperties":10,"additionalProperties":{"type":"string","maxLength":500},"description":"Up to 10 string pairs of at most 500 bytes. **Do not put personal data here.**"}}},"Session":{"type":"object","required":["id","livemode","flow_id","status","round","created_at"],"properties":{"id":{"type":"string"},"livemode":{"type":"boolean"},"flow_id":{"type":"string"},"flow_name":{"type":["string","null"]},"external_reference":{"type":["string","null"]},"metadata":{"type":["object","null"],"additionalProperties":{"type":"string"}},"status":{"type":"string","enum":["created","in_progress","submitted","in_review","approved","rejected","resubmission_requested","expired","cancelled"]},"decision":{"type":["string","null"],"enum":["approved","rejected",null]},"reason_codes":{"type":"array","items":{"type":"string"}},"round":{"type":"integer"},"locale":{"type":"string"},"resubmission_items":{"type":["array","null"],"items":{"type":"string"}},"created_at":{"type":"string","format":"date-time"},"expires_at":{"type":["string","null"],"format":"date-time"},"submitted_at":{"type":["string","null"],"format":"date-time"},"decided_at":{"type":["string","null"],"format":"date-time"},"media_purge_at":{"type":["string","null"],"format":"date-time"}}},"SessionDetail":{"allOf":[{"$ref":"#/components/schemas/Session"},{"type":"object","properties":{"result":{"type":["object","null"],"description":"Present once decided. A minimal-result flow only carries the `age_over_*` booleans.","properties":{"age_over_18":{"type":["boolean","null"]},"age_over_21":{"type":["boolean","null"]},"age_over_min":{"type":["boolean","null"]},"document":{"type":"object","properties":{"type":{"type":["string","null"]},"country":{"type":["string","null"]},"expiry":{"type":["string","null"],"format":"date"},"number_last4":{"type":["string","null"]}}},"subject":{"type":"object","properties":{"given_names":{"type":["string","null"]},"surname":{"type":["string","null"]},"date_of_birth":{"type":["string","null"]},"nationality":{"type":["string","null"]}}}}},"checks":{"type":["object","null"],"description":"Flag names of the latest automatic pre-check; never metrics.","properties":{"flags":{"type":"array","items":{"type":"string"}},"completed_at":{"type":["string","null"],"format":"date-time"}}},"timeline":{"type":"array","items":{"type":"object","properties":{"type":{"type":"string"},"at":{"type":["string","null"],"format":"date-time"},"round":{"type":["integer","null"]}}}}}}]},"SessionCreated":{"allOf":[{"$ref":"#/components/schemas/Session"},{"type":"object","required":["url","qr_svg_url","embed"],"properties":{"url":{"type":"string","format":"uri","description":"The hosted link. Shown only here and in `POST /sessions/{id}/link`."},"qr_svg_url":{"type":"string","format":"uri","description":"Signed URL of an SVG QR code of the link, valid 15 minutes."},"embed":{"type":"object","properties":{"script":{"type":"string","format":"uri"},"url":{"type":"string","format":"uri"}}},"invite":{"type":["string","null"],"enum":["queued","suppressed",null]}}}]},"SessionPage":{"type":"object","required":["data","links","meta"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Session"}},"links":{"type":"object","properties":{"first":{"type":["string","null"]},"last":{"type":["string","null"]},"prev":{"type":["string","null"]},"next":{"type":["string","null"]}}},"meta":{"type":"object","properties":{"path":{"type":"string"},"per_page":{"type":"integer"},"next_cursor":{"type":["string","null"]},"prev_cursor":{"type":["string","null"]}}}}},"Usage":{"type":"object","properties":{"period":{"type":"string","format":"date","description":"First day of the billing month."},"included":{"type":["integer","null"]},"used":{"type":"integer"},"overage":{"type":"integer"},"cap":{"type":["integer","null"]}}},"WebhookDelivery":{"type":"object","properties":{"id":{"type":"string"},"endpoint_id":{"type":"string"},"session_id":{"type":["string","null"]},"event_id":{"type":["string","null"]},"type":{"type":"string"},"status":{"type":"string","enum":["pending","delivered","failed"]},"attempt":{"type":"integer"},"response_code":{"type":["integer","null"]},"duration_ms":{"type":["integer","null"]},"error":{"type":["string","null"]},"next_attempt_at":{"type":["string","null"],"format":"date-time"},"delivered_at":{"type":["string","null"],"format":"date-time"},"created_at":{"type":["string","null"],"format":"date-time"}}},"WebhookDeliveryPage":{"type":"object","required":["data","links","meta"],"properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/WebhookDelivery"}},"links":{"type":"object","properties":{"first":{"type":["string","null"]},"last":{"type":["string","null"]},"prev":{"type":["string","null"]},"next":{"type":["string","null"]}}},"meta":{"type":"object","properties":{"path":{"type":"string"},"per_page":{"type":"integer"},"next_cursor":{"type":["string","null"]},"prev_cursor":{"type":["string","null"]}}}}}},"responses":{"CurrentTeam":{"description":"The team, with your role, and its plan in meta","content":{"application/json":{"schema":{"type":"object","required":["data","meta"],"properties":{"data":{"$ref":"#/components/schemas/Team"},"meta":{"type":"object","properties":{"plan":{"type":"object","properties":{"slug":{"type":"string"},"name":{"type":"string"}}}}}}}}}},"Unauthenticated":{"description":"No token, an unknown, expired or revoked one, or its owner is suspended (`unauthenticated`)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"Forbidden":{"description":"The token lacks the ability (`missing_ability`), the role doesn't allow it (`forbidden`), the plan has no API access or the team is suspended (`team_suspended`)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"NotFound":{"description":"Not found, including a team you are not a member of (`team_not_found`)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"TeamRequired":{"description":"You belong to several teams and sent no X-Team-Id (`team_required`), or a token was sent in the query string (`token_in_query`)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"ValidationFailed":{"description":"Invalid fields (`validation_failed`); see `errors`","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"TooManyRequests":{"description":"Rate limit of the token's plan reached (`rate_limited`)","headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait"}},"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}},"Conflict":{"description":"The session is in a status that does not allow this (`not_cancellable`, `not_relinkable`)","content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/Problem"}}}}}}}