Back to Parent

desc 'sends a test MMS to your twilio number'
task :send_photo do

  client = Twilio::REST::Client.new ENV["TWILIO_ACCOUNT_SID"], ENV["TWILIO_AUTH_TOKEN"]
  message, media = city_message


   client.api.account.messages.create(
   from: ENV["TWILIO_FROM"],
   to: ENV["MY_NUMBER"],
   body: message,
   media_url: media
   )

end
Click to Expand

Content Rating

Is this a good/useful/informative piece of content to include in the project? Have your say!

0