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

REST Account Import Error-Pagination(Offset)

Puspanjali
New Contributor
New Contributor

 

Hi Team,

I'm trying to import the account from the target application while importing I'm facing the below error

Error from Run History

Puspanjali_0-1666938865217.png

Error from logs

 

[quartzScheduler_Worker-13] DEBUG integration.ExternalConnectionCallService  - Key=fullorincremental Value=full
2022-10-28 05:31:47,208 [quartzScheduler_Worker-13] DEBUG integration.ExternalConnectionCallService  - Key=incrementalenddatetime Value=
2022-10-28 05:31:47,210 [quartzScheduler_Worker-13] DEBUG services.ImportUtilityService  - Endpoint 'SalesAPI_REST' found for the Security System 'SalesAPI_REST' with Endpointkey: 127
2022-10-28 05:31:47,210 [quartzScheduler_Worker-13] DEBUG integration.ExternalConnectionCallService  - *******endpoint=SalesAPI_REST and secSystem=SalesAPI_REST******************
2022-10-28 05:31:47,211 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Job Type : full
2022-10-28 05:31:47,211 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Import-Type : accounts
2022-10-28 05:31:47,211 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - connectionid: 58
2022-10-28 05:31:47,211 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Loading Start for Security System - SalesAPI_REST
2022-10-28 05:31:47,211 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Finding Endpoint for the security System - SalesAPI_REST
2022-10-28 05:31:47,212 [quartzScheduler_Worker-13] DEBUG services.ImportUtilityService  - Endpoint 'SalesAPI_REST' found for the Security System 'SalesAPI_REST' with Endpointkey: 127
2022-10-28 05:31:47,251 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - processAccountsFullBySequentialAndIterative - params.origParams.stageNumber : null
2022-10-28 05:31:47,251 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - callStageNumber : 0
2022-10-28 05:31:47,251 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - callStageNumber: 0
2022-10-28 05:31:47,251 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - stageNumber: null
2022-10-28 05:31:47,251 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - processAccountsFullBySequentialAndIterative - Not Multitrigger call
2022-10-28 05:31:47,251 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Inside processAccountsFinal.
2022-10-28 05:31:47,252 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Inside processAccounts.
2022-10-28 05:31:47,464 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Inside pullObjectsByRest
2022-10-28 05:31:47,464 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  -
2022-10-28 05:31:47,464 [quartzScheduler_Worker-13] DEBUG services.HttpClientUtilityService  - isFipsEnabled = false
2022-10-28 05:31:47,464 [quartzScheduler_Worker-13] DEBUG services.HttpClientUtilityService  - getHttpClient - sslParams : null
2022-10-28 05:31:47,464 [quartzScheduler_Worker-13] DEBUG services.HttpClientUtilityService  - getHttpClient - proxyParams : null
2022-10-28 05:31:47,464 [quartzScheduler_Worker-13] DEBUG services.HttpClientUtilityService  - getHttpClient - sslSocketFactory : null
2022-10-28 05:31:47,469 [quartzScheduler_Worker-13] DEBUG services.HttpClientUtilityService  - getHttpClient - HttpClientBuilder.create().build() called.
2022-10-28 05:31:47,543 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  -
2022-10-28 05:31:47,543 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - pullObjectsByRest - responseStatusCode ::200
2022-10-28 05:31:47,544 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Entered getResponseHeaders method
2022-10-28 05:31:47,544 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - responseError : null
2022-10-28 05:31:47,544 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - isAuthError: true
2022-10-28 05:31:47,544 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Access token expired. throwing null / [] exception for retry
2022-10-28 05:31:47,547 [quartzScheduler_Worker-13] ERROR rest.RestProvisioningService  - Exception in pullObjectsByRest :Ambiguous method overloading for method java.lang.Exception#<init>.
Cannot resolve which method to invoke for [null] due to overlapping prototypes between:
  [class java.lang.Throwable]
  [class java.lang.String]
2022-10-28 05:31:47,549 [quartzScheduler_Worker-13] ERROR rest.RestProvisioningService  - Inside token Expiry Exception block. connectionParamMap.refreshTryCount : 0
2022-10-28 05:31:47,549 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Incrementing connectionParamMap.refreshTryCount : 1
2022-10-28 05:31:47,549 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - maxRefreshTryCount : 5
2022-10-28 05:31:47,648 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - params?.paginationParam?.iterationCount = 0
2022-10-28 05:31:47,649 [quartzScheduler_Worker-13] DEBUG rest.RestProvisioningService  - Inside pullObjectsByRest
 
 
ImportAccountEntJSON - JSON configured 
 
{
"accountParams": {
"connection": "SalesAPIAuth",
"processingType": "SequentialAndIterative",
"successResponses": {
"statusCode": [
200
]
},
"unsuccessResponses": null,
"statusAndThresholdConfig": {
"statusColumn": "customproperty11",
"activeStatus": [
"active"
],
"deleteLinks": false,
"accountThresholdValue": 1000,
"correlateInactiveAccounts": true,
"inactivateAccountsNotInFile": false
},
"call": {
"call1": {
"callOrder": 0,
"stageNumber": 0,
"http": {
"url": "https://XXXXXXXXXXX/XXXXXXXXXXXX/app/dispatch/API/v3/users",
"httpMethod": "GET",
"httpContentType": "application/json",
"httpHeaders": {
"Authorization": "Basic XXXXXXXXXXXXXXXXXXXXXXXX",
"Content-Type": "application/json"
}
},
"listField": "result.elements",
"keyField": "accountID",
"statusConfig": {
"active": "active",
"inactive": "disabled"
},
"colsToPropsMap": {
"accountID": "username~#~char",
"name": "username~#~char",
"customproperty1": "firstName~#~char",
"customproperty2": "lastName~#~char",
"customproperty3": "email~#~char",
"customproperty4": "divisionId~#~char",
"customproperty11": "accountStatus~#~char",
"status": "accountStatus~#~char"
},
"pagination": {
"offset": {
"offsetParam": "offset",
"batchParam": "limit",
"batchSize": 100,
"totalCountPath": {
"connection": "SalesAPIAuth",
"http": {
"URL": "https://XXXXXXXXXXXXXX/XXXXXXXXXXX/app/dispatch/API/v3/users",
"httpHeaders": {
"Authorization": "Basic XXXXXXXXXXXXXXXXXXXXXXXXX"
},
"httpContentType": "application/x-www-form-urlencoded",
"httpMethod": "GET"
},
"totalCountPath": "map1.totalCount"
}
}
}
}
}
},
"entitlementParams": {},
"acctEntParams": {}
}
 
Response from postman
Puspanjali_1-1666940982740.png

Please suggest if I need to change anything on my JSON

 

Regards,
Puspanjali

 

2 REPLIES 2

rushikeshvartak
All-Star
All-Star

Your authentication token is getting expired . Is it not generating using connection json ?


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

Puspanjali
New Contributor
New Contributor

Hi Rushikesh,

Yes there is some issue with my connection, I changed that

After that, I tried and I could able to get only a few records (100)when the job tried to get all records it threw 403 

"pagination": {
"nextUrl": {
"nextUrlPath": "${response?.completeResponseMap?.result.nextPage==null?null:response.completeResponseMap.result.nextPage}"
}
}
}
}

Error

Puspanjali_0-1667211707691.png

Regards,
Puspanjali