Create credit note
Endpoint: POST /v10/credit-notes
caution
This endpoint will by default create the credit note as a draft that can be booked later.
If you want to create a booked credit note then pass status: booked
a long with the data.
Parameter | Required | Default | Description |
---|---|---|---|
credit_note | Yes | Credit note data |
Credit note data
Parameter | Required | Default | Description |
---|---|---|---|
customer_id | Yes, if no order_invoice_id is given | Identification of the customer. Use this to create a manual credit note (a credit note that does not come from an invoice) | |
order_invoice_id | Yes, if no customer_id is given | Identification of the invoice that you are trying to fully or partially credit | |
status | open | Is the credit note booked or not? Possible values: open , booked | |
notes | NULL | An optional note/comment | |
lines.* | Yes | An array of object credit notes line data |
Order line data
Parameter | Required | Default | Description |
---|---|---|---|
variant_id | Yes, if no sku or ean is given | The variant ID of the line | |
sku | Yes, if no variant_id or ean is given | The SKU of the line | |
ean | Yes, if no variant_id or sku is given | The EAN of the line | |
quantity | Yes | The number of pieces for this line | |
claim_type | return | The claim type of the line. Possible values: return , claim . return will return the item to inventory, claim will not |
Example
POST /v10/credit-notes
{
"credit_note": {
"customer_id": 1,
"lines": [
{
"sku": "1000-100-XS",
"quantity": 1
},
{
"sku": "1000-100-S",
"quantity": 1
}
]
}
}