ApiKey that has access to your entire App on MoonKey.
1 - Implement OTP UI
Implement two UI screens to enable OTP
UI to enter phone number

UI to enter phone number
2 - Register or Create user
Each user must be stored on MoonKey Auth, so we recommend ensuring that you store our auto generated User ID from the response into your database/backend in a column or field against that user (as long as you can associate your user with the auto generated ID returned by MoonKey). We will ensure that each mobile number or email is ONLY attached to a single user at any time. We will be using the LoginOrCreateUserBySMS, if a user is found with the provided phone number, it will be returned and OTP (one-time passcode) sent out, otherwise, a new user will be created on the fly (aka JIT, Just in time).3 - Verify OTP
In the previous step, MoonKey Auth will return a response like the following,JSON
phone_number_id will be used as the method_id in the VerifyOTP endpoint.
session_token or session_expires_in parameters, a new session will then be created or extended for the given user and the session token returned.
JSON
JSON