Custom API intergration - Response Pagination

Hi, i am trying to achieve pagination with the Custom API.
The response header of the original call has the following information

Date: Wed, 27 Mar 2024 14:51:36 GMT
Content-Type: application/json; charset=utf-8
Transfer-Encoding: chunked
Connection: keep-alive
Vary: Accept-Encoding
X-Frame-Options: sameorigin
X-XSS-Protection: 1; mode=block
X-Content-Type-Options: nosniff
X-Robots-Tag: none
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: Fri, 01 Jan 1990 00:00:00 GMT

Link: 
<https://api.meraki.com/api/v1/111/bySwitch?perPage=50&startingAfter=Q222-2222-2222>; rel=first, 
<https://api.meraki.com/api/v1/111/bySwitch?perPage=50&startingAfter=QQQQ-1234-ABCD>; rel=next, 
<https://api.meraki.com/api/v1/111/bySwitch?endingBefore=QZZZ-ZZZZ-ZZZZ&perPage=50>; rel=last

The API Integration on Elastic is working as I get the data of the first page in.
But from the documentation it is not clear what I should configure for pagination
Is here someone who can assist?

Hi.

There is example for the pagination in docs: link.
Looks that you should extract a something like page_id from the response body and set value as query params or the request body:

    - set:
        target: url.params.scroll_id
        value: '[[.last_response.body._scroll_id]]'
    - set:
        target: body.scroll
        value: 5m

By the way you can try another integration - CEL

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.