# The purchase order object

| Attribute                  | Description                                                                                                                                                                                                                                           |
| :------------------------- | :---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| id                         | Unique identifier for the object.                                                                                                                                                                                                                     |
| status                     | Status of the order. Possible values are “NOT\_RECEIVED”, “PARTIALLY\_RECEIVED”, and “RECEIVED”.                                                                                                                                                      |
| billing\_status            | Indicating the status of generating the bill through accounting integration to either Xero or QuickBooks Online. Possible values are “BILLED”, “NOT\_BILLED” and “PARTIALLY\_BILLED”. “PARTIALLY\_BILLED” does not apply to Xero integration.         |
| last\_document\_status     | Status of the last e-mail sent from (O)PO card. Possible values are "NOT\_SENT", "SENDING", "FAILED", and "SENT".                                                                                                                                     |
| order\_no                  | A unique, identifying string used in the UI and controlled by the user.                                                                                                                                                                               |
| entity\_type               | Either "regular" or "outsourced", depending on the purchase order type.                                                                                                                                                                               |
| supplier\_id               | ID of the supplier who this order belongs to.                                                                                                                                                                                                         |
| currency                   | Currency of the purchase order. Filled with supplier currency by default.                                                                                                                                                                             |
| expected\_arrival\_date    | The timestamp when the items are expected to arrive (in full) in your warehouse. ISO 8601 format with time and timezone must be used.                                                                                                                 |
| order\_created\_date       | The timestamp of creating the document. ISO 8601 format with time and timezone must be used.                                                                                                                                                          |
| additional\_info           | A string attached to the object to add any internal comments, links to external files, additional instructions, etc.                                                                                                                                  |
| location\_id               | The ID of the location to which items are received.                                                                                                                                                                                                   |
| ingredient\_availability   | Status of the ingredients required to produce products on an outsourced purchase order. Possible values are "PROCESSED", "IN\_STOCK", "NOT\_AVAILABLE", "EXPECTED", "NO\_RECIPE", "NOT\_APPLICABLE". Only applicable when entity\_type is outsourced. |
| ingredient\_expected\_date | The latest date of a manufacturing order production deadline or a purchasing order expected arrival date that relates to the required ingredient. Only applicable when entity\_type is outsourced.                                                    |
| tracking\_location\_id     | The ID location where the ingredients on the outsourced purchase order are processed. Only applicable when entity\_type is outsourced.                                                                                                                |
| total                      | The total value of the order (including taxes) in purchase order currency.                                                                                                                                                                            |
| total\_in\_base\_currency  | The total value of the order (including taxes) in base currency.                                                                                                                                                                                      |
| purchase\_order\_rows      | An array of purchase order rows.                                                                                                                                                                                                                      |
| created\_at                | The timestamp when the purchase order was created.                                                                                                                                                                                                    |
| updated\_at                | The timestamp when the purchase order was last updated.                                                                                                                                                                                               |

## The purchase order row object

| Attribute                       | Description                                                                                                                                    |
| :------------------------------ | :--------------------------------------------------------------------------------------------------------------------------------------------- |
| id                              | Unique identifier for the object.                                                                                                              |
| quantity                        | The quantity of items for the order line.                                                                                                      |
| variant\_id                     | ID of product or material variant added to the order line.                                                                                     |
| tax\_rate\_id                   | ID of tax added to price per unit.                                                                                                             |
| price\_per\_unit                | The sales price of one unit (excluding taxes) in sales order currency.                                                                         |
| purchase\_uom                   | The unit used to measure the quantity of the items (e.g. pcs, kg, m) you purchase. It can be different from the unit used to track stock.      |
| purchase\_uom\_conversion\_rate | The conversion rate between the purchase and stock tracking UoMs.                                                                              |
| batch\_transactions             | An array of batch transactions and their quantities. You can receive stock for the same item in multiple batches.                              |
| batch\_transaction.batch\_id    | ID of the batch for the received item.                                                                                                         |
| batch\_transactions.quantity    | The quantity received in a particular batch.                                                                                                   |
| total                           | The total value of the purchase order row (excluding taxes) in purchase order currency.                                                        |
| total\_in\_base\_currency       | The total value of the purchase order row (excluding taxes) in base currency.                                                                  |
| conversion\_rate                | Currency rate used to convert from purchase order currency into factory base currency.                                                         |
| conversion\_date                | The date of the conversion rate used.                                                                                                          |
| received\_date                  | The date when the items on the purchase order row were received to your stock.                                                                 |
| created\_at                     | The timestamp when the purchase order row was created.                                                                                         |
| updated\_at                     | The timestamp when the purchase order row was last updated.                                                                                    |
| arrival\_date                   | The timestamp when the item on the row is expected to arrive (in full) in your warehouse. ISO 8601 format with time and timezone must be used. |