Databricks - Data Export
Automatically export message events from OneSignal to Databricks.

Overview
The OneSignal + Databricks integration allows you to automatically export message event data from OneSignal to your Databricks lakehouse. This eliminates the need for manual data extraction and gives your team direct access to near real-time engagement data for advanced analysis, dashboarding, and reporting.
You’ll gain visibility into events across email, push notifications, in-app messages, and SMS, and can build custom analytics to inform marketing strategies and cross-functional insights.
Currently, we support message send and engagement events (e.g., clicks, opens). Future updates will expand event coverage to offer a more complete view of your users' journeys.
Requirements
OneSignal
- Annual Plan is required to access this integration.
Databricks
- Platform: AWS, Azure, or GCP
- Plan: Premium or higher
- Unity Catalog Enabled:
- Required for permission management and schema creation.
- Legacy deployments without Unity Catalog are not supported.
- SQL Warehouse:
- Used for ingesting and querying exported event data.
Setup
1. Configure Databricks
Collect SQL Warehouse Info
- Navigate to SQL Warehouses in your Databrick workspace.
- Select your warehouse and click the Connection details tab.
- Save the following values, you will need them shortly:
- Server Hostname
- Port
- HTTP Path

Create a Service Principal
- In Workspace Settings, go to Identity and Access > Service Principals.
- Click Add Service Principal, then Add New.
- Give it a recognizable name (e.g.,
onesignal-sync
).

Generate a Secret for your Service Principal
- Click into the created Service Principal.
- Go to the Secrets tab.
- Click Generate Secret and save the resulting token.
One time access!
⚠️ You won’t be able to view this secret again, so store it securely.

Add Permissions to your Service Principal
- Navigate to your Databricks Catalog.
- Open the Permissions tab.
- Click Grant, then:
- Select your Service Principal.
- Grant the following permissions:
- USE CATALOG
- USE SCHEMA
- SELECT
- MODIFY
- CREATE SCHEMA
- CREATE TABLE

2. Connect OneSignal to Databricks
- In OneSignal, navigate to Data > Integrations > Databricks.
- Paste the following from your Databricks workspace:
- Server Hostname
- Port
- HTTP Path
- Catalog Name
- Schema Name
- Service Principal credentials (ID + Secret)

-
OneSignal Settings
- Set up Sync Frequency, the most frequent setting is 15 minutes
- Dataset and Destination Table names will be pre set
- Dataset is named as
onesignal_events_your-appid
- Destination Table is names as
message_events
- you can update these names if you need to
- Dataset is named as
- Select the events you care to receive in your BigQuery dataset. Feel free to select them all.
-
Click “Save” and wait for the success confirmation
3. Send a message to generate events
Once connected, send messages using OneSignal via any channel you use (push, email, in-app, SMS). Message Events will begin syncing into Databricks based on your integration settings.
4. View data in Databricks
- In Databricks, go to your Catalog.
- After syncing has succeeded, a new Schema (with the name provided during setup) will appear.
- Inside, you'll find tables containing exported event data.

- Click into a table to preview Sample Data.

