on 06/26/2023 09:46 AM
While trying to perform a provisioning for creating an account on Azure AD, the request fails. This issue was caused due to usage of incorrect JSON.
[quartzScheduler_Worker-8] DEBUG rest.RestProvisioningService - Error WebService call failed After retrying 5 times with responseStatusCode-401, Failed url-https://graph.microsoft.com/v1.0/users, Error Message - {
"error": {
"code": "InvalidAuthenticationToken",
"message": "CompactToken parsing failed with error code: 80049217",
"innerError": {
"date": "2020-08-21T00:19:05",
"request-id": "4d5dc085-8b73-4fef-97fd-1fb2a55fbda8"
}
}
}
Update the connection Json as follows :
{
"authentications": {
"userAuth": {
"authType": "oauth2",
"url": "https://xxxxxxxxxxxx/oauth2/token",
"httpMethod": "POST",
"httpParams": {
"grant_type": "client_credentials",
"client_secret": "xxxxxxxxxx",
"client_id": "xxxxxxxxxx",
"resource": "https://graph.microsoft.com/"
},
"httpHeaders": {
"contentType": "application/x-www-form-urlencoded"
},
"httpContentType": "application/x-www-form-urlencoded",
"expiryError": "ExpiredAuthenticationToken",
"authError": [
"InvalidAuthenticationToken"
],
"timeOutError": "Read timed out",
"errorPath": "error.code",
"maxRefreshTryCount": 5,
"tokenResponsePath": "access_token",
"retryFailureStatusCode": [
401
],
"tokenType": "Bearer",
"accessToken": "Bearer abc"
}
}
}