Create Invoice
POST {{baseUrl}}/orders/invoices
This endpoint allows you to create an invoice to a specific order from your side, either as an uploaded file, path url, or ordinary data and order in your body request.
💡 Note
For the
orderdata type, you will need to specify the Invoice issuance to be from Salla. However, for the other data types available, such asdata,url, andfile, you will need to set it to custom from the Store Settings.
Request Body
{"order_id"=>"<integer>", "type"=>"credit_note", "data_type"=>"file", "url"=>"<string>", "invoice_number"=>"<string>", "sub_total"=>"<number>", "total"=>"<number>", "shipping_cost"=>"<number>", "cash_on_delivery_cost"=>"<number>", "tax"=>"<number>", "tax_value"=>"<integer>"}
HEADERS
| Key | Datatype | Required | Description |
|---|---|---|---|
Content-Type | string | ||
Accept | string |
RESPONSES
status: OK
{"status":"\u003cnumber\u003e","success":"\u003cboolean\u003e","data":{"id":"\u003cnumber\u003e","order_id":"\u003cinteger\u003e","type":"\u003cstring\u003e","sub_total":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"},"shipping_cost":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"},"cod_cost":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"},"discount":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"},"tax":{"percent":"\u003cstring\u003e","amount":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"}},"total":{"amount":"\u003cnumber\u003e","currency":"\u003cstring\u003e"},"date":"\u003cstring\u003e","items":[{"id":"\u003cnumber\u003e","item_id":"\u003cnumber\u003e","name":"\u003cstring\u003e","quantity":"\u003cnumber\u003e","price":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"},"discount":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"},"tax":{"percent":"\u003cstring\u003e","amount":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"}},"total":{"amount":"\u003cnumber\u003e","currency":"\u003cstring\u003e"}},{"id":"\u003cnumber\u003e","item_id":"\u003cnumber\u003e","name":"\u003cstring\u003e","quantity":"\u003cnumber\u003e","price":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"},"discount":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"},"tax":{"percent":"\u003cstring\u003e","amount":{"amount":"\u003cstring\u003e","currency":"\u003cstring\u003e"}},"total":{"amount":"\u003cnumber\u003e","currency":"\u003cstring\u003e"}}]}}