Mono Connect provides event callbacks to help you monitor and respond to widget states and user actions.Documentation Index
Fetch the complete documentation index at: https://sammydocs.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Event Callbacks
onSuccess
Required callback that triggers after successful account linking or payment.onClose
Optional callback for when the widget is closed.onLoad
Optional callback triggered when the widget is mounted to the DOM.onEvent
Optional callback for monitoring specific events during the Connect flow.Available Events
| Event Name | Description | Data Properties |
|---|---|---|
LOADED | Widget has been loaded | timestamp |
OPENED | Widget is displayed to user | timestamp |
EXIT | User closes the widget | timestamp, pageName |
ERROR | An error occurred | errorType, errorMessage |
INSTITUTION_SELECTED | User selected a bank | institution: {id, name}, authMethod |
AUTH_METHOD_SWITCHED | Authentication method changed | prevAuthMethod, authMethod |
SUBMIT_CREDENTIALS | Login attempt made | timestamp |
SUBMIT_MFA | MFA code submitted | mfaType |
ACCOUNT_LINKED | Account successfully connected | institution: {id, name} |
ACCOUNT_SELECTED | Account selection made | selectedAccountsCount |
SUCCESS | Overall success event | Varies based on operation type |
Event Data Object
The data object passed to onEvent contains different properties based on the event:Usage Example
All events include timestamp and reference (if provided) in their data object. The reference can be used to track specific Connect instances across events.