---
title: "Obtain access token"
method: POST
path: "/api/token"
tags: ["OAuth"]
---

# Obtain access token

`POST /api/token`

OAuth2 token endpoint. Exchanges an authorization code for an access token.

## Response `200`

Access token successfully obtained.

- object
  - `token_type` string, required
  - `access_token` string, required
  - `expires_in` integer, required

## Other responses

- `400` — Failed to obtain access token.

---

[API](https://skmtc.net/lichess/apis/lichess-org-api-reference.md) · [All operations](https://skmtc.net/lichess/apis/lichess-org-api-reference/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/lichess/lichess-org-api-reference/versions/1425db81eb3b/schema)
