PARTNERS - Please join us for our upcoming webinar:
Leveraging Intelligent Recommendations for Operational Transformation.
AMS Partners click HERE | EMEA/APJ Partners click HERE

accountIdPath in Create account JOSN for REST Connector

Rajesh_IAM
Regular Contributor
Regular Contributor

Hi All,

I am facing some issue with account Id Path in Create Account JSON for REST application.
Below is the API response for create account.

Rajesh_IAM_0-1702630572825.png

Now post account creation, we need to map this generated unique Id (response) to accountID attribute in user's account. I used below syntax, but its working as expected.
 "accountIdPath": "response.Message",

Could you please review API response and help me in accountIdPath issue.

12 REPLIES 12

Rajesh-R
Saviynt Employee
Saviynt Employee

@Rajesh_IAM  Could you try with:

 "accountIdPath": "call1.message",

 


Thanks
Rajesh Ramalingam
Saviynt India

Rajesh_IAM
Regular Contributor
Regular Contributor

@Rajesh-R , I tried above mentioned syntax, but still its not working. Post account creation, unique ID value was not mapped to accountID.

Rajesh_IAM_0-1702644173481.png

 

@Rajesh_IAM try below

"accountIdPath":"call1.message.response"


"CreateAccount.message.response"

 

"responseColsToPropsMap": {
"accountID": "CreateAccount.message.response~#~char"
},

Please share you createaccount ,if above are not working

 

Regards,
Sumathi Somala

If this reply answered your question, please Accept As Solution and give Kudos.

@SumathiSomala  Thank you for your response. I tried above mentioned ways, still its not working.

Below is the create account JSON:

{
"accountIdPath": "call1.message.response",
"responseColsToPropsMap": {
"accountID": "call1.message.response~#~char"
},
"call": [
{
"name": "call1",
"connection": "NexTra",
"url": "xxxxxxxxxxxxxxxxxxxxxx",
"httpMethod": "POST",
"httpHeaders": {
"Content-Type": "application/json",
"Accept": "application/json"
},
"httpParams": "{\"Email\":\"${user.customproperty32}\",\"DomainLogin\":\"xxxxx\\\\\\\\${user.customproperty30}\",\"FirstName\":\"${user.firstname}\",\"LastName\":\"${user.lastname}\",\"JobTitle\":\"${user.title}\"}",
"httpContentType": "application/json",
"successResponses": {
"statusCode": [
200,
201
]
},
"unsuccessResponses": {
"statusCode": [
400,
401,
405,
403,
500
]
}
}
]
}

Please review and help me to resolve this issue.

@Rajesh_IAM Could you please the postman response screenshot?

Regards,
Sumathi Somala

If this reply answered your question, please Accept As Solution and give Kudos.

@SumathiSomala Here is the API response screenshot.

Rajesh_IAM_0-1702976375269.png

 

@Rajesh_IAM did you try below

"accountIdPath": "call1.message",
"responseColsToPropsMap": {
},

 

Regards,
Sumathi Somala

If this reply answered your question, please Accept As Solution and give Kudos.

@SumathiSomala I tried above syntax, AccountID filed mapped with like below.

Rajesh_IAM_0-1702978066621.png

Here I need to keep only unique ID values and rest of the data should be removed. Do I need to use any string to remove unnecessary data here.?

@Rajesh_IAMtry below

"accountIdPath": "#CONST#${String acctId = response.call1.message.responseMessage; acctId = acctId.toString().replace('\"',''); return acctId}"

 Refer below forum thread,

Solved: [REST Connector] CreateAccountJson - remove specia... - Saviynt Forums - 35466

 

Regards,
Sumathi Somala

If this reply answered your question, please Accept As Solution and give Kudos.

Rajesh-R
Saviynt Employee
Saviynt Employee

@Rajesh_IAM - It seems your call name is different.

Try with the following:

 "accountIdPath": "CreateAccount.message",

Thanks
Rajesh Ramalingam
Saviynt India

rushikeshvartak
All-Star
All-Star

CreateAccount.message.response


Regards,
Rushikesh Vartak
If this helped you move forward, click 'Kudos'. If it solved your query, select 'Accept As Solution'.

@rushikeshvartak  Thank you for your response. I tried above mentioned ways, still its not working.

Below is the create account JSON:

{
"accountIdPath": "call1.message.response",
"responseColsToPropsMap": {
"accountID": "call1.message.response~#~char"
},
"call": [
{
"name": "call1",
"connection": "NexTra",
"url": "xxxxxxxxxxxxxxxxxxxxxx",
"httpMethod": "POST",
"httpHeaders": {
"Content-Type": "application/json",
"Accept": "application/json"
},
"httpParams": "{\"Email\":\"${user.customproperty32}\",\"DomainLogin\":\"xxxxx\\\\\\\\${user.customproperty30}\",\"FirstName\":\"${user.firstname}\",\"LastName\":\"${user.lastname}\",\"JobTitle\":\"${user.title}\"}",
"httpContentType": "application/json",
"successResponses": {
"statusCode": [
200,
201
]
},
"unsuccessResponses": {
"statusCode": [
400,
401,
405,
403,
500
]
}
}
]
}
Please review and help me to resolve this issue.