Announcing the Saviynt Knowledge Exchange unifying the Saviynt forums, documentation, training,
and more in a single search tool across platforms. Read the announcement here.

Responsestatuscode 400 erro while performing Rest API for Azure AD

Kirti14
New Contributor
New Contributor

I was trying to perform importuserjson for member account for Azure AD connection and faced 400 authentication error. 
Even in postman status code is fine but facing issue on saviynt side.

Connection Json:
{
"authentications": {
"AzureADProvisioning": {
"authType": "oauth2",
"url": "https://login.microsoftonline.com/xxxxyyyyddddsd/oauth2/v2.0/token",
"httpMethod": "POST",
"httpParams": {
"grant_type": "client_credentials",
"client_secret": "xxxxyyxx",
"client_id": "xxxxxxx",
"scope": "https://graph.microsoft.com/.default"
},
"httpHeaders": {
"contentType": "application/x-www-form-urlencoded"
},
"httpContentType": "application/x-www-form-urlencoded",
"expiryError": "ExpiredAuthenticationToken",
"authError": [
"InvalidAuthenticationToken"
],
"retryFailureStatusCode": [
401
],
"timeOutError": "Read timed out",
"errorPath": "error.code",
"maxRefreshTryCount": 5,
"tokenResponsePath": "access_token",
"tokenType": "Bearer",
"accessToken": "Bearer abcd"
}

}
}

 

 

IMport userjson :

{
"name": "call1",
"connection": "AzureADProvisioning",
"url": "https://graph.microsoft.com/v1.0/users/$filter=userType+eq+'Member'&$select=id,accountEnabled,userty...",
"httpMethod": "GET",
"httpHeaders": {
"Authorization": "${access_token}",
"Accept": "application/json"
},
"statusConfig": {
"active": "true",
"inactive": "false"
},
"colsToPropsMap": {
"customproperty3": "userPrincipalName~#~char",
"customproperty25": "accountEnabled~#~char",
"customproperty26": "createdDateTime~#~date",
"customproperty29": "lastPasswordChangeDateTime~#~date",
"username": "onPremisesExtensionAttributes.extensionAttribute6~#~char",
"email": "mail~#~char"

},
"userResponsePath": "value",
"pagination": {
"nextUrl": {
"nextUrlPath": "${(response?.completeResponseMap?.get('@odata.nextLink')==null)? null : response?.completeResponseMap?.get('@odata.nextLink')}"
}
}
}

 

 

ON the postman side these values were passed :

Kirti14_0-1711452173810.png

Logs:

I am getting 400 response status code:

Kirti14_1-1711452862814.png

 

 

Kirti14_2-1711452900956.png

 

 

@PLease help me out.

 

 

 

1 REPLY 1

rushikeshvartak
All-Star
All-Star

Share logs in file by enabling showlogs =true


Regards,
Rushikesh Vartak
If you find the response useful, kindly consider selecting Accept As Solution and clicking on the kudos button.