Get purchase orders filtered and paged

Prev Next
Post
/api/v1/invoices/purchaseorders/filter

Get a paged list of existing purchase orders, optionally filtered to the given parameters.

Description

Retrieve a paged list of existing purchase order, filtered to the given parameters.

Use Case

The user needs to identify which purchase orders are currently registered in Bloxs. For example, they may want to retrieve all the purchase order from a specific supplier (relationsReference).

Request fields

The request contains the following fields:

FieldDescription
pageSizeThe maximum number of pages to be returned per request. The default number is 100 and the maximum is 1.000. If more results are returned than specified in the PageSize, the remaining pages are dropped based on the reference (number).
pageNumberThis allows the requesting party to specify which of the pages they want to receive.
columnNameThe data field based on which sorting is applied. For example, if the results are sorted based on ascending name, columnName will contain the value 'name'.
orderBased on this value, the property defined in 'columnName' is either sorted ascending (a-z) or descending (z-a).
reference
This pertains to the reference of the specific purchase order. This reference can be used to obtain further information regarding the invoice through the GET operation.
externalIdentifierThe unique identifier for this specific purchase order, not created by Bloxs.
ownerReferenceThe reference of the relation that is the buying party in this purchase order. This refers to the reference created by Bloxs, not to be confused with the externalIdentifier.
relationReferenceThe reference of the relation that is the selling party in this purchase order (supplier). This reference is created by Bloxs.
proposalReferenceThe reference of the proposal which (usually) preceded the purchase order. This reference is created by Bloxs.
proposalTotalAmountExcl.fromTotal amount of the proposal excluding VAT. The amount is expressed with two decimals. This defines the lower border of the range.
proposalTotalAmountExcl.to
Total amount of the proposal excluding VAT. The amount is expressed with two decimals. This defines the upper border of the range.
totalAmountExcl.fromTotal amount of the purchase order excluding VAT. The amount is expressed with two decimals. This defines the lower border of the range.
totalAmountExcl.toTotal amount of the purchase order excluding VAT. The amount is expressed with two decimals. This defines the upper border of the range.
invoicedAmount.fromThe amount that has been invoiced till today. The amount is expressed with two decimals. This defines the lower border of the range.
invoicedAmount.toThe amount that has been invoiced till today. The amount is expressed with two decimals. This defines the upper border of the range.
outstandingAmount.from
The amount that of today has not been invoiced, and is therefore still outstanding. The amount is expressed with two decimals. This defines the lower border of the range.
outstandingAmount.to
The amount that of today has not been invoiced, and is therefore still outstanding. The amount is expressed with two decimals. This defines the upper border of the range.

Response fields

In addition to the request, the 200 response contains the fields in the table below. 

FieldDescription
subjectThe subject of the purchase order.
workflowState

1 = Draft

Concept status. Edits are still possible.

2 = OnHold

This means that an purchase order is on hold before it can be approved, for example due to a dispute with the supplier.

3 = Cancelled

This purchase order was, for example, not needed or created in error.

4 = ApprovalWorkflow

Submitted for approval. For example, the purchase order is pending approval by person X. This may involve a simple or extended approval chain of multiple people.

7 = Final

This is the most relevant status for integration partners. Purchase orders are then fully processed (and potentially sent).

9 = Disapproved

The purchase order has been returned by an approver for adjustments by the creator.

10 = OwnerApprovalWorkflow

Submitted for approval by the owner. The purchase order is then awaiting the owner’s approval via the owners’ portal. This is in addition to the normal approval process but is linked to the use of the owners’ portal.

11 = DisapprovedByOwner

Disapproved by the owner. This requires further review.

finalizationStateThe status of payment.
0 = Open
1 = Completed
2 = Closed
Security
HTTP
Type Bearer

Please enter a valid token

Body parameters
Expand All
object
paging
object (PagingInfo)
pageSize
integer (int32) | null
Minimum1
Maximum1000
pageNumber
integer (int32) | null
Minimum1
Maximum9999
sorting
object (SortingInfo)
columnName
string | null
order
integer (int32)
Valid values[ 0, 1 ]
filter
object (PurchaseOrderSearchRequestFilter)
reference
string | null
externalIdentifier
string | null
ownerReference
string | null
relationReference
string | null
proposalReference
string | null
proposalTotalAmountExcl
object (CompareFilterModelDecimal)
from
number (double) | null
to
number (double) | null
totalAmountExcl
object (CompareFilterModelDecimal)
from
number (double) | null
to
number (double) | null
invoicedAmount
object (CompareFilterModelDecimal)
from
number (double) | null
to
number (double) | null
outstandingAmount
object (CompareFilterModelDecimal)
from
number (double) | null
to
number (double) | null
Responses
200

OK

Expand All
object
paging
object (PagingInfo)
pageSize
integer (int32) | null
Minimum1
Maximum1000
pageNumber
integer (int32) | null
Minimum1
Maximum9999
sorting
object (SortingInfo)
columnName
string | null
order
integer (int32)
Valid values[ 0, 1 ]
purchaseOrders
Array of object (PurchaseOrderSearchResultFilter) | null
object
reference
string | null
externalIdentifier
string | null
ownerReference
string | null
relationReference
string | null
proposalReference
string | null
subject
string | null
proposalTotalAmountExcl
number (double) | null
workflowState
integer (int32)
Valid values[ 1, 2, 3, 4, 7, 9, 10, 11 ]
finalizationState
integer (int32)
Valid values[ 0, 1, 2 ]
totalAmountExcl
number (double)
invoicedAmount
number (double) | null
outstandingAmount
number (double) | null