# NBA player index API

Get NBA Player Index data via REST or OpenAny MCP—with pay-per-use pricing and no subscription. Powered by Apish, pass parameters such as limit, output, raw, and retrieve structured data including unique NBA player identifier, player first name, player last name, listed player position, and team three-letter abbreviation to filter international or alumni cohorts, and populate team and position directories.

Documentation: https://openany.si/nba/nba-player-index-api/fe96a66d-19df-4d8f-9521-5447701e8742/
API ID: fe96a66d-19df-4d8f-9521-5447701e8742
Provider: apish
Contract revision: 3
Method: GET
Endpoint: https://api.openany.si/v1/agent-apis/apish/nba/v1/players
Page update time: 2026-12-03T02:55:47.267Z
Access: OpenAny REST
OpenAny MCP: availability is not supplied by this REST contract. Check get_api on the configured OpenAny MCP server before execution.
Request content type: none
Execution mode: sync
Authentication: Authorization: Bearer $OPENANY_API_KEY

## Billing
Price: $0.002 / billing credit
API-key calls use your shared balance. Review the published billing rules before making a paid request.
Price source: OpenAny public API contract.
Contract update time: 2026-12-03T02:40:54.826Z. This is not a price-change timestamp.
```json
{
  "currency": "USD",
  "mode": "rules",
  "parameters": [],
  "policy_version": 2,
  "sale": {
    "addons": [],
    "base_price_micro_usd": "0",
    "max_cost_micro_usd": "2000",
    "quantities": [
      {
        "id": "upstream_credits",
        "label": "Actual API.SH credits consumed",
        "max_quantity": "1",
        "measure": "value",
        "pointer": "/credits_used",
        "price_micro_usd": "2000",
        "quantity_scale": 0,
        "source": "response",
        "unit": "credit",
        "unit_quantity": "1"
      }
    ],
    "rounding": "ceil",
    "variants": []
  }
}
```

## Usage and limits
## NBA Player Index API

Filter the NBA player index using optional season, team (abbreviation or nickname), position (G, F, C or combinations like G-F), country, college, draft\_year (or undrafted), historical (true to include past players when paired with team, country, college or draft\_year), page and limit (1-500, default 100).

## What You Can Build

- **Filter international or alumni cohorts**: Query country=France or college=Duke with historical=true to list active and former NBA players.
- **Populate team and position directories**: Filter by team and position to build browseable roster and depth-chart selectors.
- **Seed player IDs for batch enrichment**: Paginate players\[\].person\_id to feed the Player Profile, Game Log or Awards APIs.

## Returned Data

| Field | Meaning |
| --- | --- |
| `season` | Season represented in the directory |
| `players[].person_id` | Unique NBA player identifier |
| `players[].player_first_name` | Player first name |
| `players[].player_last_name` | Player last name |
| `players[].position` | Listed player position |
| `players[].team_abbreviation` | Team three-letter abbreviation |
| `players[].country` | Player country of origin |
| `players[].college` | Player college or prior affiliation |
| `players[].pts` | Points per game summary |
| `next_page` | Next page number, or null on the final page |

## Request parameters
```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "NBA player index API request inputs",
  "$comment": "Declared input types grouped by HTTP location. Path, query and header values describe decoded inputs and are serialized as text on the wire; body is the payload. This is not an exhaustive provider contract or a schema for the raw HTTP request.",
  "type": "object",
  "properties": {
    "path": {
      "type": "object",
      "properties": {}
    },
    "query": {
      "type": "object",
      "properties": {
        "season": {
          "type": "string",
          "description": "Season as `2025-26` or its first year `2025`; the current season by default."
        },
        "team": {
          "type": "string",
          "description": "Team abbreviation (`LAL`, `BOS` ...) or nickname."
        },
        "position": {
          "type": "string",
          "description": "`G`, `F`, `C`, or a combination like `G-F`."
        },
        "country": {
          "type": "string",
          "description": "Country, e.g. `France`."
        },
        "college": {
          "type": "string",
          "description": "College name or part of it."
        },
        "draft_year": {
          "type": "string",
          "description": "Draft year, or `undrafted`."
        },
        "historical": {
          "type": "boolean",
          "description": "`true` to include past players (needs team, country, college or draft_year)."
        },
        "page": {
          "type": "integer",
          "description": "Page number, from 1."
        },
        "limit": {
          "type": "integer",
          "description": "Players per page (1-500, default 100)."
        },
        "raw": {
          "type": "string",
          "description": "0 leaves out the bulky `raw` source blocks (often 10-30x smaller).",
          "enum": [
            "0",
            "1"
          ]
        },
        "fields": {
          "type": "string",
          "description": "Comma-separated fields to return, e.g. `posts.id,posts.title`. Call metadata is always included."
        },
        "fresh": {
          "type": "string",
          "description": "1 skips the 24-hour cache and fetches live.",
          "enum": [
            "1"
          ]
        },
        "output": {
          "type": "string",
          "description": "JSON only for this OpenAny product. Omit output or use json; CSV and NDJSON are not supported.",
          "enum": [
            "json"
          ]
        },
        "records": {
          "type": "string",
          "description": "With output=csv|ndjson: the top-level list to turn into rows (e.g. `reviews`), or `.` for the whole object as one row."
        }
      }
    },
    "headers": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "path",
    "query",
    "headers"
  ]
}
```

