Pagination

Every list returns one page and the cursor to reach the next.

List endpoints never return everything. Each returns one page wrapped in the same envelope, plus opaque cursors for moving through the rest.

1{
2 "object": "list",
3 "url": "/api/v1/gifts",
4 "has_more": true,
5 "next_cursor": "eyJpZCI6NDE0LCJ0aWQiOjIxfQ...",
6 "previous_cursor": null,
7 "data": [ ]
8}
FieldMeaning
objectAlways "list".
urlThe path this collection was served from.
has_moreWhether another page exists in the direction you are paging.
next_cursorPass as starting_after to move forward. null on the last page.
previous_cursorPass as ending_before to move backward.
dataThe resources for this page.

Parameters

ParameterDescription
limitPage size. Defaults to 25.
starting_afterPage forward from this cursor.
ending_beforePage backward from this cursor.

limit is clamped, not rejected. Values outside 1100 are silently coerced into range, so limit=5000 returns 100 rather than an error. Do not rely on the number you sent being the number you get.

starting_after and ending_before are mutually exclusive. If you send both, starting_after wins.

Paging forward

Read next_cursor from the response and send it back as starting_after. Stop when has_more is false.

$# first page
$curl -G https://api.awardspring.com/api/v1/gifts \
> -H "X-Spring-API-Key: YOUR_KEY" \
> --data-urlencode "limit=25"
$
$# next page
$curl -G https://api.awardspring.com/api/v1/gifts \
> -H "X-Spring-API-Key: YOUR_KEY" \
> --data-urlencode "limit=25" \
> --data-urlencode "starting_after=eyJpZCI6NDE0LCJ0aWQiOjIxfQ..."

Send filters on the first request only

This is the part that surprises people. Filters are pinned into the cursor. Send q, donor_id, type and similar on the first request; every later page carries them automatically.

On the scholarship reporting endpoints this is not merely unnecessary but wrong — award_cycle_id is baked into the cursor, so repeating it on a later page can conflict with what the cursor already asserts.

$# correct: filter on page one, cursor alone afterwards
$curl -G https://api.awardspring.com/api/v1/scholarships/awarded-students \
> -H "X-Spring-API-Key: YOUR_KEY" \
> --data-urlencode "award_cycle_id=12"
$
$curl -G https://api.awardspring.com/api/v1/scholarships/awarded-students \
> -H "X-Spring-API-Key: YOUR_KEY" \
> --data-urlencode "starting_after=b3B0cV8..."

Cursors are opaque and signed

A cursor is a signed token bound to your institution and to the filters that produced it. It is not a page number, an offset, or a record id, and it is not meant to be read.

Never build, edit, truncate, or store one for later reuse. A cursor that has been tampered with, has expired, belongs to another institution, or disagrees with the filters on the request returns 400 invalid_cursor.

If you need to resume work later, re-run the first request rather than persisting a cursor.