Skip to main content
GET
Search Profile Transactions

Filtering

This endpoint accepts filter and sort query parameters. See Filtering, sorting, and search for paging and for the shared search_with, custom_field, and json_contains filters.

Examples

Operators

Filter attributes

Each attribute above is also a valid sort key, for example ?sort=-deliver_at for descending order. Dot notation filters on a related record. Use not_has to exclude rows that have a matching related record. Related attributes are filter only, not sort keys.

Search attributes

filter[search] runs one partial match term across profile_id, external_id, receipt_ref, linked_receipt_ref. A record matches when any one of those attributes contains the term.

Custom field filters

Transaction records carry custom fields, so this endpoint also accepts filter[custom_field][namespace:handle].

Discount reason filters

Transaction items carry the discounts applied to them, so this endpoint also accepts filter[discount_reason]. A record matches when any one of its items carries a discount with a matching reason, and it is returned once however many of its items match. This filter has its own operators. The ones in the table above do not apply to it, and an operator it does not accept is ignored rather than rejected. % and _ in the value are matched as characters, not as wildcards, so a reason like Wedding Party 25% can be given as written.
eq, in and starts_with are resolved with an index. contains and ends_with begin with a wildcard, which no index can serve, so they are answered by a scan and get slower as the record set grows. Reach for a more specific operator where you can.

Path Parameters

profile
string<uuid>
required

The profile ID

Response

Transaction

data
Transaction · object
required