> ## Documentation Index
> Fetch the complete documentation index at: https://docs.oddspapi.io/llms.txt
> Use this file to discover all available pages before exploring further.

# 获取赛事

> 列出赛事。

查询模式：`fixtureIds` 或过滤器（`sportId`、`tournamentId`、`statusId`、可选时间范围）。

如果提供 `bookmakers`，则包含博彩公司元数据，结果可能按映射可用性过滤。



## OpenAPI

````yaml /zh/api-reference/openapi.json get /fixtures
openapi: 3.1.0
info:
  title: 赔率 API v5
  version: 5.0.0
  description: 高性能赔率API，由Valkey + Supabase RPC发现支持。
servers:
  - url: https://v5.oddspapi.io/zh
security:
  - ApiKeyAuth: []
tags:
  - name: common
  - name: fixtures
  - name: fixtures/odds
  - name: futures
  - name: futures/odds
  - name: mapping
  - name: media
  - name: settlement
paths:
  /fixtures:
    get:
      tags:
        - fixtures
      summary: 获取赛事
      description: |-
        列出赛事。

        查询模式：`fixtureIds` 或过滤器（`sportId`、`tournamentId`、`statusId`、可选时间范围）。

        如果提供 `bookmakers`，则包含博彩公司元数据，结果可能按映射可用性过滤。
      operationId: fixtures_filtered__lang__fixtures_get
      parameters:
        - name: fixtureIds
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
          description: Comma/space-separated fixture IDs (fast path).
        - name: sportId
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
          description: Single sport ID.
        - name: tournamentId
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
          description: Single tournament ID.
        - name: bookmakers
          in: query
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
          description: >-
            Comma/space-separated bookmaker slugs. If present (even empty),
            includes bookmaker META and filters by mapping.
        - name: startTimeFrom
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
          description: Start time from (epoch seconds).
        - name: startTimeTo
          in: query
          required: false
          schema:
            anyOf:
              - type: integer
              - type: 'null'
          description: Start time to (epoch seconds).
      responses:
        '200':
          description: Returns Fixture[] (fixture meta objects)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FixtureList'
              examples:
                example:
                  summary: Fixtures list
                  value:
                    - fixtureId: id1100013270505056
                      status:
                        live: true
                        statusId: 1
                        statusName: Live
                      sport:
                        sportId: 11
                        sportName: Basketball
                      tournament:
                        tournamentId: 132
                        tournamentName: NBA
                        categoryName: USA
                      season:
                        seasonId: 131631
                        seasonName: NBA 25/26
                        seasonRound: null
                      venue:
                        venueId: 6054
                        venueName: Madison Square Garden
                        venueLocation: New York, NY, USA
                      startTime: 1776729600
                      trueStartTime: '2026-04-21T00:09:08+00:00'
                      trueEndTime: null
                      participants:
                        participant1Id: 3421
                        participant1RotNr: 303
                        participant1Name: New York Knicks
                        participant1ShortName: New York
                        participant1Abbr: NYK
                        participant2Id: 3423
                        participant2RotNr: 302
                        participant2Name: Atlanta Hawks
                        participant2ShortName: Atlanta
                        participant2Abbr: ATL
                      scores:
                        p1:
                          period: p1
                          participant1Score: 32
                          participant2Score: 23
                          updatedAt: '2026-04-21T00:59:42.287458+00:00'
                        p2:
                          period: p2
                          participant1Score: 29
                          participant2Score: 31
                          updatedAt: '2026-04-21T01:25:05.532295+00:00'
                        result:
                          period: result
                          participant1Score: 61
                          participant2Score: 54
                          updatedAt: '2026-04-21T01:24:37.154297+00:00'
                      clock:
                        currentPeriod: null
                        currentTime: null
                        remainingTime: null
                        remainingTimeInPeriod: null
                        stopped: null
                      expectedPeriods: 4
                      periodLength: 12
                      externalProviders:
                        betgeniusId: 13808265
                        betradarId: 70505056
                        flashscoreId: nTPkYS3K
                        mollybetId: 2026-04-21,29093,29096
                        oddinId: null
                        opticoddsId: 20260421A1AB4678
                        pinnacleId: 1628730839
                        sofascoreId: 15935017
                        lsportsId: null
                        txoddsId: null
                      bookmakers: {}
        '400':
          $ref: '#/components/responses/ApiError'
        '401':
          $ref: '#/components/responses/ApiError'
        '403':
          $ref: '#/components/responses/ApiError'
        '404':
          $ref: '#/components/responses/ApiError'
        '422':
          $ref: '#/components/responses/ValidationError'
        '429':
          $ref: '#/components/responses/ApiError'
