linxio-js
API Reference

Authentication

Login, OTP verification, token refresh, current user, and logout HTTP endpoints.

Authentication endpoints create and maintain the bearer token used by the rest of the API.

POST /login

POST

Create a session

/loginlinxio.auth.login(request)

Authenticates a Linxio user and returns a JWT token plus refresh token.

Body parameters

email
string
required
Email address for the Linxio user.
password
string
required
Password for the Linxio user.
domain
string
optional
Optional tenant-domain hint accepted by some login flows.

Response fields

token
string
optional
JWT bearer token for authenticated requests.
refreshToken
string
optional
Refresh token for renewing the session.
expireAt
ISODateString
optional
Token expiry timestamp when supplied by Linxio.
otp_required
boolean
optional
Whether OTP must be completed before the session is usable.
teamType
string
optional
Team type such as client, reseller, or admin when supplied.
roleId
LinxioId
optional
Role identifier when supplied.

POST /login/otp

POST

Verify one-time password

/login/otplinxio.auth.verifyOtp(request)

Completes OTP verification when Linxio requires it for the account.

Body parameters

email
string
required
Email address used for login.
code
string
required
One-time password code.

Response fields

token
string
optional
JWT bearer token for authenticated requests.
refreshToken
string
optional
Refresh token for renewing the session.
expireAt
ISODateString
optional
Token expiry timestamp when supplied by Linxio.

POST /token/refresh

POST

Refresh JWT auth token

/token/refreshlinxio.auth.refresh(refreshToken)

Exchanges a refresh token for a new JWT token.

Body parameters

refreshToken
string
required
Refresh token returned by login or a previous refresh call.

Response fields

token
string
optional
New JWT bearer token.
refreshToken
string
optional
New refresh token when Linxio rotates it.
expireAt
ISODateString
optional
Token expiry timestamp when supplied by Linxio.

GET /me

GET

Get current user

/melinxio.auth.me(fields)

Returns the current authenticated user.

Query parameters

fields[]
string[]
optional
Optional field projection for the current-user response.

Response fields

id
LinxioId
optional
Current user ID when supplied.
email
string
optional
Current user email when supplied.
fullName
string
optional
Current user display name when supplied.
teamType
string
optional
Current team type when supplied.
permissions
string[]
optional
Permission keys when supplied.
team
object
optional
Current team details when supplied.

POST /logout

POST

Log out current session

/logoutlinxio.auth.logout()

Logs out the current session server-side.

Body parameters

none
void
optional
Send an empty JSON object or no body.

Response

status
204 or JSON
optional
Linxio may return an empty success response.

On this page