Use this API request to edit user details. SCIM provides a rich patch specification based upon JSON Patch.

PATCH

/users

Operation parametersDetails
addWhether to add the attribute value
replaceWhether to replace the attribute value
removeWhether to remove the attribute value
Path parameterDetails
attributeThe attribute to apply the operation to.
Example: externalId
attributePath[filter].subattribute
where filter is [attribute op value]
The path signifies the target attribute to apply the operation to.
Example: name.givenName

Example: Add an entitlement to a user:

PATCH /Users/2819c223-7f76-453a-919d-413861904646 HTTP/1.1
Host: api.anaplan.com
Accept: application/scim+json
Content-Type: application/scim+json

{
 "schemas": [
   "urn:ietf:params:scim:api:messages:2.0:PatchOp"
 ],
 "Operations": [
   {
     "op": "add",
     "path": "entitlements",
     "value": [
       {
         "value": "2819c223-7f76-453a-919d-413861904646",
         "type": "WORKSPACE"
       }
     ]
   }
 ]
}

Example: Replace all entitlements of type WORKSPACE with a single workspace.

PATCH /Users/2819c223-7f76-453a-919d-413861904646 HTTP/1.1
Host: api.anaplan.com
Accept: application/scim+json
Content-Type: application/scim+json

{
 "schemas": [
   "urn:ietf:params:scim:api:messages:2.0:PatchOp"
 ],
 "Operations": [
   {
     "op": "replace",
     "path": "entitlements[type eq \"WORKSPACE\"]",
     "value": [
       {
         "value": "2819c223-7f76-453a-919d-413861904646",
         "type": "WORKSPACE"
       }
     ]
   }
 ]
}

Example: Remove all entitlements of type WORKSPACE:

PATCH /Users/2819c223-7f76-453a-919d-413861904646 HTTP/1.1
Host: api.anaplan.com
Accept: application/scim+json
Content-Type: application/scim+json

{
    "schemas": ["urn:ietf:params:scim:api:messages:2.0:PatchOp"],
    "Operations": [{
         "op": "remove",
         "path": "entitlements[type eq \"WORKSPACE\"]"]
}

Response

HTTP/1.1 200 OK
Content-Type: application/scim+json
Location: https://api.anaplan.com/scim/1/0/v2/Users/2819c223-7f76-453a-919d-413861904646

{
 "schemas": [
   "urn:ietf:params:scim:schemas:core:2.0:User"
 ],
 "id": "2819c223-7f76-453a-919d-413861904646",
 "externalId": "bjensen",
 "active": true,
 "meta": {
   "resourceType": "User",
   "created": "2011-08-01T21:32:44.882Z",
   "lastModified": "2011-08-01T21:32:44.882Z",
   "location": "https://api.anaplan.com/scim/1/0/v2/Users/2819c223-7f76-453a-919d-413861904646"
 },
 "name": {
   "formatted": "Barbara Jensen",
   "familyName": "Jensen",
   "givenName": "Barbara"
 },
 "displayName": "Barbara Jensen",
 "entitlements": [
   {
     "display": "Finance Workspace",
     "value": "6edb50156273d29050001",
     "type": "WORKSPACE",
     "primary": true
   },
   {
     "value": "6edb50156273d29050001",
     "type": "WORKSPACE_IDS"
   },
   {
     "value": "Finance Workspace",
     "type": "WORKSPACE_NAMES"
   }
 ]
}