Skip to main content

Create purchase orders

The POST /pic/link/purchase-orders/create endpoint allows you to create purchase orders (POs) generated from an external system. πŸ‘”πŸ’ΌπŸ€

Authorization​

This endpoint requires authentication through Basic Auth with the username and password of the backend that will consume it. To create and configure a backend, follow the backends tutorial

Request parameters​


This request does not contain parameters of type Path

Examples​

curl --location 'https://<identifier>.api.appliqloud.com/pic/link/purchase-orders/create' \
--header 'Content-Type: application/json' \
--header 'Authorization: Basic <token>' \
--data '{
"inputs": [
{
"header": {
"purchaseOrderId": "450000001",
"purchaseOrderType": "IMPORT",
"accountingEntityId": "AE1",
"vendorBusinessPartnerId": "9715",
"currencyId": "MXN"
},
"items": [
{
"itemId": "10",
"itemType": "GOODS",
"ascriptionType": "INVENTORY",
"productGroupId": "1",
"productId": "101",
"locationId": "MX-LOC",
"storageId": "123123",
"requiredDeliveryDate": "2024-07-22",
"quantity": 5,
"unitId": "EA",
"netUnitPrice": 6000
}
]
}
]
}'

Responses​


The purchase orders were created successfully

{
"success": [
{
"header": {
"purchaseOrderId": "450000001",
"purchaseOrderStatus": "OPEN",
"purchaseOrderType": "IMPORT",
"accountingEntityId": "AE1",
"vendorBusinessPartnerId": "9715",
"currencyId": "MXN",
"netTotalPrice": 6000.0
},
"items": [
{
"itemId": "10",
"itemType": "GOODS",
"ascriptionType": "EXPENSE",
"productGroupId": "1",
"productId": "101",
"locationId": "MX-LOC",
"storageId": "123123",
"requiredDeliveryDate": "2024-07-22",
"quantity": 5,
"unitId": "EA",
"netUnitPrice": 6000.0,
"netTotalPrice": 30000.0
}
]
}
],
"errors": []
}