React Native SDK
Using our React Native SDK makes it easy to integrate Shen.AI into a new or existing cross-platform (iOS and Android) React Native app.
The best way to get started is to download and build the example app - available here on GitHub .
The Shen AI SDK supports Expo. The minimal Expo example is available here on GitHub .
Installing the SDK package
To start working with the SDK, you’ll need to download the SDK package and extract it in your React Native codebase. The SDK is packaged as a React Native package that you can reference locally in the filesystem (as opposed to the public npm registry).
Specify the relative path to the extracted SDK in package.json
"dependencies": {
...
"react-native-shenai-sdk": "file:./react-native-shenai-sdk"
}Custom frame input
React Native exposes CameraMode.CUSTOM_FRAMES, so you can configure the SDK not to start a camera:
import { initialize, CameraMode } from "react-native-shenai-sdk";
await initialize(API_KEY, USER_ID, {
cameraMode: CameraMode.CUSTOM_FRAMES,
});Further steps
Please see permissions, initialization, configuration and video measurement for further steps.