API
Cancel order
Cancel an aggregator order and, when supported by the payment processor, refund the payment.
POST
Cancels an order previously created through Inject order. Fire looks up the order by
account and order_uid, updates the order to CANCELED, and returns the updated order in the standard API envelope.
If the stored payment processor supports refunds (for example, Deuna), Fire attempts the refund and sets payment_status to REFUNDED on success. For other processors, Fire cancels the payment state and sets payment_status to CANCELED.
string
required
Bearer token obtained from POST /login. Format:
Bearer <accessToken>.string
required
Your Fire API key.
string
required
Must be
integration. Identifies the request as coming from an external integration.string
required
Account identifier used to find the order.
string
default:"application/json"
Use
application/json for the request body.string
required
UID of the order to cancel.
string
required
Reason for the cancellation or refund request.
string
Optional. UID of the payment method used to resolve refund credentials when you need to target a specific method.
string
required
Vendor UID used to resolve payment credentials.
string
Customer email sent to the payment processor when required.
string
Registered customer UID. When present, Fire treats the refund payload as authenticated.
string
Anonymous customer UID. Used as the payment user identifier when
customer_uid is not present.string
Store UID used to resolve store-specific payment credentials.
string
Sales medium used to resolve credentials. Supported values:
APP, WEB.string
Optional. Cancellation reason ID or code from the catalog. When provided, it is persisted on the order and reported to the payment gateway.
object
Updated order. Prices in
order_lines, totals, and payment_methods are returned as external, unscaled amounts.number
HTTP status code from the API envelope.
string
Trace identifier for support and debugging.
Processing rules
- When provided,
payment_method_uidhelps resolve credentials, but Fire evaluates the payment methods stored on the order. - For Deuna refunds, the order must include
metadata.order_token; otherwise Fire returns400. - After saving the updated order, Fire returns prices transformed for external consumption.
- Fire notifies the cancellation downstream after the order is saved.
Post-cancellation behavior
Fiscal voiding is asynchronous
When the order had a fiscal document issued, Fire requests its cancellation from the provider and leaves the document incancelling. The final state arrives via a provider webhook, not in this endpoint’s response.
If the provider webhook never arrives, the document stays in
cancelling indefinitely — no automatic retry unblocks it. If you need fiscal certainty, waiting for this endpoint’s 200 is not enough; check the document status afterwards.
Amounts are not zeroed
A cancelled order keeps its totals and its payment methods with the original amounts.order_lines, totals and payment_methods come back with the same values they had before the cancellation; what changes is status and payment_status.
This is deliberate: the order records what happened, not what remains in force. If you reconcile amounts against cancelled orders you will find they match perfectly — because exactly what was sold was charged, before the void. The right reconciliation for a cancelled order is not “do the amounts match?” but “was every link reversed?”.
Cancellation is all-or-nothing
There is no per-line or partial-amount void: the whole order is cancelled or nothing is. That is why the request carries no amounts and no item list. To reverse only part of an order, cancel it and inject a new one.What to verify on the client side
- Do not assume the fiscal document is voided because you got a
200. Check its status if you need certainty. payment_statusdistinguishes two different outcomes:REFUNDED(the processor returned the money) andCANCELED(the charge was voided without a refund). They are not equivalent for reconciliation.- The downstream event fires after the order is saved, not after the fiscal void is confirmed. It arrives before the chain is closed.

