curl --request PATCH \
--url http://localhost:3001/v1/purchase-order/{id} \
--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"
}'
{
"id": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"purchaseOrderNumber": "<string>",
"externalId": "<string>",
"orderDate": "2023-11-07T05:31:56Z",
"deliveryDate": "2023-11-07T05:31:56Z",
"supplierId": "<string>",
"lineItems": [
{
"id": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"productCode": 123,
"title": "<string>",
"description": "<string>",
"quantity": 123,
"unit": 123,
"unitPrice": 123,
"totalPrice": 123,
"discount": 123,
"taxRate": 123,
"taxAmount": 123
}
]
}
Update a purchase order by its unique identifier.
curl --request PATCH \
--url http://localhost:3001/v1/purchase-order/{id} \
--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"
}'
{
"id": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"purchaseOrderNumber": "<string>",
"externalId": "<string>",
"orderDate": "2023-11-07T05:31:56Z",
"deliveryDate": "2023-11-07T05:31:56Z",
"supplierId": "<string>",
"lineItems": [
{
"id": "<string>",
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z",
"productCode": 123,
"title": "<string>",
"description": "<string>",
"quantity": 123,
"unit": 123,
"unitPrice": 123,
"totalPrice": 123,
"discount": 123,
"taxRate": 123,
"taxAmount": 123
}
]
}
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
The response is of type object
.