Register
TIP
Payload
RegisterPayload
first_name
string
RegisterPayload.first_name
last_name
string
RegisterPayload.last_name
phone
string
RegisterPayload.phone
country_code
string
RegisterPayload.country_code
Default:
SA
country_key
string
RegisterPayload.country_key
Default:
+966
verified_by
enum<string>
RegisterPayload.verified_by
Allowed values:
emailphone
Default:
phone
email
string
RegisterPayload.email
code
number
RegisterPayload.code
Response
Success
Error
auth.register.success
success
boolean
success
status
enum<number>
status
Allowed values:
200201202
data
object
data
case
enum<string>
required
new_customer
. This indicates that the user is a new customer and must go through the registration process. On the other hand, its value will be authenticated
when a token is returned. This indicates that the user has been authorized and is ready to log in.Allowed values:
new_customerauthenticated
redirect_url
string
required
token
string
required
verification
object
required
Usage
register()
creates a new customer account. A registration request must provide a user with the following information: first_name
, last_name
, email
, phone
, country_code
, and country_key
. Additionally, the login verification type should be stored in verfied_by
, so that later the verification code
will be sent to that verification type.
Events
onRegistered
onRegistrationFailed
Modified at 2025-03-04 12:54:02