curl --request POST \
--url https://api.cubbo.com/v1/returns/{return_id}/decision \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"decision": "resend"
}
'{
"decision": "cancel_forward",
"return_id": 98765,
"return_status": "CANCELLED"
}Returns
Decide what to do with an order returned by the carrier
When a carrier cannot deliver an order and brings it back, Cubbo creates a return of type
RETURNED_BY_CARRIER in status PENDING and waits for a decision. Use this endpoint to take
that decision:
resend: Cubbo duplicates the original order into a new order (same items, same shipping data, cash-on-delivery and document/pickup requirements carried over), assigns the units reserved by the return to it and ships it again. The return moves toORDEREDand the new order is returned increated_order. Answers 201.cancel_forward: the order is not resent. The reserved units are released back to available inventory and the return moves toCANCELLED. Answers 200.
Only a PENDING return of type RETURNED_BY_CARRIER can be decided; anything else answers
422 RETURN_NOT_DECIDABLE. Your API credentials need the permission to resolve returns.
POST
/
returns
/
{return_id}
/
decision
curl --request POST \
--url https://api.cubbo.com/v1/returns/{return_id}/decision \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"decision": "resend"
}
'{
"decision": "cancel_forward",
"return_id": 98765,
"return_status": "CANCELLED"
}Authorizations
Body
application/json
Response
Decision cancel_forward applied; the return is cancelled.
Lifecycle status of a return.
PENDING: created and waiting for a decision (review of a customer request, or decision on an order returned by the carrier).REQUESTED: resolved; the customer has the return instructions and the goods are expected back.ORDERED: resolved by creating a new (replacement or resend) order.CANCELLED: cancelled before the goods came back; reserved stock was released.ARRIVED_AT_WAREHOUSE: the package arrived at the warehouse and is waiting to be processed.AWAITING_INSPECTION: the package was opened and is waiting for inspection of its contents.RECEIVED: the goods were checked in and are being re-entered into inventory.REENTERED: the goods were fully re-entered into inventory; the return is complete.UNSUCCESSFUL: closed without receiving anything; every expected product was missing on reception.
Available options:
PENDING, REQUESTED, ORDERED, CANCELLED, ARRIVED_AT_WAREHOUSE, AWAITING_INSPECTION, RECEIVED, REENTERED, UNSUCCESSFUL Example:
"PENDING"