Back

Search

Search

Methods

Inventory

OrderPrintStatus
Orders

PurchaseOrder /Modify_AdditionalCostAllocation

Allows 150 calls per minute

Response: Modify_AdditionalCostAllocationResponse



Modify additional cost allocation items

Parameters

NameTypeDescription
requestModify_AdditionalCostAllocationRequest

Permissions

GlobalPermissions.Inventory.PurchaseOrder.EditPurchaseOrderNode

Example Request

The following request format is required for this method.

Get

Endpoint URL

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

GET https://eu-ext.linnworks.net/api/PurchaseOrder/Modify_AdditionalCostAllocation?request=%7B%0D%0A%20%20%22PurchaseId%22%3A%20%2293a024ce-2a73-4160-a6dc-fa208ef7ea0f%22%2C%0D%0A%20%20%22itemsToAdd%22%3A%20%5B%0D%0A%20%20%20%20%7B%0D%0A%20%20%20%20%20%20%22PurchaseItemId%22%3A%20%223bd69797-d46a-4df4-ae34-75160f4e710e%22%2C%0D%0A%20%20%20%20%20%20%22Id%22%3A%20%22bdce9f98-a8c3-4fd7-bd90-cc25d494d4bc%22%2C%0D%0A%20%20%20%20%20%20%22PurchaseAdditionalCostItemId%22%3A%203%2C%0D%0A%20%20%20%20%20%20%22AllocationPercentage%22%3A%204.0%0D%0A%20%20%20%20%7D%0D%0A%20%20%5D%2C%0D%0A%20%20%22itemsToUpdate%22%3A%20%5B%0D%0A%20%20%20%20%7B%0D%0A%20%20%20%20%20%20%22CostAllocationId%22%3A%201%2C%0D%0A%20%20%20%20%20%20%22Id%22%3A%20%229fd5e459-c5b0-407e-b509-9f2284c840f0%22%2C%0D%0A%20%20%20%20%20%20%22PurchaseAdditionalCostItemId%22%3A%203%2C%0D%0A%20%20%20%20%20%20%22AllocationPercentage%22%3A%204.0%0D%0A%20%20%20%20%7D%0D%0A%20%20%5D%2C%0D%0A%20%20%22itemsToDelete%22%3A%20%5B%0D%0A%20%20%20%201%0D%0A%20%20%5D%0D%0A%7D

Headers

Connection: keep-alive
Accept: application/json
Accept-Encoding: gzip, deflate
Authorization: INSERT_YOUR_TOKEN_HERE

Post

Endpoint URL

POST https://eu-ext.linnworks.net/api/PurchaseOrder/Modify_AdditionalCostAllocation

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.

request={
  "PurchaseId": "93a024ce-2a73-4160-a6dc-fa208ef7ea0f",
  "itemsToAdd": [
    {
      "PurchaseItemId": "3bd69797-d46a-4df4-ae34-75160f4e710e",
      "Id": "bdce9f98-a8c3-4fd7-bd90-cc25d494d4bc",
      "PurchaseAdditionalCostItemId": 3,
      "AllocationPercentage": 4.0
    }
  ],
  "itemsToUpdate": [
    {
      "CostAllocationId": 1,
      "Id": "9fd5e459-c5b0-407e-b509-9f2284c840f0",
      "PurchaseAdditionalCostItemId": 3,
      "AllocationPercentage": 4.0
    }
  ],
  "itemsToDelete": [
    1
  ]
}

Response

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

{
  "ModifiedItems": [
    {
      "Id": "9c16c74a-bfe9-46f6-b0b8-bae07a80443f",
      "CostAllocationId": 2,
      "PurchaseAdditionalCostItemId": 3,
      "PurchaseItemId": "98f47eec-f50a-49d7-a077-74ac5cb0026d",
      "AllocationPercentage": 5.0
    }
  ]
}