Skip to main content

Pagination

List endpoints use cursor-based keyset pagination for consistent, efficient paging through large result sets.

How it works

  1. Make your first request (no cursor):
curl -H "X-API-Key: gld_your_key" \
  "https://api.gildea.ai/v1/signals?q=AI&limit=10"
  1. Check has_more and next_cursor in the response:
{
  "data": [...],
  "has_more": true,
  "next_cursor": "eyJwdWJsaXNoZWRfYXQiOiIyMDI2LTAyLTE0VDEwOjAwOjAwWiJ9"
}
  1. Pass next_cursor as the cursor parameter for the next page:
curl -H "X-API-Key: gld_your_key" \
  "https://api.gildea.ai/v1/signals?q=AI&limit=10&cursor=eyJwdWJsaXNoZWRfYXQiOi..."
  1. Repeat until has_more is false.

Parameters

ParameterTypeDefaultRangeDescription
limitinteger251–50Results per page
cursorstringOpaque cursor from previous response

Paginated endpoints

  • GET /v1/signals — signals list
  • GET /v1/entities — entities list

Why cursor-based?

Cursor pagination is more efficient and consistent than offset-based pagination:
  • No skipped/duplicated results when data changes between pages
  • Consistent performance regardless of page depth (no OFFSET N scan)
  • Opaque cursors — the format may change without breaking clients