curl --request PUT \
--url https://{host}/cleemy-procurement/api/documents/{id} \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"owner": {
"id": 123
},
"type": "Invoice",
"context": {
"purchase": {
"id": 123,
"type": "Subscription"
}
},
"documentBreakdown": {
"id": 2,
"href": "<string>",
"name": "<string>"
},
"documentDate": "2023-12-25",
"documentNumber": "<string>",
"amountIncludingTaxes": {
"excludingTaxes": {
"value": 123,
"currency": "Invalid"
},
"taxes": [
{
"rateTypeId": 123,
"value": 123,
"currency": "Invalid"
}
],
"includingTaxes": {
"value": 123,
"currency": "Invalid"
}
},
"accountingLabel": "<string>",
"comment": "<string>",
"intraCommunityTaxes": true,
"attachments": [
{
"id": 123,
"file": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"href": "<string>",
"name": "<string>",
"displayHref": "<string>"
},
"createdAt": "2023-11-07T05:31:56Z",
"pages": {
"displayHrefTemplate": "<string>",
"count": 123
}
}
],
"dueDate": "2023-12-25",
"paymentDetails": {
"paymentMethod": "BankTransfer",
"bankAccount": {
"iban": "<string>",
"bic": "<string>"
}
},
"author": {
"id": 123
},
"modifier": {
"id": 123
}
}
'{
"id": 123,
"owner": {
"id": 123,
"href": "<string>",
"name": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"pictureHref": "<string>"
},
"type": "Invoice",
"context": {
"purchase": {
"id": 123,
"href": "<string>",
"name": "<string>",
"type": "Subscription"
}
},
"documentBreakdown": {
"id": 2,
"href": "<string>",
"name": "<string>"
},
"documentDate": "2023-12-25",
"documentNumber": "<string>",
"amountIncludingTaxes": {
"excludingTaxes": {
"value": 123,
"currency": "Invalid"
},
"taxes": [
{
"rateTypeId": 123,
"value": 123,
"currency": "Invalid"
}
],
"includingTaxes": {
"value": 123,
"currency": "Invalid"
}
},
"accountingLabel": "<string>",
"comment": "<string>",
"intraCommunityTaxes": true,
"attachments": [
{
"id": 123,
"file": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"href": "<string>",
"name": "<string>",
"displayHref": "<string>"
},
"createdAt": "2023-11-07T05:31:56Z",
"pages": {
"displayHrefTemplate": "<string>",
"count": 123
}
}
],
"ocrStatus": "Pending",
"dueDate": "2023-12-25",
"paymentDetails": {
"paymentMethod": "BankTransfer",
"bankAccount": {
"iban": "<string>",
"bic": "<string>"
}
},
"createdAt": "2023-11-07T05:31:56Z",
"modifiedAt": "2023-11-07T05:31:56Z",
"author": {
"id": 123,
"href": "<string>",
"name": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"pictureHref": "<string>"
},
"modifier": {
"id": 123,
"href": "<string>",
"name": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"pictureHref": "<string>"
}
}Update a document’s information (e.g. accounting fields, amounts, supplier details) before booking it.
Warning: This is a PUT request — the entire resource must be provided. Any field omitted from the payload may be reset to its default value.
curl --request PUT \
--url https://{host}/cleemy-procurement/api/documents/{id} \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"owner": {
"id": 123
},
"type": "Invoice",
"context": {
"purchase": {
"id": 123,
"type": "Subscription"
}
},
"documentBreakdown": {
"id": 2,
"href": "<string>",
"name": "<string>"
},
"documentDate": "2023-12-25",
"documentNumber": "<string>",
"amountIncludingTaxes": {
"excludingTaxes": {
"value": 123,
"currency": "Invalid"
},
"taxes": [
{
"rateTypeId": 123,
"value": 123,
"currency": "Invalid"
}
],
"includingTaxes": {
"value": 123,
"currency": "Invalid"
}
},
"accountingLabel": "<string>",
"comment": "<string>",
"intraCommunityTaxes": true,
"attachments": [
{
"id": 123,
"file": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"href": "<string>",
"name": "<string>",
"displayHref": "<string>"
},
"createdAt": "2023-11-07T05:31:56Z",
"pages": {
"displayHrefTemplate": "<string>",
"count": 123
}
}
],
"dueDate": "2023-12-25",
"paymentDetails": {
"paymentMethod": "BankTransfer",
"bankAccount": {
"iban": "<string>",
"bic": "<string>"
}
},
"author": {
"id": 123
},
"modifier": {
"id": 123
}
}
'{
"id": 123,
"owner": {
"id": 123,
"href": "<string>",
"name": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"pictureHref": "<string>"
},
"type": "Invoice",
"context": {
"purchase": {
"id": 123,
"href": "<string>",
"name": "<string>",
"type": "Subscription"
}
},
"documentBreakdown": {
"id": 2,
"href": "<string>",
"name": "<string>"
},
"documentDate": "2023-12-25",
"documentNumber": "<string>",
"amountIncludingTaxes": {
"excludingTaxes": {
"value": 123,
"currency": "Invalid"
},
"taxes": [
{
"rateTypeId": 123,
"value": 123,
"currency": "Invalid"
}
],
"includingTaxes": {
"value": 123,
"currency": "Invalid"
}
},
"accountingLabel": "<string>",
"comment": "<string>",
"intraCommunityTaxes": true,
"attachments": [
{
"id": 123,
"file": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"href": "<string>",
"name": "<string>",
"displayHref": "<string>"
},
"createdAt": "2023-11-07T05:31:56Z",
"pages": {
"displayHrefTemplate": "<string>",
"count": 123
}
}
],
"ocrStatus": "Pending",
"dueDate": "2023-12-25",
"paymentDetails": {
"paymentMethod": "BankTransfer",
"bankAccount": {
"iban": "<string>",
"bic": "<string>"
}
},
"createdAt": "2023-11-07T05:31:56Z",
"modifiedAt": "2023-11-07T05:31:56Z",
"author": {
"id": 123,
"href": "<string>",
"name": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"pictureHref": "<string>"
},
"modifier": {
"id": 123,
"href": "<string>",
"name": "<string>",
"firstName": "<string>",
"lastName": "<string>",
"pictureHref": "<string>"
}
}API key. Value must be formatted like so: lucca application={api_key}.
ID of the document.
Document to update.
An invoice document (before booking).
Reference to a user.
Show child attributes
Type of document: Invoice or CreditNote.
Invoice, CreditNote Context data for the document.
Show child attributes
Show child attributes
Represents an amount of money with VAT taxes.
Show child attributes
Show child attributes
Show child attributes
Reference to a user.
Show child attributes
Reference to a user.
Show child attributes
OK
An invoice document (before booking).
Reference to a user.
Show child attributes
Type of document: Invoice or CreditNote.
Invoice, CreditNote Context data for the document.
Show child attributes
Show child attributes
Represents an amount of money with VAT taxes.
Show child attributes
Show child attributes
Status of OCR processing.
Pending, Processing, Processed, Failed, NotApplicable Show child attributes
Reference to a user.
Show child attributes
Reference to a user.
Show child attributes
Was this page helpful?