Guest User

Untitled

a guest
Mar 12th, 2015
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.30 KB | None | 0 0
  1.   uri = URI("XXX")
  2.   https = Net::HTTP.new(uri.host, uri.port)
  3.   request = Net::HTTP::Post.new(uri.request_uri, {'Content-Type' => 'application/x-www-form-urlencoded'})
  4.   body = {"key" => @api_key, "message" => mes, "to" => phoneNumber}
  5.   request.body = body.to_json
  6.   response = https.request(request)
Advertisement
Add Comment
Please, Sign In to add comment