Pagination in Freshservice Custom Objects API is not working

Hi All,

Thanks in Advance.

I am creating a custom app in Freshservice to automate the creation of Onboarding Ticket whenever a new employee is hired in my HRMS System.

I have my list of Job titles in a custom objects.
The list is quite big as it consists of 150+ items in it.

I want to get all the custom object records to do a mapping and create the onboarding ticket with proper job title.

The issue that I am facing here is the GET Api for custom object records only return a maximum of 100 records in a single request.
The page query param doesn’t seem to work here.

And When I referred to the API documentations, I came to know that there will be a next_page_link will be sent along with the response which will be further used to get the next page of records.

It is not working.

The below is the URL.
https://lego-us.freshworksapi.com/v1/entities/140671/records?page_size=100&next_token=2OIIo813r66KlskmtWry6ojtSfwYRtQlcECr7Cc0Pk3Z9tNyvDf1LOM7TVHdl&sort_by=bo_updated_at;DESC"

Can anyone help me with this?

Let me know if I am missing something here.

Hi @Sarnith_Balan,

Could you share the GET API request that has been used, along with the query parameters?
Also, is it possible to share the API response with hidden sensitive information?

I’m facing the same Issue with the custom object. Pagination isn’t working. For example i make GET request:

https://xxx.freshservice.com/api/v2/objects/26000005600/records?page_size=2

Answer is:

{
    "records": [
        {
            "data": {
              removed
            }
        },
        {
            "data": {
                removed
            }
        }
    ],
    "next_page_link": "https://lego-euc.freshworksapi.com/v1/entities/341329/records?page_size=2&next_token=2OIIo813r66Kv9VdRqrmJOKU6AK66fyXrNkvxGNOSIK8TRvFAbrcBWdxIyVHZ&sort_by=bo_updated_at;DESC",
    "meta": {
        "total_records": 27
    }
}

The next page link isn’t working. So I use the “next_token” in me new API Get request:

https://xxx.freshservice.com/api/v2/objects/26000005600/records?page_size=2&next_token=2OIIo813r66Kv9VdRqrmJOKU6AK66fyXrNkvxGNOSIK8TRvFAbrcBWdxIyVHZ

But the API sends the same result as on the first request.

Can you help?

I am running into the same issue. Can we get an ETA on when the Next_page_link will be fixed?

I was running into this same issue. Was on with support and they gave my a clunky work-around (passing a /V1 call into a /V2 endpoint).

This worked on the first “next-page” but returns the same token time and again after that. We are at 200 Max records… I guess thats progress…lol