SCIM group API reference¶
You can use the SCIM group API to access, create, and modify roles.
Snowflake uses SCIM to import roles from Okta, Azure AD and custom-built applications. The roles in these identity providers map one-to-one with Snowflake roles.
Roles, sometimes called groups, are a collection of access privileges. To access securable objects in Snowflake, privileges must be assigned to roles, and roles are assigned to other roles or users.
Access permissions and rights that are granted to the role are automatically inherited by every member, such as a user, of the role. For more information, see Overview of Access Control.
A user’s access requirements to Snowflake can change. For example, a user can change from being an individual contributor to a manager in their organization, which may require their role in Snowflake to change, or they may require access to data sets only available to managers.
As the user’s role changes in the identity provider, their access to Snowflake automatically changes when their organization role maps to the corresponding Snowflake role.
HTTP headers¶
The Snowflake SCIM API uses bearer tokens for HTTP authentication.
Each HTTP request to the Snowflake SCIM API allows the following HTTP headers:
| Header | Value |
|---|---|
Authorization (Required) | Bearer <access_token>. Snowflake accepts different types of tokens. See Authenticating SCIM API requests. |
Content-Type | application/scim+json |
Accept-Encoding | utf-8 |
Accept-Charset | utf-8 |
Base URL¶
If you are authenticating with External OAuth or programmatic access tokens, specify which SCIM security integration to use by including its UUID in the URL:
To obtain the integration_uuid, run a DESCRIBE SECURITY INTEGRATION command
and copy the value of the SCIM_ENDPOINT_ID property. For example:
If your account has only one enabled SCIM security integration, you can omit the UUID:
If you are authenticating with a SCIM access token, use the shorter base
URL /scim/v2/.
For more information about authentication and base URLs, see Send SCIM requests.
Group attributes¶
You can specify group (that is, a role) attributes in the body of the API requests as key-value pairs in JSON format. These pairs contain information about the group, such as the group’s display name. Identity providers can specify their own key names for each attribute.
Snowflake supports the following SCIM attributes for role lifecycle management. Attributes are writable unless otherwise noted.
| SCIM Group Attribute | Snowflake Group Attribute | Type | Description |
|---|---|---|---|
id | id | String | The immutable, unique identifier (GUID) of the role in Snowflake. Snowflake does not return this value. You can find this value by calling the Information Schema table function REST_EVENT_HISTORY. Check the IdP logs to ensure the values match. |
displayName | name | String | The text shown in the user interface when referring to the group. |
members.value | N/A | String | The id of the user who is a member of the role. |
schemas | N/A | String | An array of strings to indicate the namespace URIs. For example, urn:ietf:params:scim:schemas:core:2.0:Group. |
Get details about a group by displayName¶
- Method and endpoint:
GET /scim/v2/Groups?filter=displayName eq "{{group_name}}"- Description:
Returns details about a group associated with the
displayNamequery parameter.If the
MONITOR ROLEprivilege is granted to the SCIM provisioner, then the SCIM provisioner can see all groups in a Snowflake account, instead of only seeing groups owned by the SCIM provisioner.For example, to grant the
MONITOR ROLEprivilege to a SCIM provisioner, you can use the GRANT command:Returns the HTTP response status code
200if the HTTP request successfully completed.
Get details about a group by groupId¶
- Method and endpoint:
GET /scim/v2/Groups/{{group_id}}- Description:
Returns details about a group associated with the
group_idpath parameter.Returns the HTTP response status code
200if the HTTP request successfully completed.
List groups¶
- Method and endpoint:
GET /scim/v2/Groups- Description:
Returns a paginated list of groups (roles) in the account, optionally matching a filter.
If the
MONITOR ROLEprivilege is granted to the SCIM provisioner, then the SCIM provisioner can see all groups in a Snowflake account, instead of only seeing groups owned by the SCIM provisioner.For example, to grant the
MONITOR ROLEprivilege to a SCIM provisioner, you can use the GRANT command:Returns the HTTP response status code
200if the HTTP request successfully completed.Note
This endpoint’s behavior is controlled by the 2026_03 behavior change bundle. For rollout details, see SCIM: List API returns paginated results; unsupported filters rejected (Pending).
- Optional query parameters:
filter=displayName { eq | sw } "{displayName}"- eq:
Searches for a group with a name that matches the provided
displayNamevalue. The search matches both the exact value and its fully uppercased equivalent.Pagination query parameters, such as
startIndexandcount, are ignored when usingeq.Example: the following request finds a role named
ABC:- sw:
Searches for group names that start with the value provided for
displayName. The search is case-sensitive.Example: the following request finds roles starting with
ABC, such asABC_ADMINorABC_READER. Note thatsw "abc"would not match a role namedABC_ADMIN.
startIndexThe 1-based index of the first result to return. Values less than 1 are treated as 1. Non-numeric values return HTTP
400.Default:
1.Example: the following request returns a list of groups, skipping the first group:
countThe maximum number of groups returned per page. Negative values are treated as 0 (returns an empty
Resourcesarray). Values above 1000 are treated as 1000. Non-numeric values return HTTP400.Default:
100.Max:
1000.Example: the following request returns a list of groups, skipping the first group, with a maximum of 10 groups per page:
excludedAttributesExcludes the specified attributes from the response. Only
membersis supported, which omits the list of users that belong to each group. Other values are ignored.Example: the following request returns the first page of groups without their members returned:
Note
For accounts with large numbers of groups, specifying
excludedAttributescan significantly reduce response size and latency.- Limitations:
- Only the
displayNameattribute is supported for filtering. Filtering on other attributes returns an empty result set. - Only the
eqandswoperators are supported. Using an unsupported operator returns HTTP400with SCIM error typeinvalidFilter. - Compound filters using logical operators (
and,or) are not supported and return HTTP400with SCIM error typeinvalidFilter. - The
swoperator is case-sensitive for groups. - The
membersattribute for groups includes only users directly granted the role. Users who inherit the role through the role hierarchy are not included.
- Only the
- Response body objects:
itemsPerPageequals thecountvalue used for the query.totalResultsequalsstartIndex+countwhen more pages are available, or the total number of matching items when no more pages are available.Clients should check that the sum of
startIndexanditemsPerPageis less than or equal tototalCount.Clients should continue making requests until the sum of
startIndexanditemsPerPageis greater thantotalCount.See Group attributes for group attribute details.
- Examples:
An example response that returns a paginated list of groups, excluding their
membersattribute from the results:
Create a group¶
- Method and endpoint:
POST /scim/v2/Groups- Description:
Creates a new group in Snowflake.
Returns the HTTP response status code
201if the HTTP request successfully completed.- Examples:
Create a group with the
displayNamescim_test_group2:
Update a group¶
- Method and endpoint:
PATCH /scim/v2/Groups/{{group_id}}- Description:
Updates the display name attribute or group membership of the group associated with the
group_idpath parameter.You must set
optoaddorreplaceto perform this HTTP request.Returns a
200or204HTTP response status code if the HTTP request successfully completed. A200status code indicates the SCIM client is Okta.- Examples:
Update a group
displayName, remove a member and add a member:
Delete a group¶
- Method and endpoint:
DELETE /scim/v2/Groups/{{group_id}}- Description:
Deletes the group associated with the
group_idpath parameter.