curl -X POST https://api.stateset.com/v1/return \ -H "Authorization: Bearer YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "order_id": "ORD-789456", "customer_email": "customer@example.com", "reason_code": "defective", "type": "replacement", "items": [ { "sku": "SHOE-RED-10", "quantity": 1, "reason": "defective", "condition": "B" } ], "customer_notes": "Sole is separating from the shoe" }'
{ "id": "RET-0901f083-aa1c-43c5-af5c", "rma": "RMA-2024-1014", "order_id": "ORD-789456", "customer_email": "customer@example.com", "status": "NEW", "type": "replacement", "reason_code": "defective", "created_at": "2024-01-15T10:30:00Z", "updated_at": "2024-01-15T10:30:00Z", "workflow_id": "wf-return-0901f083", "items": [ { "id": "RLI-123", "sku": "SHOE-RED-10", "quantity": 1, "reason": "defective", "condition": "B", "product_name": "Red Running Shoe Size 10", "refund_amount": 89.99 } ], "shipping": { "carrier": "fedex", "tracking_number": "7799832198765", "label_url": "https://api.stateset.com/labels/RET-0901f083.pdf", "label_created_at": "2024-01-15T10:30:15Z" }, "totals": { "subtotal": 89.99, "tax_refund": 7.20, "shipping_refund": 0.00, "total_refund": 97.19 }, "timeline": [ { "event": "return_created", "timestamp": "2024-01-15T10:30:00Z", "description": "Return request created" }, { "event": "label_generated", "timestamp": "2024-01-15T10:30:15Z", "description": "Shipping label generated and emailed" } ] }
Create a new return record with automatic RMA generation and workflow initiation
returns:write
Authorization: Bearer YOUR_API_KEY
Show Item object properties
defective
not_as_described
wrong_item
damaged
other
A
B
C
D
not_satisfied
arrived_late
damaged_in_transit
replacement
refund
store_credit
Show Address properties