Andres
10/28/2024, 3:08 PMuser
10/28/2024, 3:09 PMcursor_value
to extract the full URL from the response. 3. Configure the page_token_option
to use the RequestPath
type. Here's an example of how you can configure this in your YAML file: yaml paginator: type: "DefaultPaginator" pagination_strategy: type: "CursorPagination" cursor_value: "{{ response.__next }}" page_token_option: type: "RequestPath"
This configuration tells Airbyte to use the full URL returned in the __next
property of the response for the next request. The RequestPath
type in the page_token_option
ensures that the entire URL is used for the subsequent request, rather than just appending a parameter to the existing URL. This approach is particularly useful for APIs that return a full URL for the next page, as mentioned in the [Airbyte documentation on Cursor Pagination](https://docs.airbyte.com/connector-development/connector-builder-ui/pagination#cursor-pagination): "For cursor pagination, if path
is selected as the Inject into
option, then the entire request URL for the subsequent request will be replaced by the cursor value. This can be useful for APIs that return a full URL that should be requested for the next page of results, such as the GitHub API." By using this configuration, you don't need to extract or provide the UID of the next cursor object separately. The full URL returned by the API will be used directly for the next request.