Script pagination
Last updated
Last updated
If a standard pagination type can't meet your pagination requirements, you can create a custom script and apply this as the pagination method
for endpoints.
Pagination scripts are added and tested via the custom scripts option in the usual way. Content for these scripts depends on your requirements and the API for your connector. As with any script, you can include references to flow variables, meta-variables, and payload variables.
For more information about developing pagination scripts, please see our pagination scripts page.
For standard pagination methods, parameters are defined when a method is selected for the endpoint. For example, the next page url
pagination method prompts for a next page field
parameter:
If you're developing a script to handle pagination, you can either:
define pagination parameters as required or optional URL parameters
define pagination parameters in your script
To apply a script that you've developed for pagination, follow the steps below.
Step 1
From the endpoint pagination tab, select the script
pagination method:
Step 2
Use the select a script
field to choose the required pagination script - for example:
All scripts created for your company are available for selection. If you select a script that isn't deployed, it will be deployed the first time this endpoint is used (in this case the first request may take longer than usual).
Step 3 Use the version field to choose which version of the selected script to use - for example:
If your script is updated in future, remember to come back here and (if appropriate) select the later version.
Step 4 Click save and go back to return the list of endpoints: