Ori Shalom
03/24/2026, 2:26 PMgroups, without needing to predefine the possible group values.
At the moment, in the SSO settings, I can define attribute mappings that map attributes coming from the IdP to custom user attributes. However, custom user attributes do not seem to support a dynamic list type.
When I define the groups custom attribute as a text attribute, the mapping only stores the first group.
When I define it as a multi-select attribute without predefined values, the attribute mapping UI does not offer this attribute as a mapping target.
Is there a supported way to map the full list of IdP groups into a user attribute dynamically?DevRev
03/24/2026, 2:27 PM{
"attributeMapping": {
"customAttributes": {
"groups": "idp_groups_attribute_name"
}
}
}
Alternative Approach
If the multi-select attribute without predefined values isn't appearing in the mapping UI, you can use the customAttributes field in the attribute mapping configuration . This allows mapping IdP attributes directly to custom user attributes .
The documentation confirms that Descope allows mapping attributes from your IdP to custom user attributes when configuring attribute mapping , and multi-select attributes can be utilized as arrays .
If you're still experiencing issues with the multi-select attribute not appearing in the mapping UI, this may be a UI limitation that requires using the Management API to configure the mapping directly.
User Management | Descope Documentation
SSO with SAML Provider | Descope Documentation
Get Tenant's SAML/OIDC Settings | API Reference | Descope Documentation
Configure Okta SSO as IDP | Descope Documentation
Tenants | Descope DocumentationOri Shalom
03/24/2026, 2:39 PMDevRev
03/24/2026, 2:39 PMcurl -X POST "<https://api.descope.com/v1/mgmt/tenant/settings/sso/saml>"
-H "Authorization: Bearer <ProjectId:ManagementKey>"
-H "Content-Type: application/json"
-d '{
"tenantId": "your-tenant-id",
"attributeMapping": {
"customAttributes": {
"groups": "your_idp_groups_attribute_name"
}
}
}'
Alternative Solutions
1. Use the group field in attribute mapping - Map your IdP groups attribute to the standard group field, then access the full groups array in your application logic
2. Custom Claims in JWT - Configure custom claims to include the groups data from the IdP response, making it available in your JWT tokens
The UI limitation you've identified is a known gap where multi-select attributes without predefined options don't appear in the mapping dropdown. The API approach bypasses this UI restriction and should allow you to map the dynamic groups list to your custom attribute.
Get Tenant's SAML/OIDC Settings | API Reference | Descope DocumentationChris Carper
03/24/2026, 4:32 PMBhagwanta Yeole
03/24/2026, 8:28 PMAvi Glozman
03/24/2026, 10:06 PMOri Shalom
03/25/2026, 9:29 AMAvi Glozman
03/25/2026, 2:45 PMOri Shalom
03/25/2026, 3:49 PMDoron Sharon
03/25/2026, 6:33 PMidpGroups after the SSO action and append them to the JWT using the custom claims action.
For the 2nd bullet, it is a bit tricky since the groups are not there upon login, so you can use the management API to get the groups and append them to the JWT in the same way. (Soon we gonna add a flow action to get the user’s group).
However, please note that embedding all groups directly in the JWT may not be ideal. In cases where users belong to many groups, this can significantly increase the token size and potentially cause issues (e.g., browser limitations on header size).
A more scalable approach would be to fetch the relevant user groups from your application using the Groups API when needed, rather than including them all in the JWT.Doron Sharon
03/25/2026, 6:43 PMOri Shalom
03/25/2026, 7:01 PMidpGroups prop is not scoped to user (it’s not user.idpGroups). Will it return the actual user groups or all idp groups?Doron Sharon
03/25/2026, 7:12 PMDoron Sharon
03/25/2026, 7:14 PMDoron Sharon
04/06/2026, 4:10 PMidpGroups , which you can use later (add to JWT, etc.)Ori Shalom
04/06/2026, 4:37 PM