> ## Documentation Index
> Fetch the complete documentation index at: https://docs.elumenta.ru/llms.txt
> Use this file to discover all available pages before exploring further.

# Refresh Token

> Get a new access token using a refresh token

<ParamField body="refresh_token" type="string" required>
  The refresh token returned from login, register, or a previous refresh.
</ParamField>

## Request

```bash theme={null}
curl -X POST https://elumenta.ru/api/v2/auth/refresh \
  -H "Content-Type: application/json" \
  -d '{"refresh_token": "eyJhbGciOiJIUzI1NiJ9..."}'
```

## Response

```json theme={null}
{
  "access_token": "eyJhbGciOiJIUzI1NiJ9...",
  "refresh_token": "eyJhbGciOiJIUzI1NiJ9...",
  "token_type": "bearer"
}
```

Access tokens expire in **15 minutes**. Refresh tokens are valid for **30 days** and rotate on each use — always store the latest one.

## Errors

| Code  | Meaning                          |
| ----- | -------------------------------- |
| `401` | Refresh token expired or invalid |
