Skip to content

Company sign-in (SSO) and SCIM

The technical side of signing in with a company account and of provisioning people from an identity provider. The step-by-step setup in Entra, Google, Okta and others is in the Manage handbook: company sign-in and SCIM.

Per organisation, under Manage → Sign-in (/v1/admin/sso, organisation administrators). The platform’s operator must allow company sign-in for the installation; otherwise these routes answer 403 org_sign_in_disabled.

Provider Protocol What Academy needs
Microsoft Entra ID OpenID Connect directory (tenant) id, client id, client secret
Google Workspace OpenID Connect client id, client secret
Any OpenID Connect provider (Okta, Keycloak, Auth0, …) OpenID Connect issuer, client id, client secret
Any SAML 2.0 identity provider SAML 2.0 the IdP’s metadata XML, the attribute names for email and display name
  • Redirect URI: https://<api>/v1/auth/sso/callback, the same for every connection.
  • Flow: authorization code with PKCE (S256), scope openid email profile. The provider’s /.well-known/openid-configuration is read from the issuer and must name exactly that issuer. Microsoft’s issuer is https://login.microsoftonline.com/<tenant id>/v2.0, Google’s https://accounts.google.com.
  • Who signs in: Microsoft: the token’s tid must be the configured tenant; the person is the oid, the address email or else preferred_username. Google: the token must carry hd and email_verified. Other providers: email, with email_verified marking it as verified. An Entra groups claim updates the teams that follow those groups.
  • The client secret is sent in the token request’s body. Academy emails the administrators 30 days before the secret’s expiry date you entered.
Value for the identity provider Address
Entity ID and metadata https://<api>/v1/auth/saml/<connection id>/metadata
Assertion consumer service (HTTP-POST) https://<api>/v1/auth/saml/<connection id>/acs
Sign-in start https://<api>/v1/auth/saml/<connection id>/start
  • Academy’s metadata carries its own key (RSA 3072, valid 5 years) for signing requests and for encrypted assertions.
  • The IdP’s metadata must have exactly one HTTP-Redirect single sign-on endpoint and 1 to 5 RSA certificates of at least 2,048 bits, at least one of them current.
  • Assertions must be signed (SHA-256, SHA-512 or RSA-PSS), at most 5 minutes old, with 30 seconds of clock skew allowed. They may be encrypted. NameID formats: persistent, unspecified or email address.
  • SAML connections don’t read groups.

Only addresses in proven domains sign in through a connection, and a domain belongs to one organisation only. For each domain Academy shows a TXT record:

_i3-academy.example.com. TXT "i3-academy-verify=3f9c…"

The value must match exactly (chunks of a long TXT record are joined). A missing record is 422 dns_record_missing; a domain another organisation proved is 409 domain_taken. Changing a connection’s issuer or tenant withdraws its proofs and issues new values. A connection can be switched on only after a passed test and with a proven domain.

  • GET /v1/auth/sso/discover?email=ada@example.com answers {"startUrl": …} when the address’s domain has a connection, so a sign-in page can offer the right button.
  • https://<portal>/login?org=<slug> opens the organisation’s sign-in.
  • Company sign-in only binds everyone with an address in a proven domain, administrators too (ADR 0432).

Identity providers (Entra, Okta, OneLogin, JumpCloud and others) create, change and suspend people and keep teams in step.

  • Base URL: https://<api>/scim/v2 (no /v1).
  • Token: organisation administrators create one under Manage → Sign-in → Automatic provisioning (SCIM) (POST /v1/admin/scim/tokens). It looks like scim_<cell>_…, is shown once, and acts with its creator’s current roles. Send it as Authorization: Bearer scim_…; without it, even the discovery endpoints answer 401. When the organisation’s contract has ended, SCIM answers 403.
  • Media type: application/scim+json (plain JSON is accepted).
Resource Methods
/Users GET (list, filter), POST
/Users/{id} GET, PUT, PATCH, DELETE
/Groups GET (list, filter, excludedAttributes=members), POST
/Groups/{id} GET, PUT, PATCH, DELETE
/ServiceProviderConfig, /ResourceTypes, /Schemas GET
  • userName (or else the primary address in emails) must be an email address in one of the organisation’s proven domains. New people join as learners; active: false creates them suspended.
  • PATCH with add or replace changes active, displayName, name.formatted, name.givenName, name.familyName, externalId, title, and from the enterprise extension department, employeeNumber and manager (manager.value is the manager’s SCIM id). remove clears employment fields. userName and emails are not changed through SCIM, and other paths are ignored.
  • PUT replaces the user: employment fields left out are cleared.
  • DELETE suspends the person in the organisation; their learning history stays.
  • Fields an HR connector leads are left as the HR system has them.
  • External learners, LMS guests and erased people are not listed.
  • Enterprise extension: urn:ietf:params:scim:schemas:extension:enterprise:2.0:User.

A group is a team kept by SCIM. PATCH handles displayName, externalId and members (add, remove, replace, also members[value eq "<id>"]) and answers 204. Deleting a group removes its members; a team that has training records stays, as a team kept by hand.

  • Filters: only eq, for users on userName, emails.value, externalId or id, for groups on displayName or externalId. That is what Entra and Okta use.
  • Pages: startIndex (from 1) and count (default 100, at most 200).
  • Not supported: bulk, sorting, ETags and password changes (ServiceProviderConfig says so).

Besides SCIM, a team can follow a group directly (POST /v1/teams with directory: {connectionId, groupId}):

  • Microsoft Entra, through the sign-in’s own app registration with the application permissions GroupMember.Read.All and User.Read.All: members of the group and its nested groups, with jobTitle, department, officeLocation, employeeId and manager.
  • Google Workspace, through a service account with domain-wide delegation and the scopes admin.directory.group.readonly and admin.directory.group.member.readonly (PUT /v1/admin/sso/connections/{id}/directory): members including nested groups, no employment data.

Teams sync daily and with POST /v1/teams/{id}/sync. Only people with addresses in proven domains are taken; people who never signed in get an account so their trainings start; members the sync added leave when they leave the group.