Back

Search

Search

Methods

Inventory

Orders

PurchaseOrder /Search_PurchaseOrders

Response: Search_PurchaseOrdersResult



Searches purchase order by a number of parameters, such as Date of Purchase, status, reference number.
Returns paged result of purchase order header.

Parameters

NameTypeDescription
searchParameterSearch_PurchaseOrderParameterSearch Parameter class

HTTP Endpoint

Server /PurchaseOrder / Search_PurchaseOrders

Permissions

GlobalPermissions.PurchaseOrder.SearchPurchaseOrderNode

Example Code

Example Request

The following request format is required for this method.

POST https://eu-ext.linnworks.net//api/PurchaseOrder/Search_PurchaseOrders HTTP/1.1
Host: eu-ext.linnworks.net
Connection: keep-alive
Accept: application/json, text/javascript, */*; q=0.01
Origin: https://www.linnworks.net
Accept-Language: en
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/42.0.2311.90 Safari/537.36
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
Referer: https://www.linnworks.net/
Accept-Encoding: gzip, deflate
Authorization: INSERT_YOUR_TOKEN_HERE

searchParameter={
  "DateFrom": "2019-06-12T09:27:49.8020786+01:00",
  "DateTo": "2019-06-12T09:27:49.8020786+01:00",
  "Status": 0,
  "ReferenceLike": "sample string 1",
  "EntriesPerPage": 2,
  "PageNumber": 3,
  "Location": [
    "9e4d73a0-ee98-4542-8235-4b04e71afd56",
    "50a59e23-26b1-4a53-9755-bb7b44f98800"
  ],
  "Supplier": [
    "3c12b3c3-f34c-4e34-8ad4-a94a640bb855",
    "aec050aa-757d-4277-bca9-40137f639ff1"
  ]
}

Response

This is an example response. Results may vary depending on your data.

{
  "Result": [
    {
      "pkPurchaseID": "69108256-80e5-4e98-ba43-c39edda275fb",
      "fkSupplierId": "cf8ef99f-408c-4226-bf61-dad3fa95ebb2",
      "fkLocationId": "5f407f72-de84-4571-9d55-c014a5591087",
      "ExternalInvoiceNumber": "sample string 4",
      "Status": 0,
      "Currency": "sample string 5",
      "SupplierReferenceNumber": "sample string 6",
      "Locked": true,
      "LineCount": 8,
      "DeliveredLinesCount": 9,
      "UnitAmountTaxIncludedType": 10,
      "DateOfPurchase": "2019-06-12T09:27:52.0666566Z",
      "DateOfDelivery": "2019-06-12T09:27:52.0666566Z",
      "QuotedDeliveryDate": "2019-06-12T09:27:52.0666566Z",
      "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
    },
    {
      "pkPurchaseID": "69108256-80e5-4e98-ba43-c39edda275fb",
      "fkSupplierId": "cf8ef99f-408c-4226-bf61-dad3fa95ebb2",
      "fkLocationId": "5f407f72-de84-4571-9d55-c014a5591087",
      "ExternalInvoiceNumber": "sample string 4",
      "Status": 0,
      "Currency": "sample string 5",
      "SupplierReferenceNumber": "sample string 6",
      "Locked": true,
      "LineCount": 8,
      "DeliveredLinesCount": 9,
      "UnitAmountTaxIncludedType": 10,
      "DateOfPurchase": "2019-06-12T09:27:52.0666566Z",
      "DateOfDelivery": "2019-06-12T09:27:52.0666566Z",
      "QuotedDeliveryDate": "2019-06-12T09:27:52.0666566Z",
      "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
    }
  ],
  "TotalPages": 1,
  "CurrentPageNumber": 2,
  "EntriesPerPage": 3,
  "TotalNumberOfRecords": 4
}