---
title: "Create API token"
method: POST
path: "/api/project/tokens"
tags: ["Project Tokens"]
---

# Create API token

`POST /api/project/tokens`

Creates a project API token for server-side authentication to SignalWire REST APIs, with only the permission categories supplied in the request. Use it when a backend service needs durable project credentials; client applications should receive a service-specific token such as a [Chat Token](/docs/apis/rest/chat-tokens/create-chat-token), [PubSub Token](/docs/apis/rest/pubsub/create-token), [Room Token](/docs/apis/rest/video/room-tokens/create-room-token), or [Subscriber Token](/docs/apis/rest/subscribers/tokens/create-subscriber-token) instead. The token remains usable until you delete it or remove required permissions.

The Compatibility API exposes the same project tokens through its account-scoped route. Use [Generate a new API Token](/docs/compatibility-api/rest/tokens/create-token) for that request format.

#### Permissions

The API token used to authenticate must have the following scope(s) enabled to make a successful request: _Management_.

[Learn more about API scopes](/docs/platform/your-signalwire-api-space).

#### Token Permissions

You must set the functions allowed by this API Token by selecting which types of requests this API Token is allowed to make.

Valid options are: calling, chat, datasphere, fax, management, messaging, numbers, pubsub, storage, tasking, and video

## Request body

- ProjectCreateTokenRequest — Request body for creating a new API Token.
  - `name` string, required — The name representing the API token.
  - `permissions` ProjectTokenPermission[], required — The permissions you would like to enable for this token. Valid permissions are calling, chat, datasphere, fax, management, messaging, numbers, pubsub, storage, tasking, and video
  - `subproject_id` string, uuid — Universal Unique Identifier.

## Response `200`

The request has succeeded.

- ProjectTokenResponse
  - `id` string, uuid, required — Universal Unique Identifier.
  - `name` string, required — The name of the created API Token.
  - `permissions` ProjectTokenPermission[], required — The permissions enabled for this token.
  - `token` string, required — The API token that can be used along with the project ID for basic authentication

## Other responses

- `401` — Access is unauthorized.
- `422` — The request contains invalid parameters. See errors for details.
- `500` — An internal server error occurred.

---

[API](https://skmtc.dev/signalwire/apis/signalwire-rest-api.md) · [All operations](https://skmtc.dev/signalwire/apis/signalwire-rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/signalwire/signalwire-rest-api/revisions/792d5b8e2970/schema)
