-
Type:
Bug
-
Resolution: Timed out
-
Priority:
Low
-
Component/s: User Sync - SCIM Maintenance
-
1
-
Severity 3 - Minor
Issue Summary
Sending a PATCH request against a SCIM directory with a 'replace' Operation, that includes the emails field which is the same as the current state fails with the following error:
"status": "400",
"detail": "Resource [USER] One email address need to be marked as primary."
This is reproducible on Data Center: Not verified
Steps to Reproduce
With curl
curl --request PATCH \ --url 'https://api.atlassian.com/scim/directory/xxxxxxxxxxxxxxxxxx/Users/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx' \ --header 'Authorization: Bearer <token>' \ --header 'Accept: application/json' \ --header 'Content-Type: application/json' \ --data '{ "schemas":[ "urn:ietf:params:scim:api:messages:2.0:PatchOp" ], "Operations":[ { "op": "replace", "path": "active", "value": "true" }, { "op": "replace", "path": "emails", "value": [ { "value": "email@example.com", "primary": true } ] } ] }'
Send this to a user with is active:false and I get the following.
{"schemas":["urn:ietf:params:scim:api:messages:2.0:Error"],"status":"400","detail":"Resource [USER] One email address need to be marked as primary."}%
Expected Results
Sucess 200
Actual Results
Failed 400
{"schemas":["urn:ietf:params:scim:api:messages:2.0:Error"],"status":"400","detail":"Resource [USER] One email address need to be marked as primary."}%
Workaround
Use PUT command or not send the email attribute that has not changed.
- mentioned in
-
Page Loading...