LogoLogo
  • Contributing to RudderStack
  • Destination_Name
  • LICENSE
  • RudderStack Docs
  • docs
    • FAQ
    • Identity Resolution
    • Home
    • cloud-extract-sources
      • ActiveCampaign Source
      • Bing Ads
      • Chargebee
      • Common Settings
      • Facebook Ads
      • Freshdesk
      • Google Ads Source
      • Google Analytics
      • Google Search Console
      • Google Sheets
      • Cloud Extract Sources
      • Intercom v2
      • Intercom
      • Mailchimp
      • Marketo
      • Mixpanel
      • NetSuite
      • Pipedrive
      • QuickBooks
      • Salesforce Pardot
      • Sendgrid Source
      • Stripe Source
      • Xero
      • Zendesk Chat
      • Zendesk
      • hubspot
        • HubSpot Data Model and Schema Information
        • HubSpot
      • salesforce
        • Salesforce
        • Schema Comparison: RudderStack vs. Segment
    • connections
      • Connection Modes: Cloud Mode vs. Device Mode
    • data-governance
      • Data Governance
      • RudderTyper
      • Data Governance API
      • RudderTyper
      • tracking-plans
        • Tracking Plans
        • Tracking Plan Spreadsheet
    • data-warehouse-integrations
      • Amazon Redshift
      • Azure Data Lake
      • Azure Synapse
      • ClickHouse
      • Databricks Delta Lake
      • Google Cloud Storage Data Lake
      • Google BigQuery
      • Identity Resolution
      • Warehouse Destinations
      • Microsoft SQL Server
      • PostgreSQL
      • Amazon S3 Data Lake
      • Snowflake
      • FAQ
      • Warehouse Schema
    • destinations
      • Destinations
      • Webhooks
      • advertising
        • Bing Ads
        • Criteo
        • DCM Floodlight
        • Facebook App Events
        • Facebook Custom Audience
        • Facebook Pixel
        • Google Ads (gtag.js)
        • Google AdWords Enhanced Conversions
        • Google Adwords Remarketing Lists (Customer Match)
        • Advertising
        • LinkedIn Insight Tag
        • Lotame
        • Pinterest Tag
        • Reddit Pixel
        • Snap Pixel
        • TikTok Ads
      • analytics
        • Amplitude
        • AWS Personalize
        • Chartbeat
        • Firebase
        • FullStory
        • Google Analytics 360
        • Google Analytics
        • Heap.io
        • Hotjar
        • Analytics
        • Indicative
        • Keen
        • Kissmetrics
        • Kubit
        • Lytics
        • Mixpanel
        • Pendo
        • PostHog
        • Quantum Metric
        • Singular
        • adobe-analytics
          • Adobe Analytics Heartbeat Measurement
          • Mobile Device Mode Settings
          • Web Device Mode Settings
          • E-commerce Events
          • Adobe Analytics
          • Setting Up Adobe Analytics in RudderStack
        • google-analytics-4
          • Cloud Mode
          • Device Mode
          • Google Analytics 4
          • Setting up Google Analytics 4
        • profitwell
          • ProfitWell
          • Cloud Mode
          • Device Mode
      • attribution
        • Adjust
        • AppsFlyer
        • Branch
        • Attribution
        • Kochava
        • TVSquared
      • business-messaging
        • Business Messaging
        • Intercom
        • Kustomer
        • Slack
        • Trengo
      • continuous-integration
        • Visual Studio App Center
        • Continuous Integration
      • crm
        • Delighted
        • HubSpot
        • CRM
        • Salesforce
        • Variance
        • Zendesk
      • customer-data-platform
        • Customer Data Platform
        • Segment
      • error-reporting
        • Bugsnag
        • Error Reporting
        • Sentry
      • marketing
        • ActiveCampaign
        • AdRoll
        • Airship
        • Appcues
        • Autopilot
        • Blueshift
        • Braze
        • CleverTap
        • Customer.io
        • Gainsight PX
        • Gainsight
        • Marketing
        • Iterable
        • Klaviyo
        • Leanplum
        • Mailchimp
        • Marketo Lead Import
        • Marketo
        • MoEngage
        • Ometria
        • Pardot
        • Post Affiliate Pro
        • Qualtrics
        • SendGrid
        • Salesforce Marketing Cloud
        • Userlist
        • drip
          • Cloud Mode
          • Device Mode
          • Drip
          • Setting Up Drip in RudderStack
      • productivity
        • Google Sheets
        • Productivity
      • storage-platforms
        • Amazon S3
        • DigitalOcean Spaces
        • Google Cloud Storage
        • Storage Platforms
        • Azure Blob Storage
        • MinIO
        • Redis
      • streaming-platforms
        • Amazon EventBridge
        • Amazon Kinesis Firehose
        • Amazon Kinesis
        • Azure Event Hubs
        • BigQuery Stream
        • Confluent Cloud
        • Google Pub/Sub
        • Streaming Platforms
        • Apache Kafka
      • tag-managers
        • Google Tag Manager
        • Tag Managers
      • testing-and-personalization
        • Algolia Insights
        • Candu
        • Google Optimize
        • A/B Testing & Personalization
        • LaunchDarkly
        • Monetate
        • Optimizely Full Stack
        • Optimizely Web
        • Split.io
        • Statsig
        • VWO (Visual Website Optimizer)
    • get-started
      • RudderStack Cloud vs. RudderStack Open Source
      • Glossary
      • Get Started
      • RudderStack Architecture
    • reverse-etl
      • Amazon Redshift
      • Amazon S3
      • ClickHouse
      • FAQ
      • Google BigQuery
      • Reverse ETL
      • PostgreSQL
      • Snowflake
      • common-settings
        • Importing Data using Models
        • Importing Data using Tables
        • Common Settings
        • Sync Modes
        • Sync Schedule
      • features
        • Airflow Provider
        • Features
        • Models
        • Visual Data Mapper
    • rudderstack-api
      • Data Regulation API
      • HTTP API
      • RudderStack API
      • Personal Access Tokens
      • Pixel API
      • Test API
      • api-specification
        • Application Lifecycle Events Specification
        • API Specification
        • Video Events Specification
        • rudderstack-ecommerce-events-specification
          • Browsing
          • Coupons
          • E-Commerce Events Specification
          • Ordering
          • Promotions
          • Reviewing
          • Sharing
          • Wishlist
        • rudderstack-spec
          • Alias
          • Common Fields
          • Group
          • Identify
          • RudderStack Event Specification
          • Page
          • Screen
          • Track
    • rudderstack-cloud
      • Audit Logs
      • Dashboard Overview
      • Destinations
      • RudderStack Cloud
      • Live Events
      • Connection Modes: Cloud Mode vs. Device Mode
      • Sources
      • Teammates (User Management)
      • connections
        • Adding a Destination
        • Connections
    • rudderstack-open-source
      • Control Plane Setup
      • RudderStack Open Source
      • installing-and-setting-up-rudderstack
        • Developer Machine Setup
        • Docker
        • Data Plane Setup
        • Kubernetes
        • Sending Test Events
    • stream-sources
      • App Center
      • AppsFlyer
      • Auth0
      • Braze
      • Customer.io
      • Extole
      • Event Stream Sources
      • Iterable
      • Looker
      • PostHog
      • Segment
      • Shopify
      • Webhook Source
      • rudderstack-sdk-integration-guides
        • Client-side Event Filtering
        • SDKs
        • AMP Analytics
        • Cordova
        • .NET
        • Go
        • Java
        • Node.js
        • PHP
        • Python
        • React Native
        • Ruby
        • Rust
        • Unity
        • SDK FAQs
        • rudderstack-android-sdk
          • Adding Application Class
          • Flushing Events Periodically
          • Android
        • rudderstack-flutter-sdk
          • Flutter SDK v1
          • Flutter v2
          • Flutter
        • rudderstack-ios-sdk
          • iOS
          • tvOS
          • watchOS
        • rudderstack-javascript-sdk
          • Data Storage in Cookies
          • Detecting Ad-blocked Pages
          • JavaScript
          • JavaScript SDK Enhancements
          • JavaScript SDK FAQs
          • Querystring API
          • Quick Start Guide
          • Version Migration Guide
          • consent-managers
            • Consent Managers
            • OneTrust
    • transformations
      • Access Token
      • FAQ
      • Transformations
      • Transformations API
    • user-guides
      • User Guides
      • administrators-guide
        • Troubleshooting Guide
        • Alerting Guide
        • Bucket Configuration Settings for Event Backups
        • Configuration Parameters
        • Event Replay
        • High Availability
        • Horizontal Scaling
        • Administrator's Guides
        • Infrastructure Provisioning
        • Monitoring and Metrics
        • Okta SSO Setup
        • OneLogin SSO Setup
        • RudderStack Grafana Dashboard
        • Software Releases
      • how-to-guides
        • How to Use Custom Domains
        • How to Develop Integrations for RudderStack
        • How to Configure a Destination via the Event Payload
        • How to Filter Events using Different Methods
        • How to Filter Selective Destinations
        • How to Submit a Pull Request for a New Integration
        • How-to Guides
        • How to Debug Live Destination Events
        • How to Use AWS Lambda Functions with RudderStack
        • create-a-new-destination-transformer-for-rudder
          • Best Practices for Coding Transformation Functions in JavaScript
          • How to Create a New Destination Transformation for RudderStack
        • implement-native-js-sdk-integration
          • How to Add a Device Mode SDK to RudderStack JavaScript SDK
          • How to Implement a Native JavaScript SDK Integration
        • rudderstack-jamstack-integration
          • How to Integrate RudderStack with Your JAMstack Site
          • How to Integrate Rudderstack with Your Angular App
          • How to Integrate Rudderstack with Your Astro Site
          • How to Integrate Rudderstack with Your Eleventy Site
          • How to Integrate Rudderstack with Your Ember.js App
          • How to Integrate Rudderstack with a Gatsby Website
          • How to Integrate Rudderstack with a Hugo Site
          • How to Integrate Rudderstack with Your Jekyll Site
          • How to Integrate Rudderstack with Your Next.js App
          • How to Integrate Rudderstack with Your Nuxt.js App
          • How to Integrate Rudderstack with Your Svelte App
          • How to Integrate Rudderstack with Your Vue App
      • migration-guides
        • Migrating from Blendo to RudderStack
        • Migrating Your Warehouse Destination from Segment to RudderStack
        • Migration Guides
        • Migrating from Segment to RudderStack
  • src
    • @rocketseat
      • gatsby-theme-docs
        • text
          • Home
Powered by GitBook
On this page
  • Getting Started
  • Adding Device Mode Integration
  • Identify
  • Track
  • Order Completed
  • Page
  • Group
  • Contact Us

Was this helpful?

  1. docs
  2. destinations
  3. marketing

Braze

Step-by-step guide to send your event data from RudderStack to Braze

PreviousBlueshiftNextCleverTap

Last updated 3 years ago

Was this helpful?

Braze is an industry-leading customer engagement platform. It allows you to better understand your customers' in-app behavior and use the insights to improve your overall app experience, and increase engagement with them.

With RudderStack's SDK for mobile and web platforms, you can send your in-app event data to Braze directly for contextual analysis.

Find the open-source transformer code for this destination in our .

Getting Started

Before getting started, please determine whether the platform you are sending your event data from is supported. Refer to the following table for the supported source types and connection modes:

Connection Mode

Web

Mobile

Server

Device mode

Supported

Supported

-

Cloud mode

Supported

Supported

Supported

To know more about the difference between Cloud mode and Device mode in RudderStack, read the guide.

Follow these steps once you have added a source in the RudderStack app:

RudderStack connection settings for adding Braze as a destination

When creating a new Braze Rest API Key for your app, you will only need to select the users.track, users.identify, and users.alias.new endpoints under the User Data permissions

  • Once you have added the source, configure the Braze settings to complete the setup.

  • Both the App Key and the Rest Api Key can be found in the Developer Console underneath the Settings section in your Braze dashboard (left-side menu)

  • In the Developer Console under the API Settings tab, there should be 4 sections.

  • To get the App Key, go to the Identification section and look up your App Name. The key will then be the associated Identifier string. You can find more information .

  • To get the Rest Api Key, go to the Rest API Keys section and look for the API Key Name that you created. The key will then be the associated Identifier string. You can find more information .

  • To get the correct Data Center details, you can follow this very clear guide. An example of a Data Instance would be US-01. The easiest way to get your Data Center details is to simply log in to your Braze account and look at your URL. Your URL will map to what Data Center you will enter.

