/scim/Users
Allows you to create a user or get a list of users.
Prerequisite - x-csrf-token
You must get a x-csrf-token and include it in the header of every POST, PUT, PATCH or DELETE request.
For more information, see Valid CSRF Token.
GET /api/v1/scim/Users
-
HTTP Headers:
-
Authorization: Bearer <access_token>
-
x-sap-sac-custom-auth: true
-
Optional: x-csrf-token: <fetch>
-
-
URL Parameters:
-
(Optional) startIndex: the index of the first user to fetch. For example, if the start index is set to 10, the tenth user will be the first user returned.
-
(Optional) count: the number of users to return on each page.
-
(Optional) filter=<attribute>: adds a filter to the request.
Supported Attributes:-
username
-
email
Supported Operators:-
And
-
Or
-
Not
-
Eq
-
Ne
-
Co
-
Sw
-
Ew
-
-
-
Request Body: None
Example GET request: <TENANT_URL>/api/v1/scim/Users?filter=username eq "abcUser"
|
Response |
Example Response |
|---|---|
Format: application/json |
{
"schemas": [
"urn:ietf:params:scim:api:messages:2.0:ListResponse"],
"totalResults": 123,
"itemsPerPage": 10,
"startIndex": 1,
"Resources": [{<User Schema>}, ...]
}
|
POST /api/v1/scim/Users
Creates a user based on the information provided.
-
HTTP Headers:
-
Authorization: Bearer <access_token>
-
x-csrf-token: <csrf_token>
-
x-sap-sac-custom-auth: true
-
-
Parameters: None
-
Request Body: User Schema
The following example schema creates a new user:{ "schemas": [ "urn:sap:params:scim:schemas:extension:sac:2.0:user-custom-parameters", "urn:ietf:params:scim:schemas:core:2.0:User", "urn:ietf:params:scim:schemas:extension:enterprise:2.0:User", "urn:ietf:params:scim:schemas:extension:sap:2.0:User" ], "userName":"<user@email.com>", "name": { "givenName":"<User_Given_Name>", "familyName":"<User_Family_Name>" }, "displayName":"<User_Display_Name>", "emails":[ { "value":"<user@email.com>", "type":"work", "primary":true } ], "roles":[], "groups":[], "urn:ietf:params:scim:schemas:extension:enterprise:2.0:User": { "manager": { "managerId": "" } }, "urn:ietf:params:scim:schemas:extension:sap:2.0:User": { "userUuid": "<Global_User_ID>" } }For information on role assignment, see Assigning Roles to Users and Groups. For information on additional parameter options, see Optional User Parameters.
|
Response |
Example Response |
|---|---|
Format: application/scim+json (User Schema) |
The response should include the user information you provided. {
"schemas": [ "urn:sap:params:scim:schemas:extension:sac:2.0:user-custom-parameters",
"urn:ietf:params:scim:schemas:core:2.0:User",
"urn:ietf:params:scim:schemas:extension:enterprise:2.0:User",
"urn:ietf:params:scim:schemas:extension:sap:2.0:User"
}
],
"userName": "test.user@email.com",
"id": "TESTUSER",
"preferredLanguage": "en",
"meta": {
"created": "2017-09-06T21:22:26.258Z",
"location": "/api/v1/scim/Users/TESTUSER",
"resourceType": "User"
},
"name": {
"givenName": "Test",
"familyName": "User"
},
"displayName": "Test User",
"active": true,
"emails": [
{
"value": "test.user@email.com",
"type": "work",
"primary": true
}
],
"photos": [
{
"value": "https://myphotos.com/profile.png",
"type": "photo"
}
],
"roles": [
"PROFILE:sap.epm:Admin"
],
"groups": [],
"urn:ietf:params:scim:schemas:extension:sap:user-custom-parameters:1.0": {
"dataAccessLanguage": "en",
"dateFormatting": "MMM d, yyyy",
"timeFormatting": "H:mm:ss",
"numberFormatting": "1,234.56",
"cleanUpNotificationsNumberOfDays": 0,
"systemNotificationsEmailOptIn": true,
"marketingEmailOptIn": false
},
"urn:scim:schemas:extension:enterprise:1.0": {
"manager": {
"managerId": ""
}
},
"urn:ietf:params:scim:schemas:extension:sap:2.0:User": {
"userUuid": "108e42ab-b573-4c0d-23d8-da6978ac04x8"
}
}
|