# GET /v2/players/{id}/penalties

Group: Players

Football penalty record for a player across one league season: totals scored and taken, plus each kick: its fixture, its outcome (goal, save, miss, post), its xG and where in the goal it went. Available since 2026-11-04.

Plans: Requires Pro, Business or Enterprise; a Free or Starter key receives 403 endpoint_not_in_plan.

Note: Only penalties during play are included, not shoot-outs, ordered oldest first. goalMouth uses the same goal-mouth frame as the shot map. Without source data, the list is empty and the counts are null.

## Parameters

| Name | In | Required | Description |
| --- | --- | --- | --- |
| `id` | path | yes | DataSportsAPI player id, a positive integer |
| `league` | query | yes | league id, as listed by /v2/players/{id}/seasons |
| `season` | query | yes | season id, as listed by /v2/leagues/{id}/seasons |

## Response

- `data`: `PenaltyHistory`
- `meta`: league, season, count
- Objects: PenaltyHistory (https://datasportsapi.com/markdown/reference.md#penaltyhistory)

## Errors

- 403 history_not_in_plan — the season finished before your plan’s history window begins
- 403 endpoint_not_in_plan — returned to keys on the Free and Starter plans
- 404 not_found — the season id does not belong to this league

Plus the common errors (https://datasportsapi.com/markdown/docs.md#errors).

## Request

cURL:

```bash
curl -H "Authorization: Bearer sk_live_…" \
    "https://api.datasportsapi.com/v2/players/{id}/penalties?league=…&season=…"
```

TypeScript:

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

Python:

```python
res = client.players.penalties(id, league=league, season=season)
```

Go:

```go
res, err := client.Players.Penalties(ctx, id, &datasportsapi.PlayersPenaltiesParams{League: league, Season: season})
```

CLI:

```bash
$ dsa players penalties <id> --league <league> --season <season>
```

## Example response

```json
{ "data": { "scored": 1, "attempts": 1, "penalties": [ { "fixtureId": 201324, "startTime": "2026-09-12T19:00:00.000Z", "outcome": "goal",
      "goalMouthLocation": "lowRight", "goalMouth": { "x": 74.19, "y": 96.83, "z": null }, "expectedGoals": 0.7884 } ] },
  "meta": { "league": 200001, "season": 200386, "count": 1 } }
```

---

Base URL: https://api.datasportsapi.com. Authenticate each /v2 call with the header `Authorization: Bearer <key>` (secret keys begin with `sk_live_`).
HTML: https://datasportsapi.com/docs/players/penalties/ · All docs: https://datasportsapi.com/markdown/docs.md · Data reference: https://datasportsapi.com/markdown/reference.md
