Requirements
- The Enterprise plan, with Enterprise SSO enabled for your organization by Modem
- The owner role in the Modem organization. Admins and members can open the Directory Sync page but cannot see or change any of it
- Enterprise SSO configured first. Directory Sync creates accounts but issues no way to sign in — see SCIM and SSO are two halves below
- Administrator access to your directory, with permission to configure provisioning on the Modem application
What SCIM does, and does not do
SCIM and SSO are two halves
Provisioning an account is not the same as being able to use it. A SCIM-provisioned person has no password and no linked GitHub or Google account, so single sign-on is how they get in. Set up Enterprise SSO first; the Directory Sync page will tell you to do that before it offers a token. The two halves meet at one value: theexternalId your directory sends over SCIM must be the same value the SAML application sends as the NameID. That is what lets Modem recognise the person signing in as the person the directory provisioned, instead of creating a second account for them. Each setup guide names the exact attribute to use.
Connecting a directory
Open Directory Sync in Modem
Copy the SCIM base URL
Generate a token
Paste both into your directory and test the connection
Map your directory groups to Modem roles
The token
The token is a bearer credential. Treat it exactly as you would any other API secret: it can create and deactivate accounts in your Modem organization.- It is shown once, at the moment it is generated. Modem stores only a keyed hash of it and cannot show it again.
- It expires one year after it is generated. Rotate before then, or provisioning stops.
- A connection may hold up to three live tokens at once. That is the rotation window, not a fleet.
- Every request is over HTTPS. Modem refuses an expired, revoked, or unknown token with
401.
Rotating without an outage
Rotate token issues a second token alongside the first. Both work, so nothing breaks while you switch:Rotate
Update the directory
Revoke the old one
Retiring a connection
Decommission retires the connection permanently. It is irreversible, and it is not a pause button:- Every token on the connection stops working immediately.
- Every person the directory provisioned is reconciled to inactive — their access is revoked and their Modem organization membership is removed, exactly as if the directory had deactivated them one by one.
- The directory records themselves are kept, so the history of who was provisioned when is not lost.
Lifecycle
Groups and roles
A directory group grants nothing until you map it. On the Directory Sync page, each group your directory has pushed can be mapped to:- Someone in no mapped group is still a member. Provisioning is itself the access decision — the directory put them in Modem, so they belong here. Mapped groups only raise them above the default.
- The strongest role wins. Someone in both an Admin-mapped and a Member-mapped group is an admin.
- Mappings are keyed on the group’s directory id, not its name. Renaming a group in Okta or Entra does not change who is an admin.
- The owner role is never granted by a group. Promote owners by hand in Settings → Team.
- Roles granted by hand are never overwritten. If an admin invited someone in Modem directly, or they joined through domain auto-join, Directory Sync leaves their role alone in both directions — it will neither promote nor demote them.
- After you change a mapping, Modem re-applies it to everyone the directory has already provisioned. You do not need to re-push from the directory.
Enforcing SSO for provisioned users
Directory Sync adds a switch, Enforce SSO for provisioned users, which is turned on automatically when you connect your first directory. With it on, a single sign-on attempt is only accepted if the person is currently listed as active in your directory. Someone the directory has deactivated, deleted, or never provisioned is refused at sign-in with “Your account is not active”, even if their identity provider is perfectly happy to vouch for them. This is what closes the gap between “removed from the directory” and “cannot get into Modem”. Turn it off while you are migrating — during an initial rollout, while you are switching directories, or any time your directory does not yet list everyone who needs access. With it off, single sign-on works for anyone your identity provider authenticates, exactly as it does without Directory Sync.Limits and unsupported features
- A group may contain up to 1,000 direct members. Larger groups are rejected rather than truncated.
- Groups may contain users only. Nested groups and non-user members are rejected — flatten them in your directory.
- Filters support equality and
andonly.or,not, comparison operators, and presence filters are not supported. This matches what Okta and Entra send. - Pages hold at most 100 resources. A directory asking for more is given 100 and the true total, and pages through the rest.
- Passwords, photos, instant-messaging addresses, and X.509 certificates are ignored. Modem never accepts a password over SCIM.
User.groups, bulk requests,/Me, ETags, cursors, and sorting are not supported.- Custom schema extensions are not supported. The standard Enterprise User extension (
department,employeeNumber,manager, and the rest) is accepted.
Troubleshooting
Test connection fails with 404, or the directory cannot reach the endpoint
Test connection fails with 404, or the directory cannot reach the endpoint
https://app.modem.dev/api/auth/scim/v2 with no trailing slash, and no organization identifier — the
token is what identifies your organization.A user is provisioned but cannot sign in
A user is provisioned but cannot sign in
Signing in creates a second account instead of using the provisioned one
Signing in creates a second account instead of using the provisioned one
externalId your directory sends does not match the NameID the SAML application asserts. Both have to be the same immutable
directory id — see the Okta or Microsoft Entra ID guide for the exact attribute.Someone was removed from the directory but is still using Modem
Someone was removed from the directory but is still using Modem
A group push fails with an error about invalid members
A group push fails with an error about invalid members
A group mapping is not changing anyone's role
A group mapping is not changing anyone's role