Ir al contenido

tys.returns.create()

Esta página aún no está disponible en tu idioma.

Methodtryyoursize

Record a return of an order line (idempotent by return id and line).

def create(ret: OutcomeReturnInput, *, idempotency_key: Optional[str] = None) -> OutcomeReturnResult
retOutcomeReturnInputObligatorio
Propiedades
idstringObligatorio

Your return (or RMA) ID.

order_idstringObligatorio
line_idstringObligatorio
quantityintegerObligatorio
reasonstringOpcional

size_too_small, size_too_large, fit_other, style, quality, damaged_or_wrong, changed_mind, other; Shopify's ReturnReason codes (SIZE_TOO_SMALL…) and common returns-platform words are mapped. Empty: unspecified.

exchangebooleanOpcional

The item was exchanged rather than refunded.

exchange_sizestringOpcional

The size sent in exchange (implies exchange).

returned_atstringObligatorio
idempotency_keyOptional[str]Opcional= None

OutcomeReturnResult: What was recorded.

tys.returns.create({
"id": "RMA-7", "order_id": "1001", "line_id": "1", "quantity": 1,
"reason": "size_too_small", "returned_at": datetime.now(timezone.utc).isoformat(),
})

¿Te ha resultado útil esta página?