Created
December 26, 2012 10:10
-
-
Save lipchyk/4379385 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| require 'net/http' | |
| http = Net::HTTP.new('api.dominder.com') | |
| domain = 'google.com' | |
| email = 'your_email@your-email-server.com' | |
| authKey = 'your-authKey' | |
| format = 'xml' | |
| response = http.start do |http| | |
| request = Net::HTTP::Get.new("/v1/#{domain}?format=#{format}") | |
| request.basic_auth email, authKey | |
| response = http.request(request) | |
| end | |
| puts response.body |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment