Developer Guide
API GuideDeveloper Guide
  • Overview
    • Getting Started
    • Customers and Visitors
    • Events and Business Objects (BOs)
      • Sample Event Templates
  • Website
    • Getting Started
      • Direct JS Implementation
      • JS Integration via GTM
      • Tracking Haravan website events
    • Tracking Users
    • Tracking Events
      • [Direct] Sample E-Commerce Events
        • View Product
        • Add a Product to the Shopping Cart
        • View the Shopping Cart
        • Remove a Product from the Shopping Cart
        • Search for Product(s)
        • Checkout Shopping Cart
        • Apply Promotion Code
        • Purchase Product(s)
      • [GTM] Sample E-Commerce Events
        • View Product
        • Add a Product to the Shopping Cart
        • View the Shopping Cart
        • Remove a Product from the Shopping Cart
        • Search for Product(s)
        • Checkout Shopping Cart
        • Apply Promotion Code
        • Purchase Product(s)
    • Web Push
  • Android
    • Getting Started
    • Tracking Users
    • Tracking Events
    • Push Messaging
    • App Inbox Messaging
  • iOS
    • Getting Started
      • Integration of Antsomi iOS SDK
    • Tracking Users
    • Tracking Events
    • Push Messaging
  • Hybrid Apps
    • React Native
      • Tracking Users
      • Tracking Events
        • Sample E-Commerce Events
          • View Product
          • Add a Product to the Shopping Cart
          • View the Shopping Cart
          • Remove a Product from the Shopping Cart
          • Search for Product(s)
          • Checkout Shopping Cart
          • Apply Promotion Code
          • Purchase Product(s)
      • Push Messaging
      • App Inbox Messaging
    • Flutter
      • Tracking Users
      • Tracking Events
        • Sample E-Commerce Events
          • View Product
          • Add a Product to the Shopping Cart
          • View the Shopping Cart
          • Remove a Product from the Shopping Cart
          • Search for Product(s)
          • Checkout Shopping Cart
          • Purchase Product(s)
      • Push Messaging
      • App Inbox Messaging
      • App In-line Content
  • Antsomi Service Integrations
    • Media Template
    • Media JSON
      • Sample E-Commerce Events
        • Search for Product(s)
        • View Product
        • Add a Product to the Shopping Cart
        • Checkout Shopping Cart
        • Purchase Product(s)
      • Sample User Events
        • Sign-in
        • Sign-up
      • Sample Opt-in Events
        • Subscribe to Email marketing
        • Subscribe to OneSignal channel
  • 3rd Party Integrations
    • Shopify
      • Tracking Shopify website events
    • LINE
      • Integrating LINE Login with your web app
    • Google Ad Manager
      • Targeting CDP365 segment via PPID(s)
Powered by GitBook
On this page
  • 1. Installation
  • 2. Antsomi Instance Initialization
  1. Hybrid Apps

React Native

PreviousPush MessagingNextTracking Users

Last updated 1 year ago

lets you build mobile apps using only JavaScript. It uses the same design as React, letting you compose a rich mobile UI from declarative components.

Here's how you can integrate the Antsomi SDK with your React Native apps:

1. Installation

Step 1: Run npm install @antsomicorp/antsomirnsdk to install the SDK.

npm install @antsomicorp/antsomirnsdk

2. Antsomi Instance Initialization

Initialize AntsomiRnSDK in your App.tsx

import AntsomiRnSDK from '@antsomicorp/antsomirnsdk';

AntsomiRnSDK.config('<YOUR_PORTAL_ID>','<YOUR_SOURCE_ID>','<YOUR_APPLICATION_ID>', '<YOUR_APP_GROUP_ID>');

In which:

Key
Description

YOUR_APP_GROUP_ID

Your iOS App Group ID.

For example, group.antsomi.rn

YOUR_PORTAL_ID

Your CDP365 portal ID. For example, 564890637

YOUR_SOURCE_ID

Your CDP365 event source ID. For example, 564993464

YOUR_APPLICATION_ID

Your CDP365 application ID. For example, e4e8d06e-4d97-43df-93e8-c36238147ca0

Remember to verify the user's mobile device operating system to ensure accurate event source configuration. In CDP365, mobile app event sources are categorized into iOS and Android sources, so it's essential to distinguish between them based on the user's device OS.


NEXT STEP

React Native
Tracking User Attributes
Tracking User Events
Configure Push Messaging
Configure App In Box Messaging