Example 2: HTTP Client GET Pagination

This example Pipeline demonstrates how to use the Has Next field to retrieve the list of records from the specified URL. This example assumes you have a valid account to access the resources from the endpoint.

Steps

  1. Configure the HTTP Client Snap with the GET Request Method and the URI to return the response (records) from the Hub endpoint.

    Get_URI_Pagination.png

     

  2. The following configuration details are key to understanding this example:

Field

Value

Description

Field

Value

Description

Has Next

$entity['has-more']

The entity is the response returned from the specified URI and the ‘has-more’ key evaluates to true until there are no more records.

Total Pages to Fetch

2

This field represents the number of webpages from where you want to fetch the response.

Next URI

https://api.hubapi.com/contacts/v1/lists/all/contacts/all?hapikey=demo&vidOffset=" + $entity['vid-offset']

This URL indicates the video offset value that is appended to the first URI.

 

  1. On validation, the output displays the response received from the URI as highlighted in the image.

Download this Pipeline.

  File Modified

File Example_HTTPCLIENT_GET_Verify pagination.slp

Mar 08, 2024 by Kalpana Malladi