In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
Today, I will talk to you about how to use Python to send free text messages. Many people may not know much about it. In order to make you understand better, the editor has summarized the following content for you. I hope you can get something according to this article.
Preface
Today, I will take you to play, how to use Python to achieve free SMS.
Let's move on to today's topic-the twilio website.
Https://www.twilio.com
Twilio
Preparatory work
First of all, let's introduce this website, which is mainly used for sending text messages and incoming calls, and provides a complete related api.
After consulting on the Internet, this is the largest number of free text messages in many websites. Later, I will talk about some of my ideas, how not to limit the number of messages (a little bit of trouble.)
1. Go to the official website and register an account.
Just fill it in normally.
two。 Verify mailbox
If you receive it in your mailbox, click:
3. Verify the phone
4. Choose the option at will
5. Get the number provided by the server
6. Initial amount change
To calculate the account, the official will send you $15.50 for each newly applied account, which is equivalent to about 109.01 yuan at the exchange rate on December 8, 2019.
When you get the server phone number, deduct $1, leaving $14.5.
At this point, the preparatory work is complete!
Official code demonstration
The twilio website perfectly provides developers with many official examples and is extremely friendly.
Let's go straight to the official example.
1. Docs-> Helper Libraries
2.Server-Side SDKs-> Python
3. Code demo
This is the code, but install twilio yourself before you execute it.
Pip install twilio
Note that you need to replace sid and token with your own.
During execution, if your SMS phone number is not the same as the one you used to log in to the website, you will report the following HTTP400 error, to the effect that your phone number has not been verified:
Therefore, the recipient's mobile phone number needs to be verified, and the following operations can be completed.
After you have added it, execute the code again and you will receive a text message:
Make an account
Look at the picture below:
Billing stands for the meaning of bill, click to Overview, 3 is just sent a test text message deducted US dollars, previously also deducted $1 server mobile phone number registration.
Sending a text message is equal to about 20 yuan (now it seems to be only 10 cents to send a text message in China). $14.5 Universe 0.028 ≈.
It means that each account can send 517 text messages for free.
After reading the above, do you have any further understanding of how to use Python to send free text messages? If you want to know more knowledge or related content, please follow the industry information channel, thank you for your support.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.