## Response fields
Source: Inferred from examples; not an exhaustive provider schema.
```json
{
  "type": "object",
  "properties": {
    "applied_filters": {
      "type": "object",
      "properties": {
        "college": {
          "type": "null"
        },
        "country": {
          "type": "null"
        },
        "draft_year": {
          "type": "null"
        },
        "historical": {
          "type": "boolean"
        },
        "position": {
          "type": "null"
        },
        "team": {
          "type": "string"
        }
      }
    },
    "cached": {
      "type": "boolean"
    },
    "count": {
      "type": "integer"
    },
    "credits_used": {
      "type": "integer"
    },
    "fetched_at": {
      "type": "string"
    },
    "next_page": {
      "type": "integer"
    },
    "page": {
      "type": "integer"
    },
    "players": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "ast": {
            "type": "number"
          },
          "college": {
            "type": "string"
          },
          "country": {
            "type": "string"
          },
          "draft_number": {
            "type": "integer"
          },
          "draft_round": {
            "type": "integer"
          },
          "draft_year": {
            "type": "integer"
          },
          "from_year": {
            "type": "string"
          },
          "height": {
            "type": "string"
          },
          "jersey_number": {
            "type": "string"
          },
          "person_id": {
            "type": "integer"
          },
          "player_first_name": {
            "type": "string"
          },
          "player_last_name": {
            "type": "string"
          },
          "player_slug": {
            "type": "string"
          },
          "position": {
            "type": "string"
          },
          "pts": {
            "type": "number"
          },
          "reb": {
            "type": "integer"
          },
          "roster_status": {
            "type": "integer"
          },
          "stats_timeframe": {
            "type": "string"
          },
          "supplemental_status": {
            "type": "integer"
          },
          "team_abbreviation": {
            "type": "string"
          },
          "team_city": {
            "type": "string"
          },
          "team_id": {
            "type": "integer"
          },
          "team_name": {
            "type": "string"
          },
          "team_slug": {
            "type": "string"
          },
          "to_year": {
            "type": "string"
          },
          "url": {
            "type": "string"
          },
          "weight": {
            "type": "string"
          }
        }
      }
    },
    "season": {
      "type": "string"
    },
    "total": {
      "type": "integer"
    }
  }
}
```

## Request example
Scenario: Official example · Live API.SH recording · HTTP 200
```bash
curl \
  'https://api.openany.si/v1/agent-apis/apish/nba/v1/players?limit=1&output=json&raw=0&season=2025-26&team=LAL' \
  -X GET \
  -H "Authorization: Bearer $OPENANY_API_KEY" \
  -H 'Content-Type: application/json'
```

## Response example
Example from the provider's documentation. Field values in your results will differ.
Sample response · Documented HTTP 200
```json
{
  "applied_filters": {
    "college": null,
    "country": null,
    "draft_year": null,
    "historical": false,
    "position": null,
    "team": "LAL"
  },
  "cached": false,
  "count": 1,
  "credits_used": 1,
  "fetched_at": "2026-11-19T09:20:17.076Z",
  "next_page": 2,
  "page": 1,
  "players": [
    {
      "ast": 0.8,
      "college": "Arizona",
      "country": "Bahamas",
      "draft_number": 1,
      "draft_round": 1,
      "draft_year": 2018,
      "from_year": "2018",
      "height": "7-0",
      "jersey_number": "5",
      "person_id": 1629028,
      "player_first_name": "Deandre",
      "player_last_name": "Ayton",
      "player_slug": "deandre-ayton",
      "position": "C",
      "pts": 12.5,
      "reb": 8,
      "roster_status": 1,
      "stats_timeframe": "Season",
      "supplemental_status": 0,
      "team_abbreviation": "LAL",
      "team_city": "Los Angeles",
      "team_id": 1610612747,
      "team_name": "Lakers",
      "team_slug": "lakers",
      "to_year": "2026",
      "url": "https://www.nba.com/player/1629028/deandre-ayton",
      "weight": "252"
    }
  ],
  "season": "2025-26",
  "total": 17
}
```

## Error handling
400: Check the request fields.
401 / 403: Verify credentials and access permissions.
402: Inspect payment requirements and balance.
429: Respect returned retry guidance.
5xx: Inspect the error and usage record before retrying a paid operation.

## Common questions
### When should I use Player Index instead of Player Search?
Use Player Index for structured directory filtering by team, position, country, college or draft year; use Player Search for name-based lookup with q.

### How do I include historical or retired players?
Set historical=true and pair it with at least one scoping filter: team, country, college or draft_year.

### Can I filter for undrafted players?
Yes. Pass draft_year=undrafted to return players who entered the league undrafted.

### What position formats are accepted?
Pass G, F, C or combined designations such as G-F or F-C.

### How do I paginate through the directory?
Use page (from 1) and limit (1 to 500, default 100), following next_page until null.

### How do caching and response trimming work?
Output is JSON only. Pass fresh=1 to skip the 24-hour cache, raw=0 to omit raw blocks, or fields to select keys.

## Available implementations
- apish: https://openany.si/nba/nba-player-index-api/fe96a66d-19df-4d8f-9521-5447701e8742/

Integration guide: https://openany.si/docs/
Agent setup: https://openany.si/SKILL.md
