Get all products
GET {{baseUrl}}/products?owner_id=<integer>&ids=<string>&filter_id=<integer>&cursor=<string>&limit=<integer>&sort_by=id&sort_direction=asc&custom_fields=<string>
Returns data about all products.
Request Params
Key | Datatype | Required | Description |
---|---|---|---|
owner_id | string | If supplied, only products owned by the given user will be returned | |
ids | string | Optional comma separated string array of up to 100 entity ids to fetch. If filter_id is provided, this is ignored. If any of the requested entities do not exist or are not visible, they are not included in the response. | |
filter_id | string | The ID of the filter to use | |
cursor | string | For pagination, the marker (an opaque string value) representing the first item on the next page | |
limit | string | For pagination, the limit of entries to be returned. If not provided, 100 items will be returned. Please note that a maximum value of 500 is allowed. | |
sort_by | string | The field to sort by. Supported fields: id , name , add_time , update_time . | |
sort_direction | string | The sorting direction. Supported values: asc , desc . | |
custom_fields | string | Comma separated string array of custom fields keys to include. If you are only interested in a particular set of custom fields, please use this parameter for a smaller response.<br/>A maximum of 15 keys is allowed. |
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Accept | string |
RESPONSES
status: OK
{"success":true,"data":[{"id":1,"name":"Mechanical Pencil","code":"MPENCIL","description":"Product description","unit":"","tax":0,"category":"Retail","is_linkable":true,"is_deleted":false,"visible_to":3,"owner_id":1234,"add_time":"2019-12-19T11:36:49Z","update_time":"2019-12-19T11:36:49Z","billing_frequency":"monthly","billing_frequency_cycles":4,"prices":[{"product_id":1,"price":5,"currency":"EUR","cost":2,"direct_cost":1,"notes":"this is a note"}],"custom_fields":{"6d74315176adcc4c97108440449b93ba57d20704":16}}],"additional_data":{"next_cursor":"eyJmaWVsZCI6ImlkIiwiZmllbGRWYWx1ZSI6Nywic29ydERpcmVjdGlvbiI6ImFzYyIsImlkIjo3fQ"}}