v1

latestOpenAPI 3.0.1Apache 2.02026-07-26193304444.4 KB
Search

Search for resources

This endpoint allows integrators to search all of the most commonly used resources, sales, products and customers. Each type allowing search by a number of different parameters.

Supported resource types and attributes

  • Sales
    • date_from
    • date_to
    • time_from
    • time_to
    • timezone
    • status
    • state
    • attributes
    • invoice_number
    • customer_id
    • user_id
    • outlet_id
    • register_id
    • payment_type_id
    • product_id
    • sale_total
    • customer_name
  • Products
    • sku (values must be lowercased)
    • supplier_id
    • brand_id
    • tag_id
    • product_type_id
    • variant_parent_id
  • Customers
    • customer_code
    • first_name
    • last_name
    • company_name
    • mobile
    • phone
    • email

Sorting and pagination

Unlike other endpoints, search results from this endpoint can be sorted by any of the attributes above. Because of that, the default pagination mechanism is not appropriate for this endpoint. Instead, this endpoint uses offset and page_size attributes to handle search results spanning multiple pages.

🔒 Requires one of the following:

  • sales:read scope when searching for sales
  • products:read scope when searching for products
  • customers:read scope when searching for customers
get/search

Query parameters

type'sales' | 'products' | 'customers' required

The entity type to search for.

order_bystring

The attribute used to sort items returned in the response. Supported values depend on the entity type.

order_direction'asc' | 'desc'

Sorting direction.

page_sizeinteger

The maximum number of objects to be included in the response, currently limited to 1000. Specifying more than 1000 will result in 1000 objects being returned.

offsetinteger

The number of objects to be "skipped" for the response. Used for pagination.

_idstring UUID

The id of the object to be included in the response.

-_idstring UUID

The id of the object to be excluded from the response.

deletedboolean

Indicated whether deleted objects should be included in the response.

statusstring

SALES Status of the sale to find. Can be used multiple times to search for objects with different values of this parameter. Deprecated, please use state and attributes instead.

statestring

SALES State of the sale to find. Can be used multiple times to search for objects with different values of this parameter.

attributesstring[]

SALES Attributes of the sale to find. Can be used multiple times to search for objects with different values of this parameter.

invoice_numberstring

SALES Invoice number of the sale.

customer_idstring UUID

SALES The ID of the customer associated with the sales.

user_idstring UUID

SALES The ID of the user associated with the sales.

outlet_idstring UUID

SALES The ID of the outlet associated with the sales.

date_fromstring

SALES Lower limit for the sale date as UTC timestamp. Format: 2016-08-08T12:00:00Z.

date_tostring

SALES Upper limit for the sale date as UTC timestamp. Format: 2016-08-08T12:00:00Z.

time_fromstring

SALES Lower time-of-day limit (in local time) for filtering sales. Format: H:MM or HH:MM (e.g. 09:00). Use with timezone for accurate local-time filtering. When only time_from is provided, time_to defaults to 24:00.

time_tostring

SALES Upper time-of-day limit (in local time) for filtering sales. Format: H:MM or HH:MM (e.g. 17:00). Use with timezone for accurate local-time filtering. When only time_to is provided, time_from defaults to 00:00.

timezonestring

SALES IANA timezone identifier used to interpret time_from and time_to (e.g. America/Toronto). Defaults to UTC when omitted. See the list of tz database time zones for valid values.

register_idstring UUID

SALES The ID of the register associated with the sale. Can be used multiple times to search for objects with different values of this parameter.

payment_type_idstring UUID

SALES The ID of a payment type used in the sale. Can be used multiple times to search for objects with different values of this parameter.

product_idstring UUID

SALES The ID of a product included in the sale. Can be used multiple times to search for objects with different values of this parameter.

sale_totalnumber float

SALES The exact total amount of the sale to find.

customer_namestring

SALES The name of the customer associated with the sale. Supports prefix matching.

skustring

PRODUCTS The SKU of products to include in the search. Can be used multiple times to search for objects with different values of this parameter.

-skustring

PRODUCTS The SKU of products to exclude from the search. Can be used multiple times to search for objects with different values of this parameter.

supplier_idstring UUID

PRODUCTS The ID of the supplier associated with the product to include in the search. Can be used multiple times to search for objects with different values of this parameter.

-supplier_idstring UUID

PRODUCTS The ID of the supplier associated with the product to exclude from the search. Can be used multiple times to search for objects with different values of this parameter.

brand_idstring UUID

PRODUCTS The ID of the brand associated with the product to include in the search. Can be used multiple times to search for objects with different values of this parameter.

-brand_idstring UUID

PRODUCTS The ID of the brand associated with the product to exclude from the search. Can be used multiple times to search for objects with different values of this parameter.

tag_idstring UUID

PRODUCTS The ID of the tag associated with the product to include in the search. Can be used multiple times to search for objects with different values of this parameter.

-tag_idstring UUID

PRODUCTS The ID of the brand associated with the product to exclude from the search. Can be used multiple times to search for objects with different values of this parameter.

product_type_idstring UUID

PRODUCTS The ID of the product type associated with the product to include in the search. Can be used multiple times to search for objects with different values of this parameter.

-product_type_idstring UUID

PRODUCTS The ID of the product type associated with the product to exclude from the search. Can be used multiple times to search for objects with different values of this parameter.

variant_parent_idstring UUID

PRODUCTS The ID of the variant parent product associated with the product to include in the search. Can be used multiple times to search for objects with different values of this parameter.

-variant_parent_idstring UUID

PRODUCTS The ID of the variant parent product associated with the product to exclude from the search. Can be used multiple times to search for objects with different values of this parameter.

customer_codestring

CUSTOMERS The customer_code associated with the customer to find.

emailstring

CUSTOMERS The email address associated with the customer to find.

first_namestring

CUSTOMERS The first_name for the customers to find.

last_namestring

CUSTOMERS The last_name for the customers to find.

company_namestring

CUSTOMERS The company_name for the customers to find.

mobilestring

CUSTOMERS The mobile number for the customers to find.

phonestring

CUSTOMERS The phone number for the customers to find.

Response

dataobject[]

A collection of objects of one of the supported types: sales, products or customers.