---
title: "Submit or update player stats for a map"
method: POST
path: "/game/matches/{matchId}/player-stats"
tags: ["Game: Rosters & Stats"]
---

# Submit or update player stats for a map

`POST /game/matches/{matchId}/player-stats`

Sets per-player stats on an existing map score for the given mapIndex. Requires the game.scores:write permission. Supports an optional `Idempotency-Key` request header: a retry with the same key and body replays the original response, while the same key with a different body returns 409 error_idempotency_key_conflict. The idempotency identity is scoped per match.

## Path parameters

- `matchId` string, required — Match ID.

## Request body

- GamePlayerStatsBody — Request body for submitting or updating player stats for an existing map score.
  - `mapIndex` integer, required — Zero-based index of the map whose stats are being updated.
  - `playerStats` object, required — Per-player stats keyed by user ID. The map score must already exist.

## Response `200`

The player stats were updated.

- GamePlayerStatsResponse — Result of a successful player-stats update.
  - `success` true, required
  - `mapIndex` integer, required — Index of the map whose stats were updated.
  - `action` string, required — Operation performed, always "updated" on success.

## Other responses

- `400` — Bad request (invalid body, cursor, limit, or date).
- `401` — Missing or invalid API key.
- `403` — API key lacks the required permission.
- `404` — Resource not found.
- `409` — Conflict.

---

[API](https://skmtc.net/teambattles/apis/teambattles-api.md) · [All operations](https://skmtc.net/teambattles/apis/teambattles-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/teambattles/teambattles-api/revisions/2ffe8fb53b7d/schema)
