Client Events
Event Types
The Boom SDK supports two types of events: action and analytics.
- action: This action type requires developers to handle the event
- analytics: No action required
Typescript types
type EmittedEvent = AnalyticsEvent | ActionEvent;
// PageIdentifier -- page name
type PageIdentifier = string;
type AnalyticsEvent = {
type: "analytics";
action: "pageview" | "click";
source: PageIdentifier;
message?: string;
};
type ActionEvent = {
type: "action";
action: "close" | "auth-error" | "plaid_link_handoff";
source?: PageIdentifier;
message?: string;
};Introduction
Client-side emitted events have four key attributes: type, action, source, and message.
- type: Differentiates between mandatory events (action) and optional events (analytics).
- action: Provides key information about the event type.
- Possible values: close, auth-error, plaid_link_handoff, click, pageview, connect_bank
- source: Indicates the location.pathname where the event was called.
- message: Optional attribute providing additional information about the event (e.g., “Enrollment submitted”, error payload message, “Upsell clicked”, “Continue button clicked”).
Mandatory events
type: action events are mandatory to handle in your app for the optimal user experience.
List of mandatory events:
Close:
Description: The user clicked the “close icon” in the SDK. Boom SDK must be closed.
Payload:
Auth error:
Description: Provided token failed authentication. Boom SDK must be closed. Message contains information on why authentication failed.
Payload:
Plaid link handoff:
Description: User initiated Plaid link handoff. Boom SDK must be closed.
Payload:
Unsubscribe:
Description: Upon request, the Boom team can enable a self-service unenroll button in the SDK. This allows users to immediately stop reporting. If enabled, you should close the SDK upon receiving this event and update your database accordingly.
Payload:
{
"type": "action",
"action": "unsubscribe",
"source": location.pathname
}Connect bank:
Contact Boom to enable this event.
Description: User initiates adding a bank account. The Boom SDK must be closed before proceeding. You should open Plaid and pass the connected bank information to Boom.
Payload:
Pay rent handoff
Contact Boom to enable this event.
Description: Used in cases where the customer pays rent through your app and you want to own the process. The Boom SDK must be closed before starting this flow and then, you can launch your process.
Payload:
Optional events
type: analytic events are optional.
Pageview Description: Indicates that the user is on a certain page. Page identifier is passed in source.
Click Description: User clicked an interactive element. Usually contains a message.
Possible messages:
- "Upsell clicked"
- "Continue button clicked"
- "Enrollment submitted"
Possible sources:
- /plaid-connect
- /hub
- /issues/upload-lease
- /rent_reporting/onboarding/:view
- :view could be one of:
- intro
- plaid
- confirm_personal_info
- confirm_lease_info
- property_manager_details
- check_out
- /rent_reporting-id
- /settings/linked-accounts
- /settings