ErrorsBy category
Invoices errors
All error codes returned by the Invoices endpoints (132 total).
Every error returned by the Invoices endpoints. Click any code for the full example response and localized messages.
| Code | Message |
|---|---|
ATTACH_SOURCE_INVOICE_UNAVAILABLE | A source invoice is not available (it does not exist or you no longer have access); uncheck the source invoices attachment to send without the folder |
ATTACH_SOURCE_INVOICES_NO_SOURCES | The invoice has no consolidation disbursements: there are no source invoices to attach |
ATTACH_SOURCE_INVOICES_REQUIRES_PDF | Attaching the source invoices also requires attaching the invoice PDF |
ATTACH_SOURCE_PDF_MISSING | These source invoices have no generated PDF: {0} |
ATTACH_SOURCE_ZIP_TOO_LARGE | The source invoices ZIP ({0} MB) exceeds the maximum sendable size ({1} MB) |
BULK_PDF_ERROR | Error processing bulk PDF download |
CANCELLATION_VIA_SPECIFIC_ENDPOINT | To cancel an invoice use the specific cancellation endpoint |
CANNOT_DUPLICATE_DELETED_INVOICE | Cannot duplicate a deleted invoice |
COMPANY_NOT_ACTIVATED | The company is not activated in this environment: it cannot issue fiscal documents |
CONVERSION_REQUIRES_PROFORMA | Only a proforma invoice can be converted into an invoice; this document is not a proforma |
CORRECTIVE_INVOICE_INCOMPLETE | A corrective invoice must declare its rectification type and VeriFactu code (R1-R5). Create the corrective invoice from the original invoice. |
CORRECTIVE_NOT_RECTIFIABLE | A corrective invoice cannot be rectified. To fix an erroneous corrective, issue another corrective against the original invoice. |
DELETION_FAILED | Error deleting the invoice |
DUE_DATE_BEFORE_ISSUE_DATE | Due date cannot be before the issue date |
EMISSION_NOT_READY | The company is not ready to issue invoices in this environment |
EXEMPT_ZERO_RATE_REQUIRES_REASON | Lines with 0% tax rate must declare an exemption reason. Use one of: EXENTA_ART_20..26, NO_SUJETA_ART_7_9, NO_SUJETA_LOCALIZACION, ISP_ART_84_2_*, OTRO |
EXEMPTION_REGIME_NOT_SUPPORTED_IN_VERIFACTU | The given exemption reason corresponds to a special regime (REAEA, equivalence surcharge, cash basis, investment gold…), not to an art. 20-26 LIVA exemption. VeriFactu models it with clave_regimen, not operacion_exenta. Switch to the appropriate clave_regimen. |
EXEMPTION_REQUIRES_RECIPIENT_ID_TYPE | Exemption {0} requires the recipient to carry an alternative identifier of type {1} |
INVALID_IRPF | Invalid income tax withholding type: ''{0}''. Allowed values: {1} |
INVALID_IVA_SURCHARGE_PAIR | Surcharge {0}% is not valid for VAT {1}%. Allowed pairs: 21↔5.2, 10↔1.4, 4↔0.5 |
INVALID_LINE | The invoice line is not valid: {0} |
INVALID_PERCENTAGE | Tax percentage {0}% is not valid for {1}. Valid rates: {2} |
INVALID_REGIME_KEY_FOR_TAX_TYPE | Regime key {0} is not valid for {1}. Valid regime keys: {2} |
INVALID_SURCHARGE | Invalid equivalence surcharge type: ''{0}''. Allowed values: {1} |
INVALID_TAX | The tax type ''{0}'' is not valid |
INVALID_VAT | Invalid VAT type: ''{0}''. Allowed values: {1} |
INVOICE_ALREADY_VOIDED | This invoice is already voided; voiding cannot be repeated |
INVOICE_CLIENT_NOT_FOUND | Customer not found: {0} |
INVOICE_DUPLICATE_EXTERNAL_REFERENCE | An invoice with this external reference already exists |
INVOICE_NO_LINES | The invoice must have at least one line |
INVOICE_NOT_CORRECTIBLE_IN_CURRENT_STATUS | This invoice cannot be corrected in its current status. Only an issued, non-voided invoice can be corrected. |
INVOICE_NOT_FOUND | Invoice not found |
INVOICE_NOT_SCHEDULED | The invoice is not scheduled |
INVOICE_REQUIRES_AT_LEAST_ONE_NORMAL_LINE | The invoice must contain at least one NORMAL line (disbursements cannot be invoiced alone) |
INVOICE_SERIES_NOT_FOUND | Invoice series ''{0}'' not found |
INVOICE_STATUS_NOT_SCHEDULABLE | The current invoice status does not allow scheduling |
ISP_INCOMPATIBLE_WITH_SURCHARGE | Reverse-charge (ISP) lines cannot carry equivalence surcharge: the buyer auto-liquidates VAT in their country and Spanish retail surcharge does not apply |
ISSUE_DATE_IN_FUTURE | Issue date cannot be in the future. To issue an invoice on a future date, use POST /v1/invoices/{id}/schedule |
ISSUE_DATE_REQUIRED | Issue date is required |
LINE_DECLARED_TOTAL_FORBIDS_DISCOUNT | A declared total is incompatible with an explicit discount: any discount is already included in the total |
LINE_EXEMPTION_TEXT_REQUIRED | A descriptive text is required when the exemption reason is OTHER |
LINE_EXEMPTION_WITH_TAX | Line has an exemption reason but the tax rate is not 0%. Current value: {0}% |
LINE_INVALID_DISCOUNT | The discount must be between 0 and 100. Received value: {0} |
LINE_INVALID_QUANTITY | The quantity cannot be zero or null |
LINE_MAIN_TAX_REQUIRED | Each line must specify its main tax (main_tax). No default tax is applied. |
LINE_NEGATIVE_PRICE | The unit price cannot be negative |
LINE_NORMAL_DESCRIPTION_REQUIRED | Normal lines must include a description of the concept |
LINE_SUPLIDO_MUST_HAVE_NO_IRPF | SUPLIDO lines cannot apply withholding tax (IRPF) |
LINE_SUPLIDO_MUST_HAVE_NO_RECARGO | SUPLIDO lines cannot apply equivalence surcharge |
LINE_SUPLIDO_MUST_HAVE_NO_TAX | SUPLIDO lines cannot apply VAT — the main tax must be 0% or empty |
LINE_SUPLIDO_PRICE_REQUIRED | Unit price is required on SUPLIDO lines |
LINE_SUPLIDO_QUANTITY_REQUIRED | Quantity is required on SUPLIDO lines |
LINE_SUPLIDO_REFERENCE_REQUIRED | SUPLIDO lines must declare a reference to the original third-party invoice |
LINE_SUPLIDO_SOURCE_INVOICE_NOT_FOUND | One of the disbursement's source invoices does not exist or does not belong to you |
LINE_SUPLIDO_SOURCE_INVOICE_NOT_ISSUED | A disbursement's source invoices must be issued |
LINE_SUPLIDO_TOO_MANY_SOURCE_ACCOUNTS | A disbursement line cannot consolidate invoices from that many different accounts |
LINE_SUPLIDO_TOO_MANY_SOURCES | A disbursement line cannot consolidate that many source invoices |
LINE_TOTAL_INCONSISTENT | Line totals do not reconcile: expected {0}€ (base + VAT + surcharge - IRPF), declared {1}€. Difference exceeds 0.01€ |
LINE_UNIT_PRICE_XOR_DECLARED_TOTAL | The line must carry exactly one of unit_price, total_excluding_tax or total_including_tax |
LINE_ZERO_PRICE | The unit price cannot be zero |
MARK_SENT_ALREADY_SENT | The invoice is already in SENT status. |
MARK_SENT_FROM_DRAFT_NOT_ALLOWED | Cannot mark an invoice in DRAFT status as SENT. Issue it first. |
MARK_SENT_FROM_INVALID_STATE | Cannot mark as SENT from status {0}. |
MARK_SENT_FROM_LATER_STATE | Cannot mark an invoice in {0} status as SENT. The invoice is already in a later state. |
METADATA_FILTER_TOO_MANY_KEYS | The metadata filter supports at most {0} key/value pairs per request |
NEGATIVE_TOTAL_REQUIRES_RECTIFICATIVE | The invoice total cannot be negative. Use corrective invoices (R1-R5) for refunds. |
NO_INVOICES_PROVIDED | No invoices provided |
NO_PDFS_AVAILABLE | No PDFs available for download |
ONLY_DRAFT_EMITTABLE | Only draft invoices can be issued. Current status: {0} |
OPERATION_DATE_AFTER_ISSUE_DATE | Operation date cannot be after the issue date |
OSS_REGIME_INCOMPATIBLE_WITH_ISP | OSS/IOSS regime (key 17) is incompatible with reverse charge. The destination-country VAT is declared separately (Modelo 369), not as S2 |
PAYMENT_DATE_REQUIRED | Payment date is required to mark the invoice as paid |
PDF_HASH_ERROR | Error calculating PDF hash |
PDF_NOT_GENERATED | The invoice PDF has not been generated yet |
PDF_URL_EMPTY | The PDF URL is empty |
PERCENTAGE_OUT_OF_RANGE | The percentage {0} is not valid. It must be between 0 and 100 |
PREVIEW_DRAFT_ONLY | PDF preview is only available for draft invoices |
PREVIEW_GENERATION_ERROR | Error generating PDF preview |
PROFORMA_ALREADY_CONVERTED | This proforma has already been converted into an invoice; conversion cannot be repeated |
PROFORMA_CORRECTIVE_FORBIDDEN | A proforma invoice cannot be corrected; it is not a fiscal document |
PROFORMA_NOT_CONVERTIBLE | A proforma can only be converted while it is active; its current status ({0}) does not allow it |
PROFORMA_NOT_ISSUABLE | A proforma invoice is not issued: it is born active and becomes an invoice when the customer accepts it |
PROFORMA_NOT_RECURRING | A proforma invoice cannot be recurring; a quote is a one-off offer, not a subscription |
PROFORMA_OVERDUE_FORBIDDEN | A proforma invoice never becomes overdue; its validity date is informational |
PROFORMA_PAYMENT_FORBIDDEN | A proforma invoice cannot be marked as paid; it is not part of the payment cycle |
PROFORMA_RECIPIENT_REQUIRED | A proforma invoice requires a recipient (customer or complete recipient data) |
PROFORMA_SCHEDULE_FORBIDDEN | A proforma invoice cannot be scheduled; scheduling is a fiscal issuance flow |
PROFORMA_TRANSITION_FORBIDDEN | A proforma invoice can only be active, converted or voided; that status change belongs to the fiscal cycle |
PROFORMA_TYPE_CHANGE_FORBIDDEN | Cannot change type to/from PROFORMA; use the conversion flow |
RECIPIENT_ADDRESS_REQUIRED | Recipient address is required for standard invoices |
RECIPIENT_FISCAL_NAME_REQUIRED | Recipient legal name is required for standard invoices |
RECIPIENT_ID_REQUIRED | Recipient must have a NIF or alternative identifier |
RECIPIENT_NIF_AND_ID_OTHER_EXCLUSIVE | The recipient cannot carry both a Spanish NIF and an alternative identifier. Use only one |
RECIPIENT_REQUIRED_FOR_ORDINARY | Ordinary invoices require a valid recipient |
RECTIFICATION_REASON_TOO_SHORT | The rectification reason must be at least {0} characters |
RECTIFICATIVA_PARCIAL_SIN_LINEAS | Partial rectificative invoices must include correction lines. Use negative quantities/amounts to subtract, positive to add. |
RECTIFICATIVA_TOTAL_CON_LINEAS | Total rectificative invoices must not include lines. Lines are automatically copied from the original invoice with negative amounts. |
RECURRING_ALREADY_ENDED | The recurrence has already reached its end date and cannot generate more invoices |
RECURRING_END_DATE_BEFORE_START | The end date must be after the first scheduled generation ({0}) |
RECURRING_INVALID_DAY_OF_MONTH | The day of the month must be between 1 and 31 |
RECURRING_INVOICE_DELETED | Cannot create recurrence from a deleted invoice |
RECURRING_NO_LINES | At least one line must be included |
RECURRING_NOT_FOUND | Recurring invoice not found |
RECURRING_START_DATE_NOT_EDITABLE | Cannot modify the start date because invoices have already been generated |
RECURRING_TYPE_NOT_SUPPORTED | Cannot create a recurrence from a rectificative invoice |
REGIME_REQUIRES_INCOMPATIBLE_EXEMPTION | Regime {0} requires exemption reason {1}; the line does not carry it |
REGIME_REQUIRES_SURCHARGE | Regime {0} requires recargo de equivalencia and the line does not carry it |
REVERT_ONLY_FROM_SENT | Can only revert from SENT status. Current status: {0} |
SCHEDULED_DATE_IN_PAST | The scheduling date cannot be in the past |
SCHEDULED_DATE_REQUIRED | The scheduling date is required |
SERIES_DOCUMENT_TYPE_INCOMPATIBLE | Series ''{0}'' (type {1}) is not compatible with invoices of type {2} |
SERIES_FORMAT_EMPTY | The format cannot be empty |
SERIES_FORMAT_INVALID_PADDING | Invalid padding for {NUM}: {0} |
SERIES_FORMAT_LOWERCASE_VARS | Lowercase variables detected: {0}. Variables must be UPPERCASE (e.g., '{CODIGO}', '{YYYY}', '{MM}', '{NUM}') |
SERIES_FORMAT_NUM_REQUIRED | Variable {NUM} is required in the format. Sequential numbering is required by law |
SERIES_FORMAT_UNRECOGNIZED_VARS | Unrecognized variables: {0}. Valid variables: '{CODIGO}', '{YYYY}', '{YY}', '{MM}', '{NUM}', '{NUM:X}' |
SERIES_INACTIVE | The invoice series ''{0}'' is inactive |
SERIES_NUMBER_COLLISION | The number assigned by the series is already in use. Please contact support: the series numbering needs review |
SIMPLIFICADA_FORBIDS_CROSS_BORDER | Simplified invoices cannot cover intra-EU or OSS operations: identify the recipient and issue an ordinary invoice |
SIMPLIFICADA_FORBIDS_IRPF | Simplified invoices cannot carry IRPF withholding (AEAT: retention must not be reported) |
SIMPLIFICADA_FORBIDS_ISP | Simplified invoices cannot carry reverse-charge: the anonymous recipient cannot auto-liquidate |
SIMPLIFICADA_FORBIDS_SURCHARGE | Simplified invoices cannot carry recargo de equivalencia: the retailer must receive an identified ordinary (F1) invoice |
STATUS_NOT_DELETABLE | Cannot delete an invoice in status {0} |
STATUS_NOT_IMPLEMENTED | Status ''{0}'' is not implemented |
STATUS_NOT_MODIFIABLE | The invoice status cannot be modified |
SURCHARGE_REQUIRES_REGIME | Recargo de equivalencia is only compatible with regime 18; the line is on regime {0} |
TEMPLATE_MISSING_REQUIRED_VARIABLE | Template requires variable: {0} |
TEMPLATE_UNKNOWN_VARIABLE | Template contains unknown variable: {0} |
TRANSITION_NOT_SUPPORTED | Transition to status {0} is not supported |
TYPE_CHANGE_CORRECTIVE_FORBIDDEN | Cannot change type to/from CORRECTIVE |
TYPE_REQUIRED | Invoice type is required |
ZIP_GENERATION_ERROR | Error generating ZIP file |