Need help?
If you run into any issues—such as:
- Schema not appearing in Catalog
- Permission errors on table creation
- Unexpected event formats or data not syncing
Please reach out to [email protected].
Events and Properties
Below is an overview of the data available for the Databricks Data Export Integration. We will offer Message Event data in the beta, and will plan to offer more categories of event data and summary reports in the future.
For this integration, any event data generated by a user for the given OneSignal application will be exported to a customer's Databricks project. Customers will not be able to select specific event kinds or filter the events they receive.
Message Event Kinds
Type: String
The type of message and event (e.g. message.push.received
, message.push.sent
).
Message Event Kind (OneSignal) | Event name (in data set) | Event Description |
---|---|---|
Push Sent | message.push.sent | Push notification successfully sent. |
Push Received | message.push received | Push notification successfully received. See Confirmed Delivery . |
Push Clicked | message.push.clicked | Push notification touched on device |
Push Failed | message.push.failed | Push failed to be sent. Check the failed message report in OneSignal. |
Push Unsubscribed | message.push.unsubscribed | The Subscription unsubscribed from push. |
In-App Impression | message.iam.displayed | In-App Message successfully displayed on device |
In-App Clicked | message.iam.clicked | In-App Message clicked on device |
In-App Page Displayed | message.iam.pagedisplayed | In-App Message page is displayed |
Email Sent | message.email.sent | Email successfully sent |
Email Received | message.email.received | Email received by recipient |
Email Opened | message.email.opened | Email opened by recipient. See Email Message Reports for details. |
Email Link Clicked | message.email.clicked | Email link clicked on |
Email Unsubscribed | message.email.unsubscribed | Email unsubscribed by recipient |
Email Reported As Spam | message.email.resporedasspam | Email reported as spam by recipient. See Email deliverability for details. |
Email Bounced | message.email.hardbounced | Email returned to sender due to permanent error. See Email Message Reports for details. |
Email Failed | message.email.failed | Could not deliver the email to the recipient’s inbox |
Email Suppressed | message.email.supressed | The email was not sent because the email address is on the Suppression list . |
SMS Sent | message.sms.sent | SMS sent to recipient |
SMS Failed | message.sms.failed | SMS failed to send |
SMS Delivered | message.sms.delivered | SMS successfully delivered |
SMS Undelivered | message.sms.undelivered | The SMS could not be sent |
Message Events Properties (columns)
For each message event generated by a user, the following metadata will be attached to the record.
Column Name | Type | Description | Example |
---|---|---|---|
event_id | UUID/String | A unique ID that represents the event | dc76df03-287c-403a-aabd-b2d4fe44e5c6 |
event_timestamp | timestamp | The time at which the event happened | 2025-04-09 19:59:27.832 UTC |
event_kind | string | The type of event that occurred. | message.email.opened |
subscription_device_type | string | The type of device this subscription uses. | SMS |
language | string | The language of this subscription | en |
version | string | The version of the integration | 1.1.0 |
device_os | string | The device version that the user received the message on | 17.5.1 |
device_type | numerical | The type of device a user received the message on | 7 |
token | string | The push token (push), phone number(SMS) or email address (email) of the subscription | push32313097a54ac11169ea64dfa459937d2907d220201442b3fa1d02bf2dcef367 SMS 15857778888 [email protected] |
subscription_id | UUID | A unique ID that represents the device/subscription | 6e8b6978-75a4-4882-878c-2d15a78c2409 |
subscribed | boolean | The subscription status for the individual for the message they received | TRUE |
onesignal_id | UUID | The onesignal_id of the user that made the impression | dc76df03-287c-403a-aabd-b2d4fe44e5c6 |
last_active | string | When the subscription for which the event is for was last active in the application | 1712787115 |
sdk | string | The version of the OneSignal SDK in use where the message was received | 50207 |
external_id | string | The external_id of the user that made the impression | MyExternalId |
app_id | UUID | A unique ID that represents the OneSignal App ID events were generated in | bc76df03-287c-403a-aabd-b2d4fe44e5c6 |
template_id | UUID | A unique ID that represents the template used to send a message via API or Journeys | c54dea04-256c-403a-aabd-b2d4fe44e5c6 |
message_id | UUID | The ID of the request to send the message. Each message request will have a unique ID. If you sent 1 message to multiple users, they will all have the same ID. If you send the same message multiple times, each will have a unique ID. Each event for the message will reference the same message_id . | dc76df03-287c-403a-aabd-b2d4fe44e5c6 |
message_name | string | The human-readable id of the Notification/Message | Campaign 1 |
message_title | string | The Title of the Notification/Message. English only at this time | Bonus 50 coins when you play! |
message_contents | string | The Body of the message. (Truncated) English only at this time. | Play against your friends and earn an additional... |
_created _id _index _fivetran_synced | Columns created by our syncing solution in every data set (Fivetran) |
Notes
- Syncs after saving/activating may take an additional 15-30 minutes to complete
- Deactivating may still result in one final sync after deactivation.
- To ensure efficient data synchronization in your BigQuery destination, our system automatically creates and manages staging datasets. These datasets, named with a pattern like
fivetran_{two random words}_staging
, temporarily store data during processing before it's integrated into your main schema. These staging datasets are essential for maintaining a streamlined workflow and should not be deleted, as they will be automatically recreated.
FAQ
Why do I see the same message title and/or message contents but different message ID?
This likely means you sent the same message more than once. Probably related to a transactional message or a template that was sent to different users at different times and/or via different requests.
Updated 5 days ago