Skip to content

Chapter 3 · For developers

Add "Sign in with GOXOST ID" to your service

For developers: the overall steps to integrate GOXOST ID via OpenID Connect (Authorization Code + PKCE).

2 min read

On this page
  1. Key details
  2. 1. Get a client
  3. 2. The sign-in flow in brief
  4. Important

GOXOST ID is a standard OpenID Connect provider. Your service never sees the user's password, and any certified OpenID Connect library will work. Full guide: https://myid.goxost.net/docs

Key details

Issuer https://myid.goxost.net
Discovery https://myid.goxost.net/.well-known/openid-configuration
Protocol OpenID Connect 1.0, OAuth 2.0 Authorization Code
PKCE Required for every client, S256 only
Scopes openid (required), profile, email, offline_access
ID token JWT signed with RS256

1. Get a client

There's no self-service registration yet — clients are registered by the GOXOST team. Open a request in the Help Center and include:

  • the service name and logo shown on the consent screen;
  • the client type: confidential (server-side app, with a client_secret) or public (SPA, mobile app — no secret, PKCE only);
  • every redirect URI, spelled exactly (https only; http://localhost is allowed for development);
  • post-logout redirect URIs (if you need them);
  • the scopes you need.

You'll receive a client_id starting with gxid_; a confidential client also gets a client_secret that is shown only once.

2. The sign-in flow in brief

  1. For each sign-in, generate state, nonce and a code_verifier; send the SHA-256 hash of the code_verifier as the code_challenge.
  2. Redirect the user to /oauth/authorize (response_type=code, code_challenge_method=S256).
  3. The user signs in and (the first time) grants consent; GOXOST ID sends them back to your redirect URI with a code.
  4. Your server checks state and exchanges the code for tokens at /oauth/token. The code lives for 60 seconds and works once.
  5. Validate the id_token or call /oauth/userinfo.
https://myid.goxost.net/oauth/authorize
  ?response_type=code
  &client_id=YOUR_CLIENT_ID
  &redirect_uri=https%3A%2F%2Fexample.com%2Fauth%2Fgoxost%2Fcallback
  &scope=openid%20profile%20email
  &state=RANDOM_STATE
  &nonce=RANDOM_NONCE
  &code_challenge=YOUR_CODE_CHALLENGE
  &code_challenge_method=S256

Important

  • Link users by sub — it never changes, while the email can.
  • Keep the client_secret only in your server's secure configuration. If it leaks, ask support for a new one.
  • If the redirect_uri doesn't exactly match a registered one, GOXOST ID shows an error page and does not redirect.

Ready-made examples for PHP, Laravel, Node.js and Python, plus tokens, logout and mobile/SPA apps, are at https://myid.goxost.net/docs.

Was this article helpful?

Didn’t find an answer?

Send a request — a specialist will check your account and reply.