curl --request POST \
--url http://localhost:3001/v1/purchase-order \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"purchaseOrderNumber": "247000-08",
"externalId": "1234567890",
"deliveryDate": "2024-06-21",
"orderDate": "2024-06-21",
"supplierId": "1234567890",
"lineItems": [
{
"externalId": "1234567890",
"productCode": "1234567890",
"title": "Product Title",
"unit": "1234567890",
"quantity": 1,
"unitPrice": 1,
"totalPrice": 100,
"discount": 5,
"taxRate": 20,
"taxAmount": 150
}
]
}'
{
"purchaseOrderNumber": "247000-08",
"externalId": "1234567890",
"deliveryDate": "2024-06-21",
"orderDate": "2024-06-21",
"supplierId": "1234567890",
"lineItems": [
{
"externalId": "1234567890",
"productCode": "1234567890",
"title": "Product Title",
"unit": "1234567890",
"quantity": 1,
"unitPrice": 1,
"totalPrice": 100,
"discount": 5,
"taxRate": 20,
"taxAmount": 150
}
]
}
Create a new purchase order.
curl --request POST \
--url http://localhost:3001/v1/purchase-order \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"purchaseOrderNumber": "247000-08",
"externalId": "1234567890",
"deliveryDate": "2024-06-21",
"orderDate": "2024-06-21",
"supplierId": "1234567890",
"lineItems": [
{
"externalId": "1234567890",
"productCode": "1234567890",
"title": "Product Title",
"unit": "1234567890",
"quantity": 1,
"unitPrice": 1,
"totalPrice": 100,
"discount": 5,
"taxRate": 20,
"taxAmount": 150
}
]
}'
{
"purchaseOrderNumber": "247000-08",
"externalId": "1234567890",
"deliveryDate": "2024-06-21",
"orderDate": "2024-06-21",
"supplierId": "1234567890",
"lineItems": [
{
"externalId": "1234567890",
"productCode": "1234567890",
"title": "Product Title",
"unit": "1234567890",
"quantity": 1,
"unitPrice": 1,
"totalPrice": 100,
"discount": 5,
"taxRate": 20,
"taxAmount": 150
}
]
}
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
The response is of type object
.