- GET:
/v1/example.ee
- GET:
/v1/example.ee.json
By default, this will return only public information. If full WHOIS info is required, the user needs to use Google ReCaptcha. Example usage:
- GET:
/v1/test.ee?utf8=%E2%9C%93&g-recaptcha-response=03AHJ_VuvVgYnzxXAuf8rdHvTPQ5FZSHYZ...
- GET:
/v1/example.ee.json?utf8=%E2%9C%93&g-recaptcha-response=03AHJ_VuvY4cI_oBaP1BtercOD...
REST WHOIS is based on Rails 4.
git clone https://github.com/internetee/rest-whois/
cd rest-whois
rbenv local 2.3.7
bundle install
cp config/application-example.yml config/application.yml # and edit it
cp config/database-example.yml config/database.yml # and edit it
bundle exec rake db:setup # for production, please follow deployment howto
cd rest-whois
mina pr setup
edit shared/config/application.yml and shared/config/database.yml files
<VirtualHost *:80>
ServerName your-rest-whois.ee
PassengerRoot /usr/lib/ruby/vendor_ruby/phusion_passenger/locations.ini
PassengerRuby /home/registry/.rbenv/shims/ruby
PassengerEnabled on
PassengerMinInstances 10
PassengerMaxPoolSize 10
PassengerPoolIdleTime 0
PassengerMaxRequests 1000
RailsEnv production # or staging
DocumentRoot /home/registry/rest-whois/current/public
# Possible values include: debug, info, notice, warn, error, crit,
LogLevel info
ErrorLog /var/log/apache2/rest-whois.error.log
CustomLog /var/log/apache2/rest-whois.access.log combined
<Directory /home/registry/rest-whois/current/public>
# for Apache older than version 2.4
Allow from all
# for Apache verison 2.4 or newer
# Require all granted
Options -MultiViews
</Directory>
</VirtualHost>
mina pr deploy
The database is shared, and all operations take place in the registry project. It is not recommended to perform operations or migrations within the framework of rest-whois.