Get/Create Token

  • GET
  • /workspaces
  • /:workspace_domain
  • /tunnels
  • /token

Get or create tunnel token

Request

REQUIRED SCOPES
TUNNEL_INFO
URL PARAMETERS
workspace_domainrequiredstring
The human-readable ID of the workspace

Example: "my-company"

GET PARAMETERS
project_namestring
The name of the project to get the token for. If not provided, the workspace token is returned

Example: "my-project"

Response

RESPONSE BODY
tokenstring
The JWT token for tunnel authentication

Last modified on Jan 26, 2026

Request example

CURL
curl -X GET "https://api.buddy.works/workspaces/:workspace_domain/tunnels/token" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "Content-Type: application/json"
EXAMPLE RESPONSE
{ "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ3b3Jrc3BhY2VfaWQiOjEyMywidmVyc2lvbiI6MX0.abc123" }
STATUS
200 OK