Instructions for receiving otp code

1  Request OTP

Address: {domain}/sendotp/index.php

Method: POST

Request parameter description

parameter name Parameter Description Remark
appkey application key *Required

provided by the supplier

appcode application code *Required

provided by the supplier

phone phone number

 

*Required

Multiple numbers are separated by commas, no more than 1000 at a time

Description of request parameter information:

{domain}/sendotp/index.php?appkey=[appkey]&appcode=[appcode]&phone=[phone number]

Response message description

{“carrier”:”mobifone”,”error”:0,”msgid”:”18249.64660089845.6ad9fbee624d945″,”log”:”Gui thanh cong”}

The following chart returns descriptive information about the data:

field type Description
carrier String return code
error int o: success, 1: error
msgid String The unique identifier returned by the submission (32-bit string, used to get the SMS receipt)
log String Note error

 

2.   Check OTP.

Address: {domain}/checkotp/index.php

When user type OPT Code you can double check API

Method: GET

Request parameter description

parameter name Parameter Description Remark
appkey application key *Required

provided by the supplier

appcode application code *Required

provided by the supplier

phone phone number

 

*Required

Multiple numbers are separated by commas, no more than 1000 at a time

code Code verify, Text from verify_code field *Required

field description

field type Description
appkey String application key
appcode String application key
phone String phone number
code String String from field user input

Description of request parameter information:

{domain}/checkotp/index.php?appkey=[appkey]&appcode=[appcode]&phone=[phone number]&code=[code]

Response message description

{“error”:””,”result”:1,”code”:”code”}

The following chart returns descriptive information about the data:

field type Description
result 1
error String String of error
code String Code of user input

 

3.   Check account.

{domain}/manager/

User / password

 

4.    Error code description table

return code Error code description
0 Succes
1 Error

 

5. USE OTP

When user click to “Gửi mã” call api.

{domain}/sendotp/index.php

{“phone”:”number”, “appcode”:”[Supplier provider]”, “appkey”:”[Supplier provider]”}
System will send code to phone number of User.
User put code receive to Field Mã xác nhận
When user click to Gửi call API
{domain}/sendotp/index.php
Method: POST
Paramater: 
appkey=[Supplier Provider]
appcode=[Supplier Provider]
phone=[In field]
code=[code from user input]
Example: {“appcode”:”12932″,”appkey”:”d01b14c3abff53477f5a2ed7c943111212″,”code”:”235772″,”phone”:”84908606456″}

Response message description

{“error”:””,”result”:1,”code”:”code”}

 

514
514