Skip to main content
POST
Crear un API token propio

Authorizations

Authorization
string
header
required

Token de sesión Better Auth o API token (atk_...) en el header Authorization: Bearer <token>. Los JWT legacy ya no son válidos.

Body

application/json
name
string
required

Nombre descriptivo del token

Required string length: 1 - 100
Example:

"Integración ERP"

type
enum<string>
required

Tipo de token

Available options:
persistent,
temporary
Example:

"persistent"

expiresIn
number

Vida útil en milisegundos (obligatorio para tokens temporales)

Example:

3600000

Response

API token creado exitosamente

status
string
Example:

"success"

data
object