Leveraging Intelligent Recommendations for Operational Transformation. AMS Partners click HERE | EMEA/APJ Partners click HERE |
02/01/2024 12:36 PM
Hello,
We are using this as create Account JSON in our Saviynt connection form, but we get the following error when it is executed.
Create account JSON
{
"accountIdPath": "call1.message.id",
"call": [
{
"name": "call1",
"connection": "acctAuth",
"url": "https://{{serverName}}/api/DataManagement/ExecuteSequence?api-version={{version}}",
"httpMethod": "POST",
"httpParams": "{\"BaseWebServerUrl\": \"https://<...........>\",\"ApplicationName\": \"<app name>\",\"SequenceName\": \"REST_CreateProvisionRequest_PRM\",\"CustomSubstVarsAsCommaSeparatedPairs\": \"PRM_REST_Type\"=\"AddUser\", \"PRM_REST_Inputs\"=[\"UserName\"=\"TestSaviynt\", \"Email\"=\"TestSaviynt@test.user\", \"ExternalAuthProviderName\"=\"<.....>\"], \"PRM_REST_Source\"=\"REST\",\"PRM_REST_RequestSource=REST\"}",
"httpHeaders": {
"Authorization": "${access_token}"
},
"httpContentType": "application/json",
"successResponses": {
"statusCode": [
200,
201,
204
]
},
"unsuccessResponses": {
"statusCode": [
302,
400,
403,
401,
404,
501,
500
]
}
}
]
}
Error
{"auditDetails":{"call1":[{"message":"Unexpected character ('=' (code 61)): was expecting comma to separate Array entries\n at
[Source: {\"BaseWebServerUrl\": \"https://<.......>\",\"ApplicationName\": \"<app name>\",\"SequenceName\":
\"REST_CreateProvisionRequest_PRM\",\"CustomSubstVarsAsCommaSeparatedPairs\": [\"PRM_REST_Type\"=\"AddUser\", \"PRM_REST_Inputs\"=[\"UserName\"=\"TestSaviynt\",
"Email\"=\"TestSaviynt@test.user\", \"ExternalAuthProviderName\"=\"<......>\"], \"PRM_REST_Source\"=\"REST\",\" PRM_REST_RequestSource=REST\"\"]}; line: 1, column: 226]",
"status":"Failed"},
{"message":"Unexpected character ('=' (code 61)): was expecting comma to separate Array entries\n at
[Source: {\"BaseWebServerUrl\": \"<.........>\",\"ApplicationName\": \"<app name>\",\"SequenceName\":
\"REST_CreateProvisionRequest_PRM\",\"CustomSubstVarsAsCommaSeparatedPairs\": [\"PRM_REST_Type\"=\"AddUser\", \"PRM_REST_Inputs\"=[\"UserName\"=\"TestSaviynt\",
\"Email\"=\"TestSaviynt@test.user\", \"ExternalAuthProviderName\"=\"<.......>\"], \"PRM_REST_Source\"=\"REST\",\" PRM_REST_RequestSource=REST\"\"]}; line: 1, column: 226]",
"status":"Failed"},
{"message":"Unexpected character ('=' (code 61)): was expecting comma to separate Array entries\n at
[Source: {\"BaseWebServerUrl\": \"<........>\",\"ApplicationName\": \"<........>\",\"SequenceName\":
\"REST_CreateProvisionRequest_PRM\",\"CustomSubstVarsAsCommaSeparatedPairs\": [\"PRM_REST_Type\"=\"AddUser\", \"PRM_REST_Inputs\"=[\"UserName\"=\"TestSaviynt\",
\"Email\"=\"TestSaviynt@test.user\", \"ExternalAuthProviderName\"=\"<.......>\"], \"PRM_REST_Source\"=\"REST\",\" PRM_REST_RequestSource=REST\"\"]}; line: 1, column: 226]",
"status":"Failed"}]},
"call1":{"message":"Unexpected character ('=' (code 61)): was expecting comma to separate Array entries\n at [Source: {\"BaseWebServerUrl\":
\"<...........>\",\"ApplicationName\": \"<app name>\",\"SequenceName\": \"REST_CreateProvisionRequest_PRM\",
\"CustomSubstVarsAsCommaSeparatedPairs\": [\"PRM_REST_Type\"=\"AddUser\", \"PRM_REST_Inputs\"=[\"UserName\"=\"TestSaviynt\", \"Email\"=\"TestSaviynt@test.user\",
\"ExternalAuthProviderName\"=\"<........>\"], \"PRM_REST_Source\"=\"REST\",\" PRM_REST_RequestSource=REST\"\"]}; line: 1, column: 222]","status":"Failed"}}
Q1) Looking at this create account JSON and the error we get, could you please help us understand where we might be wrong?
02/01/2024 08:53 PM
{
"accountIdPath": "call1.message.id",
"call": [
{
"name": "call1",
"connection": "acctAuth",
"url": "https://cddd.com/api/DataManagement/ExecuteSequence?api-version=11111",
"httpMethod": "POST",
"httpParams": "{\"BaseWebServerUrl\": \"https://<...........>\",\"ApplicationName\": \"<app name>\",\"SequenceName\": \"REST_CreateProvisionRequest_PRM\",\"CustomSubstVarsAsCommaSeparatedPairs\": \"PRM_REST_Type\"=\"AddUser\", \"PRM_REST_Inputs\"=[\"UserName\"=\"TestSaviynt\", \"Email\"=\"TestSaviynt@test.user\", \"ExternalAuthProviderName\"=\"<.....>\"], \"PRM_REST_Source\"=\"REST\",\"PRM_REST_RequestSource=REST\"}",
"httpHeaders": {
"Authorization": "${access_token}"
},
"httpContentType": "application/json",
"successResponses": {
"statusCode": [200, 201, 204]
},
"unsuccessResponses": {
"statusCode": [302, 400, 403, 401, 404, 501, 500]
}
}
]
}
02/02/2024 09:28 AM
Hello,
Thank you for your response.
I did check the JSON provided above but it is exactly similar to the one we had submitted which gave us the following error.
ERROR
{"auditDetails":{"call1":[{"message":"Unexpected character ('=' (code 61)): was expecting comma to separate Array entries\n at
[Source: {\"BaseWebServerUrl\": \"https://<.......>\",\"ApplicationName\": \"<app name>\",\"SequenceName\":
\"REST_CreateProvisionRequest_PRM\",\"CustomSubstVarsAsCommaSeparatedPairs\": [\"PRM_REST_Type\"=\"AddUser\", \"PRM_REST_Inputs\"=[\"UserName\"=\"TestSaviynt\",
"Email\"=\"TestSaviynt@test.user\", \"ExternalAuthProviderName\"=\"<......>\"], \"PRM_REST_Source\"=\"REST\",\" PRM_REST_RequestSource=REST\"\"]}; line: 1, column: 226]",
"status":"Failed"},
Could you please review the error we are encountering and help us understand where we might be wrong?
Thank you.
02/02/2024 07:37 PM
Provide postman screenshot
02/05/2024 08:56 AM
Hello, thank you for your response. Please find attached the screenshot from Postman for Create account.
02/05/2024 07:09 PM
Don't escape parameters from CustomSubstVarsAsCommaSeparatedPairs
{
"BaseWebServerUrl": "https://<.......>",
"ApplicationName": "<app name>",
"SequenceName": "REST_CreateProvisionRequest_PRM",
"CustomSubstVarsAsCommaSeparatedPairs": [
"PRM_REST_Type=AddUser",
"PRM_REST_Inputs=[\"UserName\"=\"TestSaviynt\", \"Email\"=\"TestSaviynt@test.user\", \"ExternalAuthProviderName\"=\"<......>\"]",
"PRM_REST_Source=REST",
"PRM_REST_RequestSource=REST"
]
}