Skip to main content

Filtering lists

In endpoints that return a list, we offer various ways of filtering the information returned, depending on the field type. Filterable fields are listed in the relevant endpoint documentation.

Equal to#

parameter=value
  • For all field types you can filter by an exact value using a standard query parameter ?amount=12345

Greater than / after#

parameter[gt]=value
  • For numeric fields, amounts greater than a value ?amount[gt]=12345
  • For date fields, dates later than a given date ?createdAt[gt]=20201205

Greater than or equal to / on or later than#

parameter[gte]=value
  • For numeric fields, amounts greater than, or equal to, a value ?amount[gte]=12345
  • For date fields, dates on or later than a given date ?createdAt[gte]=20201205

Less than / before#

parameter[lt]=value
  • For numeric fields, amounts greater than a value ?amount[lt]=12345
  • For date fields, dates later than a given date ?createdAt[lt]=20201205

Less than or equal to / on or before#

parameter[lte]=value
  • For numeric fields, amounts less than, or equal to, a value ?amount[lte]=12345
  • For date fields, dates on or later than a given date ?createdAt[lte]=20201205

Any in a set of values#

parameter[]=value1&parameter[]=value2
  • Specify the same field more than once in the query string with [] and each value you want to filter by (exact matches only) ?status[]=success&status[]=pending

Not equal to a single value#

parameter[not]=value
  • To return values that are not equal to an exact value ?status[not]=pending

Not equal to a set of values#

parameter[not]=value1&parameter[not]=value2
  • To return values that are not equal to more than one exact value, specify the values in an array by adding the same field multiple times, but with an extra flag of [not]. ?status[][not]=pending&status[][not]=failed