---
title: "Invite an email into a workspace (workspace admin role and admin token scope)"
method: POST
path: "/api/workspaces/{slug}/invitations"
tags: ["Workspaces"]
---

# Invite an email into a workspace (workspace admin role and admin token scope)

`POST /api/workspaces/{slug}/invitations`

## Request

- Base URL: `https://tre-app.com`
- URL: `https://tre-app.com/api/workspaces/{slug}/invitations`
- Auth: HTTP bearer

## Headers

- `Idempotency-Key` string

## Request body

- WorkspaceInvite
  - `email` string, email, required
  - `role` 'owner' | 'admin' | 'member'

## Response `201`

Success

- WorkspaceInvitationCreated
  - `email` string, email, required
  - `role` 'owner' | 'admin' | 'member', required
  - `accepted` boolean, required: True when the address already had an account and joined immediately.

## Other responses

- `400`: Invalid request
- `401`: Unauthenticated
- `403`: Forbidden: insufficient role or token scope; scope denials name the held scope and the operation
- `404`: Not found
- `409`: Conflict
- `422`: Idempotency-Key reused with a different request body (IDEMPOTENCY_KEY_REUSED)
- `429`: Rate limited
- `500`: Internal server error
- `503`: Temporarily unavailable

---

[API](https://skmtc.dev/tre-app/apis/tre-rest-api.md) · [All operations](https://skmtc.dev/tre-app/apis/tre-rest-api/llms.txt) · [OpenAPI document](https://skmtc.dev/tre-app/apis/tre-rest-api/revisions/26a7187a05fc?raw)
