Skip to main content
Install the SDK and WebView dependency:
For secure persisted sessions, also install a native storage library.

React Native Keychain

react-native-keychain stores values in iOS Keychain and Android secure storage backed by Android Keystore.

Expo SecureStore

Expo SecureStore uses iOS Keychain and Android encrypted storage backed by Android Keystore.

Optional Android CameraX addon

The base SDK does not bundle Android CameraX. Install the optional addon only when your app wants Sagepilot’s Android in-app CameraX picker:
After installing the addon, run a fresh native Android build. A Metro reload is not enough for React Native autolinking to register the native module. For Expo apps, use a native/dev-client build:
For bare React Native apps, clean and rebuild Android:
The addon declares @sagepilot-ai/react-native-sdk as a peer dependency. Keep the base SDK installed directly in your app.

Optional host-provided picker dependencies

If you use the base SDK’s custom picker adapter instead of the CameraX addon, install only the picker modules your app needs.
See Native file picker for configuration and upload limits.

Required values

You need:
  • A Sagepilot workspace ID
  • A Sagepilot chat channel ID
  • A public SDK key in the format workspace_id:channel_id
  • Secure token storage for production apps
The key is not a secret. It is safe to ship in a mobile app. Do not put server API keys, signing secrets, or private workspace secrets in a React Native app.