# Self-host a whiteboard with single sign-on

## Agent prompt

```text
Help me self-host Slatebox as my team's whiteboard with company single sign-on. First run npx -y slatebox@latest agent-prompt and follow the brief it prints exactly. Ask me, do not guess: where it runs, our own domain, and which company sign-in we use (Microsoft Entra ID, Okta, Google Workspace, another SAML or OpenID Connect provider, or LDAP or Active Directory). Plan the install with --domain and --sso, show me the whole plan, and install only after I say yes. Then tell me to open the one-time setup link the installer printed (docker exec slatebox slatebox setup-link prints a new one, which I run myself) to create the first account, and walk me through adding our provider in the Keycloak admin console. Never print the Keycloak admin password or a SCIM token into our chat; tell me the command that shows it instead.

Read the official guide at https://docs.slatebox.com/Installation/self-hosted-whiteboard-with-sso.md first. Tell me what you verified and which steps I still need to do.

If your client cannot fetch the documentation, read the same published file at https://raw.githubusercontent.com/Slatebox/slatebox-docs/retype/Installation/self-hosted-whiteboard-with-sso.md.
```

Run Slatebox on your own server, with people signing in through your company account. It is one container, `ghcr.io/slatebox/slatebox`, with the app, live collaboration, MongoDB and Keycloak inside. Single sign-on, SCIM 2.0 and the activity log are free on a self-hosted Slatebox, and the code is open source.

## 1. Install with your domain and single sign-on

You need Node.js 22.13 or newer where you type the command, and Docker where Slatebox runs.

<!-- tabs -->

```sh Shell
npx slatebox install --domain boards.example.com --sso
```

<!-- /tabs -->

It shows a plan of everything it will write and run, and installs once you say yes. You get Slatebox at `https://boards.example.com` with certificates renewed automatically, and a **Sign in with SSO** button on the sign-in page. To install on a server over SSH or on Kubernetes, or to write Compose files or a Helm chart instead: [Install guide](install-with-docker.md)

Already running Slatebox? Take a backup first, and check that the command printed `Backup complete` and that the file is not empty:

<!-- tabs -->

```sh Docker
docker exec slatebox slatebox backup > slatebox-backup.gz
```

<!-- /tabs -->

If you installed with `npx slatebox install`, run it again with the same address options and `--sso`, for example `npx slatebox install --domain boards.example.com --sso`. Your data and your other settings stay. If you started the container yourself, start it again with `SLATEBOX_SSO=keycloak` added to the options you already use: [Turn it on](single-sign-on.md#turn-it-on)

## 2. Create the first account

The installer ends with a one-time setup link. Open it to create the first account, the server administrator. Nobody can sign up before that. The link works once, for 24 hours; this prints a new one:

<!-- tabs -->

```sh Docker
docker exec slatebox slatebox setup-link
```

<!-- /tabs -->

## 3. Connect your company sign-in

Print the Keycloak admin console address, the redirect address for your provider and the SCIM address:

<!-- tabs -->

```sh Docker
docker exec slatebox slatebox sso
```

<!-- /tabs -->

Sign in to the console as `admin` (`docker exec slatebox slatebox sso admin-password` shows the first password), make your own administrator, and in the `slatebox` realm add your provider under **Identity providers**:

| Your provider | In Keycloak |
| --- | --- |
| Microsoft Entra ID | **OpenID Connect v1.0** with `https://login.microsoftonline.com/<tenant id>/v2.0/.well-known/openid-configuration` |
| Okta | **OpenID Connect v1.0** with `https://<your org>.okta.com/.well-known/openid-configuration` |
| Google Workspace | **Google**, with **Hosted domain** set to your company's domain |
| Any SAML 2.0 provider | **SAML v2.0** with the provider's metadata |
| LDAP or Active Directory | **User federation → Add LDAP providers** |

Every field, Trust Email and the first-login flow: [Single sign-on](single-sign-on.md#add-your-companys-sign-in)

Rather connect one team's provider with nothing set on the server? A team owner opens **Team settings › Sign-in & security** and connects Microsoft Entra ID, Okta, Google Workspace, or any OpenID Connect or SAML 2.0 provider there. [Single sign-on for a team](single-sign-on.md#single-sign-on-for-a-team)

## 4. Add and remove people automatically

SCIM works with a team's own sign-in connection and a verified domain, not with the server-wide Keycloak from step 3. If you only did step 3, first connect the team's provider and verify its domain: [Single sign-on for a team](single-sign-on.md#single-sign-on-for-a-team)

Then open **Team settings › Sign-in & security › SCIM**, make a token, and give your identity provider:

| Setting | Value |
| --- | --- |
| SCIM base URL | `https://boards.example.com/scim/v2` |
| Authentication | Bearer token (`sbscim_…`) |

Your provider then adds, changes and turns off people in the team. A person it turns off is signed out everywhere. [Provisioning with SCIM](single-sign-on.md#provisioning-with-scim)

## 5. Turn off passwords, if you want

Start the container with `SLATEBOX_SSO_ONLY=true` as well. Single sign-on is then the only way in, and guests are off. [SSO only](single-sign-on.md#sso-only)

## 6. Check the activity log

**Team settings › Activity log** lists what people, guests, agents and scripts did in the team and on its slates, newest first, with each entry chained to the one before. Export it as CSV or JSON. [Activity log](single-sign-on.md#activity-log)

## 7. Connect your team's agents

Your Slatebox serves its MCP server at `https://boards.example.com/mcp`. People add that address to Claude, ChatGPT or Cursor and sign in through your company account. [Use Slatebox from your agent](../Using-Slatebox/use-from-your-agent.md)

## Questions

### Is there a self-hosted whiteboard with SSO?

Yes. Slatebox runs on your own server in one container, with Keycloak included for SAML 2.0, OpenID Connect, LDAP and Active Directory, and per-team single sign-on with SCIM 2.0. Install it with `npx slatebox install --domain boards.example.com --sso`.

### Is single sign-on free on a self-hosted Slatebox?

Yes. Single sign-on, SCIM 2.0 and the activity log are free on a self-hosted Slatebox, with no license key.

### Which identity providers work?

Microsoft Entra ID, Okta, Google Workspace, any SAML 2.0 or OpenID Connect provider, and LDAP or Active Directory through the bundled Keycloak.

### Does single sign-on need a second database or container?

No. Keycloak runs inside the same container and keeps its data in the same volume. `slatebox backup` includes it.

### Can agents still connect when single sign-on is required?

Yes. When an agent connects to `/mcp`, Slatebox opens its usual sign-in page in the browser, with **Sign in with SSO**. The person signs in, chooses **Allow**, and the agent acts with that person's access.