components:
  schemas:
    FixtureList:
      type: array
      items:
        $ref: '#/components/schemas/Fixture'
    Fixture:
      type: object
      properties:
        fixtureId:
          type: string
        status:
          $ref: '#/components/schemas/Status'
        sport:
          $ref: '#/components/schemas/SportRef'
        tournament:
          $ref: '#/components/schemas/TournamentRef'
        season:
          $ref: '#/components/schemas/SeasonRef'
        venue:
          $ref: '#/components/schemas/VenueRef'
        startTime:
          type: integer
        trueStartTime:
          type:
            - string
            - 'null'
        trueEndTime:
          type:
            - string
            - 'null'
        participants:
          $ref: '#/components/schemas/ParticipantsRef'
        scores:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/ScorePeriod'
        clock:
          anyOf:
            - $ref: '#/components/schemas/Clock'
            - type: 'null'
        expectedPeriods:
          type:
            - integer
            - 'null'
        periodLength:
          type:
            - integer
            - 'null'
        externalProviders:
          $ref: '#/components/schemas/ExternalProviders'
        bookmakers:
          type: object
          additionalProperties:
            $ref: '#/components/schemas/BookmakerFixtureMeta'
      required:
        - fixtureId
        - status
        - sport
        - tournament
        - season
        - venue
        - startTime
        - participants
        - scores
        - clock
        - externalProviders
        - bookmakers
      additionalProperties: true
    Error:
      type: object
      description: Concrete error format returned by this API (no FastAPI detail wrapper).
      properties:
        error:
          type: integer
          description: HTTP status code
        message:
          type: string
          description: Human-readable error message
        code:
          type: string
          description: Machine-readable reason code
        details:
          description: Optional extra details (string/object/array depending on the error).
      required:
        - error
        - message
      additionalProperties: true
    HTTPValidationError:
      title: HTTPValidationError
      type: object
      properties:
        detail:
          title: Detail
          type: array
          items:
            $ref: '#/components/schemas/ValidationError'
    Status:
      type: object
      properties:
        live:
          type: boolean
        statusId:
          type: integer
        statusName:
          type: string
      required:
        - live
        - statusId
        - statusName
      additionalProperties: true
    SportRef:
      type: object
      properties:
        sportId:
          type: integer
        sportName:
          type: string
      required:
        - sportId
        - sportName
      additionalProperties: true
    TournamentRef:
      type: object
      properties:
        tournamentId:
          type: integer
        tournamentName:
          type: string
        categoryName:
          type:
            - string
            - 'null'
      required:
        - tournamentId
        - tournamentName
      additionalProperties: true
    SeasonRef:
      type: object
      properties:
        seasonId:
          type:
            - integer
            - 'null'
        seasonName:
          type:
            - string
            - 'null'
        seasonRound:
          type:
            - integer
            - 'null'
      additionalProperties: true
    VenueRef:
      type: object
      properties:
        venueId:
          type:
            - integer
            - 'null'
        venueName:
          type:
            - string
            - 'null'
        venueLocation:
          type:
            - string
            - 'null'
      additionalProperties: true
    ParticipantsRef:
      type: object
      properties:
        participant1Id:
          type: integer
        participant1RotNr:
          type:
            - integer
            - 'null'
        participant1Name:
          type:
            - string
            - 'null'
        participant1ShortName:
          type:
            - string
            - 'null'
        participant1Abbr:
          type:
            - string
            - 'null'
        participant2Id:
          type: integer
        participant2RotNr:
          type:
            - integer
            - 'null'
        participant2Name:
          type:
            - string
            - 'null'
        participant2ShortName:
          type:
            - string
            - 'null'
        participant2Abbr:
          type:
            - string
            - 'null'
      required:
        - participant1Id
        - participant2Id
      additionalProperties: true
    ScorePeriod:
      type: object
      properties:
        period:
          type: string
        participant1Score:
          type: integer
        participant2Score:
          type: integer
        updatedAt:
          type: string
      required:
        - period
        - participant1Score
        - participant2Score
        - updatedAt
      additionalProperties: true
    Clock:
      type: object
      properties:
        currentPeriod:
          type:
            - string
            - 'null'
        currentTime:
          type:
            - string
            - 'null'
        remainingTime:
          type:
            - string
            - 'null'
        remainingTimeInPeriod:
          type:
            - string
            - 'null'
        stopped:
          type:
            - boolean
            - 'null'
      additionalProperties: true
    ExternalProviders:
      type: object
      additionalProperties: true
    BookmakerFixtureMeta:
      type: object
      properties:
        bookmaker:
          type: string
        bookmakerFixtureId:
          type:
            - string
            - 'null'
        fixturePath:
          type:
            - string
            - 'null'
        hasOdds:
          type: boolean
        staleOdds:
          type: boolean
        staleOddsResponseCode:
          type:
            - integer
            - 'null'
        suspended:
          type: boolean
        participantsRotated:
          type: boolean
        meta:
          type:
            - object
            - 'null'
          additionalProperties: true
        updatedAt:
          type: string
      required:
        - bookmaker
        - hasOdds
        - staleOdds
        - suspended
        - participantsRotated
        - updatedAt
      additionalProperties: true
    ValidationError:
      title: ValidationError
      type: object
      required:
        - loc
        - msg
        - type
      properties:
        loc:
          title: Location
          type: array
          items:
            anyOf:
              - type: string
              - type: integer
        msg:
          title: Message
          type: string
        type:
          title: Error Type
          type: string
  responses:
    ApiError:
      description: API error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
          examples:
            invalid_filters:
              summary: Invalid filters
              value:
                error: 400
                message: Invalid filters.
                reason: invalid_filters
            invalid_api_key:
              summary: Invalid apiKey
              value:
                error: 401
                message: invalid apiKey
                reason: invalid_api_key
            rate_limited:
              summary: Rate limited
              value:
                error: 429
                message: rate limit exceeded
                reason: rate_limited
                retryAfterSec: 1
    ValidationError:
      description: Validation Error (framework-level)
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/HTTPValidationError'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: query
      name: apiKey
      description: Your API key (query-based auth for v5).

````