Create a Return Against an Order

POST {{baseUrl}}/v1/orders/:orderId/returns

Make a return against an order. The maximum amount of the return is the amount of the order

Request Body

{"items"=>[{"description"=>"<string>", "parent"=>"<string>", "type"=>"sku", "quantity"=>"<number>", "currency"=>"<string>", "amount"=>"<number>", "order_id"=>"<string>"}, {"description"=>"<string>", "parent"=>"<string>", "type"=>"sku", "quantity"=>"<number>", "currency"=>"<string>", "amount"=>"<number>", "order_id"=>"<string>"}], "order_id"=>"<string>"}

HEADERS

KeyDatatypeRequiredDescription
Content-Typestring
Acceptstring

RESPONSES

status: OK

{&quot;data&quot;:{&quot;id&quot;:&quot;\u003cstring\u003e&quot;,&quot;amount&quot;:&quot;\u003cnumber\u003e&quot;,&quot;created&quot;:&quot;\u003cinteger\u003e&quot;,&quot;currency&quot;:&quot;KES&quot;,&quot;items&quot;:[{&quot;amount&quot;:&quot;\u003cnumber\u003e&quot;,&quot;currency&quot;:&quot;CDF&quot;,&quot;description&quot;:&quot;\u003cstring\u003e&quot;,&quot;parent&quot;:&quot;\u003cnumber\u003e&quot;,&quot;quantity&quot;:&quot;\u003cnumber\u003e&quot;,&quot;type&quot;:&quot;\u003cstring\u003e&quot;},{&quot;amount&quot;:&quot;\u003cnumber\u003e&quot;,&quot;currency&quot;:&quot;KPW&quot;,&quot;description&quot;:&quot;\u003cstring\u003e&quot;,&quot;parent&quot;:&quot;\u003cnumber\u003e&quot;,&quot;quantity&quot;:&quot;\u003cnumber\u003e&quot;,&quot;type&quot;:&quot;\u003cstring\u003e&quot;}],&quot;order&quot;:&quot;\u003cstring\u003e&quot;,&quot;refund&quot;:&quot;\u003cstring\u003e&quot;},&quot;status&quot;:{&quot;error_code&quot;:&quot;\u003cstring\u003e&quot;,&quot;message&quot;:&quot;\u003cstring\u003e&quot;,&quot;operation_id&quot;:&quot;\u003cstring\u003e&quot;,&quot;response_code&quot;:&quot;\u003cstring\u003e&quot;,&quot;status&quot;:&quot;\u003cstring\u003e&quot;}}