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

NOT ABLE TO PASS THE RESPONSE OF CALL1 in CALL2 URL

Aditya_R
New Contributor
New Contributor

Hello Everyone,

We were actually having a requirement where we have 2 URL's . The first URL is used to generate the sid which is valid till 1 hour and that sid is passed in 2nd URL, to recon accounts in IGA. In postman the first call is the POST call and the second call is the GET call.

I am attaching the ImportAccountENTJSON

{
"accountParams": {
"connection": "acctAuth",
"showLogs": true,
"createUsers": false,
"processingType": "SequentialAndIterative",
"statusAndThresholdConfig": {
"accountThresholdValue": 100,
"correlateInactiveAccounts": true,
"inactivateAccountsNotInFile": false
},
"call": {
"call1": {
"callOrder": 0,
"stageNumber": 0,
"http": {
"url": "URL 1 to generate sid",
"httpHeaders": {
"Authorization": "bearer",
"Accept": "*/*"
},
"httpParams": "search= | XYZ.csv",
"httpContentType": "text/plain",
"httpMethod": "POST"
}

},
"call2": {
"callOrder": 1,
"stageNumber": 0,
"http": {
"url": "URL to fetch accounts<sid from call1> URL",
"httpHeaders": {
"Authorization": "bearer",
"Accept": "*/*"
},
"httpContentType": "application/json",
"httpMethod": "GET"
},
"inputParams": {
"dependentCall": true
},
"listField": "results",
"keyField": "accountID",
"colsToPropsMap": {
"accountID": "userPrincipalName~#~char",
"name": "userPrincipalName~#~char",
"customproperty11": "last_usage~#~char"
},
"disableDeletedAccounts": false
}
}
}
}

 

 

POSTMAN - POST CALL BODY (CALL 1)

search= | ABC.csv

response - 

<?xml version="1.0" encoding="UTF-8"?>
<response>
    <sid>1234567890</sid>
</response>
 
POSTMAN CALL 2 ( GET)
"results": [
        {
            "last_usage": "2024-07-03",
            "userPrincipalName": "name_upn_of_the_user"
        },
 
When we run the importjob to import account for the above attached json we are getting this error 
Cannot invoke method trim() on null object
Can you please suggest few inputs on this issue ??
9 REPLIES 9

NM
Honored Contributor
Honored Contributor

Hi @Aditya_R , colstopropmapoing is required in accountentparam

Aditya_R
New Contributor
New Contributor

Hi @NM We had given colstopropmapping in the call1, But sid will be created under AccountID Keyfield and that will be imported in endpoint and there will be unnecessary entries coming in to account tab in the endpoint. We tried that approach but it did not work too.

Share that json with colsToPropsMap


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

{
"accountParams": {
"connection": "acctAuth",
"createUsers": true,
"adminName": "admin",
"processingType": "SequentialAndIterative",
"statusAndThresholdConfig": {
"deleteLinks": false,
"accountThresholdValue": 30,
"correlateInactiveAccounts": false,
"inactivateAccountsNotInFile": false,
"deleteAccEntForActiveAccounts": true
},
"call": {
"call1": {
"callOrder": 0,
"stageNumber": 0,
"http": {
"url": "URL to fetch sid",
"httpHeaders": {
"Authorization": "",
"Content-Type": "application/json"
},
"httpParams": "search=abc.csv",
"httpContentType": "application/json",
"httpMethod": "POST"
},
"listField": "response",
"keyField": "accountID",
"colsToPropsMap": {
"accountID":"sid~#~char",
"name": "sid~#~char"
},
"disableDeletedAccounts": true
},
"call2": {
"callOrder": 1,
"stageNumber": 1,
"http": {
"url": "URL{accountName}/results?output_mode=json",
"httpMethod": "GET",
"httpHeaders": {
"Authorization": "",
"Accept": "application/json"
},
"inputParams": {
"dependentCall": true
},
"httpContentType": "application/json",
"listField": "results",
"keyField": "accountID",
"colsToPropsMap": {
"accountID": "userPrincipalName~#~char",
"name": "userPrincipalName~#~char",
"customproperty11": "last_usage~#~char"
}
}
}
}
}
}

We were able to get sid from call1 can you please guide us on what to pass in call2 URL ?

Please share postman screenshot and curl command [Refer https://codingnconcepts.com/postman/how-to-generate-curl-command-from-postman/ ]



⚠️‼️‼️Do not upload any attachments that contain sensitive information, such as IP Addresses, URLs, Company/Employee Names, Email Addresses, etc.‼️‼️⚠️


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

Aditya_R_1-1722851918116.png

POST sid call

Try below

"listField": "results",
"keyField": "accountID",
"colsToPropsMap": {
"accountID": "{accountName}~#~char",
"name": "{accountName}~#~char",
"customproperty11": "last_usage~#~char"


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

Aditya_R_0-1722851759414.png

GET Accounts CALL

NM
Honored Contributor
Honored Contributor

Yes ..why haven't you defined the same in connection json??