Twilio Send messages in Python

Help us to keep this website almost Ad Free! It takes only 10 seconds of your time:
> Step 1: Go view our video on YouTube: EF Core Bulk Insert
> Step 2: And Like the video. BONUS: You can also share it!

Syntax

  • class twilio.rest.resources.Messages(*args, **kwargs)

Parameters

ParameterDetails
to (str)The destination phone number.
from_ (str)The phone number sending this message (must be a verified Twilio number)
body (str)The message you want to send, limited to 160 characters.
status_callbackA URL that Twilio will POST to when your message is processed.
application_sid (str)The 34 character sid of the application Twilio should use to handle this phone call.

Remarks

Twilio will send SMS messages for long codes (in the US, a regular ten digit number) at a rate of one message per second. For additional throughput, you can use pools of numbers with Copilot or apply for a shortcode, which can send 30 messages or more per second.



Got any Twilio Question?