Returns (returns)
Returns & complaints (Refunds, RMA). Manages the lifecycle of a return or
complaint case raised against a completed order — submission, verification and
RMA-number assignment, reverse-logistics shipments, and settlement (money
refund, store credit, replacement, or repair) including the corrective invoice.
Mirrors the orders module's configurable status-graph workflow.
Public surface
Admin routes are gated by returns:read (read) / returns:write (mutations).
| Verb + Path | Audience | Purpose |
|---|---|---|
GET /api/v1/orders/:orderId/returnable | customer | Returnable lines + eligibility for an order |
POST /api/v1/returns | customer | Open a return/complaint case |
GET /api/v1/returns | customer | List the caller's cases, or the Organization's (see Who may open, see and act on a case) |
GET /api/v1/returns/:id | customer | Case detail (customer-visible comments only) |
POST /api/v1/returns/:id/comments | customer | Reply on a case |
POST /api/v1/returns/:id/select-delivery-method | customer | Choose a return delivery method |
POST /api/v1/returns/:id/attachments | customer | Attach a file to the case |
POST /api/v1/returns/:id/cancel | customer | Withdraw the case |
GET /api/v1/returns/reasons | customer | Active reasons for the storefront form |
GET /api/v1/admin/returns | admin | List/filter/search cases + per-status counts |
GET /api/v1/admin/returns/export | admin | CSV export of the current view |
POST /api/v1/admin/returns/bulk-transition | admin | Bulk status change (skips disallowed) |
GET /api/v1/admin/returns/:id | admin | Case detail (incl. internal comments) |
POST /api/v1/admin/returns/:id/authorize | admin | Assign RMA number, advance to authorized |
POST /api/v1/admin/returns/:id/reject | admin | Reject with a mandatory reason |
POST /api/v1/admin/returns/:id/transition | admin | Guarded status transition |
GET|POST /api/v1/admin/returns/:id/settlement | admin | Prefill / execute settlement |
POST|DELETE /api/v1/admin/returns/:id/alternative-consent | admin | Record / revoke the consumer's consent to a resolution other than a refund (see Consumer withdrawal) |
GET|POST /api/v1/admin/returns/:id/comments | admin | List / add comment (visibility + notify) |
GET|POST /api/v1/admin/returns/:id/shipments + /:shipmentId/receive | admin | Return shipments |
GET|POST /api/v1/admin/returns/list-views | admin | The caller's own saved views plus every shared one / save a view |
PATCH|DELETE /api/v1/admin/returns/list-views/:id | admin | Change / delete a saved view (owner, or a platform admin for a shared one) |
…/statuses, …/transitions, …/reasons, …/delivery-methods | admin | Configuration |
Who may open, see and act on a case
On the storefront a buyer's reach follows their organization role. This module declares two organization permissions, which an Organization's administrator grants per role:
| Permission | Code | Member holds it |
|---|---|---|
| Create returns and complaints | returns.create | yes (member default) |
| View the organization's returns and complaints | returns.view_organization | no |
Administrator holds both, as it holds every permission. One code covers returns and complaints alike: they are one form and one route.
- Opening a case (
POST /api/v1/returns) needsreturns.create. Without it the request is refused403 ORGANIZATION_PERMISSION_REQUIRED, naming the permission, before the order is read; nothing is created. - Which orders a case may be opened for: any order the buyer may read — the
orders they placed, and a colleague's order when their role holds the
ordersmodule's View the organization's orders (orders.view_organization). The rule is theordersmodule's, throughOrderReadPort.findByIdForCustomer, so it matches the order list. An order out of reach answers404to the returnable-lines read and to the submission alike. A case opened from a colleague's order is filed in the name of the member who opened it: its e-mails go to them, and the colleague who placed the order sees the case only withreturns.view_organization. - Seeing cases (
GET /api/v1/returns,GET /api/v1/returns/:id): the cases the buyer filed, or — withreturns.view_organization— every case of their Organization, and of its subtree for a head-office login with roll-up enabled. Roll-up widens the reach; it never grants the permission. A case out of reach answers404, never403. Each case in the list carriescustomerAccountId, the member who filed it. - Acting on a case — commenting, attaching files, choosing the return
delivery method and cancelling — stays with the member who filed it, whatever
anyone else's permissions; to anyone else these requests answer
404. None of them needsreturns.create, so a member whose role loses it can still follow up the cases they already filed. Reading an order's returnable lines needs no permission either.
Before organization roles, every buyer — administrators included — saw and opened cases for the orders they placed only. Member keeps exactly that; an administrator now sees every case of the Organization and may open a case from a colleague's order.
On the storefront:
- Returns (
/returns) lists the cases the member may see. A colleague's case is marked Filed by a colleague. Start a new return is offered only to a member whose role holdsreturns.create; the order page offers its return or complaint entry on the same rule. - Without
returns.create, the new-case page (/returns/new) says so instead of showing the form: "Your role does not include the “Create returns and complaints” permission, so you can't start a return or a complaint. Ask your organization's administrator if you need it." - A colleague's case opens read-only. The page offers no comment box, attachment upload, return delivery choice or cancel button, and says why in one line: "This case was filed by a colleague. You can read it, but only they can add messages or change it." The filer's messages are labelled Colleague, not You.
When the module is switched off, both permissions leave the Organization's permission catalogue and every member's effective permissions; a role's stored grant is kept and applies again when the module is switched back on.
Status machine (configurable)
The case lifecycle is admin-configurable (return_statuses +
return_status_transitions, seeded on install). Defaults:
- new (initial) → authorized → received → resolved → closed (terminal)
- rejected (terminal) reachable from new/authorized/received; cancelled (terminal) from new/authorized.
Transitions are enforced; the initial status is immutable; terminal statuses
have no outgoing edges. Each transition emits templated return.status.*
before/after events and is written to the audit log — whether it had a reason
(hasReason), never the reason's text.
Key behaviours
-
Eligibility & free-return window — a case is allowed once the order reaches its fulfilment-completing status; the free-return window (
returns.free_return_days, default 14, the statutory withdrawal period of Directive 2011/83 art. 9) is counted from that moment and governs who bears the return shipping cost. The moment is the order's completion asordersrecords it (orders.completed_at), which a later edit of the order does not move; in earlier releases it was the order's last edit. See Counting the windows below. -
RMA numbering —
${prefix}${sequence}${suffix}fromreturns.rma_number_prefix/returns.rma_number_suffix, assigned on authorization, unique and never reused. -
Partial / repeat returns — per-line quantity up to the remaining returnable amount, excluding quantities already covered by non-rejected / non-cancelled cases.
-
Settlement — per-line refund defaults to the amount paid for the returned quantity and may never exceed it. For an order placed under the per-rate VAT method that amount is the drop in the value of the goods the buyer keeps: what was left paid less what the kept goods are worth after the return (VAT per rate on the kept nets, less the discount they carry), so it can differ by a cent from the returned units' own value and the order's returns together still refund exactly what was paid. Resolutions: refund (money), credit (tops up the organization's
credit_limitsgrant), replacement, or repair; a consumer withdrawal settles as a refund unless the consumer's consent to another resolution is on record (see Consumer withdrawal). A corrective invoice (invoiceskindcorrection) is requested for money/credit settlements. An order that was never invoiced has no VAT document to correct, so none is issued: the settlement succeeds, the refund is recorded on the return case and the payment record, and the result statescorrectiveInvoice: { issued: false, reason: "order_not_invoiced" }. The invoice issued later lists only what the buyer kept: a return settled with a refund or a credit takes its quantity off the order line, a line returned in full is left off, and the discount the refund carried comes off the invoice's discount line. On an order that was invoiced, a return's correction credits the returned goods and leaves on the invoice the VAT per rate on the nets the buyer kept. -
A complaint refund is a price reduction — a complaint settled with a refund or a credit leaves the goods with the buyer, so on an invoiced order its correction credits the approved amount at the line's VAT rate as a price reduction: quantity 0, no share of the order discount, and no effect on the quantity a later return of the line is credited from. A complaint resolved by replacement or repair issues no correction. A complaint refunded before the order was invoiced currently shows on the invoice as amount due.
-
The default refund is recomputed at settlement — the figure a case shows when it is opened is provisional. The settlement recomputes it, one settlement of an order at a time, from the cases settled by then. Only a return settled with a refund or a credit takes goods off what the buyer keeps; a rejected, replaced or repaired case and every complaint take nothing off. So the figure can move by a cent or two when cases are settled in a different order from the one they were opened in, or after an earlier case was rejected. The settlement form shows the recomputed figure. An approved amount equal to a default the case showed settles at the recomputed default, a lower amount is kept as typed, and a higher one is refused with
422 RETURN_REFUND_EXCEEDS_PAIDwith nothing written: reload the form and confirm. Thereturn.settledaudit entry names the lines whose default moved (recomputedDefaultItemIds), not the amounts. -
No line refunds more than it was paid — a complaint refund counts against the line it names, and the unabsorbed part of it counts against what is left paid for the order: once a return of the line has been cut by the complaint, that amount is not counted twice. A later return of that line still gets its full default, until the line's refunds, the complaint included, reach what the line was paid; from then on the case shows, and the settlement form offers, at most what is left of it, and the audit entry names the line the bound held (
ceilingBoundItemIds). The platform cannot tell which unit came back. Before settling a return, check the order's other cases for an earlier complaint on the same line: if the defective unit the complaint compensated is the one coming back, lower the amount by hand. -
A consumer's withdrawal refunds the delivery and the payment surcharge (Directive 2011/83/EU art. 13(1), Polish Consumer Rights Act art. 32 ust. 1). The case that brings back the last returned unit of a B2C order (the order's organization is a personal one) refunds the order's delivery cost and payment surcharge as well as the goods. All of these must hold:
- the case is a return, not a complaint;
- with this case, every unit of every order line has come back in a return settled with a refund or a credit. An order with a line that could not be returned can never be withdrawn in full, so it never refunds them;
- the case is settled as a refund or a credit. A replacement or a repair refunds neither charge, and an amount above 0 sent for one is refused.
A partial withdrawal refunds neither charge, and the settlement form does not offer them. The settlement form shows a Delivery cost row and a Payment surcharge row, each with what was paid as its maximum. The row is filled in with the full amount when the case was opened within the withdrawal window: 14 days from the order's completion, or the channel's
returns.free_return_dayswhen that is longer. A channel set to0still has the 14 days. Outside the window the row starts at 0 and you may raise it to what was paid. Lower the delivery to the price of the cheapest standard delivery when the customer chose a more expensive one (art. 13(2)). An amount above what was paid is refused with422 RETURN_REFUND_EXCEEDS_PAID(details.codedeliveryorsurcharge). Through the API,deliveryRefundAmountandsurchargeRefundAmountwork differently from the line amounts. When you leave one out, it settles at the default recomputed at settlement. When you send one, it settles at exactly that amount,0included, as long as it is not above the maximum. A figure the case showed when it was opened can be above the maximum by then, and is refused. The settlement form sends only an amount you changed. The case'stotalRefundAmountthen includes the charges, so it is more than the sum of the lines. The case detail reports them aschargeRefunds, and thereturn.settledaudit entry names the charges that were refunded (refundedCharges), not the amounts. A business customer's return and every complaint are unchanged.On an invoiced order, the correction credits the delivery and the surcharge on lines of their own, at the VAT rate the invoice charged them at (0 % today). When everything came back and was refunded, the invoice nets to zero. On an order not invoiced yet, the invoice issued later charges only what is left of each charge, and leaves a line out when nothing is left. So a premium delivery reduced to the standard price is invoiced alone for the difference. When everything was refunded, there is no sale left and the invoice is refused.
Cases settled before this behaviour existed are not changed. To find B2C orders that were returned in full without a delivery refund, see the upgrade guide.
-
A switched-off payment gateway refuses the settlement. Money resolutions on a gateway-paid order call the PSP module that took the payment; when an operator has that module switched off — or the deployment does not offer it — the settlement answers
503 MODULE_DISABLEDnaming the module, withRetry-After. Nothing moves: the case keeps its status, norefundsrow is written, no corrective invoice is issued and no customer e-mail goes out. Switching the module back on is the whole remedy. This is distinct from a deployment that has no PSP refund integration at all, which still settles aspending_manualfor a person to pay out by hand — there is nothing there to switch on. -
Saved views on the Returns list — the Saved views control above the list stores its status, kind and RMA-number filters and its sort (the list has no column picker), privately or shared with every admin who can open the list. The four
list-viewsroutes are gated byreturns:readand follow the same rules as the order, product and quote request lists' saved views: names are trimmed, 1–160 characters, without control or format characters; one admin cannot hold two views whose names differ only by case or surrounding spaces (409 RETURN_SAVED_VIEW_NAME_TAKEN);filtersis capped at 8 KB,visibleColumnsat 64 entries of 64 characters andsort.fieldat 64 characters;sharedandsortare required on create. Another admin's private view and an id that is not a UUID both answer404; a shared view is changed or deleted by its owner or by an admin whose access is not restricted to a set of organizations (403otherwise). List items carryownedByCallerandcanModify, andDELETEanswers{ data: { deleted: <id> } }. Views saved before these rules keep their names as stored — including blank names and duplicates — until their owner renames or deletes them; a change that leaves the name alone is never refused for it.
Refusals
Each refusal below has its own code and a sentence in English and Polish,
which names the values in details. The buyer reads it in the language the
storefront asked for, the operator in their own. Until issue #625 they were
VALIDATION_FAILED, most with the reason in details.code; the status is
unchanged. The status code travels as details.statusCode, because
details.code is the slot for a refusal's token.
| Code | Status | When | details |
|---|---|---|---|
RETURN_ORDER_NOT_ELIGIBLE | 422 | POST /api/v1/returns — the order is not completed yet | orderId |
RETURN_QUANTITY_EXCEEDS_RETURNABLE | 422 | POST /api/v1/returns — a line asks for more than it can still return | orderItemId, requested, remaining |
RETURN_REASON_INACTIVE | 422 | POST /api/v1/returns — the reason was switched off | reasonId |
RETURN_COMMENTS_CLOSED | 409 | a comment on a case in a terminal status | returnCaseId, statusCode |
RETURN_CASE_CLOSED | 409 | POST /api/v1/returns/:id/select-delivery-method on a case in a terminal status | returnCaseId, statusCode |
RETURN_DELIVERY_METHOD_UNAVAILABLE | 422 | the same route — the return delivery method is not offered | returnDeliveryMethodId |
RETURN_SETTLEMENT_IN_PROGRESS | 409 | POST /api/v1/admin/returns/:id/settlement — another return of the order is being settled; try again | orderId |
RETURN_REFUND_EXCEEDS_PAID | 422 | the same route — a refund above what may be refunded, for a line or, with code delivery / surcharge, a charge | returnCaseItemId (a line), requested, maximum, currency |
RETURN_REFUND_GATEWAY_FAILED | 502 | the same route — the payment gateway refused the refund; nothing is settled | settlementState, failureReason (the gateway's words), providerDetails |
RETURN_STATUS_CODE_TAKEN | 409 | POST /api/v1/admin/returns/statuses — another status has the code | statusCode |
RETURN_STATUS_TERMINAL_HAS_TRANSITIONS | 409 / 422 | marking a status with outgoing transitions terminal (code mark_terminal), or a transition from a terminal status in PUT …/transitions (code add_transition) | statusCode, and outgoingCount or toStatusCode |
RETURN_STATUS_NOT_DELETABLE | 409 | deleting the initial status (code initial) | statusCode |
RETURN_STATUS_IN_USE | 409 | deleting a status cases are in | statusCode, caseCount |
Amounts are two-decimal strings. An unknown order line or return line, an
unknown reason id, a missing refund payment method, a blank rejection reason
and a transition naming a status that does not exist stay VALIDATION_FAILED.
Counting the windows
Both windows this module judges — the channel's free-return window and the
consumer's statutory withdrawal period — count from the same moment: when the
order entered its fulfilment-completing status (completingStatusEnteredAt,
from OrderReturnContextPort). An order that has not been completed has not
started either period. The platform has no delivery date (a shipment's success
is the carrier accepting the parcel, which is earlier than the consumer
receiving it), so the operator completing the order is the closest fact there
is; the Orders page asks operators to complete an order when the goods have
been delivered. This module does not read Shipments for it, so switching
Shipments off changes nothing about either window.
- Calendar days in
returns.time_zone. A period of n days ends at the end of the n-th calendar day after the day of completion, in the zone the setting names (an IANA name, defaultEurope/Warsaw, settable per sales channel; a zone the runtime does not know is refused). The day of completion itself is not counted. - Weekends. A last day on a Saturday or Sunday moves to the following Monday. Public holidays are not modelled: there is no holiday calendar.
- The statutory period is 14 days, whatever
returns.free_return_dayssays — a channel set to0or to fewer days cannot shorten it. - A 7-day grace. An operator may complete an order before the parcel arrives, so the consumer's withdrawal stays possible for 7 calendar days after the later of the statutory end and the channel's free-return window. A withdrawal made in the grace is accepted and marked as outside the statutory period, for the operator to judge.
In earlier releases the free-return window ended exactly free_return_days × 24 h
after the order's last edit. It now ends up to a day later (up to three over a
weekend), never earlier. The statutory period and the grace are computed by
domain/withdrawal-period.ts; the withdrawal function that uses them arrives in
a later release.
Consumer withdrawal
A consumer who buys at a distance may withdraw from the contract within the statutory period without giving a reason, and is then reimbursed by the same means of payment unless they expressly agree otherwise (Directive 2011/83 art. 9 and 13(1); in Poland, art. 27 and 32 of the ustawa o prawach konsumenta). This module tells such a case apart from any other return and settles it accordingly.
- Which case is a consumer withdrawal. A
return(never a complaint) by a personal Organization (the one every consumer gets at checkout; never a company), filed while the withdrawal is still possible for the order: the statutory 14 days, the channel's longer free-return window, and the 7-day grace after both (see Counting the windows). The answer is fixed when the case is filed and the case detail reports it asconsumerWithdrawal; the admin case view marks the case Consumer withdrawal. A personal Organization's return filed after the grace is a commercial return under the shop's own policy, and nothing below applies to it. Personal is judged at the moment the order was placed: an order placed while the Organization was personal stays a consumer's after an operator converts that Organization to a company. A sole trader buying through a company Organization may have the same right under Polish law (art. 38a); the platform cannot tell, so an operator handles such a case by hand. - Cases filed before this release carry no answer (
consumerWithdrawal: null) and are treated as ordinary returns. Classifying them needs the Organization, which a migration may not read, so a later release classifies the open ones in the background. - A refund by default. The settlement form starts on Refund money, to
the order's own payment method (
defaultRefundPaymentMethodIdin the settlement prefill). The method is chosen by name from the shop's payment methods, with the order's own listed first and marked; when that list cannot be read, the form falls back to a field for the method's id. Credit, replacement and repair stay visible but cannot be chosen until the consumer's consent is on record, and the settlement refuses them with422 RETURN_ALTERNATIVE_RESOLUTION_CONSENT_REQUIRED(details.resolutionnames the one refused). The prefill names them inconsentRequiredForand keeps every resolution inresolutionOptions. Company returns and complaints are unaffected. - Another payment method warns, and does not refuse. A cash-on-delivery
order cannot be refunded "by the same means", and a bank transfer is the
accepted practice there. The form shows a warning, the settlement goes
through, and its audit entry (
return.settled) recordsconsumerWithdrawal: trueandrefundMethodDiffers: true. - Recording the consumer's consent. The consent normally reaches the shop by
e-mail or telephone. An operator with
returns:writerecords it in the Consumer withdrawal panel of the case: what the consumer agreed to (credit, a replacement or a repair), when (not in the future, not before the case was filed), and an evidence note of up to 2000 characters, for example "Customer's e-mail of 10 Nov 2026, ticket #123". The settlement then accepts that resolution, and still refuses the other two. Recording it again replaces the earlier one. Revoke consent removes it after a confirmation, which says what is lost: the evidence note is deleted, while the history keeps that the consent was recorded and revoked. Both are audited (return_case.alternative_consent.recordand.revoke) with the operator as the actor; the entry holds the resolution, the moment and the source, not the evidence note, which stays on the case. Once the case is settled its consent is frozen: both answer409(details.code: 'consent_frozen'). A case in a terminal status of the configured workflow (rejected,cancelled, or any status an operator marked terminal) can never be settled, so its consent is closed too: both answer409(details.code: 'case_closed'), nothing is written, and the panel shows the consent on record read-only, with no actions. The time the consent was given is shown in the operator's browser time zone, which is named beside it. A case that is not a consumer withdrawal answers422(details.code: 'not_consumer_withdrawal'). - Personal data. The withdrawal statement this module will store keeps the consumer's name and e-mail address in two columns of their own, which can be cleared while the statement itself is kept as the shop's evidence.
The withdrawal function on the storefront (art. 11a, inserted by Directive (EU) 2023/2673 and applicable from 19 June 2026), the acknowledgement e-mail and the 14-day reimbursement deadline arrive in later releases.
Returnable products
Whether a line may be returned is decided by the product's Returnable flag as it stood when the order was placed — the Orders module records it on each order line at placement, and later changes to the product do not reach orders already placed. The flag is set on the product in the catalogue (the Catalog module's page describes it, including how to set it for many products at once through Bulk edit).
- Per-line answer.
GET /api/v1/orders/:orderId/returnablegives each linereturnable(always present) and, for a line that may not be returned,notReturnableReason: 'product_not_returnable'. A line of an order placed before the flag was recorded carries no recorded value and counts as returnable. eligibleanswers for return-kind cases only. The order-level verdict is, in this order of precedence:order_not_completing,fully_returned, thenno_returnable_lines.eligible: falsewithreason: 'no_returnable_lines'means the order still has quantities left but none of them on a returnable line: no return can be opened, but a complaint still can.- A return naming a non-returnable line is refused.
POST /api/v1/returnswithkind: 'return'answers422 RETURN_LINE_NOT_RETURNABLEwhen any requested line was recorded as not returnable, withdetails.productName(the first such line),details.orderItemIds[]anddetails.lines[](orderItemId,productName) naming every such line. Nothing is written. - Complaints are never restricted by the flag: a
complaintmay name any line of the order. Nothing is refunded for a non-returnable line by default: such a complaint line is stored with an approved refund of0, while its default refund stays the amount paid — the most the operator may approve. The admin case view marks the line Not returnable at purchase and the settlement form starts from0for it, so a refund or credit for it happens only when the operator enters an amount. The case detail gives each linereturnableAtPurchase(true,false, ornullfor a line placed before the value was recorded). - Duplicate lines are summed. When a request names one order line more
than once, the quantities are added up per order line and that total is
checked against the line's remaining quantity, for both kinds; a total above
it is refused with
422 RETURN_QUANTITY_EXCEEDS_RETURNABLE. The entries are still stored as sent. - Order of the checks. A line that does not belong to the order
(
details.code: 'unknown_line') is reported before any quantity error, the quantity check runs before the reason check (unknown_reason, orRETURN_REASON_INACTIVEfor a reason that was switched off), and returnability is checked last. Cases opened before a product was marked not returnable are never re-evaluated.
On upgrade, every existing product is not returnable. The flag defaults to off, so lines of orders placed after the release are not returnable until the product is marked returnable in the catalogue — select the products on the product list and use Bulk edit → Returnable → Yes — returnable. Orders placed before the release are unaffected: their lines carry no recorded value and stay returnable.
In the audit log
A return case is an Organization's record, and the platform-wide audit log is read
by everybody holding audit_log:read whatever Organizations they may see. So the
case's entries name and count, and hold no amount and no free text:
return.settled records the resolution, the currency, the settlement state and
the correction's outcome, with the lines and charges it concerns by id or kind;
return.status_changed records the status and whether a reason was given. The
amounts are on the case and its refund. A reason given with a status change is
passed to the status events that change emits and
is not recorded anywhere else. Entries recorded before this change keep what they
were written with.
Cross-module interfaces
The module reads/affects other domains only through documented ports, never internal imports:
OrderReadPort.findByIdForCustomer(orders) — whether the buyer may read the order a case is opened for (their own, or a colleague's withorders.view_organization).OrganizationPermissionPort(organizations) —returns.createandreturns.view_organization, asked per request.OrganizationDetailsPort.findById(organizations) — whether the case's Organization is personal, read once when a return is filed.OrderReturnContextPort(orders) — paid-per-line amounts + completing-status time, the order's payment method, and each line'sreturnableAtPurchase(true/falseas recorded at placement,nullfor an order placed before it was recorded). Orders reports the fact; the policy fornull— returnable — is this module's. It also reports the order's delivery cost and payment surcharge.OrganizationDetailsPort(organizations) — whether the order's organization is a personal one (B2C), which decides whether a withdrawal refunds the delivery and the surcharge.PaymentRefundPort(payments) — issue the refund, answerpending_manualwhere no PSP integration exists, or refuse when the gateway that took the payment is switched off.CorrectiveInvoicePort(invoices) — create acorrectioninvoice, or answer that none is due because the order carries no invoice to correct. A consumer's completing withdrawal also names the delivery and surcharge it refunds (charges).CreditTopupPort(credit_limits) — credit the organization grant.ShipmentService(shipments) — optional replacement outbound shipment.
Schema
Migration 20260625T144227_returns_init.ts creates return_cases, return_case_items,
return_case_comments, return_statuses, return_status_transitions,
return_reasons, return_delivery_methods, refunds, return_shipments,
return_case_attachments, return_list_saved_views, and the
return_cases_rma_seq sequence.
Migration 20261108T023047_returns_consumer_withdrawal.ts adds the consumer
withdrawal's columns to return_cases (consumer_withdrawal, the consent
columns, and the facts of the reimbursement deadline) and creates
return_withdrawal_statements. It touches no other module's table, so it
leaves existing cases unclassified.
Migration 20261108T125405_returns_case_charge_refunds.ts adds four columns to
return_cases: default_delivery_refund, approved_delivery_refund,
default_surcharge_refund and approved_surcharge_refund, each 0.00 by
default. Existing cases keep 0.00.