SETTO API

Replace one player of a team with another («Sustitución») (needs the `manage` scope)

POST
/v1/external/tournaments/{idx}/teams/{teamIdx}/substitute

Swaps outPlayerIdx for the incoming player in ONE write: the team keeps its place, games, results, standings, groups, seed and registration status. The incoming player is an existing one (inPlayerIdx, a player of a tournament within the token’s reach) or a new one (inPlayer; a player of this tournament with the same email is reused): exactly one of the two. A team name made of its players’ names follows the change (renamed); a custom name stays. The leaving player keeps everything they did (results, waivers, payments) and stays in SETTO. Nothing about payments changes: warnings carries PAYMENT_REVIEW when the team has payment marks. Optional Idempotency-Key header. Recorded in «Actividad».

Authorization

apiToken
AuthorizationBearer <token>

API token (organization or personal)

In: header

Path Parameters

idx*string

Tournament identifier

Formatuuid
teamIdx*string

Team identifier

Formatuuid

Header Parameters

Idempotency-Key?string

Optional. A unique string (1-255 visible ASCII characters) per intended write, sent again unchanged when retrying THAT write: for 24 h the same key with the same request answers the first answer again (Idempotency-Replayed: true) instead of writing twice. The same key with another request is a 422 IDEMPOTENCY_KEY_REUSED; while the first still runs, a 409 IDEMPOTENCY_IN_PROGRESS (Retry-After). A 429 or a 409 TOURNAMENT_BUSY is never stored: retry with the same key.

Lengthlength <= 255

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/external/tournaments/497f6eca-6276-4993-bfeb-53cbbbba6f08/teams/497f6eca-6276-4993-bfeb-53cbbbba6f08/substitute" \  -H "Content-Type: application/json" \  -d '{    "outPlayerIdx": "c9d0e1f2-a3b4-4567-8c8d-9e0f1a2b3c4d"  }'
{  "team": {    "idx": "b8c9d0e1-f2a3-4456-8b7c-8d9e0f1a2b3c",    "name": "Lugo / Ramirez",    "seed": 3,    "seedNumber": 1,    "club": "Club Deportivo Santa Fe",    "picture": "https://cdn.setto.io/teams/lugo-ramirez.png",    "description": "Campeones 2025",    "ranking": 12,    "isWildCard": false,    "qualifierStatus": "COMPETING",    "drawAssignment": "QUALIFYING",    "withdrawn": false,    "createdAt": "2026-08-01T17:30:00.000Z",    "division": {      "idx": "a7b8c9d0-e1f2-4345-8a6b-7c8d9e0f1a2b",      "name": "Primera Varonil"    },    "players": [      {        "idx": "c9d0e1f2-a3b4-4567-8c8d-9e0f1a2b3c4d",        "firstName": "Mario",        "lastName": "Lugo",        "avatar": "https://cdn.setto.io/avatars/mario-lugo.png"      }    ],    "captainProfileIdx": "c9d0e1f2-a3b4-4567-8c8d-9e0f1a2b3c4d",    "leagueTeam": {      "idx": "d0e1f2a3-b4c5-4678-8d9e-0f1a2b3c4d5e",      "name": "Club Santa Fe",      "color": "#1E3A8A",      "logo": "https://cdn.setto.io/league-teams/santa-fe.png",      "position": 1,      "pointsAdjustment": 0    }  },  "out": {    "idx": "c9d0e1f2-a3b4-4567-8c8d-9e0f1a2b3c4d",    "firstName": "Mario",    "lastName": "Lugo",    "avatar": "https://cdn.setto.io/avatars/mario-lugo.png"  },  "in": {    "idx": "c9d0e1f2-a3b4-4567-8c8d-9e0f1a2b3c4d",    "firstName": "Mario",    "lastName": "Lugo",    "avatar": "https://cdn.setto.io/avatars/mario-lugo.png"  },  "inCreated": false,  "renamed": {    "from": "Pérez / Gómez",    "to": "Ruiz / Gómez"  },  "warnings": [    {      "code": "PAYMENT_REVIEW",      "message": "The team has payment marks or a payment link: review its payments in the dashboard.",      "mensaje": "revisa los pagos de este equipo en el panel",      "divisionIdx": "a7b8c9d0-e1f2-4345-8a6b-7c8d9e0f1a2b",      "teamIdx": "b8c9d0e1-f2a3-4456-8b7c-8d9e0f1a2b3c",      "name": "5a varonil",      "numberOfSets": 2    }  ]}