purchase_order

Edit Purchase Order

Edit a single purchase order. The purchase order must still be a draft.

put/purchase-orders/{id}

Request

  • Base URL: https://app.zenventory.com/rest
  • URL: https://app.zenventory.com/rest/purchase-orders/{id}
  • Auth: none declared

Path parameters

idinteger required

Id of the purchase order.

Request body

supplierIdinteger required

Id of the supplier that is being ordered from.

supplierNamestring required

Name of the supplier that is being ordered from. Ignored if supplierId is provided.

warehouseIdinteger

Id of the warehouse the items will be delivered to. If no warehouse parameters are given, then the user's current warehouse will be used.

warehouseNamestring

Name of the warehouse the items will be delivered to. Ignored if warehouseId is provided.

draftboolean

True if the purchase order should be created as a draft to allow future editing.

requiredByDatestring date
projectNumberstring
notesstring
shipMethodstring
termsstring
userField1string
userField2string
userField3string
purchasedForClientboolean

Can only be true if the purchase order is for a client.

Response

Success

idinteger
orderNumberstring
draftboolean
completedboolean
deletedboolean
createdDatestring date-time
preparedDatestring date-time
requiredByDatestring date
projectNumberstring
notesstring
shipMethodstring
termsstring
userField1string
userField2string
userField3string

Example response

{
  "id": 333,
  "orderNumber": "PO#375",
  "supplier": {
    "id": 35,
    "name": "Gift"
  },
  "warehouse": {
    "id": 1,
    "name": "Main Warehouse"
  },
  "client": {
    "id": 3,
    "name": "Hardware Store"
  },
  "user": {
    "id": 1,
    "name": "Mr Sparks"
  },
  "draft": true,
  "createdDate": "2020-12-02T10:24:26-07:00",
  "requiredByDate": "2020-12-02",
  "items": [
    {
      "id": 456,
      "itemId": 2306,
      "sku": "FumoFumo-002",
      "description": "Marisa Kirisame",
      "quantity": 10,
      "uom": "Each",
      "unitCost": 20
    },
    {
      "id": 457,
      "itemId": 2330,
      "sku": "FumoFumo-006",
      "description": "Alice Margatroid",
      "quantity": 10,
      "uom": "Each",
      "unitCost": 20
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.