SCIM
Overview:
(SCIM) - The System for Cross-domain Identity Management, is common standard protocol- allows for the automation of user provisioning.
Its intent is to reduce the cost and complexity of user management operations by providing a common user schema
Easy to move users in to, out of, and around the cloud.
SCIM can be used to manage users, groups
SCIM can help ensure that users can only access authorized resources.
SCIM can be used to deactivate accounts immediately
Key Highlights of the SCIM:
SCIM API Integration: Full compliance with SCIM 2.0 specification (RFC 7644) for seamless user and group provisioning.
User Lifecycle Management: Ability to create, modify, retrieve, and delete users via SCIM API.
Group Management: Full support for group creation, modification, and group and member management.
Bulk Upload Operation: Added support for bulk user and group operations, allowing administrators to provision or update large sets of users and groups in a single API call.
PATCH Operation Support: Implemented PATCH operations for partial updates to both users and groups. Efficiently update specific attributes without needing to send the entire resource payload, improving performance and flexibility in user management.
SCIM Discovery: Skillmine Auth implements SCIM discovery endpoints, allowing client applications to retrieve metadata about supported resources.
Enhanced Security: SCIM endpoints are secured with OAuth 2.0 tokens, ensuring safe and secure communication between Skillmine Auth and identity providers.
Operations
For manipulation of resources, SCIM provides a REST API with a rich but simple set of operations, which support everything from patching a specific attribute on a specific user to doing massive bulk updates:
Create: POST https://api-base-url.com/scim/v2/{resource}
Read: GET https://api-base-url.com/scim/v2/{resource}/{id}
Replace: PUT https://api-base-url.com/scim/v2/{resource}/{id}
Delete: DELETE https://api-base-url.com/scim/v2/{resource}/{id}
Update: PATCH https://api-base-url.com/scim/v2/{resource}/{id}
Search: GET https://api-base-url.com/scim/v2/{resource}?filter={attribute}{op}{value}&sortBy={attributeName}&sortOrder={ascending|descending}
Bulk: POST https://api-base-url.com/scim/v2/Bulk
Discovery
To simplify interoperability, SCIM provides three end points to discover supported features and specific attribute details:
GET https://api-base-url.com/scim/v2/ServiceProviderConfig
Specification compliance, authentication schemes, data models.
GET https://api-base-url.com/scim/v2/ResourceTypes
An endpoint used to discover the types of resources available.
GET https://api-base-url.com/scim/v2/Schemas
Introspect resources and attribute extensions.
To create the SCIM related schema in the Skillmine Auth, refer to the link https://authdocs.skill-mine.com/licentio-documentation/settings/schemas
SCIM Flow Mapping
Navigate to Admin Side Menu > Settings > SCIM Settings.
In this section, you will map the SCIM flow for user onboarding. Select the appropriate flow that suits your requirements for user creation.
Attribute Mapping
Next, map the SCIM attributes to the corresponding Skillmine Auth attributes.
There are two resource types: User and Enterprise User.
Depending on the type of user you are creating, choose the appropriate resource type.
Ensure the correct mapping of attributes between SCIM and Skillmine Auth for proper functionality.
SCIM User Schema
The following SCIM User schema defines the structure for all user operation requests and responses.
For all SCIM API requests, you need to include the Skillmine Auth token in the request header. For example, the header key should be 'Authorization' with the value 'Bearer <access_token>'.
Create User
Read User
Update User
Delete User
Sample SCIM Error Response
Here are the common HTTP status codes used in SCIM responses for user-related operations, along with descriptions:
1. 200 OK
Description: The request was successful, and the response body contains the representation of the requested resource (e.g., user details). This status code is typically returned for GET requests or successful PATCH/PUT updates.
Example: A successful user retrieval (GET) or update (PUT/PATCH).
2. 201 Created
Description: The resource (e.g., user) has been successfully created. This status code is typically returned for POST requests that create a new user.
Example: A new user was successfully created via a POST request.
3. 204 No Content
Description: The request was successful, but there is no content to return in the response body. This is commonly returned for DELETE requests or for operations that do not require a body in the response.
Example: A user was successfully deleted via a DELETE request.
4. 400 Bad Request
Description: The request is malformed or missing required parameters, and the server is unable to process it. This status code is returned when the request does not adhere to SCIM standards.
Example: Missing required attributes in the user creation request (e.g., missing
userName
or invalidemail
format).
5. 401 Unauthorized
Description: The request lacks valid authentication credentials. The client must authenticate itself to get the requested response.
Example: Missing or invalid
Authorization
header (Bearer token).
6. 403 Forbidden
Description: The server understands the request, but the client does not have permission to access the resource. This is returned when the client is authenticated but does not have the necessary authorization.
Example: A user without proper admin permissions attempting to modify another user's data.
7. 404 Not Found
Description: The requested resource could not be found. This is returned when trying to retrieve or operate on a user that does not exist.
Example: Trying to retrieve a non-existing user by ID.
8. 409 Conflict
Description: The request could not be completed due to a conflict with the current state of the resource. This is typically used when trying to create a user that already exists or when there are conflicts in the data.
Example: Trying to create a user with an existing
userName
.
9. 422 Unprocessable Entity
Description: The server understands the request but is unable to process it due to semantic errors. This is typically returned for validation issues, such as an invalid email format or missing required fields.
Example: A user creation request with invalid email format or missing mandatory attributes like
userName
.
10. 500 Internal Server Error
Description: The server encountered an unexpected condition that prevented it from fulfilling the request. This is a generic error indicating an issue on the server side.
Example: Server error during user creation or retrieval.
11. 503 Service Unavailable
Description: The server is currently unable to handle the request due to temporary overloading or maintenance. This indicates that the service is temporarily unavailable.
Example: Temporary server issues or maintenance window for SCIM services.
Last updated