Create a credit note

Reverse a posted invoice with a credit note.

POST https://cotlet.dev/api/v1/odoo/invoices/{invoice_id}/credit-notes

write Confirm

Uses the Credit Note window of the invoice. In reverse mode the credit note is a draft prefilled from the original invoice. In reverse_and_new mode it is validated, reconciled with the original and a new draft invoice is opened. If money goes back to the customer, register that payment afterwards. By default you confirm each call; you can switch that off for this tool.

Parameters

Parameters: create_credit_note
NameTypeDescription
invoice_id integer required integer Invoice ID from list_invoices or create_draft_invoice.
reason string required string Reason shown on the credit note.
mode enum enum reverse: a draft credit note you can adjust; reverse_and_new: a validated credit note plus a new draft invoice. Default: reverse.

Request

cURL
curl -X POST https://cotlet.dev/api/v1/odoo/invoices/1/credit-notes \
  -H "Authorization: Bearer $COTLET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"reason":"reason"}'
Python
result = client.call("odoo", "create_credit_note", {"invoice_id":1,"reason":"reason"})
Node.js
const result = await cotlet.call('odoo', 'create_credit_note', {"invoice_id":1,"reason":"reason"});
CLI
cotlet call odoo create_credit_note --data '{"invoice_id":1,"reason":"reason"}'

Example response

JSON

{
  "credit_note_id": 4230,
  "reverses": "INV/2026/00398",
  "mode": "reverse",
  "status": "draft",
  "reason": "Wrong quantity",
  "amount_total": 2150,
  "currency": "EUR"
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.