Empowering Minds with Tech Knowledge.

How to setup OTP SMS API in your code?

How to setup OTP SMS API in your code?

16/October/2024 18:39    Comments (0)     Share:        Bookmark

1. Once you purchased the OTP SMS service, you will get login details to the panel.

2. Use the login details given to you in your client area to login into the panel or you can click on "Login to Panel" Button. If you see below window, click on "Send anyway" Button.



3. Now, your panel will open. Click on the rocket button in the bottom of the page.

4. Copy the User and Key from the from the Request API.



5. Use below PHP code to send the OTP from your website/application. If you want, you can use API to integrate in any language. We are using PHP here, because of high demand by users.

$num="User mobile here";
$otp="OTP to send";
$dv_user="enter user ID here";
$dv_key="Enter key here";
$arrContextOptions=array(
"ssl"=>array(
"verify_peer"=>false,
"verify_peer_name"=>false,
),
);
$otp_url="http://otp.xhost.co.in/submitsms.jsp?user=$dv_user&key=$dv_key&mobile=+91$num&message=Hi%20Dear%2C%20Your%20Otp%20is%20$otp.%20OTP%20request%20for%20OTP.%20Don%27t%20Share%20with%20Anyone.%20Thanks%2C%20Team%20SB%20Genus.&senderid=SBGINF&accusage=1";
$response = file_get_contents($otp_url, false, stream_context_create($arrContextOptions));
?>

Comments (0)
Leave a Reply

Your email address and mobile will not be published.

Trending Blog
How to install SSL in Vestacp Panel?
24/September/2024 17:12
How to install SSL in Vestacp Panel?
How to install software in aaPanel?
16/October/2024 18:13
How to install software in aaPanel?
How to setup News/Blog website?
16/October/2024 22:55
How to setup News/Blog website?
How to install SSL in cPanel?
16/October/2024 12:24
How to install SSL in cPanel?
How to setup a prime website?
09/January/2025 14:26
How to setup a prime website?
How to setup basic website?
16/October/2024 19:04
How to setup basic website?
Related Blog

16/October/2024 17:20 Comments (1)
How to create a ticket?
17/October/2024 16:13 Comments (0)
How to setup a reseller panel?
17/October/2024 17:39 Comments (0)
How to check if VPS is UP or Down?

Subscribe our Newsletter