Skip to navigation

List Purchase Orders

View as Markdown

Returns a page of the merchant’s purchase orders, newest first by default. Follow the next or prev link to page; each carries the cursor and the original filters.

Authentication

AuthorizationBearer

Authentication using Personal Access Token (PAT) token

OR
AuthorizationBearer
OAuth2 authentication using JWT tokens

Query parameters

cursorstringOptional
Opaque page cursor from a previous response's next or prev link. Carries its own sort.
sort_bystringOptional

created_at (default), id or external_reference. Ignored when a cursor is given.

sort_dirstringOptional

asc or desc (default). Ignored when a cursor is given.

limitintegerOptional
Results per page, 1 to 250. Defaults to 50.
statuslist of enumsOptional

Only purchase orders in one of these statuses. Repeat the parameter for more than one (status=2&status=3).

Allowed values:
idslist of longsOptional

Only purchase orders with one of these ids, up to 250. Repeat the parameter for more than one (ids=1&ids=2).

supplier_idintegerOptional
Only purchase orders with this supplier.
external_referencestringOptional
Only purchase orders whose external reference contains this text.
searchstringOptional
Matches the external reference, or the purchase order id too when the term is all digits.

Response

OK
firststring or nullOptional

Reserved; always null.

itemslist of objects or nullOptional
The page's results.
laststring or nullOptional

Reserved; always null.

nextstring or nullOptional
Link to the next page, or null on the last page.
prevstring or nullOptional
Link to the previous page, or null on the first page.

Errors

401
Unauthorized Error
403
Forbidden Error
422
Unprocessable Entity Error