---
title: "Create"
method: POST
path: "/access_tokens"
tags: ["PersonalAccessTokens"]
---

# Create

`POST /access_tokens`

## Request

- Base URL: `https://api.ngrok.com`
- URL: `https://api.ngrok.com/access_tokens`
- Auth: HTTP bearer

Create a new access token. The token value is returned only in this response and can't be retrieved later. If you lose it, create a new token.

## Headers

- `ngrok-version` integer, required

## Request body

- PersonalAccessTokenCreate
  - `description` string: human-readable description of this token. Optional, max 255 bytes.
  - `expires_at` string: optional expiration time for this token. If unset the token does not expire.
  - `scopes` string[]: scopes this token can use, for example `["endpoints:read"]`. Each must be a scope you can grant.

## Response `201`

Create a new access token. The token value is returned only in this response and can't be retrieved later. If you lose it, create a new token.

- PersonalAccessToken
  - `id` string: unique identifier of the access token
  - `uri` string: URI of this access token API resource
  - `description` string: human-readable description of this token
  - `token` string: opaque bearer token secret. **Only present in the Create response.**
  - `created_at` string: timestamp when the token was created, RFC 3339 format
  - `expires_at` string: optional expiration time, RFC 3339 format. Omitted if the token does not expire.
  - `revoked_at` string: optional timestamp when the token was revoked, RFC 3339 format. Omitted if not revoked.
  - `scopes` string[]: scopes this token was granted. Effective access is also limited by the owner's current role.

## Other responses

- `4XX`: An error. The body carries a machine-readable error_code and a human-readable msg; every code is documented at https://ngrok.com/docs/errors. A 429 with error code ERR_NGROK_226 means the account exceeded the documented request-rate limit.
- `5XX`: An error. The body carries a machine-readable error_code and a human-readable msg; every code is documented at https://ngrok.com/docs/errors. A 429 with error code ERR_NGROK_226 means the account exceeded the documented request-rate limit.

## Changes

- **2026-11-03** `8418dcf65430`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/ngrok/apis/ngrok-openapi/changes/access_tokens/post.md)

---

[API](https://skmtc.dev/ngrok/apis/ngrok-openapi.md) - [All operations](https://skmtc.dev/ngrok/apis/ngrok-openapi/llms.txt) - [OpenAPI document](https://skmtc.dev/ngrok/apis/ngrok-openapi/revisions/8418dcf65430?raw)
