The Mobile SDK provides pre-built React Native screen components for the identity verification onboarding flow. These screens handle the UI and logic for document selection, camera scanning, and user interactions.
Import Pattern
Screens are imported directly from their onboarding paths, not from the main package index:
⚠️ All screens must be wrapped in SelfClientProvider. The screens use useSelfClient() internally and will throw an error if used outside the provider context.
Available Screens
DocumentCameraScreen
Handles MRZ (Machine Readable Zone) scanning from identity documents using the device camera.
import IDSelectionScreen from '@selfxyz/mobile-sdk-alpha/onboarding/id-selection-screen';
<IDSelectionScreen
countryCode="USA"
documentTypes={['p', 'i']} // p = passport, i = ID card, a = aadhaar
/>
import SDKCountryPickerScreen from '@selfxyz/mobile-sdk-alpha/onboarding/country-picker-screen';
<SDKCountryPickerScreen />