Hello team,
I’m trying to update an account attribute through API, but I’m getting an error that I could not resolve.
Here is how I did the test (I replaces ids with “–” for security purposes) :
- Get request on the account:
{
"authoritative": false,
"systemAccount": false,
"uncorrelated": false,
"features": "DISCOVER_SCHEMA, PASSWORD, ENABLE, PROVISIONING, SYNC_PROVISIONING",
"uuid": null,
"nativeIdentity": "--",
"description": null,
"disabled": false,
"locked": false,
"manuallyCorrelated": true,
"hasEntitlements": true,
"sourceId": "--",
"sourceName": Asana,
"identityId": "--",
"attributes": {
"name.familyName": "Wyguvi",
"IIQDisabled": false,
"name.formatted": "Bamij Wyguvi",
"name.givenName": "Bamij",
"active": true,
"id": "--",
"department": "--",
"emails.work.primary.value": "[email protected]",
"userName": "[email protected]",
"idNowDescription": "--"
},
"id": "cbfdc42043cb4d21bfe69aabc173216f",
"name": "Bamij Wyguvi",
"created": "2023-02-20T23:06:06.103Z",
"modified": "2023-02-21T23:03:48.869Z"
}
- PUT request on this account to change the attribute (“attributes/active” from true to false)
curl -L -X PUT 'https://tenant.api.identitynow.com/v3/accounts/cbfdc42043cb4d21bfe69aabc173216f' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer ...' \
--data-raw '{
"attributes": {
"name.familyName": "Wyguvi",
"IIQDisabled": false,
"name.formatted": "Bamij Wyguvi",
"name.givenName": "Bamij",
"active": false,
"id": "--",
"department": "--",
"emails.work.primary.value": "[email protected]",
"userName": "[email protected]",
"idNowDescription": "--"
}
}'
And I get the following error:
{
"detailCode": "400.1 Bad request content",
"trackingId": "--",
"messages": [
{
"locale": "en-US",
"localeOrigin": "DEFAULT",
"text": "The request was syntactically correct but its content is semantically invalid."
},
{
"locale": "fr-FR",
"localeOrigin": "REQUEST",
"text": "La requête était syntaxiquement correcte mais son contenu est sémantiquement invalide."
}
],
"causes": []
}
Can you please help me on this issue, Thanks.