Sync paginated GraphQL requests every 5 minutes

Recipe ToolsMarketingDeveloper ToolAPI Integration

What it does

When the clock triggers every 5 minutes, this automation queries a GraphQL endpoint via HTTP to search for cards in the Pagos en Espera phase. It loops through each page of results and increments the page index until all paginated data is retrieved.

Who it's for

Operations teams who need to regularly pull paginated GraphQL data without manual intervention.

How teams use this

Sync all paginated card data regularly

Pull every card in Pagos en Espera from GraphQL on a 5-minute cycle so downstream systems always have the latest batch. No manual queries needed.

Route cards to different teams by phase

Extend this automation to check each card's phase and send it to the right team channel. Only cards matching a phase condition move forward.

Archive completed pages in a database

Add a step after each page is processed to log the results in a database or data warehouse. This keeps a record of every sync cycle.

How it works

  1. Trigger every 5 minutes. The automation runs on a 5-minute schedule to keep paginated data in sync.
  2. Query GraphQL via HTTP for cards. Call the GraphQL endpoint via HTTP to search for cards in the Pagos en Espera phase and retrieve the first page of results with node data.
  3. Process each node and check pagination. For each node returned in the results, extract the data and check whether a next page exists in the GraphQL response.
  4. Increment page index and fetch next. Increment the page index variable and call the GraphQL endpoint again via HTTP to fetch the next page. Repeat until no next page remains.