# Single sign-on

Source: https://tiltas.openpanel.sh/docs/people/sso

> Let people sign in with your company's identity provider over OpenID Connect, and require it.

With single sign-on, people whose email address is on your company's domain sign in to Tiltas through your identity
provider, such as Google Workspace, Microsoft Entra ID or Okta, over OpenID Connect (OIDC). The first time they sign in
this way, they join your Network as Members.

Only an Owner sets it up or removes it; Admins can see it.

## Before you start

In your identity provider, create an OIDC application (a "web" client) and note its **issuer URL**, **client ID** and
**client secret**. Register this redirect URI on it:

```text title="Redirect URI"
https://tiltas.openpanel.sh/api/v1/auth/sso/callback
```

It asks for the scopes `openid`, `email` and `profile`.

## Set it up

In the console, open **Enterprise** → **Single sign-on**.

Enter the **Issuer URL** (it starts with `https://`), the **Client ID** and the **Client secret**. Tiltas reads the
issuer's `/.well-known/openid-configuration` when you save, so a wrong URL is caught at once. The secret is stored
encrypted and never shown again.

Under **Email domains**, list the domains whose people sign in this way, such as your company's domain.

Choose **Save single sign-on**.

Prove each domain with a DNS TXT record. Under **Domains**, each domain shows the value to publish. At your DNS
provider, add a TXT record named `_quietlane.<domain>`, where `<domain>` is the email domain, with that value. The
record keeps this name under Tiltas.

Open the page again once the record is live. Tiltas checks it and marks the domain **Verified**.

A domain can be verified by one Account only. Single sign-on works only for verified domains.

## How people sign in

On the sign-in page they choose **Use single sign-on**, enter their **Work email** and choose **Continue with single
sign-on**. Tiltas sends them to your identity provider, then back to the console.

- Someone signing in for the first time joins your Network as a **Member**. Change their role under **Members**.
- The identity provider must vouch for the email address: an address it marks as not verified is refused.
- Their Personal devices sign in the usual way, with a code they approve in the console.

## Require single sign-on

Switch on **Require single sign-on** once every domain is verified. People with those domains then can no longer use a
Magic link: the sign-in page tells them their organisation signs in with single sign-on.

Keep it off while you test, so a mistake in the identity provider does not lock everyone out.

## Change or remove it

Choose **Edit** to change the issuer, client or domains, and enter the client secret again before you save. Choose
**Remove single sign-on** to turn it off: everyone signs in with a Magic link again. Members stay Members either way.

Changes are in the [audit log](/docs/people/audit-log), as `sso.updated` and `sso.deleted`. By API:
[Set up single sign-on](/docs/api/enterprise/putSso).
