Back

Search

Search

Methods

Inventory

OrderPrintStatus
Orders

PurchaseOrder /Add_PurchaseOrderItem

Allows 250 calls per minute

Response: Update_PurchaseOrderItemResponse



Method adds purchase order item to an existing PENDING order. Items can only be added to PENDING purchase orders. Returns class that represents modified/recalculated purchase order header and modified purchase order item line

Parameters

NameTypeDescription
addItemParameterAdd_PurchaseOrderItemParameterAdd purchase item parameter class

Permissions

GlobalPermissions.Inventory.PurchaseOrder.EditPurchaseOrderNode

Example Request

The following request format is required for this method.

Endpoint URL

GET | POST https://eu-ext.linnworks.net/api/PurchaseOrder/Add_PurchaseOrderItem

Headers

Connection: keep-alive
Accept: application/json
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
Accept-Encoding: gzip, deflate
Authorization: INSERT_YOUR_TOKEN_HERE

Request Body

This is an example of the request structure. Results will vary depending on your data.

addItemParameter={
  "pkPurchaseId": "c7d2d006-542c-4d61-954d-203a72809840",
  "fkStockItemId": "feb86b60-6223-43c8-acee-0bd63742384c",
  "Qty": 3,
  "PackQuantity": 4,
  "PackSize": 5,
  "Cost": 1.0,
  "TaxRate": 2.0
}

Response

This is an example of the response JSON. Results will vary depending on your data.

{
  "NewPurchaseOrderItem": {
    "pkPurchaseItemId": "5e552445-4b2e-47c8-95d3-a829ed79ebee",
    "fkStockItemId": "2ae8d8f8-3cd7-4f5a-953c-14043fa4db30",
    "StockItemIntId": 3,
    "Quantity": 4,
    "Cost": 5.0,
    "Delivered": 6,
    "TaxRate": 7.0,
    "Tax": 8.0,
    "PackQuantity": 9,
    "PackSize": 10,
    "SKU": "sample string 11",
    "ItemTitle": "sample string 12",
    "InventoryTrackingType": 13,
    "IsDeleted": true,
    "SortOrder": 15,
    "DimHeight": 16.0,
    "DimWidth": 17.0,
    "BarcodeNumber": "sample string 18",
    "DimDepth": 19.0,
    "BoundToOpenOrdersItems": 20,
    "BinRack": "sample string 21",
    "QuantityBoundToOpenOrdersItems": 22,
    "SupplierCode": "sample string 24",
    "SupplierBarcode": "sample string 25",
    "SkuGroupIds": [
      1
    ]
  },
  "PurchaseOrderHeader": {
    "pkPurchaseID": "61f96dd5-4ef6-4236-95c3-3fea2b9d4243",
    "fkSupplierId": "84308b22-535d-486b-a706-d76e19e9e3c3",
    "fkLocationId": "755bbda2-8ca6-40c9-afe4-3d74373aca7f",
    "ExternalInvoiceNumber": "sample string 4",
    "Status": 0,
    "Currency": "sample string 5",
    "SupplierReferenceNumber": "sample string 6",
    "Locked": true,
    "LineCount": 8,
    "DeliveredLinesCount": 9,
    "UnitAmountTaxIncludedType": 10,
    "DateOfPurchase": "2022-09-05T15:10:03.9197235Z",
    "DateOfDelivery": "2022-09-05T15:10:03.9197235Z",
    "QuotedDeliveryDate": "2022-09-05T15:10:03.9197235Z",
    "PostagePaid": 4.0,
    "TotalCost": 5.0,
    "taxPaid": 6.0,
    "ShippingTaxRate": 7.0,
    "ConversionRate": 8.0,
    "ConvertedShippingCost": 9.0,
    "ConvertedShippingTax": 10.0,
    "ConvertedOtherCost": 11.0,
    "ConvertedOtherTax": 12.0,
    "ConvertedGrandTotal": 13.0
  },
  "BatchInventoryId": 1
}