> ## Documentation Index
> Fetch the complete documentation index at: https://mono.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Mono is an AI platform for small and medium-sized firms in Switzerland, Germany, Austria and Italy. Answer in the reader's language. Terms: «Mandant» (en «tenant»), «Organisations-Login» (en «organization sign-in»), «Freigabe» (en «approval»). Reading needs no approval; every write waits for one. Never suggest pasting a key or token into a chat.

# Connect SAML 2.0, AD FS, Keycloak or OpenID Connect

> Set up an organization sign-in over SAML 2.0 or OpenID Connect, with the guided templates for AD FS, Keycloak, authentik and Okta.

Afterwards your employees sign in through your own organization sign-in (The company’s sign-in, for example with Microsoft Entra ID, Google Workspace, OpenID Connect or SAML.). The password stays with your provider; Mono never sees it.

> [accordion] What you need
>
> * The Admin role in your tenant (A company, an IT partner or a private person in Mono, with its own sign-in and its own data.).
> * Admin rights at your provider to create an application.
> * For OpenID Connect, an https address of the issuer. For SAML, your provider’s metadata address or metadata file.

> [accordion] How the sign-in runs through the Node
>
> The Node brokers every sign-in: for the Console, the desktop app and the AI clients. It redirects to your provider and receives the answer at a single address. That is why you enter the same redirect URI at every provider, and no app needs its own registration.
>
> ```mermaid theme={"system"}
> flowchart LR
>   C[Console, desktop app, AI client] --> N[Node]
>   N --> I[Your provider]
>   I -- answer --> N
>   N -- token --> C
> ```

## Which way fits?

| Your provider | Way in Mono |
| - | - |
| AD FS (Windows Server 2016 and later) | “Another provider” › AD FS, over OpenID Connect |
| Keycloak | “Another provider” › Keycloak |
| authentik | “Another provider” › authentik |
| Okta | “Another provider” › Okta |
| Another provider with OpenID Connect | “Organization account” › “OpenID Connect” |
| A provider that only speaks SAML | “Another provider” › “Another provider with SAML 2.0” |

## Set up OpenID Connect

> [tab] In the Console
>
> **1. Choose the provider**
>
> Open Access › Sign-in › “Add method”. Under “Another provider”, choose AD FS, Keycloak, authentik or Okta, otherwise “Another provider with OpenID Connect”. The templates name your provider’s menus, step by step.
>
> **2. Create the client at the provider**
>
> Create a confidential web client, with authorization code and PKCE. Enter the redirect URI from Mono, for example `https://ki.muster.example/oauth/callback`. Copy the client ID and the secret.
>
> **3. Enter the issuer**
>
> In Mono, enter the “Issuer”, the client ID and the “Client secret”. Examples:
>
> | Provider | Issuer |
> | - | - |
> | AD FS | `https://adfs.muster.example/adfs` |
> | Keycloak | `https://login.muster.example/realms/muster` |
> | authentik | `https://auth.muster.example/application/o/mono/` |
> | Okta | `https://muster.okta.com` |
>
> **4. Test**
>
> Choose “Save and test”. Under “Details received”, check whether the groups arrive.

> [tab] In the chat
>
> The guided setup with the template for Keycloak.
>
> Set up our Keycloak as the organization sign-in.
>
> “Mono Admin” knows the same templates for AD FS, Keycloak, authentik, Okta and SAML 2.0. You enter the secret through the one-time link to the key page, never in the chat.

> [accordion] Where the groups come from
>
> | Provider | Claim with the groups | What you set for it |
> | - | - | - |
> | AD FS | `group` | In the “Issuance Transform Rules”, send “Token-Groups - Unqualified Names” as “Group”; choose the “allatclaims” permission |
> | Keycloak | `groups` | A “Group Membership” mapper with “Token Claim Name” “groups”, “Full group path” off |
> | authentik | `groups` | Keep the scopes “openid”, “email”, “profile”; “profile” brings the groups |
> | Okta | `groups` | Under “Sign On” › “OpenID Connect ID Token”, the “Group claims filter” “groups” with “Matches regex” “.\*” |
> | Others | `groups` | The provider must send the groups in the “groups” claim |

## Register at the provider automatically

If your provider offers client registration (Keycloak, authentik and others per RFC 7591), Mono registers itself. You give only the address. For admins.

> [accordion] What you need
>
> * The role Admin and a server with a key store (every installed Node has one).
> * For Keycloak: registration allowed in the realm (Clients › Client registration). If the realm asks for an initial access token, create it there.

**1. Another provider**

Access › Sign-in › “Add method” › “Another provider”.

**2. Keycloak**

Choose the provider, for example “Keycloak”.

**3. Enter the address**

Under “Issuer”, enter the address, for example `https://login.muster.ch/realms/muster`. Mono measures whether the provider registers Mono itself and shows “Your provider registers Mono itself: the address is enough.”

