Using filter with collections

Rebilly provides collections filtering. You can use ?filter param on collection to define which records should be shown in the response.

Here is filter format description:

  • Fields and values in filter are separated with :: ?filter=firstName:John.

  • Fields in filter are separated with ;: ?filter=firstName:John;lastName:Doe.

  • You can use multiple values using , as values separator: ?filter=firstName:John,Bob.

  • To negate the filter use !: ?filter=firstName:!John. Note that you can negate multiple values like this: ?filter=firstName:!John,Bob. This filter rule will exclude all Johns and Bobs from the response.

  • You can use range filters like this: ?filter=amount:1..10.

  • You can use gte (greater than or equals) filter like this: ?filter=amount:1.., or lte (less than or equals) than filter like this: ?filter=amount:..10.

  • You can create some predefined values lists and use them in filter: ?filter=firstName:@yourListName. You can also exclude list values: ?filter=firstName:!@yourListName