<script> tag and use the three methods below to initialize, mount, and respond to the hosted account capture flow.
Methods
IngoInstantPayments.create(domElement, options?)
Creates an instance of the SDK and attaches it to a DOM element in your page. Returns a webPlugin object that exposes the mount and addEventListener methods.
Arguments
Options
webPlugin.mount(authorizedUrl, fundingDestination)
Mounts the iFrame and launches the account capture flow for the specified funding destination. Must be called after create().
Arguments
FUNDING_DESTINATIONS constants
webPlugin.addEventListener(event, handler)
Registers a callback function for a specific SDK event. This is the only way to receive data from the iFrame. Register listeners before or immediately after calling mount().
Arguments
Common event payload fields
Every event payload includes at minimum:
Additional fields are event-specific. See SDK Events for the full payload reference per event.