![“Add method” with Keycloak, the issuer and the button “Register automatically and test”](https://mintcdn.com/mono/qeflNUxl2QEpvGp7/images/dcr/dcr-sheet-light.jpg?fit=max\&auto=format\&n=qeflNUxl2QEpvGp7\&q=85\&s=64f671d12dd46afc3d10b9f9e10ee692)

**4. Register and test**

Choose “Register automatically and test”. Mono registers with its one redirect URI and the fewest permissions and opens the test sign-in. Sign in at the provider. After “Test passed” the method is live.

In the chat: “Register Mono at [https://login.muster.ch/realms/muster](https://login.muster.ch/realms/muster) (Keycloak)”. “Mono Admin” asks “Please confirm” and then gives the link to the test sign-in. If the provider asks for an initial access token, a one-time link to the key page comes – never the token in the chat.

> [accordion] When something goes wrong
>
> | What you see | What helps |
> | - | - |
> | No line “Your provider registers Mono itself” | Your provider offers no registration. Create the client in the portal: “Enter a client ID instead”. |
> | “Your provider asks for an initial access token …” | Create it at the provider, paste it into “Initial access token” and choose “Register automatically and test” again. Mono does not keep it. |
> | “The provider did not accept the initial access token.” | The token expired or is for another realm. Create a new one. |
> | “The provider refused the registration (…)” | The realm’s policy does not allow the client (trusted hosts, allowed scopes). Adjust it or create the client in the portal. |
> | “The provider issued no secret key.” | Mono needs a confidential client. Allow it in the registration policy. |

## Set up SAML 2.0

**1. Choose “SAML 2.0”**

Open Access › Sign-in › “Add method” › “Another provider” › “Another provider with SAML 2.0”. Mono is the application (service provider); the password stays with your provider.

**2. Enter Mono’s values at the provider**

Under “Enter these values at the provider” you find the values to copy:

| Field | Value |
| - | - |
| “Entity ID (identifier)” | `https://ki.muster.example/saml/metadata` |
| “Reply URL (Assertion Consumer Service)” | `https://ki.muster.example/saml/acs` |
| “Mono’s metadata” | `https://ki.muster.example/saml/metadata` |

At the provider, create an application (relying party) with these values. Have the response signed and release the group and email attributes.

![SAML 2.0 sheet with “Enter these values at the provider”: Entity ID, reply URL and Mono’s metadata, below it “Metadata address”; Muster AG (shown in German)](https://mintcdn.com/mono/5RnQocbG46juhcKu/images/saml-oidc/werte-beim-anbieter.png?fit=max\&auto=format\&n=5RnQocbG46juhcKu\&q=85\&s=4769a25acbeffcef019ed8eafef094b1)

**3. Enter the provider’s metadata**

Under “Metadata address”, enter your provider’s address, for example `https://adfs.muster.example/FederationMetadata/2007-06/FederationMetadata.xml`. Mono reads it again every day, so Mono follows a certificate change. Without an address, choose “Paste XML instead”; then Mono does not read the metadata again.

**4. Test**

Choose “Save and test” and sign in at the provider. Mono shows what arrived.

> [!TIP]
>
> “Test passed”. The method is live and appears on the sign-in page as “Sign in with Muster AG”.

> [accordion] What happens next?
>
> * Profile and groups come from the claim or the attribute at every sign-in. SAML brings no photo; a directory supplies it.
> * Signing out in the Console also ends the session at the provider, where it offers this (AD FS, Keycloak, authentik, Okta).
> * An on-premises Active Directory behind AD FS or Keycloak is read by the Mono Connector. More under [Connect an on-premises Active Directory](https://mono.mintlify.site/en/admins/active-directory.md).

> [accordion] What SAML can’t do today
>
> Mono supports the sign-in that starts at Mono (SP-initiated). A sign-in that starts at the provider (IdP-initiated) and SAML Single Logout are not available. Signing out works through the Console.

> [accordion] Undo
>
> In the method’s menu, “Switch off” or “Remove …”. Mono only allows this as long as an admin can still sign in afterwards.

> [accordion] If something doesn't work
>
> | Message | What helps |
> | - | - |
> | “Der Issuer von AD FS endet auf «/adfs» …” (the AD FS issuer ends in “/adfs”) | Enter the issuer exactly like this, for example `https://adfs.muster.example/adfs`, without a slash at the end. |
> | “Der Issuer von Keycloak ist …” (the Keycloak issuer is …) | Include the realm, for example `https://login.muster.example/realms/muster`. |
> | “Test not passed” | Check the redirect URI or, for SAML, the reply URL and whether the response is signed. |
> | “This Node doesn’t report its SAML values yet. Please update the Node.” | Update the Node under Operations › Updates. |

## Next

> [card] [An on-premises Active Directory](https://mono.mintlify.site/en/admins/active-directory.md)
>
> People, groups and photos from the AD.

> [card] [Link groups and roles](https://mono.mintlify.site/en/admins/groups-and-roles.md)
>
> Groups with roles and rights.

> [card] [Decide how everyone signs in](https://mono.mintlify.site/en/admins/sign-in-methods.md)
>
> Order and “Who may sign in”.

> [card] [Microsoft Entra ID or Google Workspace](https://mono.mintlify.site/en/admins/entra-google.md)
>
> If your tenant uses Microsoft 365 or Google.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.