Webhooks inform your backend in real-time of status changes of each payment, allowing you to keep your order handling to be in sync with the status of the corresponding payment even if there are disruptions in the session on the client-side.

🚧

Webhooks

In the backend, Magic will always send you webhooks to inform your backend on the status of the order, ensuring no orders are lost/dropped.

The webhooks are categorised by their status and are triggered in the following situations:

StatusDescription
createdUpon creation of the order
authorizedUpon successful payment by the shopper on the Magic Checkout
chargedUpon a successful capture request
refundedUpon a successful refund request
partially_refundedUpon a successful partially-refund amount request.
voidUpon you tell magic to void this order.
expiredIf an authorized payment is not captured before the elapsing of the expiry period indicated by the orderExpiryMilliseconds field in the initial /orders request.
refunded_not_chargedUpon the transaction goes from authorized to refund_not_charged. This happens when you don't call capture order.
not_createdThere are some issues with the request.