Skip to main content

Update the status of an invoice

The PUT /pic/link/purchase-invoices/status endpoint allows you to modify the status of an existing invoice. πŸ’ΌπŸ€

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-invoices/status' \
--request PUT \
--header 'Content-Type: application/json' \
--header 'Authorization: Basic <token>' \
--data '{
"inputs": [
{
"invoiceId": "1",
"status": "REJECTED",
"rejectionComments": "Please check the .pdf file"
}
]
}'
caution

Make sure to modify the <identifier> and <token> fields with your company identifier and authentication token respectively.

Responses​


Invoices were successfully updated

{
"success": [
{
"header": {
"invoiceId": "1",
"invoiceStatus": "REJECTED",
"accountingEntityId": "AE1",
"vendorBusinessPartnerId": "1245",
"purchaseOrderId": "450000001",
"invoiceVendorId": "14156",
"headerText": "Invoice",
"invoiceDate": "2024-08-11",
"fiscalYear": "2024",
"totalAmount": 12000.0,
"currencyId": "MXN",
"paidAmount": 0.0,
"plannedPaymentDate": null,
"lastPaymentDate": null,
"rejectionComments": "Please check the .pdf file",
"invoiceFiles": [
{
"fileType": "PDF",
"key": "invoices/d3d3dd51-c701-42f2-b1ff-558f68c3caa9.pdf",
"url":" https://s3.us-west-2.amazonaws.com/dev-apq-demos-bucket/invoices/d3d3dd51-c701-42f2-b1ff-558f68c3caa9.pdf"
}
]
},
"items": [
{
"itemId": "10",
"purchaseOrderItemId": "10",
"unitId": "EA",
"quantity": 2,
"netUnitPrice": 6000.0,
"netTotalPrice": 12000.0,
"taxesAmount": 0.0,
"extraChargesAmount": 0.0,
"totalPrice": 12000.0,
"itemText": null
}
]
}
],
"errors": []
}