Generate Invoice
POST {{baseUrl}}/orders/invoices/:order_id/generate
This endpoint allows you to generate an order invoice for a speific order.
OAuth Scopes
orders.read_write
Request Body
{"type"=>"credit_note"}
HEADERS
Key | Datatype | Required | Description |
---|---|---|---|
Content-Type | string | ||
Accept | string |
RESPONSES
status: OK
{"status":200,"success":true,"data":{"id":458282634,"type":"Credit Note","sub_total":{"amount":"300.00","currency":"SAR"},"shipping_cost":{"amount":"182.50","currency":"SAR"},"cod_cost":{"amount":"0.00","currency":"SAR"},"discount":{"amount":"0.00","currency":"SAR"},"tax":{"percent":"0.00","amount":{"amount":"0.00","currency":"SAR"}},"total":{"amount":482.5,"currency":"SAR"},"date":"2022-01-19","items":[{"name":"T-Shirt","quantity":1,"price":{"amount":"300.00","currency":"SAR"},"discount":{"amount":"0.00","currency":"SAR"},"tax":{"percent":"0.00","amount":{"amount":"0.00","currency":"SAR"}},"total":{"amount":300,"currency":"SAR"}}]}}