/api/ (except registration, login, and health) requires authentication. Hyperoru uses session tokens — long-lived opaque strings you attach to each request.
Get a session token
1. Create an account
If you do not already have a Hyperoru account, create one:2. Log in
Exchange your credentials for a session token:session_token string. Store it safely — it is the only piece of information needed to act on your account.
Use the session token
Send the token in theAuthorization header of every authenticated request:
Legacy query-parameter fallback
For backwards compatibility with older clients, the API also accepts the token as asession_token query parameter:
Token lifetime and rotation
| Property | Value |
|---|---|
| Default lifetime | 180 days |
| Rotation | Log in again at any time to get a fresh token |
| Revocation | Call POST /api/users/logout (if available on your account) or rotate the password |
| Tokens per user | Multiple tokens can be active simultaneously (one per client) |
Handling failures
| Status | What happened | What to do |
|---|---|---|
401 Unauthorized | The token is missing, invalid, or expired | Log in again and retry |
403 Forbidden | The token is valid but you lack permission for this resource | Verify the account/resource ownership |
429 Too Many Requests | You exceeded the rate limit | Back off, see Errors and rate limits |
Security recommendations
Store tokens in a secret manager (1Password, Doppler, AWS Secrets Manager). Never commit them to git.
Use a separate token for each automated client so you can rotate them independently.
Pass tokens in the
Authorization header, not as query parameters.Rotate tokens immediately if a device or machine is lost or compromised.
Treat the token like a password: anyone who has it can place trades on your behalf.
Next steps
Your first API call
A short walkthrough: log in, list accounts, fetch a price.
Errors and rate limits
How the API signals failure and how to back off.