Migrating to latest release
How to migrate to the latest release from @okhi/react-native libraries
To further improve both developer integration experience as well as library performance the latest release of OkHi React Native library combines all functionality of OkCollect & OkVerify into one single library. The library also comes with the much anticipated iOS support so you can finally start creating and verifying your iOS users.
Remove the current libraries
Remove the current OkHi libraries integrated in your project by running the script below
Remove any installed pods
Set your project up for the new library
iOS
Enable background mode in your application.
OkHi obtains verification signals in the background, to enable this make sure to add "Location updates" and "Background fetch" to your Background Modes under Signing & Capabilities of your target.
All OkHi react-native libraries target ios devices >= 12. Make sure you're targeting at-least the same by modifying your both your Podfile and deployment target.
Podile located under: ios/Podfile
Add necessary permissions to your info.plist
file located under /ios/MyApp
Installation
Install the latest library by running
Finally install all required pods by running the following command in the ios
directory
Initialization
Add the following initialization code to your index.js
file. Replace my_branch_id
and my_client_key
with the keys provided to you after sign up.
Remove previous OkVerify initialization
Address creation & verification
All existing exports from the previous libraries remain intact, all you have to do is import them from the new react-native-okhi
library
Next steps
Check out the full guide
Checkout the API reference
Build a webhook endpoint to receive OkHi address verification scores.
Last updated