# @appboxo/react-native-sdk

> BoxoSDK plugin for react native

Latest version **1.16.0** (published 2026-09-24) · Apache-2.0 license · 0 weekly downloads

## Install

```sh
npm install @appboxo/react-native-sdk
pnpm add @appboxo/react-native-sdk
yarn add @appboxo/react-native-sdk
bun add @appboxo/react-native-sdk
```

## Health

**Score 60/100 (C)** — status: active.

Positive: has types; no vulnerabilities; recently updated; high maintenance score.

Warnings: low downloads; no esm support.

## Facts

| | |
|---|---|
| Version | 1.16.0 |
| Published | 2026-09-24 |
| First published | 2020-06-23 |
| Weekly downloads | 0 |
| License | Apache-2.0 |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 346.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Appboxo pte. ltd. |
| Maintainers | alenboxo, rayevk, aitkulov, azakush |
| Keywords | boxo, boxoSDK, appboxo-react-native-sdk, boxo-react-native-sdk, appboxo, appboxoSDK |

## Links

- npm: https://www.npmjs.com/package/@appboxo/react-native-sdk
- Repository: https://github.com/Appboxo/react-native-sdk
- Homepage: https://github.com/Appboxo/react-native-sdk#readme
- Issues: https://github.com/Appboxo/react-native-sdk/issues
- npm.io page: https://npm.io/package/@appboxo/react-native-sdk

## Recent versions

- 1.16.0 (latest) — 2026-09-24
- 1.15.2 — 2026-07-29
- 1.15.1 — 2026-07-21
- 1.14.0 — 2026-06-02
- 1.13.1 — 2026-05-17
- 1.12.2 — 2026-05-07
- 1.12.1 — 2026-04-23
- 1.12.0 — 2026-04-20
- 1.11.2 — 2026-04-15
- 1.11.1 — 2026-04-10
- 1.11.0 — 2026-02-27
- 1.10.0 — 2025-11-27
- 1.9.0 — 2025-10-21
- 1.8.0 — 2025-09-10
- 1.7.2 — 2025-06-04
- … 56 more at https://npm.io/package/@appboxo/react-native-sdk/versions

## README

## Boxo SDK for React Native
A react native wrapper over Boxo SDK for IOS and Android.

Getting started:

```shell script
yarn add @appboxo/react-native-sdk 
```
or
```shell script
npm install @appboxo/react-native-sdk 
```

Next for IOS:
```shell script
cd ios && pod install
```

Usage:

```tsx
import React from 'react';
import Boxo from '@appboxo/react-native-sdk';
import { StyleSheet, View, Button } from 'react-native';

export default function App() {

  React.useEffect(() => {
    Boxo.setConfig('[client_id]', false);  //set your Boxo client_id, sandbox mode (by default is "false")
  }, [])

  const handleOpenMiniapp = () => {
    Boxo.openMiniapp('[miniapp_id]', {'key': 'value'});  //launch miniapp by id with data as {[key: string]: any} | undefined that is sent to miniapp.
  }

  return (
    <View style={styles.container}>
      <Button
        color="#841584"
        title="Launch miniapp"
        onPress={handleOpenMiniapp}
        accessibilityLabel="Launch miniapp"
    />
    </View>
  );
}

const styles = StyleSheet.create({
  container: {
    flex: 1,
    alignItems: 'center',
    backgroundColor: '#fff',
    justifyContent: 'center',
  },
});
```

To listen miniapp lifecycle events:

> Important
>
> Miniapp lifecycle events available in 1.0.8+ versions

```tsx
import React from 'react';
import Boxo from '@appboxo/react-native-sdk';
import { StyleSheet, View, Button } from 'react-native';

export default function App() {

  React.useEffect(() => {
    Boxo.setConfig('[client_id]', false);  //set your Boxo client_id, sandbox mode
    
    const subscription = Boxo.lifecycleHooksListener({
      onLaunch: (appId: string) => console.log('onLaunch', appId),  // called when the miniapp will launch with openMiniapp(...)
      onResume: (appId: string) => console.log('onResume', appId),  // called when the miniapp will start interacting with the user
      onPause: (appId: string) => console.log('onPause', appId),    // called when clicked close button in miniapp or when destroyed miniapp activity
      onClose: (appId: string) => console.log('onClose', appId),    // called when the miniapp loses foreground state
      onAuth: (appId: string) => console.log('onAuth', appId),    // called when authorization flow starts
      onError: (appId: string, error: string) => console.log('onError', appId, error),  // handle error
    });

    return () => subscription();
  }, [])

  const handleOpenMiniapp = () => {
    Boxo.openMiniapp('[miniapp_id]');  //launch miniapp by id
  }

  return (
    <View style={styles.container}>
      <Button
        color="#841584"
        title="Launch miniapp"
        onPress={handleOpenMiniapp}
        accessibilityLabel="Launch miniapp"
    />
    </View>
  );
}

const styles = StyleSheet.create({
  container: {
    flex: 1,
    alignItems: 'center',
    backgroundColor: '#fff',
    justifyContent: 'center',
  },
});
```

---
_Source: https://npm.io/package/@appboxo/react-native-sdk · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
