# Single sign-on and SCIM

Workspace owners set this up on **Settings → Single sign-on and provisioning**.

## 1. Verify your domain

Add your email domain, for example `acme.com`, then add the TXT record it shows at `_godelgate.acme.com`:

```text
godelgate-verification=<token>
```

and click **Verify**. Single sign-on only signs in emails on verified domains, so another company's identity provider can't sign anyone into your workspace. Public email domains (gmail.com, outlook.com...) can't be claimed.

## 2. Connect your identity provider

**OpenID Connect** (Okta, Microsoft Entra ID, Google Workspace, Auth0, Keycloak, OneLogin): create a web application with the redirect URI shown on the page (`https://godelgate.com/sso/oidc/callback`), then enter its issuer URL, client ID and client secret. For Entra ID the issuer is `https://login.microsoftonline.com/<tenant>/v2.0`.

**SAML 2.0:** give your identity provider the ACS URL and entity ID shown on the page (or the metadata URL), with NameID format *email address* and signed assertions. Then paste its metadata XML, or its SSO URL and signing certificate.

Choose the role new people join with (member or admin) and click **Save**. Use **Test sign-in** to try it.

People sign in by choosing **Continue with SSO** and entering their work email. Anyone on a verified domain who signs in joins the workspace.

## Requiring SSO

**Require SSO for this workspace** makes the workspace open only for sessions that signed in through its SSO; other sign-ins (Google) don't reach it. To avoid locking yourself out, Godelgate only lets you turn this on from a session that signed in with SSO.

## 3. SCIM provisioning

Create a SCIM token on the same page and give your identity provider:

- **Base URL:** `https://godelgate.com/scim/v2`
- **Token:** the `ggs_…` token (shown once), as a bearer token.

Godelgate supports SCIM 2.0 Users and Groups as Okta and Entra ID use them:

| Your identity provider does | Godelgate does |
| --- | --- |
| Creates a user | Adds them to the workspace (emails on verified domains only) |
| Deactivates or deletes a user | Removes them, revokes their keys and ends their sessions |
| Pushes a group | Its members get a policy group named after it, e.g. "Platform Eng" → `platform-eng` |

Use those groups in [policy rules](/docs/policy).
