twilioapi.py 316 B

1234567891011
  1. import twilio
  2. from twilio.rest import TwilioRestClient
  3. account_sid = "AC7889a1889c1833bd7181e45e60372776"
  4. auth_token = "1ad0315f3cc7a154aaaef048f1304f71"
  5. client = TwilioRestClient(account_sid, auth_token)
  6. def sendSMS(body, to, sender):
  7. message = client.messages.create(body=body, to=to, from_=sender)
  8. return