Click HERE to see how Saviynt Intelligence is transforming the industry. |
01/31/2024 06:04 AM - last edited on 01/31/2024 10:28 PM by Sunil
Hi team,
I'm trying to create an account for rest connection and error. Please refer below JSON and error details.
Create Account JSON 1:
{
"accountIdPath": "call1.message.values.PeopleSyncID",
"dateFormat": "yyyy-MM-dd'T'HH:mm:ssXXX",
"responseColsToPropsMap": {
"accountID": "call1.message.values.PeopleSyncID~#~char"
},
"call": [
{
"name": "call1",
"connection": "acctAuth",
"url": "https://URL/api/arsys/v1/entry/ACE:SYNC:PPL:Staging ",
"httpMethod": "POST",
"httpParams": "{\"values\": {\"CorporateID\": \"${user.employeenumber}\", \"Source_Sync_Key\":\"${user.employeeid}\", \"RemedyLoginID\": \"${user.username}\", \"FirstName\":\"${user.firstname}\", \"LastName\": \"${user.lastname}\"}}",
"httpHeaders": {
"Authorization": "AR-JWT ${access_token}"
},
"httpContentType": "application/json",
"successResponses": {
"statusCode": [
200,
201,
204,
205
]
},
"unsuccessResponses": {
"error.message": [
"Operation Failed"
],
"statusCode": [
400,
403,
401,
404,
409,
501,
500
]
}
}
]
}
Error:
call1":{"headers":{"X-Content-Type-Options":"nosniff","Connection":"keep-alive","Date":"Wed, 31 Jan 2024 13:57:15 GMT","X-Frame-Options":"SAMEORIGIN","Referrer-Policy":"strict-origin-when-cross-origin","Strict-Transport-Security":"max-age=31536000; includeSubDomains","Cache-Control":"must-revalidate,no-cache,no-store","Content-Security-Policy":"frame-ancestors 'self'","Content-Length":"622","X-XSS-Protection":"1; mode=block","Content-Type":"text/html;charset=iso-8859-1"},"message":{"html":{"head":{"meta":{"http-equiv":"Content-Type","content":"text/html;charset=ISO-8859-1"},"title":"Error 400 [ERROR (149): A user name must be supplied in the control record]"},"body":{"h2":"HTTP ERROR 400 [ERROR (149): A user name must be supplied in the control record]","table":{"tr":[{"td":"/api/arsys/v1/entry/ACE:SYNC:PPL:Staging","th":"URI:"},{"td":400,"th":"STATUS:"},{"td":"[ERROR (149): A user name must be supplied in the control record]","th":"MESSAGE:"},{"td":"org.eclipse.equinox.http.servlet.HttpServiceServlet-9b76b60","th":"SERVLET:"}]}}}},"statusCode":400,"description":null,"status":"Failed"}}
Create Account JSON 2:
{
"call": [
{
"name": "call1",
"connection": "acctAuth",
"url": "https://removed-restapi.onbmc.com/api/arsys/v1/entry/ACE:SYNC:PPL:Staging ",
"httpMethod": "PATCH",
"httpParams": "{\"values\": {\"CorporateID\": \"${user.employeenumber}\", \"Source_Sync_Key\":\"${user.employeeid}\", \"RemedyLoginID\": \"${user.username}\", \"FirstName\":\"${user.firstname}\", \"LastName\": \"${user.lastname}\"}}",
"httpHeaders": {
"Authorization": "AR-JWT ${access_token}"
},
"httpContentType": "application/json",
"successResponses": {
"statusCode": [
200,
201,
204,
205
]
}
}
]
}
Error:
call1":{"headers":{"X-Frame-Options":"SAMEORIGIN","Referrer-Policy":"strict-origin-when-cross-origin","Strict-Transport-Security":"max-age=31536000; includeSubDomains","X-Content-Type-Options":"nosniff","Content-Security-Policy":"frame-ancestors 'self'","Connection":"keep-alive","Content-Length":"0","X-XSS-Protection":"1; mode=block","Date":"Wed, 31 Jan 2024 14:03:29 GMT"},"message":"","statusCode":400,"description":null,"status":"Failed"}}
[This message has been edited by moderator to disable URL hyperlink]
01/31/2024 08:47 AM
Does it work from postman?
01/31/2024 07:51 PM
Enable debug logs in configJSON showlogs = true and share log file also share postman screenshot