Gebo.ai setup guide · Security · Page 27
Keycloak
Your people sign in to Gebo.ai with the accounts of a Keycloak realm. Add Gebo.ai as a client of the realm, then enter it in Setup.
- Time
- 10 minutes.
- You need
- An administrator of the Keycloak realm, the address Keycloak is published at, and Gebo.ai open at the address your users use.
1Add Gebo.ai to the realm
- In the Keycloak admin console choose the realm, open Clients and click Create client.
- Client type OpenID Connect, Client ID
gebo-ai, then Next. - Turn on Client authentication, keep Standard flow, then Next and Save. The redirect address comes later.
- In the Credentials tab copy the Client secret.
2Open the single sign-on settings
In Setup open Security (1) and click Single signon, oauth2 authentication (2), then + Oauth2 config.

3Enter the client

- Description: the name on the login button, for example Keycloak company realm.
- Provider: Keycloak OIDC auth provider.
- Configuration purpose: Authentication.
- Accepted audiences: only for tools that call the Gebo.ai API with tokens of this provider (page 28b). Enter the Client ID of item 5 to accept only tokens meant for Gebo.ai; empty, any token this provider signed is accepted. Signing in with the button does not depend on it.
- Client ID: the identifier the provider gave Gebo.ai.
- Secret key: the client secret the provider gave Gebo.ai.
- realm: the name of the realm, as in its address.
- serverUrl: the address Keycloak is published at, without the final
/, for examplehttps://sso.example.com. - Click Save.
<serverUrl>/realms/<realm>, exactly as Keycloak writes it in its tokens: use the public address configured in Keycloak, reachable from the Gebo.ai server too. For Keycloak versions before 17 it ends in /auth.account and names the requesting client apart: with the Client ID among the Accepted audiences, the tokens of the gebo-ai client are accepted and those of the other clients refused. For a stricter check, add an audience mapper to the client and enter its audience instead.4Give the provider the redirect address
Save closes the dialog. Click Modify next to the new configuration: Gebo.ai has given it a Code (2) and lists the addresses to enable at the provider. The redirect address to register is the one ending in /login/oauth2/code/ followed by the code (1).

In Keycloak open the gebo-ai client, paste the address among the Valid redirect URIs of its Settings and click Save.
https://gebo.company.com, before copying it: an address with localhost works only on the server itself.5Let people in
The login page now shows a button with the Description of the configuration.

By default Gebo.ai lets in the people an administrator has created: for each of them create a user whose Username is the e-mail address of their Keycloak account and whose Authentication provider is this provider, as described in page 29. To make every person the provider recognizes a user on their own, see page 28b.