---
title: "Accept a team invitation"
method: POST
path: "/api/v3/invitations/{code}/accept"
tags: ["Team Invitations"]
---

# Accept a team invitation

`POST /api/v3/invitations/{code}/accept`

## Request

- Base URL: `https://codemagic.io`
- URL: `https://codemagic.io/api/v3/invitations/{code}/accept`
- Auth: API key in header `x-auth-token`
- TypeScript: <https://skmtc.dev/codemagic/apis/codemagic-api/docs/api/v3/invitations/:code/accept/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `code` string, required

## Response `204`

Request fulfilled, nothing follows

## Other responses

- `400`: The request could not be validated
- `401`: Authentication is missing or invalid
- `403`: The invitation was sent to a different email address
- `404`: The requested resource does not exist
- `410`: The invitation has been revoked or has expired
- `429`: The rate limit has been exceeded

---

[API](https://skmtc.dev/codemagic/apis/codemagic-api.md) - [All operations](https://skmtc.dev/codemagic/apis/codemagic-api/llms.txt) - [OpenAPI document](https://skmtc.dev/codemagic/apis/codemagic-api/revisions/be09630f65e2?raw)
