realtimesportsapi-com Plays API

Play-by-play and penalties

Operations 2

GET /sports/{sport}/leagues/{league}/events/{eventId}/plays Get play-by-play #
GET /sports/{sport}/leagues/{league}/events/{eventId}/penalties Get penalty plays #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/realtimesportsapi-com:realtimesportsapi-com-plays-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

realtimesportsapi-com-plays-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Realtimesportsapi Com Plays API
  version: 1.0.0
  contact:
    name: Realtime Sports API support
    email: austin@elcodev.com
    url: https://www.realtimesportsapi.com/?utm_source=openapi
  license:
    name: Proprietary
    url: https://www.realtimesportsapi.com/terms?utm_source=openapi
  termsOfService: https://www.realtimesportsapi.com/terms?utm_source=openapi
  description: 'Operations tagged Plays across 2 of this provider''s published API definitions: original.json, realtimesportsapi-com-openapi.json. Each path carries the servers of the definition it was published in.'
servers:
- url: https://www.realtimesportsapi.com/api/v1
  description: Production
security:
- BearerAuth: []
- ApiKeyHeader: []
tags:
- name: Plays
  description: Play-by-play and penalties
paths:
  /sports/{sport}/leagues/{league}/events/{eventId}/plays:
    get:
      operationId: listPlays
      tags:
      - Plays
      summary: Get play-by-play
      description: Plays in chronological order, paginated. Use `limit` up to 1000 to fetch a whole game in one call.
      parameters:
      - name: sport
        in: path
        required: true
        description: 'Sport slug: football, basketball, baseball, hockey, soccer.'
        schema:
          type: string
          example: football
      - name: league
        in: path
        required: true
        description: League slug, e.g. nfl, college-football, nba, mens-college-basketball, mlb, nhl, eng.1, usa.1.
        schema:
          type: string
          example: nfl
      - name: eventId
        in: path
        required: true
        description: Event (game) id, as returned by the events endpoints.
        schema:
          type: string
          example: '401772982'
      - name: limit
        in: query
        required: false
        description: Maximum plays to return (default 25, max 1000).
        schema:
          type: integer
          example: 25
          default: 25
          minimum: 1
          maximum: 1000
      - name: page
        in: query
        required: false
        description: Page number (1-based).
        schema:
          type: integer
          example: 1
          default: 1
          minimum: 1
      - name: enrich
        in: query
        required: false
        description: Resolve athlete names, teams and positions for play participants (default true). Pass false for faster, id-only results.
        schema:
          type: boolean
          example: true
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    example: true
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Play'
                  meta:
                    type: object
                    properties:
                      rateLimit:
                        $ref: '#/components/schemas/RateLimit'
                      pagination:
                        $ref: '#/components/schemas/Pagination'
                required:
                - success
                - data
        '401':
          $ref: '#/components/responses/Unauthorized'
        '429':
          $ref: '#/components/responses/RateLimitExceeded'
        '500':
          $ref: '#/components/responses/ServerError'
    servers:
    - url: https://www.realtimesportsapi.com/api/v1
      description: Production
  /sports/{sport}/leagues/{league}/events/{eventId}/penalties:
    get:
      operationId: listPenalties
      tags:
      - Plays
      summary: Get penalty plays
      description: Only the penalty plays of an event; all plays are scanned, not just one page.
      parameters:
      - name: sport
        in: path
        required: true
        description: 'Sport slug: football, basketball, baseball, hockey, soccer.'
        schema:
          type: string
          example: football
      - name: league
        in: path
        required: true
        description: League slug, e.g. nfl, college-football, nba, mens-college-basketball, mlb, nhl, eng.1, usa.1.
        schema:
          type: string
          example: nfl
      - name: eventId
        in: path
        required: true
        description: Event (game) id, as returned by the events endpoints.
        schema:
          type: string
          example: '401772982'
      - name: enrich
        in: query
        required: false
        description: Resolve athlete names, teams and positions for play participants (default true). Pass false for faster, id-only results.
        schema:
          type: boolean
          example: true
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                type: object
                properties:
                  success:
                    type: boolean
                    example: true
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Play'
                  meta:
                    type: object
                    properties:
                      rateLimit:
                        $ref: '#/components/schemas/RateLimit'
                      totalPlaysScanned:
                        type: integer
                      count:
                        type: integer
                required:
                - success
                - data
        '401':
          $ref: '#/components/responses/Unauthorized'
        '429':
          $ref: '#/components/responses/RateLimitExceeded'
        '500':
          $ref: '#/components/responses/ServerError'
    servers:
    - url: https://www.realtimesportsapi.com/api/v1
      description: Production
