npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

zetakit_reactnative

v1.0.0

Published

Zeta Global React Native SDK

Downloads

19,645

Readme

Zeta Global React Native SDK

The Zeta React Native plugin enables developers to integrate Zeta's services seamlessly into React Native applications. It provides a simple, reliable, and efficient way to access Zeta APIs and build robust cross-platform apps for iOS and Android.


Key Offerings

  • User Identification: Manage user profiles, contact details, and custom attributes.
  • Event Tracking: Track custom user actions and behaviors.
  • Push Notification Handling: Register device tokens, receive and process push notifications.
  • In-App Messaging: Display rich, contextual in-app messages to users.
  • App Inbox: Retrieve, read, and manage in-app inbox messages.
  • Opt-in/out Controls: Support user privacy with tracking opt-in/opt-out preferences.

SDK Support & Compatibility

  • React Native: Version 0.76.0 and above.
  • iOS: Minimum deployment target iOS 15.1+.
  • Android: Minimum supported version Android 7.0 (API level 24).

Installation

Install the plugin in your React Native project using npm or yarn:

# Using npm
npm install zetakit_reactnative

# Using yarn
yarn add zetakit_reactnative

iOS Setup

After installing the package, install the required CocoaPods:

cd ios && pod install && cd ..

Note: Ensure your iOS project's deployment target is set to iOS 15.1 or higher.

Android Setup

Ensure your Android project has Google Play Services and Firebase Messaging configured if you are using push notifications. Set the minSdkVersion to 24 or higher in your android/app/build.gradle file.


Quick Start & Usage

1. Initialization

Initialize the Zeta SDK as early as possible in your application lifecycle (e.g., in App.tsx or your index file).

import ZetaClient, {
  ZTRegion, 
  ZTAppEnvironment,
  type ZTConfig,
} from 'zetakit_reactnative';

const config: ZTConfig = {
  clientSiteId: 'your_client_site_id',
  clientSecret: 'your_client_secret',
  region: ZTRegion.US,
  appGroupId: 'your_app_group_id', // iOS only
  optIn: true,
  appEnvironment: ZTAppEnvironment.PRODUCTION,
};

ZetaClient.initialize(config, () => {
  console.log('Zeta SDK initialized successfully');
});

2. Setting User Details

Identify users and update their profiles with custom attributes.

import ZetaClient, { type ZTUserEmailContact } from 'zetakit_reactnative';

ZetaClient.user.build((user) => {
  user.uid = 'user_unique_id';
  user.firstName = 'John';
  user.lastName = 'Doe';
  
  const emailContact: ZTUserEmailContact = {
    email: '[email protected]',
    additionalInfo: {}
  };
  user.email = emailContact;

  // Set custom properties
  user.additionalProperties = {
    'membership_level': 'gold',
    'preferred_language': 'en'
  };
});

3. Event Tracking

Track custom events to understand user behavior.

import ZetaClient from 'zetakit_reactnative';

ZetaClient.events.track('purchase_completed', {
  'item_id': 'sku_12345',
  'price': 99.99,
  'currency': 'USD'
});

4. App Inbox

Retrieve and manage messages in the user's App Inbox.

import ZetaClient from 'zetakit_reactnative';

// Fetch all inbox messages
const messages = await ZetaClient.inbox.getMessages();

// Mark a message as read
await ZetaClient.inbox.markAsRead(messageId);

// Delete a message
await ZetaClient.inbox.deleteMessage(messageId);

// Get unread message count
const unreadCount = await ZetaClient.inbox.getUnreadCount();

5. Push Notification Management

Update Device Token

Send the push token to Zeta to target the device.

import ZetaClient from 'zetakit_reactnative';

ZetaClient.user.updateDeviceToken('your_device_token');

Handle Push Notifications (iOS Only)

Process incoming push notification payloads.

import ZetaClient from 'zetakit_reactnative';

const handled = await ZetaClient.push.handleNotificationsMessage(
  response,
  actionIdentifier, // optional; iOS falls back to UNNotificationDefaultActionIdentifier
);

if (handled) {
  completionHandler();
}

Note: On Android, handleNotificationsMessage resolves to false so shared JS code does not need platform guards.

Native Push Configurations

  • iOS: Native iOS setup is required to configure push notifications. Refer to the Zeta iOS SDK Push Documentation for details.
  • Android: If your application does not use a custom service, the SDK automatically captures the device token. If you override the default push channel behavior, configure the channel in your Application.onCreate method. Refer to the Zeta Android SDK Push Documentation for details.

Controlling Log Level

Use ZTLogger.setLogLevel(...) to control the verbosity of native SDK logs. Call it before ZetaClient.initialize(...) to capture startup logs.

import ZetaClient, { ZTLogger, ZTLogLevel } from 'zetakit_reactnative';

ZTLogger.setLogLevel(ZTLogLevel.DEBUG);
ZetaClient.initialize(config, () => {
  console.log('SDK initialized with DEBUG logging');
});

Available log levels: NONE (default), VERBOSE, DEBUG, INFO, WARNING, ERROR.


Version 1.0.0 Highlights & Migration

zetakit_reactnative 1.0.0 is built on top of the following native SDK versions:

  • Android native dependency: net.zetaglobal.app:core:1.0.1
  • iOS native dependency: ZetaCore 1.0.0

Upgrading from 0.2.x? See MIGRATION.md for the full list of breaking changes.