Generate Hathora Developer Token
Certain API calls require you to have a Hathora developer token. Examples: creating a room, application, or deployment.
Steps to get a non-expiring token:
- Install Hathora Cloud CLI -
npm install -g @hathora/cli
- Log in to your Hathora account -
hathora-cloud login
- Locate your auth token - it should be stored in
~/.config/hathora/token
(if you re-runhathora-cloud login
, it will tell you the path)
Using developer token
When making Hathora Cloud API requests that require the developer token, it must be included as an authorization header:
"Authorization: Bearer $TOKEN"