Skip to main content

Update Okta User Org Role

For every user, Statsig surfaces a SCIM field named statsigOrgRole. Through this field, you can manage organization user roles. Currently, Okta can only push role updates to Statsig. We currently support the following org roles: Member Admin Owner

Step 1. Create the Custom Attribute in Okta

Navigate to Directory > Profile Editor and select the User (default) Okta profile. This represents all of the Okta users’ attributes. Scroll down and press Add Attribute and fill out the new attribute to have the variable name statsigOrgRole.
Okta profile editor showing custom statsigOrgRole attribute being added

Step 2. Create the Custom Attribute in the Statsig SCIM Integration

Now Navigate to the Statsig SCIM Integration's User Profile in the Profile Editor. Add an new attribute that matches the following format:
  • Variable name: statsigOrgRole
  • External namespace: urn:ietf:params:scim:schemas:core:2.0:User
  • Attribute type: either Personal or Group, depending if using groups for app assignment
Statsig SCIM integration user profile with statsigOrgRole attribute definition

Step 3. Create a Mapping from Statsig to Okta for the Custom Attribute

On the same Statsig SCIM profile editor, navigate to the Mappings button. Scroll down to the new attribute statsigOrgRole and map user.statsigOrgRole to the Okta attribute statsigOrgRole.
Okta mapping editor linking statsigOrgRole between Statsig and Okta profiles

Step 4. Create a mapping from Okta to Statsig for the Custom Attribute

Now navigate to the Okta User to Statsig SCIM user mapping.
Okta to Statsig user mapping screen for statsigOrgRole attribute
Scroll down to the statsigOrgRole attribute and map user.statsigOrgRole to the Okta attribute statsigOrgRole.
statsigOrgRole attribute mapping row pointing from user field to Okta attribute
Now all users will be synced with their organization role. On the Statsig SCIM integration you can modify a user’s role directly as well.

Step 5. Modify Integration Mappings

Navigate to the Statsig SCIM integration provisioning section. Under the “To App” tab, scroll down to the statsigOrgRole attribute.
Provisioning To App tab showing statsigOrgRole attribute settings
Set the attribute value to Map from Okta Profile and statsigOrgRole. Set apply on Create and update.
Set value dialog choosing Map from Okta Profile for statsigOrgRole
Navigate to the “To Okta” tab and scroll down to the statsigOrgRole attribute.
Provisioning To Okta tab listing statsigOrgRole attribute
Set the attribute value to Map from Statsig Profile and statsigOrgRole. Set apply on Create.
Set value dialog mapping statsigOrgRole from Statsig profile back to Okta