Text message verification-how does PHP call the SMS interface?

Source: Internet
Author: User
Our APP has a feedback function. Now I want to send a text message to each feedback user, and I have purchased the text message verification service. Because the APP is outsourced, PHP + MYSQL is used in the background, and phpmyadmin is available, and I will click the frontend and python. It is troublesome to add this function now. Who gives us an idea. Our APP has a feedback function. Now I want to send a text message to each feedback user, and I have purchased the text message verification service.
Because the APP is outsourced, PHP + MYSQL is used in the background, and phpmyadmin is available, and I will click the frontend and python. It is troublesome to add this function now.
Who gives us an idea.

Reply content:

Our APP has a feedback function. Now I want to send a text message to each feedback user, and I have purchased the text message verification service.
Because the APP is outsourced, PHP + MYSQL is used in the background, and phpmyadmin is available, and I will click the frontend and python. It is troublesome to add this function now.
Who gives us an idea.

Check what type of SMS interface is used. http is used here. Therefore, you can call curl directly.

Does the text message verification service have a php sdk? If the http protocol is used, php curl can be used for implementation.

Generally, text message providers provide PHP sdks, which are developed based on their interface documentation.

  1. $ Clent = new clent ([params]);

  2. $ Client-> sendSMS ([infomation]);

After receiving the feedback from the app, the background calls the corresponding API of the sms sdk of the SMS service provider to send the corresponding SMS to the user (according to the description, it should belong to the SMS notification class ), however, it cannot be ensured that the user will receive the message (for example, the user's mobile phone is in arrears), but the call result will be returned to the backend if the call is successful or not. If you are not familiar with PHP, you can check whether the python sdk is provided. After the key and other information are configured according to the SDK documentation, you can send text messages, because http interfaces are usually provided, so you can use the http corresponding to the request in python.

Generally, it is an HTTP interface. If you use a CULR request, the text message service provider will have a php sdk. You can download the SDK and integrate it into the code ~, Welcome to try SUBMAIL's short message service, SUBMAIL

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.