NameChecker makes it easy to check the availability of a word across various top-level domains and social networks.
It powers checking at namedar.com.
Add this line to your application's Gemfile:
And then execute:
Or install it yourself as:
$ gem install name_checker
availability = NameChecker.check(<WORD>, <SERVICE>)
availability = .("banana", "twitter") availability.text #=> "banana" availability.available? #=> false # NOTE: It is important to include the period at the start # of the TLD when checking hosts. availability = .("availabledomain", ".net") availability.text #=> "availabledomain.net" availability.available? #=> true
Supported Social Networks
Supported Top-level Domains
See the documentation of the Ruby-Whois Gem.
Checking Domain Availability
To use the RoboWhois service, simply configure NameChecker with an API key.
.config do |config| config.robo_whois_api_key = 'jdsfldsjflkj' end
All domain availability requests will then route through RoboWhois.
- Fork it
- Create your feature branch (
git checkout -b my-new-feature)
- Commit your changes (
git commit -am 'Added some feature')
- Push to the branch (
git push origin my-new-feature)
- Create new Pull Request
Running the Specs
You will need to add a RoboWhois Api Key to
spec/spec_helper.rb to be
able to run all of the specs. Set it up like this:
# Add your robo whois api key here: ROBO_WHOIS_API_KEY = 'YOUR_KEY'
You can still run the specs without an API key. However, all specs related to the RoboWhoisChecker will fail.