---
title: "POST /token"
method: POST
path: "/token"
---

# POST /token

`POST /token`

## Request

- Base URL: `https://api.sandbox-gameye.gameye.net`
- URL: `https://api.sandbox-gameye.gameye.net/token`
- Auth: none declared

## Request body

- CreateTokenRequestBody
  - `name` string, required: The name of the token to be created.
  - `scopes` string[], required: The list of scopes that the token should be created with.
  - `expires_after` string: The time after which the token should expire. Valid time units are 'm' and 'h'. Values equal to less than a minute will be rounded up to a minute.

## Response `201`

A new API token has successfully been generated.

- TokenCreatedResponseBody
  - `token` string, required

## Other responses

- `401`: You are not authorized to perform this request.
- `409`: Name conflict.
- `422`: Bad request. This may imply that the given request has invalid syntax.

---

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