cURL
curl --request PATCH \
--url https://cockroachlabs.cloud/api/scim/v2/Users/{id} \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--json '{"Operations":[{"op":"replace","path":"userName","value":"newUserName"},{"op":"replace","value":{"displayName":"New Name","emails":[{"primary":true,"value":"new@example.com"}]}},{"op":"remove","path":"externalId"}],"schemas":["urn:ietf:params:scim:api:messages:2.0:PatchOp"]}'{
"id": "<string>",
"schemas": [
"<string>"
],
"active": true,
"displayName": "<string>",
"emails": [
{
"value": "<string>",
"display": "<string>",
"primary": true,
"type": "<string>"
}
],
"externalId": "<string>",
"groups": [
{
"display": "<string>",
"ref": "<string>",
"type": "<string>",
"value": "<string>"
}
],
"meta": {
"created": "<string>",
"lastModified": "<string>",
"location": "<string>",
"resourceType": "<string>"
},
"name": {
"familyName": "<string>",
"givenName": "<string>"
},
"userName": "<string>"
}{
"code": 123,
"details": [
{
"@type": "<string>"
}
],
"message": "<string>"
}Apply a sequence of operations to modify attributes of a SCIM User resource. Supports ‘add’, ‘remove’, and ‘replace’ operations per RFC 7644 Section 3.5.2. Operations are applied atomically — if any operation fails, no changes are applied. The request body must include the ‘schemas’ field set to ‘urn:ietf:params:scim:api:messages:2.0:PatchOp’.
Can be used by the following roles assigned at the organization scope:
- ORG_ADMIN
PATCH
/
api
/
scim
/
v2
/
Users
/
{id}
cURL
curl --request PATCH \
--url https://cockroachlabs.cloud/api/scim/v2/Users/{id} \
--header 'Authorization: Bearer REPLACE_BEARER_TOKEN' \
--json '{"Operations":[{"op":"replace","path":"userName","value":"newUserName"},{"op":"replace","value":{"displayName":"New Name","emails":[{"primary":true,"value":"new@example.com"}]}},{"op":"remove","path":"externalId"}],"schemas":["urn:ietf:params:scim:api:messages:2.0:PatchOp"]}'{
"id": "<string>",
"schemas": [
"<string>"
],
"active": true,
"displayName": "<string>",
"emails": [
{
"value": "<string>",
"display": "<string>",
"primary": true,
"type": "<string>"
}
],
"externalId": "<string>",
"groups": [
{
"display": "<string>",
"ref": "<string>",
"type": "<string>",
"value": "<string>"
}
],
"meta": {
"created": "<string>",
"lastModified": "<string>",
"location": "<string>",
"resourceType": "<string>"
},
"name": {
"familyName": "<string>",
"givenName": "<string>"
},
"userName": "<string>"
}{
"code": 123,
"details": [
{
"@type": "<string>"
}
],
"message": "<string>"
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Body
application/json
Response
A successful response.

