Zap Payments

Documentation

Checkout events

Modal checkout runs in an iframe and communicates with your page via postMessage. The pay button also emits DOM events.

postMessage (hosted checkout → parent)

{ source: "zap", type: "uc:paid" | "uc:close" | "uc:resize", … }
typeMeaning
uc:paidPayment succeeded; includes receiptId and receiptUrl
uc:closeModal closed
uc:resizeContent height changed (desktop modal)

DOM events on <pay-button>

EventWhen
uc:paidSame as postMessage paid
uc:closedModal closed; detail.paid is boolean
uc:errorSession creation failed