Skip to main content
POST

Bulk cancel invoices

Scope:sales:invoices.write
https://api.holded.com/api/v2/invoices/bulk/cancel

Cancels multiple invoices (facturas) in a single request; returns 207 when some could not be cancelled (e.g. drafts or already cancelled) and 422 when all fail. Use when the user asks to cancel several invoices at once, or "cancelar facturas en bloque". See the single-invoice cancel endpoint for individual cancellations.

Request body

object
ids[]string[]required

List of invoice IDs to cancel

Request

python
import requests

url = "https://api.holded.com/api/v2/invoices/bulk/cancel"
headers = {
    "Authorization": "Bearer YOUR_API_KEY",
    "Accept": "application/json",
}

payload = {
    "ids": [
        "string"
    ]
}
response = requests.post(url, headers=headers, json=payload)
print(response.json())

Responses

Success responses

204All invoices cancelled
207Some invoices could not be cancelledapplication/json
object
messagestring

Human-readable description of the partial failure

Error responses

400Bad requestapplication/json
401Invalid or missing API keyapplication/json
403Insufficient permissionsapplication/json
422Unable to cancel invoicesapplication/json
429Rate limit exceededapplication/json