---
title: "Get an MLB player"
method: GET
path: "/mlb/player"
tags: ["MLB"]
---

# Get an MLB player

`GET /mlb/player`

## Request

- Base URL: `https://api.crawlora.net/api/v1`
- URL: `https://api.crawlora.net/api/v1/mlb/player`
- Auth: API key in header `x-api-key`

Returns an MLB player by numeric `id`. The response has the full name, position, bats and throws sides, birth date, city and country, current age, height, weight, jersey number, MLB debut date, active flag and current team. Unknown players return `404`.

## Query parameters

- `id` string, required

## Headers

- `x-api-key` string, required

## Response `200`

OK

- MlbPlayerResponseDoc
  - `code` integer
  - `data` MlbPlayerResponse
    - `fetched_at` string
    - `player` MlbPlayer
      - `active` boolean
      - `bat_side` string
      - `birth_city` string
      - `birth_country` string
      - `birth_date` string
      - `current_age` integer
      - `current_team` MlbTeamRef
        - `abbreviation` string: Short team abbreviation, for example `NYY`. Omitted when not available.
        - `id` integer: MLB team id.
        - `name` string: Full team name.
      - `full_name` string
      - `height` string
      - `id` integer
      - `mlb_debut_date` string
      - `pitch_hand` string
      - `position` string
      - `position_code` string
      - `primary_number` string
      - `weight` integer
    - `source_url` string
  - `msg` string

## Other responses

- `400`: Bad Request
- `404`: Not Found
- `429`: Too Many Requests
- `503`: Service Unavailable

---

[API](https://skmtc.dev/crawlora/apis/crawlora-api.md) · [All operations](https://skmtc.dev/crawlora/apis/crawlora-api/llms.txt) · [OpenAPI document](https://skmtc.dev/crawlora/apis/crawlora-api/revisions/028417aa35bb?raw)
