A very simple Ruby library for accessing the B-Cycle API; a work in progress.
Add this line to your application's Gemfile:
gem 'bcycle', :git => 'git://github.com/bshelton229/bcycle-ruby.git'
Load All Kiosks
Bcycle.kiosks
=> [#<Bcycle::Kiosk:0x007f981c012a78 @id=1645, @name="250 Columbine ", @status="Active"...
To filter kiosks, just use ruby Array's select (The api can't access indidivual records)
Bcycle.kiosks.select { |kiosk| kiosk.state == 'WI' and kiosk.city == 'Madison' and kiosk.active? }
You can find a particular kiosk
Bcycle.find 1874
=> #<Bcycle::Kiosk:0x007f981b1760c8 @id=1874, @name="Wisconsin & E. Mifflin", @status="Active"......
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request