POST
/
v1
/
purchase-order
Create 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
    }
  ]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Response

201 - application/json

The response is of type object.