---
title: "Apply club roster CSV import"
method: POST
path: "/api/admin/teams/{teamId}/roster/import"
tags: ["Admin", "Teams"]
---

# Apply club roster CSV import

`POST /api/admin/teams/{teamId}/roster/import`

## Request

- Base URL: `https://app.d-sports.org`
- URL: `https://app.d-sports.org/api/admin/teams/{teamId}/roster/import`
- Auth: HTTP bearer

Same canManageTeam gate and the same body as preview. Writes only when errors is empty. Adds and updates set rosterProvenance club. Active players missing from the file are deactivated (isActive false, status departed), never deleted. One transaction; a unique-name collision rolls back and returns 409.

## Path parameters

- `teamId` string, required

## Request body

- object
  - `csv` string, required

## Response `200`

{ success, data: { added, updated, deactivated } }

## Other responses

- `400`: { success: false, error, code: VALIDATION_ERROR } Row errors; nothing written.
- `401`: { success: false, error, code: UNAUTHORIZED }
- `403`: { success: false, error, code: FORBIDDEN }
- `404`: { success: false, error, code: NOT_FOUND }
- `409`: { success: false, error, code: CONFLICT }

## Changes

- **2026-11-18** `6de639c52609`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/d-sports-ecosystem/apis/d-sports-api/changes/api/admin/teams/:teamId/roster/import/post.md)

---

[API](https://skmtc.dev/d-sports-ecosystem/apis/d-sports-api.md) - [All operations](https://skmtc.dev/d-sports-ecosystem/apis/d-sports-api/llms.txt) - [OpenAPI document](https://skmtc.dev/d-sports-ecosystem/apis/d-sports-api/revisions/63735cf90a04?raw)
