Get All agents info through Freshdesk API


I want to store the agent name in my external Database. I am making an API call to get the agents Info, per page I can get a maximum of 100. My customers having more than 500 agents in their accounts. I want to assign the response of all agents in an array of JSON. I want to do it with an async-await and do-while loop. But in the FDK console, I am getting an error with async-await due to Async/await not supported in FDK.

Is there any way to overcome this issue and send the all agent’s Info in a single variable to my middleware to store it in DB?

I want to publish my app by end of this week. Please help me with this.

Hi Dinesh,
Hope you are doing good!
Async and Await is not supported by FDK,
you can try with recursive function to handle this approach…

function recursive(url, totalvalue) {
// call ajax request using request api and get the value
requestapi.get(url).then(value => {
totalvalue += value;
recursive(url, totalvalue)


it is possible to use async and await(nas ultimas versões da fdk) in serverless applications, so it would be possible to use a hybrido app and use a Server Method Invocation
in its frontend calling a serveless method. The only care is that you can have a timeout, if I am not mistaken the serveless returns the timeout if there is no answer in 5 seconds. Hope this helps!


Nice forum :smiley: Great going…