Forum Discussion
Passing a parameter to an API for retrieving paginated data
- 5 years ago
Do the first call with ?limit=100 , then query the Meta/Total value and calculate how many more calls you need to make to hit the total. Power Query allows you to create lists, and to add columns to these. with the contents of the API call returns.
- make first call with ?limit=100
- let's say the call returned with Meta/Total=760
- create a list with a value from 100 to 700 in steps of 100
- make subsequent calls with ?limit=100&offset=[list value]
- combine all results as needed.
Do the first call with ?limit=100 , then query the Meta/Total value and calculate how many more calls you need to make to hit the total. Power Query allows you to create lists, and to add columns to these. with the contents of the API call returns.
- make first call with ?limit=100
- let's say the call returned with Meta/Total=760
- create a list with a value from 100 to 700 in steps of 100
- make subsequent calls with ?limit=100&offset=[list value]
- combine all results as needed.