Authentication
You can authenticate in two ways: an API key, or a JWT from the OAuth password grant. Pick one. Both go in the request headers, and the same credentials work on the OTA endpoint and on the schedule and ticket services.
API key
Send your key in the x-api-key header on every request.
Keep your key on the server. Never ship it in a browser or a mobile app, where anyone could read it and make requests as you.
JWT (OAuth password grant)
The identity provider is an OpenID Connect server with one realm per tenant. Ask it for a token with the password grant, then send the access token as a bearer token. You need five values from your onboarding:
The token endpoint is /realms/{tenant}/protocol/openid-connect/token under the auth base URL.
The response gives you an access token and a refresh token, with their lifetimes in seconds.
Send the access token on each API call:
The access token lasts two hours and the refresh token four. Before the access token expires, trade the refresh token for a new pair at the same endpoint instead of sending the password again.
The test identity provider lives at https://test-auth.worldticket.net/auth, with the same realm path. For client setup, see the GO7 docs.