URL
Data Center Input

https://dashboard-01.braze.com

US-01

https://dashboard-03.braze.com

US-03

https://dashboard-01.braze.eu

EU-01

etc.

etc.

Adding Device Mode Integration

Depending on your platform of integration, follow the steps below to add Braze to your project:

iOS Android React Native Please follow these steps to add Braze to your iOS project:

  • Open the Podfile of your project and add the following line:

    pod 'Rudder-Braze'

    followed by the command as shown:

    $ pod install
  • Finally change the SDK initialization to the following snippet:

    RudderConfigBuilder *builder = [[RudderConfigBuilder alloc] init];
    [builder withDataPlaneUrl:<DATA_PLANE_URL>];
    [builder withFactory:[RudderBrazeFactory instance]];
    [RudderClient getInstance:<WRITE_KEY>; config:[builder build]];

To add Braze to your Android project, follow these steps:

  • Open your app/build.gradle (Module: app) file, and add the following:

    repositories {
      mavenCentral()
      maven { url "https://appboy.github.io/appboy-android-sdk/sdk" }
    }
  • Add the following under dependencies section:

      implementation 'com.rudderstack.android.sdk:core:1.0.1'
      implementation 'com.rudderstack.android.integration:braze:1.0.2'
      implementation 'com.appboy:android-sdk-ui:6.0.+'
      // if you haven't included Gson already
      implementation 'com.google.code.gson:gson:2.8.6'
  • Finally, change the SDK initialization to the following:

      val rudderClient: RudderClient = RudderClient.getInstance(
          this,
          <WRITE_KEY>,
          RudderConfig.Builder()
              .withDataPlaneUrl(<DATA_PLANE_URL>)
              .withLogLevel(RudderLogger.RudderLogLevel.DEBUG)
              .withFactory(BrazeIntegrationFactory.FACTORY)
              .build()
      )

