> ## Documentation Index
> Fetch the complete documentation index at: https://docs.awardforce.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Pagination

> Navigate paginated Award Force API responses using page query parameters and helper links.

Our APIs support offset-based pagination with the query parameter `?page=1`. Use `?per_page=` to control the number of records returned per page (between `1` and `100`, default `10`).

<CodeGroup>
  ```bash Request theme={null}
  # Get the first page with 5 results per page
  curl "https://api.us.cr4ce.com/user?page=1&per_page=5"

  # Get the next page
  curl "https://api.us.cr4ce.com/user?page=2&per_page=5"
  ```
</CodeGroup>

Paginated resource responses contain a specific set of pagination helper links in the
top-level object.

Use these links to navigate to different pages of data.

```json Response theme={null}
{
  "current_page": 1,
  "data": [],
  "first_page_url": "https://api.us.cr4ce.com/user?page=1&per_page=5",
  "from": 1,
  "last_page": 10,
  "last_page_url": "https://api.us.cr4ce.com/user?page=10&per_page=5",
  "next_page_url": "https://api.us.cr4ce.com/user?page=2&per_page=5",
  "path": "https://api.us.cr4ce.com/user",
  "per_page": 5,
  "prev_page_url": "",
  "to": 10,
  "total": 200
}
```

## Paginated results

Paginated responses usually include the following fields:

<ResponseField name="current_page" type="integer">
  Number of the page returned by this response. The first page is `1`.
</ResponseField>

<ResponseField name="data" type="array">
  Array containing resource information.
</ResponseField>

<ResponseField name="first_page_url" type="string">
  URL of the first page in the result set. Relative when the requested page is beyond the last page.
</ResponseField>

<ResponseField name="from" type="integer | null">
  Position of the first record on this page within the full result set. The first record is at position `1`. `null` when the requested page is beyond the last page.
</ResponseField>

<ResponseField name="last_page" type="integer">
  Number of the last page. Equals the total number of pages.
</ResponseField>

<ResponseField name="last_page_url" type="string">
  URL of the last page in the result set. Relative when the requested page is beyond the last page.
</ResponseField>

<ResponseField name="next_page_url" type="string | null">
  URL of the next page in the result set. Empty string when the current page is the last page.
</ResponseField>

<ResponseField name="path" type="string">
  Canonical URL of the endpoint, without query parameters.
</ResponseField>

<ResponseField name="per_page" type="integer">
  Maximum number of records returned per page.
</ResponseField>

<ResponseField name="prev_page_url" type="string | null">
  URL of the previous page in the result set. Empty string when the current page is the first page.
</ResponseField>

<ResponseField name="to" type="integer | null">
  Position of the last record on this page within the full result set. `null` when the requested page is beyond the last page.
</ResponseField>

<ResponseField name="total" type="integer">
  Total number of records across all pages.
</ResponseField>
