{
  "openapi": "3.1.0",
  "info": {
    "title": "RTFC API",
    "description": "Real-time fact-checking API.\n\nSubmit a claim - or a debate, a transcript, or a link to a video - and get back a\nverdict with sources, plus what it cost.\n\n## Authentication\n\nSend a Personal Access Token as either header:\n\n    X-Auth-Token: rtfc_\u2026\n    Authorization: Bearer rtfc_\u2026\n\nCreate one in the dashboard under **Settings \u2192 API Tokens**, or mint one for an\nend user of your own product with `POST /v1/provision/user`.\n\nTokens can be **scoped** to `read`, `write`, `stream`, `provision` or `admin`. A\ntoken created with no scopes has full access.\n\n## Conventions\n\n**Errors** carry a stable machine-readable code - branch on `error.code`, not on\nthe prose:\n\n    {\"detail\": \"Debate not found\",\n     \"error\": {\"code\": \"debate_not_found\", \"message\": \"Debate not found\",\n               \"details\": {}, \"request_id\": \"req_\u2026\"}}\n\n**Every response** carries `X-Request-Id`. Send your own to correlate with your\nlogs; quote it in a support request.\n\n**Lists** return `{\"items\": [...], \"total\": N, \"limit\": L, \"offset\": O}`, where\n`total` is the number of matching rows, not the page size.\n\n**Creates** accept an `Idempotency-Key` header. Retrying with the same key replays\nthe original response (`Idempotency-Replayed: true`) instead of acting twice -\nwhich is what you want when a request times out and you cannot tell whether it\nlanded.\n\n## Versioning\n\n`/v1` is stable: fields are added, never renamed or removed, so treat unknown\nfields as forward compatibility rather than an error. A breaking change would ship\nas `/v2` alongside it.\n\nThe unversioned `/api/...` paths are a permanent alias kept for existing\nintegrations. New code should use `/v1`.\n",
    "version": "v1"
  },
  "paths": {
    "/v1/usage/me": {
      "get": {
        "tags": [
          "usage"
        ],
        "summary": "Get My Usage",
        "description": "Your billed spend and activity over a window.\n\nReturns totals, a time series, a breakdown by kind (LLM, search, STT) and a\nbreakdown by debate. `range` accepts `7d`, `30d`, `mtd` or `all`; pass\nexplicit `from`/`to` instead for an exact window.\n\nCosts are BILLED \u2014 what you owe, markup included. Raw provider cost is not\nexposed here.",
        "operationId": "get_my_usage_v1_usage_me_get",
        "parameters": [
          {
            "name": "range",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Range"
            }
          },
          {
            "name": "from",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "From"
            }
          },
          {
            "name": "to",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "To"
            }
          },
          {
            "name": "granularity",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "day",
              "title": "Granularity"
            }
          },
          {
            "name": "kind",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Kind"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Usage"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/usage/me/summary": {
      "get": {
        "tags": [
          "usage"
        ],
        "summary": "Get My Usage Summary",
        "description": "All-time, last-7-day and last-30-day rollup \u2014 claims, debates, transcript\nminutes, API calls and billed spend. The cheap call for a usage widget.",
        "operationId": "get_my_usage_summary_v1_usage_me_summary_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UsageSummary"
                }
              }
            }
          }
        }
      }
    },
    "/v1/plans": {
      "get": {
        "tags": [
          "plans"
        ],
        "summary": "List Public Plans",
        "description": "The plans a customer can choose from.",
        "operationId": "list_public_plans_v1_plans_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PlanList"
                }
              }
            }
          }
        }
      }
    },
    "/v1/subscriptions/me": {
      "get": {
        "tags": [
          "plans"
        ],
        "summary": "Get My Subscription",
        "description": "Your current plan, billing period, included units and usage against them.\n\n`unlimited: true` means the account predates plans and nothing is enforced\nfor it. Otherwise `included_units` is what to check before offering a\nfeature, so your UI can hide what the plan does not allow instead of\nsurfacing a 403.",
        "operationId": "get_my_subscription_v1_subscriptions_me_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Subscription"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "plans"
        ],
        "summary": "Change My Plan",
        "description": "Switch your own plan. The plan is resolved server-side from `plan_slug`,\nnever from a client-supplied id or price.\n\nTakes effect immediately and starts a fresh billing period. If a quota pause\nwas blocking research, this lifts it and re-queues the held claims.",
        "operationId": "change_my_plan_v1_subscriptions_me_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangePlanRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Subscription"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/billing/checkout-session": {
      "post": {
        "tags": [
          "billing"
        ],
        "summary": "Create Checkout Session",
        "description": "Start a Stripe Checkout session to subscribe to a paid plan.\n\nThe plan is resolved server-side from `plan_slug` - never from a\nclient-supplied price or plan id. 404s for the free plan (it has no\nStripe price) or an unknown slug, and 503 if Stripe isn't configured on\nthis instance. Redirects to Stripe's hosted Checkout; on completion the\nwebhook activates the subscription, so poll `GET /subscriptions/me`\nrather than trusting the redirect alone.",
        "operationId": "create_checkout_session_v1_billing_checkout_session_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CheckoutSessionRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CheckoutSession"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/billing/portal-session": {
      "post": {
        "tags": [
          "billing"
        ],
        "summary": "Create Portal Session",
        "description": "Open the Stripe Customer Portal for the caller's own subscription\n(update card, view invoices, cancel). 404 if the caller has never\nchecked out (no Stripe customer on file yet).",
        "operationId": "create_portal_session_v1_billing_portal_session_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PortalSession"
                }
              }
            }
          }
        }
      }
    },
    "/v1/countries": {
      "get": {
        "tags": [
          "reference-data"
        ],
        "summary": "List Countries",
        "description": "Countries with \u22651 enabled, non-blocked source at trust_score \u2265 0.6.",
        "operationId": "list_countries_v1_countries_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "integer",
                  "maximum": 500,
                  "minimum": 1
                },
                {
                  "type": "null"
                }
              ],
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 0,
              "default": 0,
              "title": "Offset"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CountryList"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/languages": {
      "get": {
        "tags": [
          "reference-data"
        ],
        "summary": "List Languages",
        "description": "Languages offered for debate creation.\n\nThis list only gates what the dashboard and API clients are offered - the\ndetector and worker accept any language code, so it is not a pipeline\nconstraint.",
        "operationId": "list_languages_v1_languages_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "integer",
                  "maximum": 500,
                  "minimum": 1
                },
                {
                  "type": "null"
                }
              ],
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 0,
              "default": 0,
              "title": "Offset"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/LanguageList"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/sources": {
      "get": {
        "tags": [
          "reference-data"
        ],
        "summary": "List Sources",
        "description": "The source catalogue with trust scores and category slugs.",
        "operationId": "list_sources_v1_sources_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "integer",
                  "maximum": 500,
                  "minimum": 1
                },
                {
                  "type": "null"
                }
              ],
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 0,
              "default": 0,
              "title": "Offset"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SourceList"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/fact-check-queries/{query_id}/vote": {
      "post": {
        "tags": [
          "votes"
        ],
        "summary": "Vote Query",
        "description": "Cast or update the current user's upvote (1) / downvote (-1) on a panel.\n\nOne vote per user per query_id: re-casting with the opposite value flips the\nexisting vote; re-casting the same value is a no-op. Only users with access to\nthe panel's debate may vote.",
        "operationId": "vote_query_v1_fact_check_queries__query_id__vote_post",
        "parameters": [
          {
            "name": "query_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Query Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/VoteRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QueryVotes"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "votes"
        ],
        "summary": "Unvote Query",
        "description": "Remove the current user's vote on a panel.",
        "operationId": "unvote_query_v1_fact_check_queries__query_id__vote_delete",
        "parameters": [
          {
            "name": "query_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Query Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QueryVotes"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/fact-check-queries/{query_id}/votes": {
      "get": {
        "tags": [
          "votes"
        ],
        "summary": "Get Query Votes",
        "description": "Return up/down/net vote counts for a single panel, plus the caller's own vote.",
        "operationId": "get_query_votes_v1_fact_check_queries__query_id__votes_get",
        "parameters": [
          {
            "name": "query_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Query Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QueryVotes"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claims/{claim_id}/votes": {
      "get": {
        "tags": [
          "votes"
        ],
        "summary": "Get Claim Votes",
        "description": "Return per-panel vote tallies for every panel of a claim, plus the net-winner.\n\nThe `elected_query_id` is the panel with the highest net vote total (ties broken\nby upvote count, then query_id); null when no panel has a positive net total.",
        "operationId": "get_claim_votes_v1_claims__claim_id__votes_get",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClaimVotes"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/auth/token": {
      "post": {
        "tags": [
          "auth"
        ],
        "summary": "Issue Auth Token",
        "description": "Password grant for non-browser clients (the browser extension).\n\nThe dashboard mints its own JWT after calling /api/auth/verify; standalone\nclients have no minting step of their own, so this endpoint validates the\ncredentials (same check as /api/auth/verify) and returns a ready-to-use\nHS256 access token identical in shape to the dashboard's session token.",
        "operationId": "issue_auth_token_v1_auth_token_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AuthVerifyRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AccessToken"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/tokens": {
      "get": {
        "tags": [
          "auth"
        ],
        "summary": "List Api Tokens",
        "description": "List the current user's Personal Access Tokens (never returns the secret).",
        "operationId": "list_api_tokens_v1_tokens_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ApiTokenList"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "auth"
        ],
        "summary": "Create Api Token",
        "description": "Create a Personal Access Token. Returns the plaintext token EXACTLY ONCE.",
        "operationId": "create_api_token_v1_tokens_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateApiTokenRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreatedApiToken"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/tokens/scopes": {
      "get": {
        "tags": [
          "auth"
        ],
        "summary": "List Token Scopes",
        "description": "The scope vocabulary, so a client or the docs can render it without\nhardcoding a list that would drift.",
        "operationId": "list_token_scopes_v1_tokens_scopes_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TokenScopes"
                }
              }
            }
          }
        }
      }
    },
    "/v1/tokens/{token_id}": {
      "delete": {
        "tags": [
          "auth"
        ],
        "summary": "Revoke Api Token",
        "description": "Revoke one of the current user's tokens.",
        "operationId": "revoke_api_token_v1_tokens__token_id__delete",
        "parameters": [
          {
            "name": "token_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Token Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Deleted"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates": {
      "get": {
        "tags": [
          "debates"
        ],
        "summary": "List Debates",
        "description": "List debates visible to the current user.\n\n- Admin: all debates + creator info + access user list.\n- User: own debates (owner) + debates granted via debate_access (read).\nPass ?include_hidden=true to include debates with visible=false (admin only).\n\nSupports server-side search via ?q= (matches title/description).\nSupports pagination via ?page= and ?page_size= (default 50, max 200).\nReturns { debates: [...], total: int, page: int, page_size: int, pages: int }.",
        "operationId": "list_debates_v1_debates_get",
        "parameters": [
          {
            "name": "include_hidden",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "default": false,
              "title": "Include Hidden"
            }
          },
          {
            "name": "q",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "default": "",
              "title": "Q"
            }
          },
          {
            "name": "page",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 1,
              "title": "Page"
            }
          },
          {
            "name": "page_size",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 50,
              "title": "Page Size"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DebateList"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "debates"
        ],
        "summary": "Create Debate",
        "description": "Create a new debate and optionally pre-declare its speakers.",
        "operationId": "create_debate_v1_debates_post",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateDebateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Debate"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}": {
      "get": {
        "tags": [
          "debates"
        ],
        "summary": "Get Debate",
        "description": "Read one debate's full configuration.\n\nNEW endpoint - there was previously no single-debate read on either surface,\nonly the list. Returns the same row shape the list returns, including the\ndecoded `research_modes` list and the media identity fields, so an\nintegrator can confirm what a debate was actually configured with (which\ncountry's sources it used, whether the elector is on) without paging\nthrough /debates.",
        "operationId": "get_debate_v1_debates__debate_id__get",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Debate"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "patch": {
        "tags": [
          "debates"
        ],
        "summary": "Update Debate",
        "description": "Update debate metadata and optionally replace its speaker list.",
        "operationId": "update_debate_v1_debates__debate_id__patch",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateDebateRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Debate"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "debates"
        ],
        "summary": "Delete Debate",
        "description": "Delete a debate and all its associated data (claims, queries, embeddings).\n\nSpeakers (candidates) that are exclusively linked to this debate and have no\nclaims in any other debate are also deleted.\nShared/pool claims (see shared_claims_pool) are only unlinked from this debate -\na pool claim still linked to another debate is never touched.\nSends a delete notification to FaktoLumo if configured.",
        "operationId": "delete_debate_v1_debates__debate_id__delete",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DebateDeleted"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/claims": {
      "get": {
        "tags": [
          "debates"
        ],
        "summary": "Get Debate Claims",
        "description": "Return all claims detected for a debate with resolved speaker info.",
        "operationId": "get_debate_claims_v1_debates__debate_id__claims_get",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClaimList"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/stats": {
      "get": {
        "tags": [
          "debates"
        ],
        "summary": "Debate Stats",
        "description": "Per-speaker verdict breakdown for a debate.",
        "operationId": "debate_stats_v1_debates__debate_id__stats_get",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DebateStats"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/pause": {
      "post": {
        "tags": [
          "debates"
        ],
        "summary": "Pause Debate Research",
        "description": "Credit-exhaustion stop (Esploro): halt research on every claim already detected\nbut not yet researched, and tear the listener/detector down mid-file at an exact,\nresumable position. Already-completed panels are untouched; already-detected claims\nare kept (visible on the dashboard as pending), not dropped. See CLAUDE.md.",
        "operationId": "pause_debate_research_v1_debates__debate_id__pause_post",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DebatePaused"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/resume": {
      "post": {
        "tags": [
          "debates"
        ],
        "summary": "Resume Debate Research",
        "description": "Explicit resume (Esploro) - only happens when asked, never automatic. Re-dispatches\nevery held claim oldest-detected-first, and - if ingest itself was stopped mid-file -\nreplays the original ingest call from exactly where it stopped.\n\nA debate must never resume research while its owning account is over its RTFC-plan\nquota, regardless of which flag (credit_paused vs quota_paused) an operator is\ntrying to clear here - see CLAUDE.md \"Plans, Entitlements & Quota Enforcement\"\ndecision #2. If the quota is still exceeded this returns 402 instead of clearing\ncredit_paused.",
        "operationId": "resume_debate_research_v1_debates__debate_id__resume_post",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DebateResumed"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claim": {
      "post": {
        "tags": [
          "claims"
        ],
        "summary": "Submit Claim",
        "description": "Submit a claim to the Redis queue for fact-checking.\n\nGenerates a deterministic claim_id (SHA-256[:16] of the text) - same\nalgorithm as the C# aggregator - then pushes the claim JSON to\n`claims:pending` and publishes to `claims:new`.",
        "operationId": "submit_claim_v1_claim_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SubmitClaimRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SubmittedClaim"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/results/recent": {
      "get": {
        "tags": [
          "claims"
        ],
        "summary": "Get Recent Results",
        "description": "Return the most recent fact-check results from PostgreSQL.\n\nReturns all queries for the most recent N unique claims.\nUse `since=<ISO timestamp>` for incremental polling.\nUse `offset` for pagination (skip N unique claims).\nUse `claim_id` to fetch a specific claim regardless of recency.",
        "operationId": "get_recent_results_v1_results_recent_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 500,
              "minimum": 1,
              "default": 50,
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 0,
              "default": 0,
              "title": "Offset"
            }
          },
          {
            "name": "since",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Since"
            }
          },
          {
            "name": "debate_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Debate Id"
            }
          },
          {
            "name": "claim_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Claim Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RecentResults"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claims/{claim_id}/results": {
      "get": {
        "tags": [
          "claims"
        ],
        "summary": "Get Claim Results",
        "description": "All fact-check panels for one claim + the computed best.\n\nReturns every research-mode result (two_step / decompose / local / native /\nagentic \u2026) plus a `best` panel. `best` precedence: operator winner \u2192 crowd votes\n(highest net, `election_method:\"vote\"`) \u2192 LLM elector (`election_method:\"llm\"`,\nrequires the debate's elector enabled) \u2192 math (decisive verdict \u2192 confidence \u2192\nsource trust). One call = \"all methods\" and \"best of N\".\n\nOptional `?debate_id=` scopes `source_segment_ids`/`media_offset_ms` to that\ndebate specifically (required for a correct answer on a pool claim viewed from a\ndebate that REUSED it rather than first detected it - see media_offset_for_claim_debate).\nOmit for today's unqualified behavior.",
        "operationId": "get_claim_results_v1_claims__claim_id__results_get",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          },
          {
            "name": "debate_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Debate Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClaimResults"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claims/{claim_id}/best": {
      "get": {
        "tags": [
          "claims"
        ],
        "summary": "Get Claim Best",
        "description": "Single-answer convenience endpoint for API-only clients: just the one best panel for a\nclaim, plus `election_method` and the `elected` judge block. `best` precedence: operator\nwinner \u2192 crowd votes (`election_method:\"vote\"`) \u2192 LLM elector (`election_method:\"llm\"`,\ndebate elector enabled) \u2192 math. Returns 404 when the claim has no completed panels.\n\nOptional `?debate_id=` scopes `source_segment_ids`/`media_offset_ms` - see\n`GET /api/claims/{claim_id}/results` docstring. Optional `?lang=` translates claim\ntext + the returned panel's explanation (item 6 of the Esploro media plan).",
        "operationId": "get_claim_best_v1_claims__claim_id__best_get",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          },
          {
            "name": "debate_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Debate Id"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Panel"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claims/{claim_id}/cost": {
      "get": {
        "tags": [
          "claims"
        ],
        "summary": "Get Claim Cost",
        "description": "$ cost of one claim: detector + worker + search + elector (if used), summed\nacross every research panel of the claim. Lightweight - for esploro-proxy /\nother API clients to meter spend without pulling full panel data.\n\nFields are billed (markup applied, see CLAUDE.md \"Usage & Billing Ledger\") -\nesploro-proxy debits its wallet 1:1 off total_cost_usd, so that field must\nkeep carrying the number the caller is actually charged. Admins additionally\nget raw_cost_usd/raw_cost_breakdown (untouched provider cost).",
        "operationId": "get_claim_cost_v1_claims__claim_id__cost_get",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ClaimCost"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claims/{claim_id}/winner": {
      "post": {
        "tags": [
          "claims"
        ],
        "summary": "Set Claim Winner",
        "description": "Mark one research-mode result as the winner for a claim.\n\nClears any previous winner flag for the claim, then sets winner=true\non the row whose method matches the selected mode. The debate_stats\nquery will prefer this row when computing verdict breakdowns.",
        "operationId": "set_claim_winner_v1_claims__claim_id__winner_post",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetWinnerRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WinnerSet"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claims/{claim_id}": {
      "delete": {
        "tags": [
          "claims"
        ],
        "summary": "Delete Claim",
        "description": "Delete a single claim by its hex ID from PostgreSQL, Redis (via aggregator), and FaktoLumo.\n\nFor a shared/pool claim (linked to several debates via claim_debate_links), this\nunlinks the CALLER's debate_id from it instead of deleting outright - the claim,\nits panels, and votes are only hard-deleted once no debate links remain. debate_id\nis required (query param) in that case. Private (non-pool) claims keep today's\nexact behavior: outright deletion, debate_id is ignored.",
        "operationId": "delete_claim_v1_claims__claim_id__delete",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          },
          {
            "name": "debate_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Deleted"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/transcription-cost": {
      "get": {
        "tags": [
          "claims"
        ],
        "summary": "Get Transcription Cost",
        "description": "Exact STT $ cost for one debate/session, from stt_usage rows the listener\nwrites at session teardown (samples actually sent to the STT backend, not a\nwall-clock approximation). For Esploro/API clients to meter transcription spend.\n\ntotal_cost_usd is billed (markup applied - see CLAUDE.md \"Usage & Billing\nLedger\"); esploro-proxy debits 1:1 off it, so it must keep carrying the\nnumber the caller is actually charged. Admins additionally get\nraw_cost_usd (untouched provider cost).",
        "operationId": "get_transcription_cost_v1_debates__debate_id__transcription_cost_get",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TranscriptionCost"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/media/probe": {
      "post": {
        "tags": [
          "media"
        ],
        "summary": "Probe Media Route",
        "description": "Synchronous, anonymous, creates nothing (item 2 of the Esploro media plan).\nBody: `{\"url\": \"...\"}`. Auth required (any valid RTFC token) but not debate-scoped\n- there is no debate yet at probe time. Lets the app reject bad input (unsupported\nplatform, private video, playlist link, \u2026) while the OS share sheet is still open,\ninstead of failing later in the background. Also reports `existing_debate_id` when\na public canonical analysis of this exact video already exists, so the caller can\nskip creating a redundant debate and go straight to claim-access.",
        "operationId": "probe_media_route_v1_media_probe_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MediaProbe"
                }
              }
            }
          }
        }
      }
    },
    "/v1/media/{platform}/{external_id}/claim-access": {
      "post": {
        "tags": [
          "media"
        ],
        "summary": "Claim Media Access",
        "description": "Self-service access grant (item 4 of the Esploro media plan, redesigned per\nproduct decision - see CLAUDE.md \"Media-Source Identity\"): if a public canonical\nanalysis exists for this (platform, external_id), grant the CALLING user\ndebate_access to it (additive - never replaces existing grants) and return its\ndebate_id. Every Esploro user already has an RTFC account (machine user via\nesploro-proxy), so this is standard bearer/PAT auth, no debate-ownership check -\nthere is nothing to own yet for this caller. 404 if no public canonical match.",
        "operationId": "claim_media_access_v1_media__platform___external_id__claim_access_post",
        "parameters": [
          {
            "name": "platform",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Platform"
            }
          },
          {
            "name": "external_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "External Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MediaAccessGrant"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/upload-media": {
      "post": {
        "tags": [
          "media"
        ],
        "summary": "Upload Media",
        "description": "Download a shared video (YouTube/TikTok/Instagram - see media/platforms.py for\nthe supported-platform list) and transcribe it through a file-mode listener.\n\nAccepts JSON body: `{\"url\": \"...\"}` plus optional `whisper_provider`, `language`,\n`no_diarize`, `detector_mode`. The platform is sniffed from the URL server-side, so\nadding a platform later needs no app release. Every fetch is anonymous/cookie-less\n(see media/platforms.py docstring) - `is_public` reflects whether that anonymous\nfetch succeeded, never whether this server happens to be authenticated.\n\nEvery shared video is fact-checked regardless of public/private status - the\npublic/private distinction only controls whether a LATER user sharing the exact\nsame URL gets matched onto this debate (`debate_access` grant, no re-analysis)\ninstead of paying for a new one. If a public canonical analysis of this video\nalready exists, this call short-circuits: no ingest runs, the caller is granted\naccess to the existing debate, and the response is `{\"matched_existing\": true,\n\"debate_id\": <existing>, ...}` - the debate_id in the URL of THIS call is left\nunused; callers should switch to the returned debate_id.",
        "operationId": "upload_media_v1_debates__debate_id__upload_media_post",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MediaIngest"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/upload-media/blob": {
      "post": {
        "tags": [
          "media"
        ],
        "summary": "Upload Media Blob",
        "description": "Client-supplied-audio variant of upload-media (multipart/form-data: `file` +\noptional `whisper_provider`/`language`/`no_diarize` form fields) - reuses\nupload-audio's staging internals through the same media_ingest.start_media_ingest\nentry point. Unused at launch; the seam for letting the phone fetch platform audio\nitself if server-side IPs get walled off. No platform match/probe (no URL).",
        "operationId": "upload_media_blob_v1_debates__debate_id__upload_media_blob_post",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MediaIngest"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/upload-youtube": {
      "post": {
        "tags": [
          "media"
        ],
        "summary": "Upload Youtube",
        "description": "Thin YouTube-only alias over upload-media - kept for old app builds that still\ncall this exact path (Esploro/RTFC deploy independently; see CLAUDE.md). Same\nrequest/response shape as before; internals now shared with TikTok/Instagram.",
        "operationId": "upload_youtube_v1_debates__debate_id__upload_youtube_post",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MediaIngest"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/upload-audio": {
      "post": {
        "tags": [
          "media"
        ],
        "summary": "Upload Audio",
        "description": "Upload an audio file (mp3/m4a/wav/\u2026) and transcribe it through a file-mode listener.\n\nAccepts multipart/form-data: `file` (required) plus optional `whisper_provider`\nand `language` form fields (per-debate STT override). The file is staged to\nAUDIO_STAGE_DIR and a listener is spawned with AUDIO_SOURCE=file://\u2026 ; it decodes\nthe file, transcribes + diarizes it like live audio, then signals end-of-stream so\nthe detector flushes and the orchestrator tears the containers down.\n\nUse an HTTP STT provider (ovhcloud/scaleway/mistral) - Deepgram is streaming-only\nand not suited to finite files.",
        "operationId": "upload_audio_v1_debates__debate_id__upload_audio_post",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/MediaIngest"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/session/transcript-db": {
      "get": {
        "tags": [
          "transcript"
        ],
        "summary": "Get Transcript Db",
        "description": "Return transcript segments from PostgreSQL joined with speaker assignments.\n\nUnlike /api/session/transcript (Redis), this endpoint:\n- Survives session restarts\n- Reflects retroactive speaker reassignments immediately (JOIN, no backfill)\n- Supports full pagination and sort order\n\nOptional `?lang=` translates only the segments not already in that language\n(see `_apply_segment_translations`) - omit for today's unchanged behavior.",
        "operationId": "get_transcript_db_v1_session_transcript_db_get",
        "parameters": [
          {
            "name": "debate_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Debate Id"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 2000,
              "default": 100,
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 0,
              "title": "Offset"
            }
          },
          {
            "name": "order",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "pattern": "^(asc|desc)$",
              "default": "asc",
              "title": "Order"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Transcript"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/transcript": {
      "get": {
        "tags": [
          "transcript"
        ],
        "summary": "Get Debate Transcript",
        "description": "Return the full persistent transcript for any debate (past or active).\n\nOptional `?lang=` translates only the segments not already in that language -\nsee `_apply_segment_translations`.",
        "operationId": "get_debate_transcript_v1_debates__debate_id__transcript_get",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 5000,
              "default": 500,
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "default": 0,
              "title": "Offset"
            }
          },
          {
            "name": "order",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "pattern": "^(asc|desc)$",
              "default": "asc",
              "title": "Order"
            }
          },
          {
            "name": "lang",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Lang"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Transcript"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/transcript-segment": {
      "post": {
        "tags": [
          "transcript"
        ],
        "summary": "Ingest Transcript Segment",
        "description": "Ingest one or more client-STT transcript segments for a running client session.\n\nPublishes each segment to session:debate:{debate_id}:client_text - the listener\nspawned by /api/session/client-start (AUDIO_SOURCE=client://) subscribes to this\nchannel and feeds each segment through the same process_segment pipeline as every\nother source (persistence, transcript_log, detector hand-off). This endpoint does\nno DB/Redis-log writes itself - the listener is the single writer.\n\n`segment_id` (a UUID from the caller) is forwarded and, when present, becomes the\npersisted transcript_segments.id - so claims.source_segment_ids ends up containing\nthe caller's own segment ids, letting it correlate a claim back to the segments it\nsent. Accepts either single-segment fields (text, timestamp, \u2026) or a batch array\n`segments: [{text, timestamp, language, segment_id}, \u2026]`.",
        "operationId": "ingest_transcript_segment_v1_debates__debate_id__transcript_segment_post",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TranscriptSegmentRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SegmentsPublished"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/debates/{debate_id}/upload-transcript": {
      "post": {
        "tags": [
          "transcript"
        ],
        "summary": "Upload Transcript",
        "description": "Upload a text/subtitle/PDF/DOCX file and feed it through the detector pipeline.\n\nAccepts multipart/form-data with a single `file` field.\nReturns immediately after parsing; publishing happens in a background thread.\nPublishes chunks to transcripts:{debate_id} so the detector processes them\nidentically to live audio.",
        "operationId": "upload_transcript_v1_debates__debate_id__upload_transcript_post",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/TranscriptUploaded"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claims/{claim_id}/source-segments": {
      "get": {
        "tags": [
          "transcript"
        ],
        "summary": "Get Claim Source Segments",
        "description": "Which transcript segments a claim came from.\n\nUse it to highlight the exact lines that produced a claim. Pass `?debate_id=`\nfor a shared claim: the segments differ per debate, and without it you get\nwhichever debate first detected it rather than yours.",
        "operationId": "get_claim_source_segments_v1_claims__claim_id__source_segments_get",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          },
          {
            "name": "debate_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SourceSegments"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/session/spawn-status/{debate_id}": {
      "get": {
        "tags": [
          "sessions"
        ],
        "summary": "Session Spawn Status",
        "description": "Return spawn status for a debate (pending|active|error|stopped|unknown).\nPolled by the dashboard every second while Start is in progress.",
        "operationId": "session_spawn_status_v1_session_spawn_status__debate_id__get",
        "parameters": [
          {
            "name": "debate_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Debate Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SpawnStatus"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/session/start": {
      "post": {
        "tags": [
          "sessions"
        ],
        "summary": "Session Start",
        "description": "Start a debate session. Publishes spawn request to orchestrator and returns 'pending'.\nThe dashboard polls /api/session/spawn-status/{id} until the orchestrator confirms 'active'\nor reports 'error'. session:active_debates is populated only after orchestrator confirms.",
        "operationId": "session_start_v1_session_start_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SessionStartRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SessionStarted"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/session/stop": {
      "post": {
        "tags": [
          "sessions"
        ],
        "summary": "Session Stop",
        "description": "Deactivate a debate session. Removes debate_id from active set and cleans per-debate keys.",
        "operationId": "session_stop_v1_session_stop_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SessionStopRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SessionStopped"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/session/client-start": {
      "post": {
        "tags": [
          "sessions"
        ],
        "summary": "Session Client Start",
        "description": "Start a client-STT session for a mobile/client source (e.g. Esploro app).\n\nSpawns a real listener (AUDIO_SOURCE=client://, no audio/STT - see\nservices/listener/src/main.rs) + detector pair, exactly like a normal recording\nsession. The caller pushes transcript segments via\nPOST /api/debates/{id}/transcript-segment, which publishes them to\nsession:debate:{id}:client_text for the listener to persist + forward - the\nlistener's process_segment is the single source of truth for transcript_segments\n/ transcript_log / detector hand-off, same as every other source. The session\nstays alive until POST /api/session/stop is called.",
        "operationId": "session_client_start_v1_session_client_start_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ClientStartRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/SessionStarted"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/session/audio-ingest-token": {
      "post": {
        "tags": [
          "sessions"
        ],
        "summary": "Audio Ingest Token",
        "description": "Mint a short-lived ws:// audio-ingest JWT for a debate's already-running session.\n\nFor server-to-server audio sources (e.g. the Esploro proxy relaying phone audio) that\nalready know their one debate_id - unlike the browser extension's /pending poll above,\nwhich exists to scan all active debates because the extension can't be told directly\nwhich tab just started recording.",
        "operationId": "audio_ingest_token_v1_session_audio_ingest_token_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AudioIngestTokenRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/AudioIngestToken"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/queue": {
      "get": {
        "tags": [
          "diagnostics"
        ],
        "summary": "Queue Status",
        "description": "Return current Redis stream consumer group lag (pending + unacked messages).",
        "operationId": "queue_status_v1_queue_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/QueueDepth"
                }
              }
            }
          }
        }
      }
    },
    "/v1/pending-claims": {
      "get": {
        "tags": [
          "diagnostics"
        ],
        "summary": "Get Pending Claims",
        "description": "Return claim IDs currently pending in claims:stream consumer group.",
        "operationId": "get_pending_claims_v1_pending_claims_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PendingClaims"
                }
              }
            }
          }
        }
      }
    },
    "/v1/claims/pipeline": {
      "get": {
        "tags": [
          "diagnostics"
        ],
        "summary": "Get Claims Pipeline",
        "description": "Return a unified view of all claims across the pipeline.\n\nCombines:\n- Redis claims:pending  \u2192 status \"pending\"\n- Redis claims:processing \u2192 status \"processing\"\n- PostgreSQL fact_check_queries (recent completed) \u2192 status from verdict\n\nEach item has: claim_id, claim_text, research_mode, timestamp, status,\nspeaker, debate_id, debate_title, query_id (if completed),\nquestion_category_id, question_category_label.",
        "operationId": "get_claims_pipeline_v1_claims_pipeline_get",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 500,
              "minimum": 1,
              "default": 100,
              "title": "Limit"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/PipelineClaims"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/diagnose/dropped-claims": {
      "get": {
        "tags": [
          "diagnostics"
        ],
        "summary": "Diagnose Dropped Claims",
        "description": "Find claims that were detected but have incomplete or missing PostgreSQL records.\n\nThree categories:\n- incomplete: log_query_start fired (fact_check_queries row exists) but\n  completed_at IS NULL - worker crashed or timed out after starting research.\n- no_query: claim reached check_claim (claims row exists, log_claim fired)\n  but no fact_check_queries row at all - crash before log_query_start.\n- stuck_stream: claim is in claims:stream PEL (unacked by worker group) for\n  longer than the window - worker that claimed it crashed before ACK.\nClaims that crashed before log_claim leave no PostgreSQL trace and cannot be\ndetected here.",
        "operationId": "diagnose_dropped_claims_v1_diagnose_dropped_claims_get",
        "parameters": [
          {
            "name": "minutes",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "maximum": 1440,
              "minimum": 1,
              "default": 60,
              "title": "Minutes"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DroppedClaims"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/diagnose/{claim_id}": {
      "get": {
        "tags": [
          "diagnostics"
        ],
        "summary": "Diagnose Claim",
        "description": "Full pipeline trace for a specific claim - for debugging any verdict.\n\nDiagnoses failures across all research modes (two_step, decompose, native,\nlocal, perplexity) with detailed search, content extraction, and LLM analysis.\n\nOptional query param `query_id` (UUID) pins the lookup to a specific\nfact_check_queries row, which is essential in parallel mode where the same\nclaim_id has multiple rows (one per research arm).",
        "operationId": "diagnose_claim_v1_diagnose__claim_id__get",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          },
          {
            "name": "query_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Query Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Diagnosis"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/stream/token": {
      "post": {
        "tags": [
          "streaming"
        ],
        "summary": "Issue Stream Token",
        "description": "Return a short-lived JWT for EventSource clients that cannot send headers.\n\nCarries the real user's sub/role (not a fixed placeholder) so SSE endpoints can\nenforce require_debate_access on the ?token= path exactly like the header path.",
        "operationId": "issue_stream_token_v1_stream_token_post",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/StreamToken"
                }
              }
            }
          }
        }
      }
    },
    "/v1/stream": {
      "get": {
        "tags": [
          "streaming"
        ],
        "summary": "Stream Results",
        "description": "Server-Sent Events: push new fact-check results in real-time.\n\nThe client receives `{type: 'result', ...result_fields}` events as workers\ncomplete new claims. A `{type: 'ping'}` keepalive is sent every ~20 s.\n\nPass `?debate_id=<uuid>` to receive only events for that debate.\nOmit to receive all events (backward compat).\n\nAuth: Bearer header takes priority; fallback to ?token=<stream_token>.",
        "operationId": "stream_results_v1_stream_get",
        "parameters": [
          {
            "name": "debate_id",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Debate Id"
            }
          },
          {
            "name": "token",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Token"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/stream/claim/{claim_id}": {
      "get": {
        "tags": [
          "streaming"
        ],
        "summary": "Stream Claim Progress",
        "description": "Server-Sent Events: stream real-time processing steps for a single claim.\n\nOn connect, replays buffered events from Redis (claim:progress:{claim_id}),\nthen subscribes to live events. Closes automatically on 'verdict' or 'error'\nstep, or when the client disconnects.\n\nAuth: Bearer header takes priority; fallback to ?token=<stream_token> (EventSource\ncan't send headers) - same scheme as /api/stream.",
        "operationId": "stream_claim_progress_v1_stream_claim__claim_id__get",
        "parameters": [
          {
            "name": "claim_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Claim Id"
            }
          },
          {
            "name": "token",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "null"
                }
              ],
              "title": "Token"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {}
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/webhook-events": {
      "get": {
        "tags": [
          "webhooks"
        ],
        "summary": "List Webhook Events",
        "description": "The event vocabulary. Append-only - ignore an event you do not\nrecognise rather than treating it as an error.",
        "operationId": "list_webhook_events_v1_webhook_events_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookEvents"
                }
              }
            }
          }
        }
      }
    },
    "/v1/webhooks": {
      "get": {
        "tags": [
          "webhooks"
        ],
        "summary": "List Webhooks",
        "description": "Your registered endpoints. Secrets are never returned here \u2014 only a\nprefix, so a leaked listing cannot be used to forge signatures.",
        "operationId": "list_webhooks_v1_webhooks_get",
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookList"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "webhooks"
        ],
        "summary": "Create Webhook",
        "description": "Register an endpoint. The signing `secret` is returned EXACTLY ONCE -\nstore it now; later reads show only a prefix.",
        "operationId": "create_webhook_v1_webhooks_post",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWebhookRequest"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreatedWebhook"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/webhooks/{webhook_id}": {
      "get": {
        "tags": [
          "webhooks"
        ],
        "summary": "Get Webhook",
        "description": "One endpoint. Returns `secret_prefix`, never the secret itself.",
        "operationId": "get_webhook_v1_webhooks__webhook_id__get",
        "parameters": [
          {
            "name": "webhook_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Webhook Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Webhook"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "patch": {
        "tags": [
          "webhooks"
        ],
        "summary": "Update Webhook",
        "description": "Change an endpoint's URL, events, label, or pause it with\n`{\"active\": false}` \u2014 pausing keeps its delivery history, deleting does not.",
        "operationId": "update_webhook_v1_webhooks__webhook_id__patch",
        "parameters": [
          {
            "name": "webhook_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Webhook Id"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateWebhookRequest"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Webhook"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "webhooks"
        ],
        "summary": "Delete Webhook",
        "description": "Remove an endpoint. Its delivery history is removed with it; pause it\ninstead if you want to keep the log.",
        "operationId": "delete_webhook_v1_webhooks__webhook_id__delete",
        "parameters": [
          {
            "name": "webhook_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Webhook Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Deleted"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/webhooks/{webhook_id}/rotate-secret": {
      "post": {
        "tags": [
          "webhooks"
        ],
        "summary": "Rotate Webhook Secret",
        "description": "Issue a new signing secret. The old one stops working immediately, so\ndeploy the new secret to the receiver before rotating.",
        "operationId": "rotate_webhook_secret_v1_webhooks__webhook_id__rotate_secret_post",
        "parameters": [
          {
            "name": "webhook_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Webhook Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CreatedWebhook"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/webhooks/{webhook_id}/deliveries": {
      "get": {
        "tags": [
          "webhooks"
        ],
        "summary": "List Deliveries",
        "description": "Delivery log, newest first - status, attempt count, next retry, error.",
        "operationId": "list_deliveries_v1_webhooks__webhook_id__deliveries_get",
        "parameters": [
          {
            "name": "webhook_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Webhook Id"
            }
          },
          {
            "name": "limit",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "integer",
                  "maximum": 200,
                  "minimum": 1
                },
                {
                  "type": "null"
                }
              ],
              "default": 50,
              "title": "Limit"
            }
          },
          {
            "name": "offset",
            "in": "query",
            "required": false,
            "schema": {
              "type": "integer",
              "minimum": 0,
              "default": 0,
              "title": "Offset"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookDeliveryList"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/webhooks/{webhook_id}/test": {
      "post": {
        "tags": [
          "webhooks"
        ],
        "summary": "Test Webhook",
        "description": "Queue a synthetic delivery and send it immediately, so an integrator can\ncheck their signature verification without waiting for a real event.",
        "operationId": "test_webhook_v1_webhooks__webhook_id__test_post",
        "parameters": [
          {
            "name": "webhook_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "Webhook Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WebhookTestResult"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/provision/user": {
      "post": {
        "tags": [
          "provisioning"
        ],
        "summary": "Provision User",
        "description": "Create an active machine user (role=user, no password) and return a PAT.\n\nReturns {user_id, username, token} - token shown once, never retrievable.\nOnly provisioner or admin may call this.",
        "operationId": "provision_user_v1_provision_user_post",
        "responses": {
          "201": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ProvisionedUser"
                }
              }
            }
          }
        }
      }
    },
    "/v1/provision/user/{user_id}/tokens": {
      "post": {
        "tags": [
          "provisioning"
        ],
        "summary": "Provision Rotate Token",
        "description": "Mint a fresh PAT for a machine user (key rotation). Returns {token} once.",
        "operationId": "provision_rotate_token_v1_provision_user__user_id__tokens_post",
        "parameters": [
          {
            "name": "user_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "User Id"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/RotatedToken"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    },
    "/v1/provision/user/{user_id}": {
      "delete": {
        "tags": [
          "provisioning"
        ],
        "summary": "Provision Delete User",
        "description": "Delete a machine user and cascade-delete their debates (GDPR erasure for that device).\n\nRevokes all PATs, deletes debates owned by the machine user, then deactivates the user.\nOnly provisioner (own provisioned users) or admin may call this.",
        "operationId": "provision_delete_user_v1_provision_user__user_id__delete",
        "parameters": [
          {
            "name": "user_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "title": "User Id"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/DeletedUser"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "AccessToken": {
        "properties": {
          "access_token": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Access Token"
          },
          "username": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Username"
          },
          "role": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Role"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "AccessToken"
      },
      "ApiToken": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "prefix": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Prefix"
          },
          "scopes": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Scopes"
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires At"
          },
          "revoked_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Revoked At"
          },
          "last_used_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Last Used At"
          },
          "created_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created At"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "ApiToken"
      },
      "ApiTokenList": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/ApiToken"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "ApiTokenList"
      },
      "AudioIngestToken": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "ws_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ws Url"
          },
          "ingest_token": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ingest Token"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "AudioIngestToken",
        "description": "409 while the listener is still spawning - that is RETRYABLE, not fatal."
      },
      "AudioIngestTokenRequest": {
        "properties": {
          "debate_id": {
            "type": "string",
            "title": "Debate Id"
          }
        },
        "type": "object",
        "required": [
          "debate_id"
        ],
        "title": "AudioIngestTokenRequest"
      },
      "AuthVerifyRequest": {
        "properties": {
          "username": {
            "type": "string",
            "title": "Username"
          },
          "password": {
            "type": "string",
            "title": "Password"
          }
        },
        "type": "object",
        "required": [
          "username",
          "password"
        ],
        "title": "AuthVerifyRequest"
      },
      "ChangePlanRequest": {
        "properties": {
          "plan_slug": {
            "type": "string",
            "title": "Plan Slug"
          }
        },
        "type": "object",
        "required": [
          "plan_slug"
        ],
        "title": "ChangePlanRequest"
      },
      "CheckoutSession": {
        "properties": {
          "checkout_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Checkout Url"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "CheckoutSession"
      },
      "CheckoutSessionRequest": {
        "properties": {
          "plan_slug": {
            "type": "string",
            "title": "Plan Slug"
          }
        },
        "type": "object",
        "required": [
          "plan_slug"
        ],
        "title": "CheckoutSessionRequest"
      },
      "ClaimCost": {
        "properties": {
          "detector_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Detector Cost Usd"
          },
          "worker_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Worker Cost Usd"
          },
          "search_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Cost Usd"
          },
          "elector_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Elector Cost Usd"
          },
          "total_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total Cost Usd"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "ClaimCost",
        "description": "Billed cost of one claim. `raw_cost_usd` appears for admin callers only."
      },
      "ClaimList": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "ClaimList"
      },
      "ClaimResults": {
        "properties": {
          "claim_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Id"
          },
          "claim_text": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Text"
          },
          "panels": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Panel"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Panels"
          },
          "best": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/Panel"
              },
              {
                "type": "null"
              }
            ]
          },
          "conflict": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Conflict"
          },
          "election_method": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Election Method"
          },
          "elected": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/ElectedBlock"
              },
              {
                "type": "null"
              }
            ]
          },
          "votes": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/VoteBlock"
              },
              {
                "type": "null"
              }
            ]
          },
          "total_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total Cost Usd"
          },
          "cost_breakdown": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/CostBreakdown"
              },
              {
                "type": "null"
              }
            ]
          },
          "source_segment_ids": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Source Segment Ids"
          },
          "media_offset_ms": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Offset Ms"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "ClaimResults",
        "description": "Every panel for a claim, plus the computed best one.\n\n`best` may be null when no panel has completed. `election_method` says HOW best\nwas chosen: operator winner -> crowd votes -> LLM elector -> math.\n`conflict` is true when panels disagree on a decisive verdict."
      },
      "ClaimVotes": {
        "properties": {
          "claim_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Id"
          },
          "panels": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Panels"
          },
          "elected_query_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Elected Query Id"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "ClaimVotes"
      },
      "ClientStartRequest": {
        "properties": {
          "debate_id": {
            "type": "string",
            "title": "Debate Id"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "detector_mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Detector Mode"
          },
          "detector_window_chars": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Detector Window Chars"
          },
          "cost_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cost Weight"
          },
          "latency_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Latency Weight"
          },
          "quality_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Quality Weight"
          }
        },
        "type": "object",
        "required": [
          "debate_id"
        ],
        "title": "ClientStartRequest"
      },
      "CostBreakdown": {
        "properties": {
          "detector_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Detector Cost Usd"
          },
          "worker_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Worker Cost Usd"
          },
          "search_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Cost Usd"
          },
          "elector_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Elector Cost Usd"
          },
          "total_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total Cost Usd"
          },
          "currency": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Currency"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "CostBreakdown"
      },
      "CountryList": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "CountryList"
      },
      "CreateApiTokenRequest": {
        "properties": {
          "name": {
            "type": "string",
            "title": "Name"
          },
          "expires_in_days": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires In Days"
          },
          "scopes": {
            "items": {
              "type": "string"
            },
            "type": "array",
            "title": "Scopes",
            "default": []
          }
        },
        "type": "object",
        "required": [
          "name"
        ],
        "title": "CreateApiTokenRequest"
      },
      "CreateDebateRequest": {
        "properties": {
          "title": {
            "type": "string",
            "title": "Title"
          },
          "date": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Date"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "speakers": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Speakers"
          },
          "research_mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Mode"
          },
          "research_modes": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Modes"
          },
          "search_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Provider",
            "default": "duckduckgo"
          },
          "search_provider_b": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Provider B",
            "default": ""
          },
          "search_group": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Group",
            "default": ""
          },
          "whisper_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Whisper Provider",
            "default": "local"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language",
            "default": "fr"
          },
          "country": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Country",
            "default": ""
          },
          "llm_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Llm Provider",
            "default": ""
          },
          "llm_model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Llm Model",
            "default": ""
          },
          "planner_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Planner Provider",
            "default": ""
          },
          "planner_model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Planner Model",
            "default": ""
          },
          "force_refresh": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Force Refresh",
            "default": false
          },
          "force_web_search": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Force Web Search",
            "default": true
          },
          "channel": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Channel"
          },
          "elector_enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Elector Enabled",
            "default": false
          },
          "shared_claims_pool": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Shared Claims Pool"
          },
          "cost_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cost Weight"
          },
          "latency_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Latency Weight"
          },
          "quality_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Quality Weight"
          }
        },
        "type": "object",
        "required": [
          "title"
        ],
        "title": "CreateDebateRequest"
      },
      "CreateWebhookRequest": {
        "properties": {
          "url": {
            "type": "string",
            "title": "Url"
          },
          "events": {
            "items": {
              "type": "string"
            },
            "type": "array",
            "title": "Events",
            "default": []
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          }
        },
        "type": "object",
        "required": [
          "url"
        ],
        "title": "CreateWebhookRequest"
      },
      "CreatedApiToken": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "prefix": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Prefix"
          },
          "scopes": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Scopes"
          },
          "expires_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Expires At"
          },
          "revoked_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Revoked At"
          },
          "last_used_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Last Used At"
          },
          "created_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created At"
          },
          "token": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Token"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "CreatedApiToken",
        "description": "`token` is the plaintext secret and is returned EXACTLY ONCE, at creation."
      },
      "CreatedWebhook": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Url"
          },
          "events": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Events"
          },
          "active": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Active"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "secret_prefix": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Secret Prefix"
          },
          "created_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created At"
          },
          "updated_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Updated At"
          },
          "secret": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Secret"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "CreatedWebhook"
      },
      "Debate": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "title": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Title"
          },
          "date": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Date"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "created_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created At"
          },
          "visible": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Visible"
          },
          "research_mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Mode"
          },
          "research_modes": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Modes"
          },
          "search_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Provider"
          },
          "search_group": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Group"
          },
          "whisper_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Whisper Provider"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "country": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Country"
          },
          "llm_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Llm Provider"
          },
          "llm_model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Llm Model"
          },
          "force_refresh": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Force Refresh"
          },
          "force_web_search": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Force Web Search"
          },
          "channel": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Channel"
          },
          "faktolumo_enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Faktolumo Enabled"
          },
          "elector_enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Elector Enabled"
          },
          "shared_claims_pool": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Shared Claims Pool"
          },
          "media_platform": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Platform"
          },
          "media_external_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media External Id"
          },
          "media_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Url"
          },
          "media_duration_s": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Duration S"
          },
          "media_is_canonical": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Is Canonical"
          },
          "media_is_public": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Is Public"
          },
          "media_title": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Title"
          },
          "media_description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Description"
          },
          "ingest_state": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ingest State"
          },
          "ingest_resume_offset_ms": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ingest Resume Offset Ms"
          },
          "research_paused": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Paused"
          },
          "created_by_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created By Id"
          },
          "created_by_username": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created By Username"
          },
          "claim_count": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Count"
          },
          "access_level": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Access Level"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Debate"
      },
      "DebateDeleted": {
        "properties": {
          "deleted": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Deleted"
          },
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "claims_deleted": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claims Deleted"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "DebateDeleted"
      },
      "DebateList": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Debate"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          },
          "debates": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Debate"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debates"
          },
          "page": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Page"
          },
          "page_size": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Page Size"
          },
          "pages": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Pages"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "DebateList",
        "description": "Carries BOTH the legacy keys and the standard envelope - see api/pagination.py."
      },
      "DebatePaused": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "ingest_state": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ingest State"
          },
          "ingest_resume_offset_ms": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ingest Resume Offset Ms"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "DebatePaused"
      },
      "DebateResumed": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "claims_retriggered": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claims Retriggered"
          },
          "ingest_resumed": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ingest Resumed"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "DebateResumed"
      },
      "DebateStats": {
        "properties": {
          "debate": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Debate"
          },
          "speakers": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Speakers"
          },
          "totals": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Totals"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "DebateStats",
        "description": "Verdict breakdown for one debate, per speaker and in total."
      },
      "Deleted": {
        "properties": {
          "deleted": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Deleted"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          },
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "claim_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Id"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Deleted",
        "description": "Generic delete acknowledgement. Shapes differ slightly by resource, which is\nwhy the fields are all optional rather than one enforced schema."
      },
      "DeletedUser": {
        "properties": {
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          },
          "user_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "User Id"
          },
          "debates_deleted": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debates Deleted"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "DeletedUser"
      },
      "Diagnosis": {
        "properties": {
          "claim": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Claim"
          },
          "query": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Query"
          },
          "llm_interactions": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Llm Interactions"
          },
          "searches": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Searches"
          },
          "diagnosis": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Diagnosis"
          },
          "timeline": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Timeline"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Diagnosis",
        "description": "Full trace for one claim: the LLM calls, searches and timing behind it.\n\nDeliberately typed loosely. The diagnostics group is documented as NOT covered\nby the deprecation policy precisely because these shapes track internal pipeline\nstructure, so pinning them here would either be a lie or a constraint nobody\nintends to honour. (`timeline` in particular is an object of phase timings, not\na list \u2014 this model claimed a list and turned a working endpoint into a 500\nuntil it was corrected against a real response.)"
      },
      "DroppedClaims": {
        "properties": {
          "window_minutes": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Window Minutes"
          },
          "dropped": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Dropped"
          },
          "counts": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Counts"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "DroppedClaims",
        "description": "Claims that entered the stream and produced nothing. Loosely typed for the\nsame reason as Diagnosis above."
      },
      "ElectedBlock": {
        "properties": {
          "reason": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Reason"
          },
          "model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Model"
          },
          "confidence": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Confidence"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "ElectedBlock"
      },
      "HTTPValidationError": {
        "properties": {
          "detail": {
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            },
            "type": "array",
            "title": "Detail"
          }
        },
        "type": "object",
        "title": "HTTPValidationError"
      },
      "Language": {
        "properties": {
          "value": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Value"
          },
          "label": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Label"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Language"
      },
      "LanguageList": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Language"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "LanguageList"
      },
      "MediaAccessGrant": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "granted": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Granted"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "MediaAccessGrant",
        "description": "404 when no public analysis of this video exists yet."
      },
      "MediaIngest": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          },
          "matched_existing": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Matched Existing"
          },
          "platform": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Platform"
          },
          "external_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "External Id"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "MediaIngest",
        "description": "`matched_existing` true means NOTHING was ingested: the returned debate_id is\na pre-existing public analysis the caller was granted access to."
      },
      "MediaProbe": {
        "properties": {
          "platform": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Platform"
          },
          "external_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "External Id"
          },
          "canonical_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Canonical Url"
          },
          "title": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Title"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "uploader": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Uploader"
          },
          "creator": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Creator"
          },
          "uploader_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Uploader Id"
          },
          "thumbnail_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Thumbnail Url"
          },
          "duration_s": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Duration S"
          },
          "is_public": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Is Public"
          },
          "is_live": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Is Live"
          },
          "has_captions": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Has Captions"
          },
          "reject_reason": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Reject Reason"
          },
          "existing_debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Existing Debate Id"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "MediaProbe",
        "description": "Anonymous public-accessibility probe. Creates nothing.\n\n`reject_reason` is empty when the video is usable; otherwise one of\nunsupported_platform | not_a_single_video | unavailable | private | needs_auth |\ngeo_blocked | live_in_progress. `existing_debate_id` is set when a public\ncanonical analysis of this exact video already exists - share that instead of\ningesting again."
      },
      "Panel": {
        "properties": {
          "query_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Query Id"
          },
          "claim_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Id"
          },
          "claim_text": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Text"
          },
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "research_mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Mode"
          },
          "composite_mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Composite Mode"
          },
          "verdict": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Verdict"
          },
          "confidence": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Confidence"
          },
          "explanation": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Explanation"
          },
          "sources": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Source"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Sources"
          },
          "sub_questions": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Sub Questions"
          },
          "pending_documents": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Pending Documents"
          },
          "processing_time_ms": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Processing Time Ms"
          },
          "winner": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Winner"
          },
          "manually_added": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Manually Added"
          },
          "priority": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Priority"
          },
          "complexity": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Complexity"
          },
          "cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cost Usd"
          },
          "source_segment_ids": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Source Segment Ids"
          },
          "media_offset_ms": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Offset Ms"
          },
          "explanation_machine_translated": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Explanation Machine Translated"
          },
          "explanation_original_language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Explanation Original Language"
          },
          "completed_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Completed At"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Panel",
        "description": "One research method's answer for a claim.\n\n`verdict` is one of TRUE / FALSE / PARTIALLY_TRUE / UNVERIFIABLE / MISLEADING /\nPENDING (lowercased in responses). `confidence` is 0-1. `cost_usd` is the\nBILLED cost of this panel."
      },
      "PendingClaims": {
        "properties": {
          "claim_ids": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Ids"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "PendingClaims"
      },
      "PipelineClaims": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "PipelineClaims"
      },
      "Plan": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "slug": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Slug"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "price_eur_month": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Price Eur Month"
          },
          "included_units": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Included Units"
          },
          "overage_allowed": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Overage Allowed"
          },
          "hard_cap_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Hard Cap Usd"
          },
          "max_concurrent_debates": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Max Concurrent Debates"
          },
          "rate_limit_rpm": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Rate Limit Rpm"
          },
          "features": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Features"
          },
          "is_public": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Is Public"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Plan"
      },
      "PlanList": {
        "properties": {
          "plans": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Plan"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Plans"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "PlanList"
      },
      "PortalSession": {
        "properties": {
          "portal_url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Portal Url"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "PortalSession"
      },
      "ProvisionedUser": {
        "properties": {
          "user_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "User Id"
          },
          "username": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Username"
          },
          "token": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Token"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "ProvisionedUser"
      },
      "QueryVotes": {
        "properties": {
          "upvotes": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Upvotes"
          },
          "downvotes": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Downvotes"
          },
          "net": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Net"
          },
          "query_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Query Id"
          },
          "my_vote": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "My Vote"
          },
          "vote": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Vote"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "QueryVotes"
      },
      "QueueDepth": {
        "properties": {
          "pending": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Pending"
          },
          "processing": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Processing"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "QueueDepth"
      },
      "RecentResults": {
        "properties": {
          "results": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Panel"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Results"
          },
          "items": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Panel"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "RecentResults"
      },
      "RotatedToken": {
        "properties": {
          "token": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Token"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "RotatedToken"
      },
      "SegmentsPublished": {
        "properties": {
          "published": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Published"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "SegmentsPublished"
      },
      "SessionStartRequest": {
        "properties": {
          "debate_id": {
            "type": "string",
            "title": "Debate Id"
          },
          "audio_source": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Audio Source"
          },
          "selected_source": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Selected Source"
          },
          "detector_mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Detector Mode"
          },
          "claim_context_method": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Context Method"
          },
          "detector_window_chars": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Detector Window Chars"
          },
          "whisper_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Whisper Provider"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "cost_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Cost Weight"
          },
          "latency_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Latency Weight"
          },
          "quality_weight": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Quality Weight"
          }
        },
        "type": "object",
        "required": [
          "debate_id"
        ],
        "title": "SessionStartRequest"
      },
      "SessionStarted": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "SessionStarted"
      },
      "SessionStopRequest": {
        "properties": {
          "debate_id": {
            "type": "string",
            "title": "Debate Id"
          }
        },
        "type": "object",
        "required": [
          "debate_id"
        ],
        "title": "SessionStopRequest"
      },
      "SessionStopped": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "SessionStopped"
      },
      "SetWinnerRequest": {
        "properties": {
          "mode": {
            "type": "string",
            "title": "Mode"
          }
        },
        "type": "object",
        "required": [
          "mode"
        ],
        "title": "SetWinnerRequest"
      },
      "Source": {
        "properties": {
          "url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Url"
          },
          "title": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Title"
          },
          "snippet": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Snippet"
          },
          "domain": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Domain"
          },
          "trust_score": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Trust Score"
          },
          "claimant_cited": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claimant Cited"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Source"
      },
      "SourceEntry": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "domain": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Domain"
          },
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "trust_score": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Trust Score"
          },
          "country": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Country"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "categories": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Categories"
          },
          "enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Enabled"
          },
          "blocked": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Blocked"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "SourceEntry"
      },
      "SourceList": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/SourceEntry"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "SourceList"
      },
      "SourceSegments": {
        "properties": {
          "claim_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Id"
          },
          "source_segment_ids": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Source Segment Ids"
          },
          "segments": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Segments"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "SourceSegments"
      },
      "SpawnStatus": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          },
          "error": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Error"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "SpawnStatus",
        "description": "`status` is pending | active | error | stopped | unknown. Poll until it\nleaves `pending` - spawning is asynchronous."
      },
      "StreamToken": {
        "properties": {
          "stream_token": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Stream Token"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "StreamToken",
        "description": "5-minute, SSE-only token for clients that cannot send headers."
      },
      "SubmitClaimRequest": {
        "properties": {
          "text": {
            "type": "string",
            "title": "Text"
          },
          "context": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Context"
          },
          "speaker": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Speaker"
          },
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "research_mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Mode"
          },
          "search_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Provider"
          },
          "search_provider_b": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Provider B"
          },
          "search_group": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Group"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language",
            "default": "fr"
          },
          "force_refresh": {
            "type": "boolean",
            "title": "Force Refresh",
            "default": false
          },
          "force_web_search": {
            "type": "boolean",
            "title": "Force Web Search",
            "default": true
          },
          "rerun_panel": {
            "type": "boolean",
            "title": "Rerun Panel",
            "default": false
          },
          "manually_added": {
            "type": "boolean",
            "title": "Manually Added",
            "default": false
          },
          "result_mode_key": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Result Mode Key"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "SubmitClaimRequest"
      },
      "SubmittedClaim": {
        "properties": {
          "claim_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Id"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          },
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "SubmittedClaim"
      },
      "Subscription": {
        "properties": {
          "plan": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Plan"
          },
          "unlimited": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Unlimited"
          },
          "subscription_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Subscription Id"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          },
          "period_start": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Period Start"
          },
          "period_end": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Period End"
          },
          "included_units": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Included Units"
          },
          "overage_allowed": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Overage Allowed"
          },
          "features": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Features"
          },
          "usage": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/UsageWindow"
              },
              {
                "type": "null"
              }
            ]
          },
          "overage_usd_so_far": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Overage Usd So Far"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Subscription",
        "description": "`unlimited` true = a legacy account with no subscription row; enforcement is\na no-op for it."
      },
      "TokenScope": {
        "properties": {
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "TokenScope"
      },
      "TokenScopes": {
        "properties": {
          "scopes": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/TokenScope"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Scopes"
          },
          "default_when_empty": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default When Empty"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "TokenScopes"
      },
      "Transcript": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "segments": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/TranscriptSegment"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Segments"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Transcript"
      },
      "TranscriptSegment": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "text": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Text"
          },
          "speaker_label": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Speaker Label"
          },
          "speaker_name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Speaker Name"
          },
          "ts": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Ts"
          },
          "media_offset_ms": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Media Offset Ms"
          },
          "whisper_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Whisper Provider"
          },
          "detected_language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Detected Language"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "TranscriptSegment"
      },
      "TranscriptSegmentItem": {
        "properties": {
          "text": {
            "type": "string",
            "title": "Text"
          },
          "timestamp": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Timestamp"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "segment_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Segment Id"
          }
        },
        "type": "object",
        "required": [
          "text"
        ],
        "title": "TranscriptSegmentItem"
      },
      "TranscriptSegmentRequest": {
        "properties": {
          "text": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Text"
          },
          "timestamp": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Timestamp"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "segment_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Segment Id"
          },
          "segments": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/TranscriptSegmentItem"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Segments"
          }
        },
        "type": "object",
        "title": "TranscriptSegmentRequest"
      },
      "TranscriptUploaded": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "segment_count": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Segment Count"
          },
          "filename": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Filename"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "TranscriptUploaded"
      },
      "TranscriptionCost": {
        "properties": {
          "debate_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debate Id"
          },
          "duration_seconds": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Duration Seconds"
          },
          "provider_breakdown": {
            "anyOf": [
              {},
              {
                "type": "null"
              }
            ],
            "title": "Provider Breakdown"
          },
          "total_cost_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total Cost Usd"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "TranscriptionCost",
        "description": "Exact STT spend for one debate, from the listener's own usage log.\n\nNOTE the field name: `total_cost_usd`, not `transcription_cost_usd`. Kept as-is\nbecause esploro-proxy reads it."
      },
      "UpdateDebateRequest": {
        "properties": {
          "title": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Title"
          },
          "date": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Date"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "speakers": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Speakers"
          },
          "research_mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Mode"
          },
          "research_modes": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Research Modes"
          },
          "search_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Provider"
          },
          "search_provider_b": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Provider B"
          },
          "search_group": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Search Group"
          },
          "whisper_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Whisper Provider"
          },
          "language": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Language"
          },
          "country": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Country"
          },
          "llm_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Llm Provider"
          },
          "llm_model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Llm Model"
          },
          "planner_provider": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Planner Provider"
          },
          "planner_model": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Planner Model"
          },
          "force_refresh": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Force Refresh"
          },
          "force_web_search": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Force Web Search"
          },
          "channel": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Channel"
          },
          "faktolumo_enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Faktolumo Enabled"
          },
          "elector_enabled": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Elector Enabled"
          },
          "shared_claims_pool": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Shared Claims Pool"
          }
        },
        "type": "object",
        "title": "UpdateDebateRequest"
      },
      "UpdateWebhookRequest": {
        "properties": {
          "url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Url"
          },
          "events": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Events"
          },
          "active": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Active"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          }
        },
        "type": "object",
        "title": "UpdateWebhookRequest"
      },
      "Usage": {
        "properties": {
          "user_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "User Id"
          },
          "granularity": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Granularity"
          },
          "totals": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/UsageTotals"
              },
              {
                "type": "null"
              }
            ]
          },
          "series": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Series"
          },
          "by_kind": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "By Kind"
          },
          "by_debate": {
            "anyOf": [
              {
                "items": {},
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "By Debate"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Usage"
      },
      "UsageSummary": {
        "properties": {
          "user_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "User Id"
          },
          "all_time": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/UsageWindow"
              },
              {
                "type": "null"
              }
            ]
          },
          "last_7d": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/UsageWindow"
              },
              {
                "type": "null"
              }
            ]
          },
          "last_30d": {
            "anyOf": [
              {
                "$ref": "#/components/schemas/UsageWindow"
              },
              {
                "type": "null"
              }
            ]
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "UsageSummary"
      },
      "UsageTotals": {
        "properties": {
          "events": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Events"
          },
          "quantity": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Quantity"
          },
          "billed_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Billed Usd"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "UsageTotals"
      },
      "UsageWindow": {
        "properties": {
          "claims": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claims"
          },
          "debates": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Debates"
          },
          "transcript_minutes": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Transcript Minutes"
          },
          "api_calls": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Api Calls"
          },
          "billed_usd": {
            "anyOf": [
              {
                "type": "number"
              },
              {
                "type": "null"
              }
            ],
            "title": "Billed Usd"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "UsageWindow"
      },
      "ValidationError": {
        "properties": {
          "loc": {
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            },
            "type": "array",
            "title": "Location"
          },
          "msg": {
            "type": "string",
            "title": "Message"
          },
          "type": {
            "type": "string",
            "title": "Error Type"
          }
        },
        "type": "object",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "title": "ValidationError"
      },
      "VoteBlock": {
        "properties": {
          "upvotes": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Upvotes"
          },
          "downvotes": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Downvotes"
          },
          "net": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Net"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "VoteBlock"
      },
      "VoteRequest": {
        "properties": {
          "vote": {
            "type": "integer",
            "title": "Vote"
          }
        },
        "type": "object",
        "required": [
          "vote"
        ],
        "title": "VoteRequest"
      },
      "Webhook": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "url": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Url"
          },
          "events": {
            "anyOf": [
              {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Events"
          },
          "active": {
            "anyOf": [
              {
                "type": "boolean"
              },
              {
                "type": "null"
              }
            ],
            "title": "Active"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          },
          "secret_prefix": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Secret Prefix"
          },
          "created_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created At"
          },
          "updated_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Updated At"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "Webhook",
        "description": "A registered endpoint. `secret` appears ONLY in the create and rotate\nresponses; every other read returns `secret_prefix` alone."
      },
      "WebhookDelivery": {
        "properties": {
          "id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Id"
          },
          "event": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Event"
          },
          "status_code": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status Code"
          },
          "attempt": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Attempt"
          },
          "next_retry_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Next Retry At"
          },
          "delivered_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Delivered At"
          },
          "error": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Error"
          },
          "created_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "string",
                "format": "date-time"
              },
              {
                "type": "string",
                "format": "date"
              },
              {
                "type": "null"
              }
            ],
            "title": "Created At"
          },
          "payload": {
            "anyOf": [
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "type": "null"
              }
            ],
            "title": "Payload"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "WebhookDelivery"
      },
      "WebhookDeliveryList": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/WebhookDelivery"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          },
          "deliveries": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/WebhookDelivery"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Deliveries"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "WebhookDeliveryList"
      },
      "WebhookEvent": {
        "properties": {
          "name": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Name"
          },
          "description": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Description"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "WebhookEvent"
      },
      "WebhookEvents": {
        "properties": {
          "events": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/WebhookEvent"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Events"
          },
          "default_when_empty": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Default When Empty"
          },
          "signature_header": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Signature Header"
          },
          "signature_tolerance_seconds": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Signature Tolerance Seconds"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "WebhookEvents"
      },
      "WebhookList": {
        "properties": {
          "items": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Webhook"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Items"
          },
          "total": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Total"
          },
          "limit": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Limit"
          },
          "offset": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Offset"
          },
          "webhooks": {
            "anyOf": [
              {
                "items": {
                  "$ref": "#/components/schemas/Webhook"
                },
                "type": "array"
              },
              {
                "type": "null"
              }
            ],
            "title": "Webhooks"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "WebhookList"
      },
      "WebhookTestResult": {
        "properties": {
          "queued": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Queued"
          },
          "attempted": {
            "anyOf": [
              {
                "type": "integer"
              },
              {
                "type": "null"
              }
            ],
            "title": "Attempted"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "WebhookTestResult"
      },
      "WinnerSet": {
        "properties": {
          "claim_id": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Claim Id"
          },
          "mode": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Mode"
          },
          "status": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "title": "Status"
          }
        },
        "additionalProperties": true,
        "type": "object",
        "title": "WinnerSet"
      }
    },
    "securitySchemes": {
      "XAuthToken": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Auth-Token",
        "description": "A Personal Access Token (rtfc_\u2026) or a session JWT."
      },
      "BearerToken": {
        "type": "http",
        "scheme": "bearer",
        "description": "The same token, sent as `Authorization: Bearer \u2026`."
      }
    },
    "parameters": {
      "RequestId": {
        "name": "X-Request-Id",
        "in": "header",
        "required": false,
        "schema": {
          "type": "string"
        },
        "description": "Correlation id echoed back on the response. Generated if omitted."
      },
      "IdempotencyKey": {
        "name": "Idempotency-Key",
        "in": "header",
        "required": false,
        "schema": {
          "type": "string"
        },
        "description": "On creates: retrying with the same key replays the original response."
      }
    }
  },
  "security": [
    {
      "XAuthToken": []
    },
    {
      "BearerToken": []
    }
  ],
  "tags": [
    {
      "name": "auth",
      "description": "Obtain and manage API credentials."
    },
    {
      "name": "provisioning",
      "description": "Create isolated accounts for your own end users. See the multi-tenancy guide."
    },
    {
      "name": "debates",
      "description": "A debate is the unit of work: a transcript, its claims, and the bill."
    },
    {
      "name": "sessions",
      "description": "Start and stop the ingest pipeline for a debate."
    },
    {
      "name": "transcript",
      "description": "Push text in, read the transcript back out."
    },
    {
      "name": "media",
      "description": "Fact-check a video, a stream, or an audio file."
    },
    {
      "name": "claims",
      "description": "Claims, research panels, verdicts and what they cost."
    },
    {
      "name": "votes",
      "description": "Per-user votes on research panels \u2014 the crowd-election input."
    },
    {
      "name": "streaming",
      "description": "Server-Sent Events: results as they land."
    },
    {
      "name": "webhooks",
      "description": "Be notified when work finishes, without holding a connection open."
    },
    {
      "name": "usage",
      "description": "Your spend and activity."
    },
    {
      "name": "plans",
      "description": "Plans, quotas and subscription self-service."
    },
    {
      "name": "reference-data",
      "description": "Read-only lookups: countries, languages, sources."
    },
    {
      "name": "diagnostics",
      "description": "Debug why a claim produced nothing. NOT covered by the deprecation policy."
    }
  ]
}