Documentation Index

Fetch the complete documentation index at: https://www.bloxs.io/llms.txt

Use this file to discover all available pages before exploring further.

Get a purchase order

Prev Next
Get
/api/v1/invoices/purchaseorders

Get an existing purchase order.

Get a Purchase Order

Retrieves the full record of a single existing purchase order.

A purchase order in Bloxs is based on an externally supplied quote (proposal) from a supplier; a developer calls this endpoint to look up a purchase order already registered in Bloxs, typically to check its approval status, invoicing progress, or totals against the original quote.

A purchase order belongs to a specific owner's financial administration and a specific relation (the supplier).


Request Fields

Field

Type

Required

Description

reference

string

Required (at least one of reference or externalIdentifier must be given)

The internal identifier of the purchase order.

externalIdentifier

string

Required (at least one of reference or externalIdentifier must be given)

The external API identifier of the purchase order.


Response Fields

Field

Type

Required

Description

reference

string, max 100

Required

The internal identifier (Reference/Code) of the purchase order.

externalIdentifier

string, max 100

Required

The external API identifier of the purchase order, if any.

ownerReference

string, max 100

Required

The internal identifier (Reference/Code) of the owner whose financial administration this purchase order belongs to.

relationReference

string, max 100

Required

The internal identifier (Reference/Code) of the supplier this purchase order was issued to.

proposalReference

string, max 100

Required

The reference of the externally supplied quote (proposal) from the supplier that this purchase order is based on.

proposalTotalAmountExcl

number (double), nullable

Optional

The total amount excluding VAT stated on the supplier's quote, in the administration's base currency (major units).

subject

string, max 512, nullable

Optional

The subject or description line of the purchase order.

workflowState

integer (enum)

Optional

The approval workflow state of this purchase order. Allowed values: 1 = Draft, 2 = OnHold, 3 = Cancelled, 4 = ApprovalWorkflow, 7 = Final, 9 = Disapproved, 10 = OwnerApprovalWorkflow, 11 = DisapprovedByOwner.

finalizationState

integer (enum)

Optional

The invoicing progress of this purchase order, independent of its approval workflowState. Allowed values: 0 = Open, 1 = Completed, 2 = Closed.

totalAmountExcl

number (double)

Optional

The total purchase order amount excluding VAT, calculated from its own lines, in the administration's base currency (major units).

invoicedAmount

number (double), nullable

Optional

The amount already invoiced against this purchase order, calculated by Bloxs from purchase invoices referencing it, in the administration's base currency (major units).

outstandingAmount

number (double), nullable

Optional

The amount of this purchase order not yet invoiced, calculated by Bloxs, in the administration's base currency (major units).

lines

array of objects, nullable

Optional

The purchase order's line items. See sub-fields below.

lines.lineIndex

integer

Optional

The position of this line within the purchase order.

lines.expectedDate

string (date)

Required (within each line)

The expected date for this line, formatted as ISO 8601 (YYYY-MM-DD).

lines.description

string, max 512, nullable

Optional

The description text for this line.

lines.ledgerAccountCode

string, max 12

Required (within each line)

The general ledger account code this line is booked to.

lines.realEstateObjectReference

string, max 100, nullable

Optional

The internal identifier of the real estate object this line is allocated to, if applicable.

lines.taxRateCode

string, max 100, nullable

Optional

The VAT/tax rate applied to this line, represented as a descriptive label rather than a short code.

lines.amountExcl

number (double)

Required (within each line)

The line amount excluding VAT, in the administration's base currency (major units).

Security
Query parameters
reference
string

The internal identifier of the model (i.e. Reference, Code, Name, depends on model).

externalIdentifier
string

The external API identifier of the model.

Responses
200

OK

Expand All
object
reference
string
Min length0
Max length100
externalIdentifier
string
Min length0
Max length100
ownerReference
string
Min length0
Max length100
relationReference
string
Min length0
Max length100
proposalReference
string
Min length0
Max length100
proposalTotalAmountExcl
number (double) | null
subject
string | null
Min length0
Max length512
workflowState
integer (int32)

Draft = 1 OnHold = 2 Cancelled = 3 ApprovalWorkflow = 4 Final = 7 Disapproved = 9 OwnerApprovalWorkflow = 10 DisapprovedByOwner = 11

finalizationState
integer (int32)

Open = 0 Completed = 1 Closed = 2

totalAmountExcl
number (double)
invoicedAmount
number (double) | null
outstandingAmount
number (double) | null
lines
Array of object (PurchaseOrderLineAPIModel) | null
object
lineIndex
integer (int32)
expectedDate
string (date)
description
string | null
Min length0
Max length512
ledgerAccountCode
string
Min length0
Max length12
realEstateObjectReference
string | null
Min length0
Max length100
taxRateCode
string | null
Min length0
Max length100
amountExcl
number (double)
404

The requested purchase order was not found.