components:
  schemas:
    Play:
      type: object
      properties:
        id:
          type: string
          example: '4017729821234'
        sequenceNumber:
          type: string
        text:
          type: string
          example: P.Mahomes pass short right to T.Kelce for 12 yards
        shortText:
          type: string
        alternativeText:
          type: string
        type:
          type: object
          properties:
            id:
              type: string
              example: '24'
            text:
              type: string
              example: Pass Reception
            abbreviation:
              type: string
              example: REC
        period:
          type: integer
          example: 2
        clock:
          type: object
          properties:
            value:
              type: number
              example: 323
            displayValue:
              type: string
              example: '5:23'
        wallClock:
          type: string
          format: date-time
        homeScore:
          type: integer
          example: 14
        awayScore:
          type: integer
          example: 10
        scoringPlay:
          type: boolean
          example: false
        scoreValue:
          type: integer
          example: 0
        scoringType:
          type: string
        situation:
          type:
          - object
          - 'null'
          properties:
            down:
              type: integer
            distance:
              type: integer
            yardLine:
              type: integer
            yardsToEndzone:
              type: integer
            downDistanceText:
              type: string
            possessionText:
              type: string
        endSituation:
          type:
          - object
          - 'null'
          properties:
            down:
              type: integer
            distance:
              type: integer
            yardLine:
              type: integer
            yardsToEndzone:
              type: integer
        yardsGained:
          type: integer
          example: 12
        teamId:
          type: string
          example: '12'
        athletes:
          type: array
          items:
            $ref: '#/components/schemas/PlayAthlete'
        priority:
          type: boolean
        modified:
          type: string
    Error:
      type: object
      properties:
        success:
          type: boolean
          example: false
        error:
          type: object
          properties:
            code:
              type: string
              example: MISSING_TOKEN
            message:
              type: string
              example: Authorization required
            hint:
              type: string
              example: 'Use Authorization: Bearer <your-api-key> or X-API-Key: <your-api-key>.'
          required:
          - code
          - message
      required:
      - success
      - error
    Pagination:
      type: object
      properties:
        page:
          type: integer
          example: 1
        pageSize:
          type: integer
          example: 25
        total:
          type: integer
          example: 180
        totalPages:
          type: integer
          example: 8
        pageCount:
          type: integer
          example: 8
          description: Present on some endpoints instead of totalPages.
        hasNextPage:
          type: boolean
          example: true
        hasPreviousPage:
          type: boolean
          example: false
    PlayAthlete:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        displayName:
          type: string
        shortName:
          type: string
        position:
          type: string
          example: QB
        team:
          type: object
          properties:
            id:
              type: string
        role:
          type: string
          example: passer
        type:
          type: string
          example: passer
        order:
          type: integer
    RateLimit:
      type: object
      properties:
        limit:
          type: integer
          example: 10000
          description: Calls included this month.
        remaining:
          type: integer
          example: 9876
          description: Calls remaining this month (approximate; updated asynchronously).
        reset:
          type: integer
          example: 1767225600000
          description: Quota reset time, Unix epoch milliseconds.
  responses:
    RateLimitExceeded:
      description: 'Too many requests: either the monthly quota is exhausted (code RATE_LIMIT_EXCEEDED; upgrade or enable overage) or the plan''s per-second rate was exceeded (code RATE_LIMIT_PER_SECOND; Free 1/s, Starter 5/s, Growth 10/s, Pro 20/s, Scale 100/s). Wait for `Retry-After` seconds.'
      headers:
        Retry-After:
          description: Seconds until you may retry.
          schema:
            type: integer
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: 'Missing, malformed, unknown or expired API key (codes: MISSING_TOKEN, USER_NOT_FOUND, TRIAL_EXPIRED).'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    ServerError:
      description: Unexpected error. Safe to retry with backoff.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: 'Your API key from the dashboard: `Authorization: Bearer <api key>`. Keys are opaque strings, not JWTs.'
    ApiKeyHeader:
      type: apiKey
      in: header
      name: X-API-Key
      description: Alternative to the Authorization header (useful behind proxies that strip Authorization).
externalDocs:
  description: Guides, WebSocket and webhook docs
  url: https://www.realtimesportsapi.com/docs?utm_source=openapi
x-refined-from:
- original.json
- realtimesportsapi-com-openapi.json