Skip to content

Credit Notes

Issue credit notes to correct or cancel previously sent invoices on the Peppol network.

When to Issue a Credit Note

Credit notes are used to partially or fully reverse a previously sent invoice. Common scenarios include:

  • Full cancellation — the entire invoice was sent in error
  • Partial correction — wrong quantity, price, or VAT rate on some lines
  • Returns — goods returned by the buyer
  • Post-delivery discount — agreed discount after invoice was sent

Sending a Credit Note

Use peppol.invoices.send() with isCreditNote: true. The key difference: you must include an invoiceReference pointing to the original invoice number.

Required Fields

  • invoiceReference — the number of the original invoice being credited
  • invoiceReferenceDate — the issue date of that invoice, YYYY-MM-DD. Recommended everywhere, and required under the French regime (see below)
  • number — a unique credit note number (e.g. CN-2026-001)
  • to, lines — same as invoice
The invoiceReference field is mandatory for credit notes. Omitting it is a validation error: getpeppr requires it so the credit note stays traceable to its invoice, and the network requires an identifier on every reference you give (BR-55).

French credit notes need the invoice date

A credit note that declares the French regime must give both the number and the issue date of the invoice it credits. French invoicing rule BR-FR-CO-05 ignores a reference without its date. If either is missing, getpeppr refuses the credit note with 400 invoices.france_credit_note_reference_invalid before anything is sent, and the message names the field to add.

Quantities are positive

Write each line as you would on the invoice: a positive quantity and a positive unitPrice. The isCreditNote: true flag is what turns the document into a credit, so getpeppr applies the sign for you. To credit two returned units, send quantity: 2, not -2.

  • A zero or negative quantity is refused with 422 invoices.invalid_line_quantity, naming the line, before anything is sent.
  • To reduce the amount credited, add an allowance to the line or to the document.
Credit notes follow the same status lifecycle as invoices. Track delivery with Document Status and receive updates via Webhooks (the standard invoice.* events, e.g. invoice.sent, invoice.paid).
import { Peppol } from "@getpeppr/sdk";

const peppol = new Peppol({ apiKey: "sk_live_..." });

// A credit note MUST reference the original invoice
const creditNote = await peppol.invoices.send({
  number: "CN-2026-001",
  isCreditNote: true,
  invoiceReference: "INV-2026-042",  // required
  invoiceReferenceDate: "2026-03-15", // its issue date — required in France

  to:   { name: "ACMEDIA",  peppolId: "0208:0685660237", street: "Avenue Louise 54", city: "Brussels", postalCode: "1050", country: "BE" },

  lines: [
    { description: "Arc Reactor Maintenance Q1 — cancelled", quantity: 1, unitPrice: 50_000, vatRate: 21 },
  ],

  paymentTerms: "Refund within 14 days",
  paymentIban: "BE68539007547034",
});

console.log(`Credit note sent: ${creditNote.id}`);