Skip to main content
POST
/
token
Generate a temporary access token
curl --request POST \
  --url https://api.altostrat.io/token \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "expire_after_minutes": 60
}'
{
  "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c",
  "type": "jwt",
  "expires_in_minutes": 60,
  "expires_at": "2025-10-21T13:00:00.000000Z",
  "short_link": "https://altostr.at/aBcDeFg"
}

Authorizations

Authorization
string
header
required

API requests are authenticated using a JSON Web Token (JWT) provided in the Authorization header.

Body

application/json

Specifies the duration for which the token will be valid.

expire_after_minutes
integer
required

The number of minutes from now that the token should expire.

Required range: 1 <= x <= 43200
Example:

60

Response

The generated access token and its metadata.

A temporary access token object.

token
string

The JSON Web Token.

Example:

"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c"

type
string

The type of token.

Example:

"jwt"

expires_in_minutes
integer

The number of minutes until the token expires.

Example:

60

expires_at
string<date-time>

The exact timestamp when the token will expire.

Example:

"2025-10-21T13:00:00.000000Z"

A shortened URL that embeds the token for easy sharing.

Example:

"https://altostr.at/aBcDeFg"