06/02/2023 12:23 AM
Hi Everyone,
Trying to integrate the Freshservice with Saviynt. During the Import, getting stuck at the Pagination.
The Freshservice API's Pagination link is available in the Headers - Link. Refer the screenshot below,
We will have to replace the < and >; rel="next" from the Headers_Link and then pass this a the nextUrlPath. Also when there is no Link key present in the Headers, it means that's the end of it.
<https://ringcentral-fs-sandbox.freshservice.com/api/v2/requesters?include_agents=true&per_page=100&p...>; rel="next"
I've trailed following Paginations but both doesn't work. Please suggest how I can make this work. Attaching the complete ImportAcctEnt JSON for reference
Solved! Go to Solution.
06/05/2023 10:33 AM
Can you escape double quotes in your replace function and then try replace('>; rel=\"next\"','')
06/06/2023 02:02 AM
Thank you Sahil. That did work for me. I'm now seeing a different issue while running the Access Import. Attaching the same for your reference and my ImportAcctEnt JSON is available in my post. Can you please let me know how I can fix this?
06/06/2023 08:06 AM
This appears to be an issue with your Connection JSON. Can you check if the call name in Connection JSON is same as that you have defined in Import JSON
"connection": "acctAuth",
06/06/2023 08:49 AM
yes it is the same in my connectionJSON. Can you please refer the below,
{
"authentications": {
"acctAuth": {
"authType": "Basic",
"url": "https://xxx-fs-sandbox.freshservice.com/api/v2/requesters",
"httpMethod": "POST",
"httpParams": {
},
"httpHeaders": {
"contentType": "application/json"
},
"httpContentType": "application/json",
"properties": {
"userName": "xxx",
"password": "xxxxx"
},
"expiryError": "ExpiredAuthenticationToken",
"authError": [
"InvalidAuthenticationToken",
"AuthenticationFailed"
],
"timeOutError": "Read timed out",
"errorPath": "error.code",
"maxRefreshTryCount": 5,
"tokenResponsePath": "access_token",
"tokenType": "Basic",
"accessToken": "xxx",
"testConnectionParams": {
"http": {
"url": "https://xxx-fs-sandbox.freshservice.com/api/v2/requesters",
"httpMethod": "GET",
"requestBody": "",
"httpParams": {
},
"httpHeaders": {
"contentType": "application/json",
"Authorization": "xxx"
},
"httpContentType": "application/json"
},
"successResponse": [
],
"successResponsePath": "responseText",
"errors": [
"fail",
"error"
],
"errorPath": "responseText"
},
"apiRateLimitConfig": {
"retryAfterCalls": 100,
"retryWaitSeconds": 60
}
}
}
}
06/06/2023 08:56 AM
In that case can you check for the logs. Do ensure to update ConfigJSON param in the REST connection with value {"showLogs":true} before running the job. This enables additional logging for REST connection and may be helpful.
06/09/2023 05:11 AM
Hi @SB I will try this for the access import. There is one more issue with the account import. When I first ran the account import, the accounts were reconciled and everything looks good. The second time I run it, I got error that it's "Account threshold (accountThresholdValue) exceeded. Current threshold limit 300 and missing accounts during import 774. No action was taken on missing accounts due to the threshold breach." That is, whatever accounts got reconciled, will show as manually suspended from import if I increase the threshold. How can I fix this? Can you please help check the JSON once? Attaching the Freshservice ImportAcctEntJSON for reference.
06/12/2023 08:55 AM
hi @SB, Can you please check this at your end and share your suggestions?
06/12/2023 09:40 AM
If your goal is to mark the missing accounts as SFIS, then increase the accountThreshold to 1000 in your import JSON.
"accountThresholdValue": 1000,
06/12/2023 10:00 AM
Hi @naveenss , thanks for the response. When I do that, all the accounts move to suspended from the import, which is not what I want.
@SB , When I do the import from application for the first time, I'm seeing all the accounts and groups in the Saviynt system. The second time I run the import it is failing with Account Threshold error that all the accounts that were reconciled are now missing, whereas these accounts are present in the endpoint.
06/12/2023 10:03 AM
This does mean that the accounts data is not received as part of the api call. You will need to update ConfigJSON param in the REST connection with value {"showLogs":true} before running the job.
The jobs should print where it did receive any data or if the call failed or any other reason to help identify with the issue.
06/12/2023 09:33 AM
I am not sure I understood the ask. Can you rephrase it.