Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- uri = URI("XXX")
- https = Net::HTTP.new(uri.host, uri.port)
- request = Net::HTTP::Post.new(uri.request_uri, {'Content-Type' => 'application/x-www-form-urlencoded'})
- body = {"key" => @api_key, "message" => mes, "to" => phoneNumber}
- request.body = body.to_json
- response = https.request(request)
Advertisement
Add Comment
Please, Sign In to add comment