{
    "openapi": "3.1.0",
    "info": {
        "title": "MyCup API",
        "version": "1.0.0",
        "description": "One API over everything MyCup does, for three audiences.\n\n**Platform** credentials reach the whole estate and are issued to MyCup staff.\n**Partner** credentials are attached to an explicit list of tournaments; one credential can\nserve many. **Public** publishable keys are read-only and safe to embed in a front-end.\n\nPlatform and partner credentials use the `client_credentials` grant: POST your `client_id`\nand `client_secret` to `/api/v1/oauth/token` and send the returned access token as a bearer.\nPublic keys are presented directly in the `X-MyCup-Key` header.\n\n### The rules are the panel's rules\n\nThe API is a second front-end, not a second back-end. Every restriction it applies is read\nfrom the same service the MyCup panel reads, so the two cannot drift:\n\n- **Scopes narrow, they never widen.** Every scope also requires the tournament permission\n  behind it, so a credential can be narrower than any human role and never wider.\n- **Plan limits** answer `402` with the plan you would need, not `403`.\n- **A finished tournament** freezes its structure and keeps its record editable: you can\n  still correct a score or a kickoff time, but not add a team.\n- **The public surface mirrors the website**, page-visibility included. A page the organiser\n  switched off returns `404` here too.\n\n### Conventions\n\nResponses are `{\"data\": …}`, with `meta` and `links` on collections. Times are ISO-8601 with\nan offset. Errors carry a stable `error.code` — branch on that, never on the message, which\nis localised. Unsafe requests accept an `Idempotency-Key` header, which matters most on the\ndestructive ones: regenerating a match list refuses with `409` and a list of what would be\nlost unless you pass `confirm_destructive`.",
        "contact": {
            "name": "MyCup",
            "url": "https://mycup.me"
        }
    },
    "servers": [
        {
            "url": "https://mycup.me",
            "description": "This environment"
        }
    ],
    "tags": [
        {
            "name": "Authentication",
            "description": "Exchanging credentials for an access token."
        },
        {
            "name": "Public",
            "description": "Read-only tournament data, authenticated with a publishable key. Mirrors the public website, page-visibility rules included: a page the organiser switched off returns 404 here too."
        },
        {
            "name": "Partner",
            "description": "Full read and write access to the tournaments a credential is attached to."
        },
        {
            "name": "Platform",
            "description": "Estate-wide access. MyCup staff credentials only."
        }
    ],
    "paths": {
        "/api/v1/admin/announcements": {
            "get": {
                "operationId": "api.v1.platform.announcements.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List announcements",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.announcements.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create an announcement",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/announcements/{announcement}": {
            "patch": {
                "operationId": "api.v1.platform.announcements.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the announcement",
                "parameters": [
                    {
                        "name": "announcement",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Announcement id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.announcements.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Delete the announcement",
                "parameters": [
                    {
                        "name": "announcement",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Announcement id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ]
            }
        },
        "/api/v1/admin/api-clients": {
            "get": {
                "operationId": "api.v1.platform.api-clients.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List api clients",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:api-clients:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:api-clients:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.api-clients.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create an api client",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:api-clients:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:api-clients:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/api-clients/{client}": {
            "get": {
                "operationId": "api.v1.platform.api-clients.show",
                "tags": [
                    "Platform"
                ],
                "summary": "Get the api client",
                "parameters": [
                    {
                        "name": "client",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Client id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:api-clients:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:api-clients:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.platform.api-clients.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the api client",
                "parameters": [
                    {
                        "name": "client",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Client id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:api-clients:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:api-clients:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.api-clients.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Delete the api client",
                "parameters": [
                    {
                        "name": "client",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Client id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:api-clients:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:api-clients:write"
                ]
            }
        },
        "/api/v1/admin/api-clients/{client}/revoke": {
            "post": {
                "operationId": "api.v1.platform.api-clients.revoke",
                "tags": [
                    "Platform"
                ],
                "summary": "Revoke the credential",
                "parameters": [
                    {
                        "name": "client",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Client id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:api-clients:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:api-clients:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/api-clients/{client}/rotate": {
            "post": {
                "operationId": "api.v1.platform.api-clients.rotate",
                "tags": [
                    "Platform"
                ],
                "summary": "Rotate the credential secret",
                "parameters": [
                    {
                        "name": "client",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Client id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:api-clients:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:api-clients:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/blog-posts": {
            "get": {
                "operationId": "api.v1.platform.blog-posts.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List blog posts",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.blog-posts.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create a blog post",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/blog-posts/{post}": {
            "get": {
                "operationId": "api.v1.platform.blog-posts.show",
                "tags": [
                    "Platform"
                ],
                "summary": "Get the blog post",
                "parameters": [
                    {
                        "name": "post",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Post id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.platform.blog-posts.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the blog post",
                "parameters": [
                    {
                        "name": "post",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Post id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.blog-posts.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Delete the blog post",
                "parameters": [
                    {
                        "name": "post",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Post id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ]
            }
        },
        "/api/v1/admin/discount-codes": {
            "get": {
                "operationId": "api.v1.platform.discount-codes.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List discount codes",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.discount-codes.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create a discount code",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/discount-codes/{code}": {
            "delete": {
                "operationId": "api.v1.platform.discount-codes.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Delete the discount code",
                "parameters": [
                    {
                        "name": "code",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Code id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:write"
                ]
            }
        },
        "/api/v1/admin/discounts": {
            "get": {
                "operationId": "api.v1.platform.discounts.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List discounts",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.discounts.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create a discount",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/discounts/{discount}": {
            "get": {
                "operationId": "api.v1.platform.discounts.show",
                "tags": [
                    "Platform"
                ],
                "summary": "Get the discount",
                "parameters": [
                    {
                        "name": "discount",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Discount id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.platform.discounts.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the discount",
                "parameters": [
                    {
                        "name": "discount",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Discount id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.discounts.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Delete the discount",
                "parameters": [
                    {
                        "name": "discount",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Discount id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:write"
                ]
            }
        },
        "/api/v1/admin/invoices": {
            "get": {
                "operationId": "api.v1.platform.invoices.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List invoices",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:read"
                ]
            }
        },
        "/api/v1/admin/metrics": {
            "get": {
                "operationId": "api.v1.platform.metrics",
                "tags": [
                    "Platform"
                ],
                "summary": "Estate-wide numbers",
                "parameters": [
                    {
                        "name": "since",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Only count records created on or after this date."
                    },
                    {
                        "name": "include_subscription_metrics",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Include the inherited, not-applicable subscription block."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Tournaments, users, one-time orders and revenue. Revenue is what was actually CHARGED (after discounts), not list price.\n\nSubscription metrics (MRR, churn, active subscriptions) are inherited from SaaSykit and describe recurring revenue MyCup does not have. They are returned only with `include_subscription_metrics=1`, and labelled as not applicable.",
                "security": [
                    {
                        "oauth2": [
                            "platform:metrics"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:metrics"
                ]
            }
        },
        "/api/v1/admin/one-time-products": {
            "get": {
                "operationId": "api.v1.platform.one-time-products.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List one time products",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.one-time-products.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create an one time product",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/one-time-products/{product}": {
            "get": {
                "operationId": "api.v1.platform.one-time-products.show",
                "tags": [
                    "Platform"
                ],
                "summary": "Get the one time product",
                "parameters": [
                    {
                        "name": "product",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Product id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.platform.one-time-products.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the one time product",
                "parameters": [
                    {
                        "name": "product",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Product id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.one-time-products.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Withdraw a plan from sale",
                "parameters": [
                    {
                        "name": "product",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Product id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "⚠️ Returns **200 with the updated product**, not 204. This is the only DELETE on the API that does — everywhere else DELETE means 204 and gone.\n\nIt deactivates rather than deletes: every order that ever bought this plan still points at it, and PlanManager reads the product behind a purchase to decide what that tournament is entitled to today, so destroying one would strip features from tournaments that paid for them. The body is returned so a caller can see `is_active` and `is_visible` are now false.",
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:write"
                ]
            }
        },
        "/api/v1/admin/orders": {
            "get": {
                "operationId": "api.v1.platform.orders.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List orders",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:read"
                ]
            }
        },
        "/api/v1/admin/roadmap-items": {
            "get": {
                "operationId": "api.v1.platform.roadmap-items.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List roadmap items",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.roadmap-items.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create a roadmap item",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/roadmap-items/{item}": {
            "get": {
                "operationId": "api.v1.platform.roadmap-items.show",
                "tags": [
                    "Platform"
                ],
                "summary": "Get the roadmap item",
                "parameters": [
                    {
                        "name": "item",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Item id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.platform.roadmap-items.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the roadmap item",
                "parameters": [
                    {
                        "name": "item",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Item id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.roadmap-items.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Delete the roadmap item",
                "parameters": [
                    {
                        "name": "item",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Item id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:content:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:content:write"
                ]
            }
        },
        "/api/v1/admin/roles": {
            "get": {
                "operationId": "api.v1.platform.roles.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List roles",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:users:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.roles.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create a role",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Gated on `platform:users:write`, not a scope of its own: a credential that can edit roles can grant itself, in effect, anything a user can do.\n\nPermissions are ATTACHED, never created — the permission list is defined by the code that checks it, and inventing a new string here would produce a role granting something nothing will ever ask about. A `tenant_id` makes this a tournament role rather than a platform one.",
                "security": [
                    {
                        "oauth2": [
                            "platform:users:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/roles/{role}": {
            "get": {
                "operationId": "api.v1.platform.roles.show",
                "tags": [
                    "Platform"
                ],
                "summary": "Get the role",
                "parameters": [
                    {
                        "name": "role",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Role id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:users:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.platform.roles.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the role",
                "parameters": [
                    {
                        "name": "role",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Role id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:users:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.roles.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Delete the role",
                "parameters": [
                    {
                        "name": "role",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Role id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:users:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:write"
                ]
            }
        },
        "/api/v1/admin/tournaments": {
            "get": {
                "operationId": "api.v1.platform.tournaments.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List tournaments",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.tournaments.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create a tournament",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Goes through the signup funnel's own path, so the tournament arrives with its owner role, its setup-progress rows and its smart-defaulted settings.",
                "security": [
                    {
                        "oauth2": [
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "owner_user_id": {
                                        "type": "integer",
                                        "description": "The account that will own it."
                                    },
                                    "name": {
                                        "type": "string"
                                    },
                                    "sport_code": {
                                        "type": "string"
                                    },
                                    "time_zone": {
                                        "type": "string"
                                    },
                                    "country_code": {
                                        "type": "string"
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/tournaments/{tournament}": {
            "get": {
                "operationId": "api.v1.platform.tournaments.show",
                "tags": [
                    "Platform"
                ],
                "summary": "Get the tournament",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.platform.tournaments.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the tournament",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.tournaments.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Delete the tournament",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/admin/tournaments/{tournament}/restore": {
            "post": {
                "operationId": "api.v1.platform.tournaments.restore",
                "tags": [
                    "Platform"
                ],
                "summary": "Restore the tournament",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/transactions": {
            "get": {
                "operationId": "api.v1.platform.transactions.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List transactions",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:billing:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:billing:read"
                ]
            }
        },
        "/api/v1/admin/users": {
            "get": {
                "operationId": "api.v1.platform.users.index",
                "tags": [
                    "Platform"
                ],
                "summary": "List users",
                "parameters": [
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:users:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:read"
                ]
            },
            "post": {
                "operationId": "api.v1.platform.users.store",
                "tags": [
                    "Platform"
                ],
                "summary": "Create a user account",
                "parameters": [
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Goes through UserService, which hashes the password (or generates one nobody knows when none is given), records the signup and fires `Registered` so verification mail goes out. Omitting `password` and leaving `send_invitation` true is the intended path for an account somebody else is creating.",
                "security": [
                    {
                        "oauth2": [
                            "platform:users:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/admin/users/{user}": {
            "get": {
                "operationId": "api.v1.platform.users.show",
                "tags": [
                    "Platform"
                ],
                "summary": "Get the user",
                "parameters": [
                    {
                        "name": "user",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "User id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:users:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.platform.users.update",
                "tags": [
                    "Platform"
                ],
                "summary": "Update the user",
                "parameters": [
                    {
                        "name": "user",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "User id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "platform:users:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.platform.users.destroy",
                "tags": [
                    "Platform"
                ],
                "summary": "Soft-delete a user account",
                "parameters": [
                    {
                        "name": "user",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "User id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Refused with `409 user_has_tournaments` while the user still administers a tournament, because removing them can leave a live tournament with nobody able to administer it. The delete is soft: orders and invoices must outlive the account for accounting reasons.",
                "security": [
                    {
                        "oauth2": [
                            "platform:users:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "platform:users:write"
                ]
            }
        },
        "/api/v1/me": {
            "get": {
                "operationId": "api.v1.me",
                "tags": [
                    "Authentication"
                ],
                "summary": "Describe the calling credential and the tournaments it reaches",
                "parameters": [],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": []
                    }
                ]
            }
        },
        "/api/v1/oauth/revoke": {
            "post": {
                "operationId": "api.v1.oauth.revoke",
                "tags": [
                    "Authentication"
                ],
                "summary": "Revoke the presented access token",
                "parameters": [],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": []
                    }
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/oauth/token": {
            "post": {
                "operationId": "api.v1.oauth.token",
                "tags": [
                    "Authentication"
                ],
                "summary": "Exchange credentials for an access token",
                "parameters": [],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "The `client_credentials` grant, and the only grant. Credentials may travel in the body or as HTTP Basic. An unknown client_id and a wrong secret return the same error on purpose.",
                "security": [],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "grant_type": {
                                        "type": "string",
                                        "enum": [
                                            "client_credentials"
                                        ]
                                    },
                                    "client_id": {
                                        "type": "string"
                                    },
                                    "client_secret": {
                                        "type": "string"
                                    },
                                    "scope": {
                                        "type": "string",
                                        "description": "Optional space-separated narrowing. Must be a subset of the grant."
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/public/tournaments/{tournament}": {
            "get": {
                "operationId": "api.v1.public.show",
                "tags": [
                    "Public"
                ],
                "summary": "Get the tournament",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/announcements": {
            "get": {
                "operationId": "api.v1.public.announcements",
                "tags": [
                    "Public"
                ],
                "summary": "List announcements",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/assistants": {
            "get": {
                "operationId": "api.v1.public.assistants",
                "tags": [
                    "Public"
                ],
                "summary": "Top assist providers",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/divisions": {
            "get": {
                "operationId": "api.v1.public.divisions",
                "tags": [
                    "Public"
                ],
                "summary": "List divisions",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Returns an empty list for a tournament with one division or none — the same rule the website follows, so a front-end built on this API does not sprout a filter with one option in it.",
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/documents": {
            "get": {
                "operationId": "api.v1.public.documents",
                "tags": [
                    "Public"
                ],
                "summary": "List documents",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/matchdays": {
            "get": {
                "operationId": "api.v1.public.matchdays",
                "tags": [
                    "Public"
                ],
                "summary": "List matchdays",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/matches": {
            "get": {
                "operationId": "api.v1.public.matches.index",
                "tags": [
                    "Public"
                ],
                "summary": "List fixtures",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "date",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "A calendar day in the tournament's own timezone."
                    },
                    {
                        "name": "from",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Start of a date range (inclusive)."
                    },
                    {
                        "name": "to",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "End of a date range (inclusive)."
                    },
                    {
                        "name": "team",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Matches involving this team, home or away."
                    },
                    {
                        "name": "division",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Limit to one division."
                    },
                    {
                        "name": "phase",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Limit to one phase."
                    },
                    {
                        "name": "matchday",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Limit to one matchday."
                    },
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "not_started, in_progress or finished."
                    },
                    {
                        "name": "include",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "events"
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/matches/{match}": {
            "get": {
                "operationId": "api.v1.public.matches.show",
                "tags": [
                    "Public"
                ],
                "summary": "Get the match",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "match",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/phases": {
            "get": {
                "operationId": "api.v1.public.phases.index",
                "tags": [
                    "Public"
                ],
                "summary": "List phases",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/phases/{phase}/standings": {
            "get": {
                "operationId": "api.v1.public.phases.standings",
                "tags": [
                    "Public"
                ],
                "summary": "Standings for one phase",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "phase",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Phase id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/players/{player}": {
            "get": {
                "operationId": "api.v1.public.players.show",
                "tags": [
                    "Public"
                ],
                "summary": "Get the player",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "player",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Player id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/scorers": {
            "get": {
                "operationId": "api.v1.public.scorers",
                "tags": [
                    "Public"
                ],
                "summary": "Top scorers",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/sponsors": {
            "get": {
                "operationId": "api.v1.public.sponsors",
                "tags": [
                    "Public"
                ],
                "summary": "List sponsors",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/staff/{staff}": {
            "get": {
                "operationId": "api.v1.public.staff.show",
                "tags": [
                    "Public"
                ],
                "summary": "Get the staff member",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "staff",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Staff id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/standings": {
            "get": {
                "operationId": "api.v1.public.standings",
                "tags": [
                    "Public"
                ],
                "summary": "Standings for every phase",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "One call rather than discovering the phases and fanning out. Each table carries its tiebreaker chain, because a table sorted by rules the client cannot see eventually gets re-sorted wrongly.",
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/structure": {
            "get": {
                "operationId": "api.v1.public.structure",
                "tags": [
                    "Public"
                ],
                "summary": "The tournament structure",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/summary": {
            "get": {
                "operationId": "api.v1.public.summary",
                "tags": [
                    "Public"
                ],
                "summary": "The end-of-tournament recap",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Champions and podium come from the winners the organiser set in the Website editor, never inferred from standings — a custom bracket's champion is a decision, and deriving it from a table has been wrong often enough to be a rule. Returns 404 until the recap is published.",
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/teams": {
            "get": {
                "operationId": "api.v1.public.teams.index",
                "tags": [
                    "Public"
                ],
                "summary": "List teams",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/teams/{team}": {
            "get": {
                "operationId": "api.v1.public.teams.show",
                "tags": [
                    "Public"
                ],
                "summary": "Get the team",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/teams/{team}/players": {
            "get": {
                "operationId": "api.v1.public.teams.players",
                "tags": [
                    "Public"
                ],
                "summary": "List a team's players",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/teams/{team}/staff": {
            "get": {
                "operationId": "api.v1.public.teams.staff",
                "tags": [
                    "Public"
                ],
                "summary": "List a team's staff",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/venues": {
            "get": {
                "operationId": "api.v1.public.venues.index",
                "tags": [
                    "Public"
                ],
                "summary": "List venues",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/public/tournaments/{tournament}/venues/{venue}": {
            "get": {
                "operationId": "api.v1.public.venues.show",
                "tags": [
                    "Public"
                ],
                "summary": "Get the venue",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "venue",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Venue id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "publicKey": []
                    }
                ]
            }
        },
        "/api/v1/tournaments/{tournament}": {
            "get": {
                "operationId": "api.v1.tenant.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the tournament",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "tournaments:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "tournaments:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the tournament",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "tournaments:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "tournaments:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/accommodation-bookings": {
            "get": {
                "operationId": "api.v1.tenant.accommodation-bookings.index",
                "tags": [
                    "Partner"
                ],
                "summary": "One group, in one accommodation, for one range of nights",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "accommodation",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Only stays at this accommodation."
                    },
                    {
                        "name": "group",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Only stays by this group."
                    },
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "confirmed, pending or cancelled."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "`check_out` is the morning they leave, so the last night charged is the day before it; `nights` publishes that count rather than leaving it to be inferred.\n\nCANCELLED bookings are returned by default. Their rooms went back to the allotment when they were cancelled, but the row stays because it is the list of who needs re-housing — filter on `status` if you only want live ones.\n\n`beds` is capacity, not people. Compare it against the group's `headcount`: if the group is larger, somebody has nowhere to sleep.",
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/accommodation-bookings/{booking}": {
            "get": {
                "operationId": "api.v1.tenant.accommodation-bookings.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the accommodation booking",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "booking",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Booking id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/accommodation-bookings/{booking}/rooming": {
            "get": {
                "operationId": "api.v1.tenant.accommodation-bookings.rooming",
                "tags": [
                    "Partner"
                ],
                "summary": "The rooming list for one booking",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "booking",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Booking id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "⚠️ ID NUMBERS AND DATES OF BIRTH ARE DELIBERATELY NOT RETURNED.\n\nA rooming list holds passport numbers and dates of birth, very often of children. Inside MyCup the ID number is stored encrypted and both are purged on a schedule once the tournament is over. An API field would be a third copy leaving the building on every poll, with no consent story and no retention story.\n\nWhat is published instead is the SHAPE of the list and its COMPLETENESS: which room, who is in it, and `is_complete` — false when a passport number or date of birth is still missing, which is the thing an integration is chasing. `is_complete` is the same predicate the organiser sees, so the two cannot disagree about which list is ready.\n\nThe identifying data continues to leave by the one audited route it already had: the organiser downloading the sheet and sending it to the hotel that asked for it.",
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/accommodations": {
            "get": {
                "operationId": "api.v1.tenant.accommodations.index",
                "tags": [
                    "Partner"
                ],
                "summary": "Hotels, hostels and schools, with the room types they are holding",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "The whole Hospitality surface (accommodation and meals) is READ ONLY and requires `hospitality:read`.\n\nUnlike the finance surface next door, the READS here are plan-gated too. A balance is a debt a club was already told about; a hotel contract — which accommodation, at what rate, through which named contact — is the commercial information the plan sells access to.\n\n`units_contracted` is what the hotel holds for you. What is LEFT is not here, because it is only meaningful for a date: ask `/availability`.",
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/accommodations/{accommodation}": {
            "get": {
                "operationId": "api.v1.tenant.accommodations.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the accommodation",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "accommodation",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Accommodation id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/accommodations/{accommodation}/availability": {
            "get": {
                "operationId": "api.v1.tenant.accommodations.availability",
                "tags": [
                    "Partner"
                ],
                "summary": "What is left of each room type, night by night",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "accommodation",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Accommodation id."
                    },
                    {
                        "name": "from",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "REQUIRED. First night, YYYY-MM-DD."
                    },
                    {
                        "name": "to",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "REQUIRED. Check-out day, YYYY-MM-DD — exclusive, so the last night counted is the day before it. At most 90 nights after `from`; longer ranges are rejected with 422."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Counted live by AccommodationInventory, the one place a remaining-unit count is worked out, so this can never disagree with the organiser's screen.\n\nThe range is HALF-OPEN: `to` is the morning people leave, so the last night counted is the day before it — the same convention a booking uses. `remaining_across` is the TIGHTEST night in the range, which is what decides whether a stay fits: a room free on three nights of four is not a room you can book for four.\n\nA negative number is a real answer, not an error. Booking past a hotel's allotment is allowed on purpose and warned about rather than blocked.\n\nThe range is CAPPED AT 90 NIGHTS. It drives a night-by-night walk, so an uncapped `?from=2020-01-01&to=2030-01-01` is ~3,650 nights times room types in one response. A longer range is a `422`, not a truncated answer — 90 nights is longer than any festival this surface was built for.",
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/announcements": {
            "get": {
                "operationId": "api.v1.tenant.announcements.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List announcements",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.announcements.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create an announcement",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/announcements/{announcement}": {
            "patch": {
                "operationId": "api.v1.tenant.announcements.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the announcement",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "announcement",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Announcement id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.announcements.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the announcement",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "announcement",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Announcement id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/assistants": {
            "get": {
                "operationId": "api.v1.tenant.assistants",
                "tags": [
                    "Partner"
                ],
                "summary": "List assistants",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "results:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "results:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/booking-forms": {
            "get": {
                "operationId": "api.v1.tenant.booking-forms.index",
                "tags": [
                    "Partner"
                ],
                "summary": "Proforma invoices raised for participants",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Only documents raised for this participant."
                    },
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "draft, sent, accepted or cancelled."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "READ ONLY. Sending a booking form claims a document number, freezes every price, writes real debt to a participant's balance and emails a PDF in the organiser's name — four irreversible things in one step, in the organiser's own document series — so there is no write route and therefore no write scope.\n\nA DRAFT has no `number`: it genuinely has none until it is sent, which is what keeps the series gapless. `issuer` and `client` are the blocks frozen at send and are null before it.\n\n⚠️ An instalment's `percent` is a FRACTION of 1 — half is `0.5`. `percent_display` carries the same value as the number an organiser typed (50), for rendering.\n\nNot plan-gated, for the same reason reading a balance is not.",
                "security": [
                    {
                        "oauth2": [
                            "finances:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/booking-forms/{document}": {
            "get": {
                "operationId": "api.v1.tenant.booking-forms.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the booking form",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "document",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Document id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "finances:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/candidates": {
            "get": {
                "operationId": "api.v1.tenant.candidates.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List candidates",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "candidates:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "candidates:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/candidates/{candidate}": {
            "get": {
                "operationId": "api.v1.tenant.candidates.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the candidate",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "candidate",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Candidate id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "candidates:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "candidates:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.candidates.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the candidate",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "candidate",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Candidate id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "candidates:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "candidates:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.candidates.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the candidate",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "candidate",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Candidate id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "candidates:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "candidates:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/candidates/{candidate}/convert": {
            "post": {
                "operationId": "api.v1.tenant.candidates.convert",
                "tags": [
                    "Partner"
                ],
                "summary": "Convert a registration into a participant",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "candidate",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Candidate id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Creates the team, copies the logo into the team's storage and sends the confirmation email, in one transaction. Refused with `402` if the plan's participant cap is already reached.",
                "security": [
                    {
                        "oauth2": [
                            "candidates:write",
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "candidates:write",
                    "teams:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/candidates/{candidate}/reject": {
            "post": {
                "operationId": "api.v1.tenant.candidates.reject",
                "tags": [
                    "Partner"
                ],
                "summary": "Reject a registration",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "candidate",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Candidate id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Marks the candidate rejected. A candidate that has already been converted cannot be rejected — delete the participant instead.",
                "security": [
                    {
                        "oauth2": [
                            "candidates:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "candidates:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/custom-attributes": {
            "get": {
                "operationId": "api.v1.tenant.custom-attributes.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List custom attributes",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "custom-attributes:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "custom-attributes:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.custom-attributes.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a custom attribute",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "custom-attributes:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "custom-attributes:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/custom-attributes/{attribute}": {
            "get": {
                "operationId": "api.v1.tenant.custom-attributes.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the custom attribute",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "attribute",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Attribute id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "custom-attributes:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "custom-attributes:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.custom-attributes.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the custom attribute",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "attribute",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Attribute id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "custom-attributes:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "custom-attributes:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.custom-attributes.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the custom attribute",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "attribute",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Attribute id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "custom-attributes:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "custom-attributes:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/divisions": {
            "get": {
                "operationId": "api.v1.tenant.divisions.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List divisions",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "divisions:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "divisions:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.divisions.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a division",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "divisions:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "divisions:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/divisions/{division}": {
            "get": {
                "operationId": "api.v1.tenant.divisions.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the division",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "division",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Division id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "divisions:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "divisions:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.divisions.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the division",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "division",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Division id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "divisions:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "divisions:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.divisions.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the division",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "division",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Division id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "divisions:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "divisions:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/divisions/{division}/logo": {
            "post": {
                "operationId": "api.v1.tenant.divisions.logo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the division logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "division",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Division id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "divisions:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "divisions:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.divisions.logo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the division logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "division",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Division id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "divisions:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "divisions:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/documents": {
            "get": {
                "operationId": "api.v1.tenant.documents.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List documents",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.documents.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Publish a document link",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Links only. Uploaded files remain a panel action: they live on a private disk and are served through a controller that re-checks the plan and the page setting on every request.",
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/documents/{document}": {
            "patch": {
                "operationId": "api.v1.tenant.documents.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the document",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "document",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Document id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.documents.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the document",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "document",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Document id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/fees": {
            "get": {
                "operationId": "api.v1.tenant.fees.index",
                "tags": [
                    "Partner"
                ],
                "summary": "Every charge template this tournament uses",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "`pricing_mode` decides what the amount is PER, and changes what the fee means entirely. `flat` bills its amount once; `per_person` bills it per head and is NOT directly applicable — it belongs on a booking form, where the pax figure is stated. `directly_applicable` is the same answer as a boolean, for clients that would rather branch on it than on the enum.",
                "security": [
                    {
                        "oauth2": [
                            "finances:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.fees.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a fee",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "A fee carries its deadline as an OFFSET (`due_days`, counted from the day each participant is billed) or a FIXED DATE (`due_on`), never both — sending one clears the other. Sending neither means this fee has no deadline, and a charge with no deadline is never chased automatically.",
                "security": [
                    {
                        "oauth2": [
                            "finances:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/fees/{fee}": {
            "get": {
                "operationId": "api.v1.tenant.fees.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the fee",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "fee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Fee id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "finances:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.fees.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the fee",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "fee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Fee id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "finances:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.fees.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the fee",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "fee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Fee id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "finances:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/fees/{fee}/apply": {
            "post": {
                "operationId": "api.v1.tenant.fees.apply",
                "tags": [
                    "Partner"
                ],
                "summary": "Raise this fee as a charge against participants",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "fee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Fee id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Goes through FeeApplier, which locks the fee row, refuses to bill a participant it has already billed for this fee, and resolves the deadline through the one method that knows the offset-vs-fixed-date distinction.\n\nReturns how many charges were `created` and how many participants were `skipped` because they already carried one.",
                "security": [
                    {
                        "oauth2": [
                            "finances:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "target": {
                                        "type": "string",
                                        "enum": [
                                            "all",
                                            "division",
                                            "selection"
                                        ]
                                    },
                                    "division_id": {
                                        "type": "string",
                                        "description": "Required when target is `division`."
                                    },
                                    "team_ids": {
                                        "type": "array",
                                        "items": {
                                            "type": "string"
                                        },
                                        "description": "Required when target is `selection`."
                                    },
                                    "occurred_on": {
                                        "type": "string",
                                        "description": "Billing date. Defaults to today in the tournament's own timezone."
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/finance-balances": {
            "get": {
                "operationId": "api.v1.tenant.finance-balances",
                "tags": [
                    "Partner"
                ],
                "summary": "What each participant owes",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Computed by FinanceLedger, the only place this arithmetic lives. All amounts are MINOR UNITS (integer cents) as stored — no float ever touches a balance.\n\nReading a balance is NOT plan-gated, unlike every finance write: an organiser whose plan lapsed must still be able to see what they are owed.",
                "security": [
                    {
                        "oauth2": [
                            "finances:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/finance-entries": {
            "get": {
                "operationId": "api.v1.tenant.finance-entries.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List finance entries",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "finances:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.finance-entries.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Record a charge, payment or refund",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Entries created here are CONFIRMED: a credential acting for the organiser is recording a decision already made. The `pending` state exists for a club's self-reported payment, which arrives through the participant panel and cannot be created from this surface.",
                "security": [
                    {
                        "oauth2": [
                            "finances:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/finance-entries/{entry}": {
            "get": {
                "operationId": "api.v1.tenant.finance-entries.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the finance entry",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "entry",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Entry id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "finances:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.finance-entries.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the finance entry",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "entry",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Entry id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "finances:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.finance-entries.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the finance entry",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "entry",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Entry id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "finances:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "finances:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/grounds/{ground}/availability": {
            "get": {
                "operationId": "api.v1.tenant.grounds.availability.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List grounds availability",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "ground",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Ground id."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.grounds.availability.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Declare when a venue is free",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "ground",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Ground id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Writing a window schedules NOTHING. MatchScheduler is the only thing that writes a kickoff time, so opening hours can be declared without any fixture moving until auto-fill is asked for.\n\n`slot_minutes` is required and is the single source of truth for how long a match occupies this venue. Sport config (periods x duration) drives the match-editor clock and deliberately does not feed scheduling.",
                "security": [
                    {
                        "oauth2": [
                            "venues:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/grounds/{ground}/availability/{availability}": {
            "patch": {
                "operationId": "api.v1.tenant.grounds.availability.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the grounds availability",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "ground",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Ground id."
                    },
                    {
                        "name": "availability",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Availability id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.grounds.availability.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the grounds availability",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "ground",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Ground id."
                    },
                    {
                        "name": "availability",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Availability id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/hospitality-groups": {
            "get": {
                "operationId": "api.v1.tenant.hospitality-groups.index",
                "tags": [
                    "Partner"
                ],
                "summary": "Who is travelling, as the units that need beds",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Only groups linked to this participant."
                    },
                    {
                        "name": "type",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "One of team, team_guests, officials, individual."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "⚠️ A GROUP IS NOT A TEAM. A club of 18 can arrive as three groups — the squad in a hostel, the coaches in a hotel, twenty parents in family rooms — and referees are a group belonging to no club at all. `team_id` is therefore nullable by design; it is what links a group's costs to a participant's balance.\n\nCalled a group here because that is the word the panel, the emails and the documentation use. The model is named `Party` only to avoid colliding with a group STAGE.",
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/hospitality-groups/{group}": {
            "get": {
                "operationId": "api.v1.tenant.hospitality-groups.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the hospitality group",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "group",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Group id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/library/clubs": {
            "get": {
                "operationId": "api.v1.tenant.library.clubs",
                "tags": [
                    "Partner"
                ],
                "summary": "List the club library",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "search",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Only entries whose name contains every word."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Page size, at most 100."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "The LIBRARY is one entry per club, player and staff member across every season of this tournament. Each season's row points at its entry through `library_id` (on teams, players and staff in partner responses only — never on the public surface, because it links one child's records across seasons).\n\nThe library fills itself: a next season copies its rows already linked, and a row added later links to its entry when exactly one entry matches, becomes a new entry when none does, and is left unlinked only when the match is ambiguous.\n\n`seasons` lists the tournaments (id) each entry appears in, oldest first.\n\nA credential attached to SOME seasons sees the library through them only: an entry is listed when it has a row in a season the credential reaches, and `seasons` names only those. Linking to an entry it could not list is refused like another tournament's entry (422).",
                "security": [
                    {
                        "oauth2": [
                            "teams:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/library/players": {
            "get": {
                "operationId": "api.v1.tenant.library.players",
                "tags": [
                    "Partner"
                ],
                "summary": "List the player library",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "search",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Only entries whose name contains every word."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Page size, at most 100."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "See the club library. People carry `birth_year` (the year only, enough to tell namesakes apart). Anonymised people are left out.",
                "security": [
                    {
                        "oauth2": [
                            "players:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/library/players/duplicates": {
            "get": {
                "operationId": "api.v1.tenant.library.players.duplicates",
                "tags": [
                    "Partner"
                ],
                "summary": "Likely duplicate players in the library",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Groups of two or more entries with the same name whose birth dates do not disagree, minus pairs marked as different people. A suggestion, never an automatic merge: two children of one name at one club are real.",
                "security": [
                    {
                        "oauth2": [
                            "players:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/library/players/{entry}/distinct": {
            "post": {
                "operationId": "api.v1.tenant.library.players.distinct",
                "tags": [
                    "Partner"
                ],
                "summary": "Mark two players as different people",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "entry",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Entry id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "The pair is never suggested as a duplicate again. Returns 403 `tournament_not_in_scope` when either person also has a row in a season this credential does not reach.",
                "security": [
                    {
                        "oauth2": [
                            "players:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "from": {
                                        "type": "string",
                                        "description": "The other library entry."
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/library/players/{entry}/merge": {
            "post": {
                "operationId": "api.v1.tenant.library.players.merge",
                "tags": [
                    "Partner"
                ],
                "summary": "Merge a duplicate player into another",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "entry",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Entry id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Every season row of the duplicate (the path entry) now points at `into`, blanks on `into` are filled from the duplicate, and the duplicate is deleted. Only the library changes: numbers, goals, lineups and documents stay exactly as each season recorded them. Returns 403 `tournament_not_in_scope` when either person also has a row in a season this credential does not reach.",
                "security": [
                    {
                        "oauth2": [
                            "players:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "into": {
                                        "type": "string",
                                        "description": "The library entry to keep."
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/library/staff": {
            "get": {
                "operationId": "api.v1.tenant.library.staff",
                "tags": [
                    "Partner"
                ],
                "summary": "List the staff library",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "search",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Only entries whose name contains every word."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Page size, at most 100."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "See the club library. Anonymised people are left out.",
                "security": [
                    {
                        "oauth2": [
                            "staff:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "staff:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/logo": {
            "post": {
                "operationId": "api.v1.tenant.logo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the tournament logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "tournaments:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "tournaments:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.logo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the tournament logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "tournaments:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "tournaments:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/matches": {
            "get": {
                "operationId": "api.v1.tenant.matches.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List fixtures",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "date",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "A calendar day in the tournament's own timezone."
                    },
                    {
                        "name": "team",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Matches involving this team, home or away."
                    },
                    {
                        "name": "phase",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Limit to one phase."
                    },
                    {
                        "name": "matchday",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Limit to one matchday."
                    },
                    {
                        "name": "venue",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Limit to one venue."
                    },
                    {
                        "name": "status",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "not_started, in_progress or finished."
                    },
                    {
                        "name": "unscheduled",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "true returns only matches with no kickoff time."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "matches:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "matches:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/matches/generate": {
            "post": {
                "operationId": "api.v1.tenant.matches.generate",
                "tags": [
                    "Partner"
                ],
                "summary": "Generate the fixture list",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "DESTRUCTIVE. Existing matches are soft-deleted and rebuilt from the current team slots, taking their events, lineups and referee assignments with them. If anything would be lost the call is refused with `409 destructive_confirmation_required` listing what would go; repeat with `confirm_destructive: true`.\n\nThere is no endpoint for creating a single match: matches exist because a structure was generated, and a hand-made fixture would belong to no group and count towards no table.",
                "security": [
                    {
                        "oauth2": [
                            "matches:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "matches:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "phase_id": {
                                        "type": "string",
                                        "description": "Limit to one phase. Omit for the whole tournament."
                                    },
                                    "shuffle_teams": {
                                        "type": "boolean"
                                    },
                                    "confirm_destructive": {
                                        "type": "boolean"
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/matches/{match}": {
            "get": {
                "operationId": "api.v1.tenant.matches.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the match",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "match",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "matches:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "matches:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.matches.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Move or restate a fixture",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "match",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Kickoff time, venue, status and description. Set `is_schedule_locked` to pin a match so auto-fill, regeneration and \"clear schedule\" leave it alone.",
                "security": [
                    {
                        "oauth2": [
                            "matches:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "matches:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/matches/{match}/events": {
            "get": {
                "operationId": "api.v1.tenant.events.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List a match's events",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "match",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match id."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "results:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "results:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.events.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Record a match event",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "match",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "A goal, card or substitution as its own row, so a live-scoring integration can post one the moment it happens instead of resubmitting the whole match. `event_code` is validated against this SPORT's event list — a handball tournament genuinely has no yellow-red card.",
                "security": [
                    {
                        "oauth2": [
                            "results:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "results:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/matches/{match}/events/{event}": {
            "patch": {
                "operationId": "api.v1.tenant.events.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the event",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "match",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match id."
                    },
                    {
                        "name": "event",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Event id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "results:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "results:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.events.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the event",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "match",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match id."
                    },
                    {
                        "name": "event",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Event id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "results:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "results:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/matches/{match}/result": {
            "put": {
                "operationId": "api.v1.tenant.matches.result",
                "tags": [
                    "Partner"
                ],
                "summary": "Record a match result",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "match",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Match id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Scores, extra time, penalties and technical results. A set-scored sport must send `sets` and is refused if it sends `home_score` — the match score there is SETS WON, derived from the per-set rows.\n\nSeparate from PATCH /matches/{match}, which moves a fixture: a score is governed by the results capability, a kickoff time by the schedule one, and a finished tournament still allows both.",
                "security": [
                    {
                        "oauth2": [
                            "results:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "results:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "status": {
                                        "type": "integer",
                                        "enum": [
                                            1,
                                            2,
                                            3
                                        ],
                                        "description": "1 not started, 2 finished, 3 in progress."
                                    },
                                    "home_score": {
                                        "type": "integer"
                                    },
                                    "away_score": {
                                        "type": "integer"
                                    },
                                    "additional_time_played": {
                                        "type": "boolean"
                                    },
                                    "penalties_played": {
                                        "type": "boolean"
                                    },
                                    "sets": {
                                        "type": "array",
                                        "items": {
                                            "type": "object"
                                        }
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/meal-services": {
            "get": {
                "operationId": "api.v1.tenant.meal-services.index",
                "tags": [
                    "Partner"
                ],
                "summary": "Sittings, and how many of each group is eating",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "date",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "A single calendar day, YYYY-MM-DD."
                    },
                    {
                        "name": "type",
                        "in": "query",
                        "required": false,
                        "schema": {
                            "type": "string"
                        },
                        "description": "breakfast, lunch, dinner, snack or other."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "⚠️ `headcount` is TYPED by the organiser, never derived from a roster. Clubs arrive late and miss a dinner, families booked half board and eat in town, and Sunday's squad is nine players because the rest went home after the semi-final. A client that recomputes these from group sizes will disagree with the number the caterer was given — which is the number that gets cooked and paid for.\n\n`total_headcount` is the figure a caterer asks for.",
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/meal-services/{meal}": {
            "get": {
                "operationId": "api.v1.tenant.meal-services.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the meal service",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "meal",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Meal id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "hospitality:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "hospitality:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/plan": {
            "get": {
                "operationId": "api.v1.tenant.plan",
                "tags": [
                    "Partner"
                ],
                "summary": "The tournament's plan, its caps and what remains",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Read this to refuse locally instead of discovering a cap through a 402 halfway through an import.",
                "security": [
                    {
                        "oauth2": [
                            "plan:read",
                            "tournaments:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "plan:read",
                    "tournaments:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/referees": {
            "get": {
                "operationId": "api.v1.tenant.referees.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List referees",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "referees:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "referees:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.referees.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a referee",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "referees:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "referees:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/referees/{referee}": {
            "get": {
                "operationId": "api.v1.tenant.referees.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the referee",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "referee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Referee id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "referees:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "referees:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.referees.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the referee",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "referee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Referee id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "referees:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "referees:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.referees.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the referee",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "referee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Referee id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "referees:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "referees:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/referees/{referee}/photo": {
            "post": {
                "operationId": "api.v1.tenant.referees.photo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the referee photo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "referee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Referee id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "referees:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "referees:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.referees.photo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the referee photo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "referee",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Referee id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "referees:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "referees:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/schedule/apply": {
            "post": {
                "operationId": "api.v1.tenant.schedule.apply",
                "tags": [
                    "Partner"
                ],
                "summary": "Apply a proposed schedule",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Recomputes the proposal server-side and accepts only your `fingerprint` as proof that nothing moved in between. A stale fingerprint is refused rather than allowed to double-book a pitch.",
                "security": [
                    {
                        "oauth2": [
                            "schedule:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "schedule:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "fingerprint": {
                                        "type": "string"
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/schedule/conflicts": {
            "get": {
                "operationId": "api.v1.tenant.schedule.conflicts",
                "tags": [
                    "Partner"
                ],
                "summary": "List scheduling clashes",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Two matches on one venue at one time, or a team in two places at once. `matches_in_conflict` counts MATCHES, not conflicts, which is the question an organiser is actually asking.",
                "security": [
                    {
                        "oauth2": [
                            "schedule:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "schedule:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/schedule/propose": {
            "post": {
                "operationId": "api.v1.tenant.schedule.propose",
                "tags": [
                    "Partner"
                ],
                "summary": "Propose a venue-aware schedule",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "WRITES NOTHING. Returns the placements plus every match it could not seat WITH A REASON — `division_venue`, `round_order`, `rest`, `max_per_day`, `team_busy`, `no_slot` — each of which points at a different remedy. Pass the returned `fingerprint` to /schedule/apply.",
                "security": [
                    {
                        "oauth2": [
                            "schedule:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "schedule:read",
                    "platform:tournaments:read"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/scorers": {
            "get": {
                "operationId": "api.v1.tenant.scorers",
                "tags": [
                    "Partner"
                ],
                "summary": "Top scorers",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "results:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "results:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/seasons": {
            "get": {
                "operationId": "api.v1.tenant.seasons.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List the seasons of this tournament",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Every season, oldest first, including this one. `is_current` marks the season the tournament is on; `reachable` says whether THIS credential is attached to that season, since a credential reaches only the seasons it was given. A tournament with no other seasons returns itself alone.",
                "security": [
                    {
                        "oauth2": [
                            "tournaments:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "tournaments:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/sponsors": {
            "get": {
                "operationId": "api.v1.tenant.sponsors.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List sponsors",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.sponsors.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a sponsor",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/sponsors/{sponsor}": {
            "patch": {
                "operationId": "api.v1.tenant.sponsors.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the sponsor",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "sponsor",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Sponsor id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.sponsors.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the sponsor",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "sponsor",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Sponsor id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/sponsors/{sponsor}/logo": {
            "post": {
                "operationId": "api.v1.tenant.sponsors.logo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the sponsor logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "sponsor",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Sponsor id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.sponsors.logo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the sponsor logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "sponsor",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Sponsor id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "website:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "website:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/standings": {
            "get": {
                "operationId": "api.v1.tenant.standings",
                "tags": [
                    "Partner"
                ],
                "summary": "List standings",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "results:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "results:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/statistics": {
            "get": {
                "operationId": "api.v1.tenant.statistics",
                "tags": [
                    "Partner"
                ],
                "summary": "List statistics",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "statistics:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "statistics:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/structure": {
            "get": {
                "operationId": "api.v1.tenant.structure.show",
                "tags": [
                    "Partner"
                ],
                "summary": "The tournament structure",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "structure:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "structure:read",
                    "platform:tournaments:read"
                ]
            },
            "put": {
                "operationId": "api.v1.tenant.structure.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Replace the tournament structure",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Does NOT regenerate matches. Call POST /matches/generate explicitly, so adjusting one group cannot silently destroy a weekend of results.",
                "security": [
                    {
                        "oauth2": [
                            "structure:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "structure:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/structure/preview": {
            "post": {
                "operationId": "api.v1.tenant.structure.preview",
                "tags": [
                    "Partner"
                ],
                "summary": "Preview a structure without saving it",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Turns \"8 teams, 2 groups, knockout from the quarters\" into the same form-data shape PUT /structure expects, so an organiser can see what they are about to commit to before anything is written.",
                "security": [
                    {
                        "oauth2": [
                            "structure:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "structure:read",
                    "platform:tournaments:read"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "generation_code": {
                                        "type": "string",
                                        "description": "league, knockout, or groups_and_knockout."
                                    },
                                    "teams_number": {
                                        "type": "integer"
                                    },
                                    "groups_number": {
                                        "type": "integer"
                                    },
                                    "playoff_rounds_number": {
                                        "type": "integer"
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/team-forms": {
            "get": {
                "operationId": "api.v1.tenant.team-forms.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List team forms",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "forms:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "forms:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.team-forms.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a team form",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "forms:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "forms:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/team-forms/{form}": {
            "get": {
                "operationId": "api.v1.tenant.team-forms.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the team form",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "form",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Form id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "forms:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "forms:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.team-forms.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update a form",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "form",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Form id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "`fields` replaces the whole set when present. Omitting it leaves the fields alone, so renaming a form does not require resending every field; sending an empty array really does clear them.\n\nBecause it REPLACES rather than merges, two clients doing read-modify-write silently overwrite each other. Send `expected_version` (the `version` from your last read) to be refused with `409 form_modified` instead of losing the other edit. It is a content hash, not a timestamp: `updated_at` is second-precision and cannot detect a same-second change.",
                "security": [
                    {
                        "oauth2": [
                            "forms:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "forms:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.team-forms.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the team form",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "form",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Form id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "forms:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "forms:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/team-forms/{form}/responses": {
            "get": {
                "operationId": "api.v1.tenant.team-forms.responses",
                "tags": [
                    "Partner"
                ],
                "summary": "Every participant's answers to this form",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "form",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Form id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "description": "Read-only. A response is the participant's own statement, made in their panel; an organiser credential that could write one would answer on the club's behalf and leave no trace that it had.\n\nAnswers are keyed by FIELD ID, never by label — a label is editable text, and keying on it would re-point every historical answer the first time somebody fixes a typo.",
                "security": [
                    {
                        "oauth2": [
                            "forms:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "forms:read",
                    "platform:tournaments:read"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/teams": {
            "get": {
                "operationId": "api.v1.tenant.teams.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List teams",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.teams.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a team",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}": {
            "get": {
                "operationId": "api.v1.tenant.teams.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the team",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.teams.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the team",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.teams.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the team",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/library": {
            "put": {
                "operationId": "api.v1.tenant.teams.library",
                "tags": [
                    "Partner"
                ],
                "summary": "Link a team to its club library entry",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "Sets which library entry this season's team is. `library_id` is an entry of this tournament's library, `\"new\"` for a new entry, or `null` to unlink. An entry nothing points at any more is removed. Returns 409 `not_a_season` when the tournament has no library.",
                "security": [
                    {
                        "oauth2": [
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "library_id": {
                                        "type": "string",
                                        "nullable": true,
                                        "description": "A club library id, \"new\", or null to unlink."
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/logo": {
            "post": {
                "operationId": "api.v1.tenant.teams.logo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the team logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.teams.logo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the team logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/photo": {
            "post": {
                "operationId": "api.v1.tenant.teams.photo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the team photo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.teams.photo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the team photo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "teams:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "teams:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/players": {
            "get": {
                "operationId": "api.v1.tenant.players.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List a team's players",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "players:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.players.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a player",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "players:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/players/{player}": {
            "patch": {
                "operationId": "api.v1.tenant.players.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the player",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "player",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Player id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "players:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.players.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the player",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "player",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Player id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "players:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/players/{player}/library": {
            "put": {
                "operationId": "api.v1.tenant.players.library",
                "tags": [
                    "Partner"
                ],
                "summary": "Link a player to their library entry",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "player",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Player id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "As for teams: an entry id, `\"new\"`, or `null` to unlink.",
                "security": [
                    {
                        "oauth2": [
                            "players:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "library_id": {
                                        "type": "string",
                                        "nullable": true,
                                        "description": "A player library id, \"new\", or null to unlink."
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/players/{player}/photo": {
            "post": {
                "operationId": "api.v1.tenant.players.photo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the player photo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "player",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Player id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "players:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.players.photo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the player photo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "player",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Player id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "players:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "players:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/staff": {
            "get": {
                "operationId": "api.v1.tenant.staff.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List a team's staff",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "staff:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "staff:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.staff.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a staff member",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "staff:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "staff:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/staff/{staff}": {
            "patch": {
                "operationId": "api.v1.tenant.staff.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the staff member",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "staff",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Staff id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "staff:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "staff:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.staff.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the staff member",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "staff",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Staff id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "staff:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "staff:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/staff/{staff}/library": {
            "put": {
                "operationId": "api.v1.tenant.staff.library",
                "tags": [
                    "Partner"
                ],
                "summary": "Link a staff member to their library entry",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "staff",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Staff id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "description": "As for teams: an entry id, `\"new\"`, or `null` to unlink.",
                "security": [
                    {
                        "oauth2": [
                            "staff:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "staff:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object",
                                "properties": {
                                    "library_id": {
                                        "type": "string",
                                        "nullable": true,
                                        "description": "A staff library id, \"new\", or null to unlink."
                                    }
                                }
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/teams/{team}/staff/{staff}/photo": {
            "post": {
                "operationId": "api.v1.tenant.staff.photo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the staff member photo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "staff",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Staff id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "staff:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "staff:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.staff.photo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the staff member photo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "team",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Team id."
                    },
                    {
                        "name": "staff",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Staff id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "staff:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "staff:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/venues": {
            "get": {
                "operationId": "api.v1.tenant.venues.index",
                "tags": [
                    "Partner"
                ],
                "summary": "List venues",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1
                        },
                        "description": "Page number."
                    },
                    {
                        "name": "per_page",
                        "in": "query",
                        "schema": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100,
                            "default": 25
                        },
                        "description": "Page size, clamped to 100 rather than refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:read",
                    "platform:tournaments:read"
                ]
            },
            "post": {
                "operationId": "api.v1.tenant.venues.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Create a venue",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            }
        },
        "/api/v1/tournaments/{tournament}/venues/{venue}": {
            "get": {
                "operationId": "api.v1.tenant.venues.show",
                "tags": [
                    "Partner"
                ],
                "summary": "Get the venue",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "venue",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Venue id."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:read",
                            "platform:tournaments:read"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:read",
                    "platform:tournaments:read"
                ]
            },
            "patch": {
                "operationId": "api.v1.tenant.venues.update",
                "tags": [
                    "Partner"
                ],
                "summary": "Update the venue",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "venue",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Venue id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "200": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": false,
                    "content": {
                        "application/json": {
                            "schema": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.venues.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Delete the venue",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "venue",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Venue id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:write",
                    "platform:tournaments:write"
                ]
            }
        },
        "/api/v1/tournaments/{tournament}/venues/{venue}/logo": {
            "post": {
                "operationId": "api.v1.tenant.venues.logo.store",
                "tags": [
                    "Partner"
                ],
                "summary": "Upload the venue logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "venue",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Venue id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "201": {
                        "description": "Success.",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "type": "object"
                                }
                            }
                        }
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:write",
                    "platform:tournaments:write"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "multipart/form-data": {
                            "schema": {
                                "type": "object",
                                "required": [
                                    "file"
                                ],
                                "properties": {
                                    "file": {
                                        "type": "string",
                                        "format": "binary",
                                        "description": "png, jpg or webp, up to 2MB. Resized to a 1200px longest edge on upload."
                                    }
                                }
                            }
                        }
                    }
                }
            },
            "delete": {
                "operationId": "api.v1.tenant.venues.logo.destroy",
                "tags": [
                    "Partner"
                ],
                "summary": "Remove the venue logo",
                "parameters": [
                    {
                        "name": "tournament",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "The tournament, by uuid or url_key. Numeric ids are deliberately not accepted."
                    },
                    {
                        "name": "venue",
                        "in": "path",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Venue id."
                    },
                    {
                        "name": "Idempotency-Key",
                        "in": "header",
                        "required": false,
                        "schema": {
                            "type": "string",
                            "maxLength": 255
                        },
                        "description": "Replay-safe retries. The same key with the same body returns the first response; with a different body it is refused."
                    }
                ],
                "responses": {
                    "204": {
                        "description": "Deleted."
                    },
                    "401": {
                        "$ref": "#/components/responses/Error401"
                    },
                    "403": {
                        "$ref": "#/components/responses/Error403"
                    },
                    "404": {
                        "$ref": "#/components/responses/Error404"
                    },
                    "422": {
                        "$ref": "#/components/responses/Error422"
                    },
                    "429": {
                        "$ref": "#/components/responses/Error429"
                    },
                    "402": {
                        "$ref": "#/components/responses/Error402"
                    },
                    "409": {
                        "$ref": "#/components/responses/Error409"
                    }
                },
                "security": [
                    {
                        "oauth2": [
                            "venues:write",
                            "platform:tournaments:write"
                        ]
                    }
                ],
                "x-required-scopes": [
                    "venues:write",
                    "platform:tournaments:write"
                ]
            }
        }
    },
    "components": {
        "securitySchemes": {
            "oauth2": {
                "type": "oauth2",
                "description": "Exchange client_id + client_secret at POST /api/v1/oauth/token, then send the access token as a bearer.",
                "flows": {
                    "clientCredentials": {
                        "tokenUrl": "/api/v1/oauth/token",
                        "scopes": {
                            "tournaments:read": "Tournament — read",
                            "tournaments:write": "Tournament — write",
                            "teams:read": "Participants — read",
                            "teams:write": "Participants — write",
                            "players:read": "Participants — read",
                            "players:write": "Participants — write",
                            "staff:read": "Participants — read",
                            "staff:write": "Participants — write",
                            "candidates:read": "Participants — read",
                            "candidates:write": "Participants — write",
                            "divisions:read": "Structure — read",
                            "divisions:write": "Structure — write",
                            "structure:read": "Structure — read",
                            "structure:write": "Structure — write",
                            "matches:read": "Matches — read",
                            "matches:write": "Matches — write",
                            "results:read": "Matches — read",
                            "results:write": "Matches — write",
                            "schedule:read": "Matches — read",
                            "schedule:write": "Matches — write",
                            "venues:read": "Venues & officials — read",
                            "venues:write": "Venues & officials — write",
                            "referees:read": "Venues & officials — read",
                            "referees:write": "Venues & officials — write",
                            "website:read": "Website & forms — read",
                            "website:write": "Website & forms — write",
                            "forms:read": "Website & forms — read",
                            "forms:write": "Website & forms — write",
                            "custom-attributes:read": "Website & forms — read",
                            "custom-attributes:write": "Website & forms — write",
                            "finances:read": "Finances — read",
                            "finances:write": "Finances — write",
                            "hospitality:read": "Hospitality — read",
                            "statistics:read": "Matches — read",
                            "plan:read": "Tournament — read",
                            "platform:tournaments:read": "Platform — read",
                            "platform:tournaments:write": "Platform — write",
                            "platform:users:read": "Platform — read",
                            "platform:users:write": "Platform — write",
                            "platform:api-clients:read": "Platform — read",
                            "platform:api-clients:write": "Platform — write",
                            "platform:billing:read": "Platform — read",
                            "platform:billing:write": "Platform — write",
                            "platform:content:read": "Platform — read",
                            "platform:content:write": "Platform — write",
                            "platform:metrics": "Platform — read"
                        }
                    }
                }
            },
            "publicKey": {
                "type": "apiKey",
                "in": "header",
                "name": "X-MyCup-Key",
                "description": "A publishable key, safe to embed in a front-end. Read-only. Also accepted as ?api_key=."
            }
        },
        "schemas": {
            "Error": {
                "type": "object",
                "description": "Every deliberate refusal. `code` is the stable contract and is never translated; `message` is localised and must not be parsed.",
                "required": [
                    "error"
                ],
                "properties": {
                    "error": {
                        "type": "object",
                        "required": [
                            "code",
                            "message"
                        ],
                        "properties": {
                            "code": {
                                "type": "string"
                            },
                            "message": {
                                "type": "string"
                            },
                            "details": {
                                "type": "object"
                            }
                        }
                    }
                }
            },
            "Pagination": {
                "type": "object",
                "properties": {
                    "current_page": {
                        "type": "integer"
                    },
                    "last_page": {
                        "type": "integer"
                    },
                    "per_page": {
                        "type": "integer"
                    },
                    "total": {
                        "type": "integer"
                    }
                }
            },
            "Tournament": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "string",
                        "format": "uuid"
                    },
                    "url_key": {
                        "type": "string"
                    },
                    "name": {
                        "type": "string"
                    },
                    "season": {
                        "type": "string",
                        "nullable": true
                    },
                    "sport_code": {
                        "type": "string",
                        "nullable": true
                    },
                    "time_zone": {
                        "type": "string"
                    },
                    "lifecycle_state": {
                        "type": "string",
                        "enum": [
                            "setup",
                            "registration",
                            "upcoming",
                            "live",
                            "completed"
                        ]
                    },
                    "is_finished": {
                        "type": "boolean"
                    },
                    "shows_divisions": {
                        "type": "boolean",
                        "description": "False when the tournament has one division or none, in which case division fields are omitted everywhere."
                    },
                    "public_pages": {
                        "type": "object",
                        "description": "Which public pages exist, so a front-end can build navigation without probing for 404s."
                    }
                }
            },
            "Match": {
                "type": "object",
                "properties": {
                    "id": {
                        "type": "string"
                    },
                    "status": {
                        "type": "string",
                        "enum": [
                            "not_started",
                            "in_progress",
                            "finished"
                        ]
                    },
                    "kickoff_at": {
                        "type": "string",
                        "format": "date-time",
                        "nullable": true,
                        "description": "The instant, with offset."
                    },
                    "kickoff_local": {
                        "type": "string",
                        "format": "date-time",
                        "nullable": true,
                        "description": "The same moment in the tournament's own timezone."
                    },
                    "home_team": {
                        "type": "object",
                        "nullable": true,
                        "description": "Null, or a placeholder carrying a source label (\"Winner of Group A\") when the entrant is undecided."
                    },
                    "away_team": {
                        "type": "object",
                        "nullable": true
                    },
                    "score": {
                        "type": "object"
                    }
                }
            },
            "StandingsRow": {
                "type": "object",
                "properties": {
                    "position": {
                        "type": "integer"
                    },
                    "team": {
                        "type": "object",
                        "nullable": true
                    },
                    "played": {
                        "type": "integer"
                    },
                    "wins": {
                        "type": "integer"
                    },
                    "draws": {
                        "type": "integer"
                    },
                    "losses": {
                        "type": "integer"
                    },
                    "goals_for": {
                        "type": "integer"
                    },
                    "goals_against": {
                        "type": "integer"
                    },
                    "goal_difference": {
                        "type": "integer"
                    },
                    "points": {
                        "type": "integer"
                    },
                    "form": {
                        "type": "array",
                        "items": {
                            "type": "string"
                        }
                    }
                }
            }
        },
        "responses": {
            "Error401": {
                "description": "Missing or invalid credentials.",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Error"
                        },
                        "example": {
                            "error": {
                                "code": "unauthenticated",
                                "message": "Missing or invalid credentials."
                            }
                        }
                    }
                }
            },
            "Error402": {
                "description": "Not included in this tournament's plan, or a plan cap was reached. Details name the plan required.",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Error"
                        },
                        "example": {
                            "error": {
                                "code": "plan_limit_reached",
                                "message": "Not included in this tournament's plan, or a plan cap was reached. Details name the plan required."
                            }
                        }
                    }
                }
            },
            "Error403": {
                "description": "The credential lacks the scope, the permission, or access to this tournament.",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Error"
                        },
                        "example": {
                            "error": {
                                "code": "insufficient_scope",
                                "message": "The credential lacks the scope, the permission, or access to this tournament."
                            }
                        }
                    }
                }
            },
            "Error404": {
                "description": "Not found — or, on the public surface, a page the organiser does not publish.",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Error"
                        },
                        "example": {
                            "error": {
                                "code": "not_found",
                                "message": "Not found — or, on the public surface, a page the organiser does not publish."
                            }
                        }
                    }
                }
            },
            "Error409": {
                "description": "The request conflicts with the tournament's state: finished, roster locked, or a destructive action needing confirmation.",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Error"
                        },
                        "example": {
                            "error": {
                                "code": "tournament_finished",
                                "message": "The request conflicts with the tournament's state: finished, roster locked, or a destructive action needing confirmation."
                            }
                        }
                    }
                }
            },
            "Error422": {
                "description": "Validation failed. `details.fields` names each failing field.",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Error"
                        },
                        "example": {
                            "error": {
                                "code": "validation_failed",
                                "message": "Validation failed. `details.fields` names each failing field."
                            }
                        }
                    }
                }
            },
            "Error429": {
                "description": "Rate limit exceeded. Retry-After says when to try again.",
                "content": {
                    "application/json": {
                        "schema": {
                            "$ref": "#/components/schemas/Error"
                        },
                        "example": {
                            "error": {
                                "code": "rate_limited",
                                "message": "Rate limit exceeded. Retry-After says when to try again."
                            }
                        }
                    }
                }
            }
        }
    }
}