Register
Use 3 endpoints StepVerifyPhone, StepVerifyEmail, StepCreate to register a user using his mobile number and email.
General Input For Any Request
base-url: https://api.vlenseg.com/api/DigitalIdentity/<endpoint_path>
Headers
Content-Type*
string
application/json
ApiKey*
string
API Key
Request Body
transactionId
GUID
The transaction Id. Required if this request belongs to an existing transaction. If null then a new transaction Id will be generated and returned in the response to be used in subsequent requests for the same transaction.
{
"data": <Data model according to each model described below>,
"error_code": <int>,
"error_message": <string>
}{
"data": null,
"error_code": 400,
"error_message": "Bad Request - Input parameters are invalid."
}Register Step 1 Check Email & Phone Is Exist
Sends Request to Check the phone number & email is exist
POST https://<base-url>/CheckExistenceOfEmailOrPhone
Use parameters mentioned in general input above, check the data model in responses below.
Process of sending OTP to phone in order to verify possession of the mobile number.
Request Body
string
phoneNumber: Represents the phone number to be verified. This parameter should include the country code. The verification process will typically involve sending a one-time code to this phone number via SMS, example +201234567891
string
email: Represents the user mail to be verified. The verification process will typically involve sending a one-time code to this mail.
Register Step 2 Verify Phone
Sends Request to Verify the phone number
POST https://<base-url>/Register/StepVerifyPhone
Use parameters mentioned in general input above, check the data model in responses below.
Process of sending OTP to phone in order to verify possession of the mobile number.
Request Body
string
phoneNumber: Represents the phone number to be verified. This parameter should include the country code. The verification process will typically involve sending a one-time code to this phone number via SMS, example +201234567891
GUID
GUID auto generated from the server when OTP is sent to mobile number, to be sent back in next request along with the OTP.
string
The one-time password that was sent via SMS to Phone Number.
To Use this API
First you need to call it with phoneNumber and a new transactionId in body.
The server will response you with phoneNumberOtpRequestId.
Send another post request on same endpoint with same transactionId and phoneNumberOtpRequestId recieved in last response, add phoneNumberOtp value.
The server will response with a parameter in the body isPhoneNumberConfirmed with a Boolean value indicates is the OTP valid or not.
Register Step 3 Verify E-Mail
Sends Request to Verify the user mail
POST https://<base-url>/Register/StepVerifyEmail
Use parameters mentioned in general input above along with below parameters, check the data model in responses below.
Process of sending OTP to verify the possession of the mail.
Request Body
string
email: Represents the user mail to be verified. The verification process will typically involve sending a one-time code to this mail.
GUID
GUID auto generated form the server for the current verify request.
string
The one-time code that was sent to the E-Mail.
To Use this API
First you need to call it with email with the previous transaction id that used in the first step Verify you phone in body.
The server will response you with emailOtpRequestId.
Send post request on same endpoint with same transactionId and add emailOtpRequestId and emailOtp value sent on mail.
The server will response with a parameter in the body isEmailConfirmed with a Boolean value indicates is the OTP valid or not.
Register Step 4 Create
POST https://<base-url>/Register/StepCreate
Use parameters mentioned in general input above, check the data model in responses below.
object:
User Current Location {latitude, longitude}
string
User mobile device id
string
User Password
GUID
The verified Phone Number Request Id from Register Step 1
GUID
The verified E-Mail Request Id from Register Step 2
Last updated