Pagination

All the "list" API endpoints for bulk fetches support pagination. These endpoints share a common structure, taking 2 parameters:

  • limit: Determines the number of items to be returned in each call and can be set to a number up to 100, which is also the default value when the parameter is not set.
  • cursor: The starting point for the set of items to be returned in chronological order. If not set, the call will return the first set of items.

The response will contain an array of items and a next_cursor, which can be passed back in as cursor to fetch the next set of items. The next_cursor is nil once the end of the set is reached.

Copy
Copied
"next_cursor": "string",
"items": [ ]

Filtering

Some "list" endpoints will also let you filter by a specific value. For example, you can filter cards by user_id, users by email, and locations and departments by name.

Copyright © Brex 2019–2021. All rights reserved.