React Native SDK
The React Native SDK provides a wrapper around the Checker SDK.
The Prembly React Native SDK provides a simple hook to integrate identity verification, KYC, and liveness checks directly into your React native applications with minimal configuration.
Available React Native Packages
| Package/SDK | Environment | Description |
|---|---|---|
| prembly-reactnative-kyc | React Native | Mobile-native components supporting camera access, document capture, and biometric checks on iOS/Android. |
Quick Start
Install the required packages to get started:
npm install prembly-react-native-kyc react-native-webview
or
yarn add prembly-react-native-kyc react-native-webview
Implementation
import React, { useState } from 'react';
import { Button, View } from 'react-native';
import { PremblyIdentityWidget } from 'prembly-react-native-kyc';
export default function App() {
const [visible, setVisible] = useState(false);
return (
<View style={{ flex: 1, justifyContent: 'center' }}>
<Button title="Verify Identity" onPress={() => setVisible(true)} />
<PremblyIdentityWidget
isVisible={visible}
widgetKey="your_widget_key_here"
widgetId="your_widget_id_here"
firstName="John"
lastName="Doe"
email="[email protected]"
phone="+2348012345678"
metadata={{
user_id: '123456'
}}
callback={(response) => {
console.log('Response:', response);
if (response.status === 'closed' || response.status === 'error_display_closed' || respo
setVisible(false);
}
}}
/>
</View>
);
}
Configuration (Props)
| Parameter | Type | Required | Description |
|---|---|---|---|
| isVisible | boolean | Yes | Controls the visibility of the widget modal |
| widgetKey | String | Yes | Your public API key from the Prembly dashboard. |
| widgetId | String | Yes | The specific verification workflow ID created in your dashboard. |
| String | No | The user's email address | |
| firstName | String | No | User's first name to pre-fill the form. |
| lastName | String | No | User's last name to pre-fill the form. |
| phone | String | No | User's phone number. |
| metadata | Object | No | Custom key-value pairs (e.g., transaction_id) passed back in response callbacks. |
| callback | Function | Yes | Function executed when verification completes or closes |
Troubleshooting (React Native)
- If the WebView displays a blank screen, ensure react-native-webview is correctly linked and compiled.
- For Android camera issues, ensure you are requesting runtime camera permissions if compiling for API level 23+
Updated about 16 hours ago
Did this page help you?
