This guide will be removed on April 29, 2022. Please use our new, easier-to-use Toast technical documentation site. All updated content is on the new site.

Paginating the request results

To control the number of Order objects that the /ordersBulk endpoint returns for each request, use the pageSize query parameter. The maximum pageSize that you can specify is 100.

If the number of matching orders is greater than the value of pageSize, use the page parameter to specify the sequence number of the set of objects to return.

For example, the time period you specify selects 100 orders. You set pageSize to 10. To return the first ten orders, set page to 1. To return the next ten orders, set page to 2.

The response header fields for the /ordersBulk endpoint include a set of response pagination links that you can use to send requests that return each Order object in the set of orders you select in a time period. These link header fields follow the pattern described in the proposed Internet Engineering Task Force (IETF) web linking standard.

For an example of the pagination links in a /ordersBulk endpoint response, see Example response data pagination header fields. For more information about Toast API response pagination, see Paginating response data.

Note

Unlike the endpoints of the Toast configuration API, the /ordersBulk endpoint does not return a last link field.

Note

The /ordersBulk endpoint has a lower rate limit than most other Toast API endpoints. API clients can poll the /orderBulk endpoint up to five times per location per second. For more information about API rate limits, see Toast rate limit values.