This demonstrates using HATT to test a set of HTTP APIs.
git clone git@github.com:rschultheis/hatt_example.git
cd hatt_example
bundle install
Go to [https://openweathermap.org/appid] to get your own APP ID (API Key).
Change the file to have these contents:
owm_app_id: <your api key>
Simply run the rspec command like so:
bundle exec rspec
One can call any hattdsl method from the command line like so:
bundle exec hatt -v weather_for "Missoula, MT"
Try the --help option for a full list of ways to use the hatt command line tool.
bundle exec hatt -q -f scripts/temperatures.rb
bundle exec hatt -v --pry-repl
> weather_for '59801'
... <big response> ...
See the official HATT repository: [https://github.com/rschultheis/hatt]