returnEstimate
What a return of these lines would withhold and pay back, before it is requested. Scoped like returnCreate, and refused for a replacement that returnCreate would refuse.
Arguments
| Argument | Type | Description |
|---|---|---|
items | [ReturnItemInput!]! |
Returns
| Field | Type | Description |
|---|---|---|
fee | Money | Total withheld across the lines; null when nothing is |
refund | Money | Total paid back across the lines: what was paid for each refunded line less its fee, plus the price difference of each exchanged one. Null for a business unit's return, which is settled by credit note. |
lines | [ReturnEstimateLine!]! |
Example
query ReturnEstimate($items: [ReturnItemInput!]!) { returnEstimate(items: $items) { fee { centAmount currency } refund { centAmount currency } lines { feeReason } }}{ "items": [ { "orderId": "id-1", "lineItemId": "id-1", "quantity": 1 } ]}{ "data": { "returnEstimate": { "fee": { "centAmount": 1, "currency": "EUR" }, "refund": { "centAmount": 1, "currency": "EUR" }, "lines": [ { "feeReason": "Example" } ] } }}The query selects the return type's fields two levels deep; pick the ones you need. The response shows its shape with placeholder values.
Served by
| @evolve-framework/commercetools | Resolved |
Used by
The storefront packages that send it, in these GraphQL documents:
- @evolve-storefront/feature-return:
GetReturnEstimate