To add Braze to your React Native project:

  • Add the RudderStack-Braze module to your app by running the following command:

    npm install @rudderstack/rudder-integration-braze-react-native
    yarn add @rudderstack/rudder-integration-braze-react-native
  • Open your android/build.gradle file (Project level), and add the following:

    repositories {
      maven { url "https://appboy.github.io/appboy-android-sdk/sdk" }
    }
  • Import the module you added above and add it to your SDK initialization code as shown:

    import rudderClient from "@rudderstack/rudder-sdk-react-native"
    import braze from "@rudderstack/rudder-integration-braze-react-native"
    const config = {
      dataPlaneUrl: DATA_PLANE_URL,
      trackAppLifecycleEvents: true,
      withFactories: [braze],
    }
    rudderClient.setup(WRITE_KEY, config)

Identify

The identify call is used to associate a user to their actions. Apart from capturing a unique user ID, RudderStack also captures optional traits associated with that user, such as name, email, IP address, etc.

A sample identifycall captured from the RudderStack Android SDK looks like the following code snippet:

rudderanalytics.identify("userid", {
  name: "John Doe",
  title: "CEO",
  email: "name.surname@domain.com",
  company: "Company123",
  phone: "123-456-7890",
  state: "Texas",
  rating: "Hot",
  city: "Austin",
  postalCode: "12345",
  country: "US",
  street: "Sample Address",
  state: "TX",
})

Ideally, the identify method is called when the user registers to the app for the first time. It can also be called after the user logs into the app, or updates their information.

Track

A sample track call looks like the following code snippet:

rudderanalytics.track("Track me", {
  category: "category",
  label: "label",
  value: "value",
})

For example, consider the following code snippet for a track event Order Completed from your JavaScript SDK:

rudderanalytics.track("Order Completed", {
  checkout_id: "fksdjfsdjfisjf9sdfjsd9f",
  order_id: "50314b8e9bcf000000000000",
  affiliation: "Google Store",
  total: 27.5,
  subtotal: 22.5,
  revenue: 25.0,
  shipping: 3,
  tax: 2,
  discount: 2.5,
  coupon: "hasbros",
  currency: "USD",
  products: [
    {
      product_id: "507f1f77bcf86cd799439011",
      sku: "45790-32",
      name: "Monopoly: 3rd Edition",
      price: 19,
      quantity: 1,
      category: "Games",
      url: "https://www.example.com/product/path",
      image_url: "https:///www.example.com/product/path.jpg",
    },
    {
      product_id: "505bd76785ebb509fc183733",
      sku: "46493-32",
      name: "Uno Card Game",
      price: 3,
      quantity: 2,
      category: "Games",
    },
  ],
})

Order Completed

When you call the track method for an event with the name Order Completed using the eCommerce API, RudderStack sends the products listed in the event to Braze as purchases.

Page

A samplepage call is as shown below:

rudderanalytics.page("PublicFacingCategory", "HomePage", {
  title: "Welcome RudderStack",
  url: "http://www.rudderstack.com",
  time: "2020-02-11T13:16:23.858Z",
})

The above call is made through the RudderStack JavaScript SDK, and sent to Braze as a track event with name set to the page name.

Group

The group call is made to associate the user with a group. The example of a group call is as shown below:

rudderanalytics.group("test_group_id", {
  name: "Group Name",
})

Once you send the group event, RudderStack will send a custom attribute to Braze with the name as ab_rudder_group_<groupId> where groupId is the ID you've passed in the group call, and will set the value to true.

For example, if the groupId is test_group_id then RudderStack will create a custom attribute to Braze with the name ab_rudder_group_test_group_id and set the value to true.

Contact Us

The track call captures all the activities that the user performs, along with any other properties that are associated with those activities. Each of these activities or actions is considered by RudderStack as an event. For more information on the track call, please refer to the guide.

The page call allows you to record your website's page views, with the additional relevant information about the page being viewed. For more information on the page call, please refer to the guide.

If you come across any issues while configuring Braze with RudderStack, please feel free to . You can also start a conversation in our community; we will be happy to talk to you!

RudderStack API Specification
RudderStack API Specification
contact us
Slack
GitHub repo
RudderStack connection modes
here
here
Braze Instances