# GET /v2/players/{id}/national-team

Group: Players

A player’s record for each national team he has played for, senior and youth: caps, goals and the day of his debut.

Note: An empty array for a player who has not played for a national team (or whose record the source does not keep).

## Parameters

| Name | In | Required | Description |
| --- | --- | --- | --- |
| `id` | path | yes | our numeric id (positive integer) |

## Response

- `data`: `NationalTeamRecord[]`
- `meta`: count
- Objects: NationalTeamRecord (https://sportsapi.app/markdown/en/reference.md#nationalteamrecord)

## Request

cURL:

```bash
curl -H "Authorization: Bearer sk_live_…" \
    "https://api.sportsapi.app/v2/players/{id}/national-team"
```

TypeScript:

```ts
const { data, meta } = await client.players.nationalTeam(id);
```

Python:

```python
res = client.players.national_team(id)
```

Go:

```go
res, err := client.Players.NationalTeam(ctx, id)
```

CLI:

```bash
$ sportsapi players national-team <id>
```

## Example response

```json
{ "data": [ { "team": { "id": 412, "name": "England", "code": "ENG", … }, "appearances": 59, "goals": 19, "debut": "2020-10-08T00:00:00.000Z" } ],
  "meta": { "count": 1 } }
```

---

Base URL: https://api.sportsapi.app. Send your API key as `Authorization: Bearer <key>` on every /v2 request; keys are created in the dashboard (https://sportsapi.app/dashboard).
HTML: https://sportsapi.app/docs/players/national-team · All docs: https://sportsapi.app/markdown/en/docs.md
