/sptrans-ruby

Primary LanguageRubyDo What The F*ck You Want To Public LicenseWTFPL

Sptrans

O objetivo dessa gem é facilitar o acesso à API Olho Vivo

Installation

Add this line to your application's Gemfile:

gem 'sptrans'

And then execute:

$ bundle

Or install it yourself as:

$ gem install sptrans

Uso

sp_trans = SPTrans.new token
linhas = sp_trans.linhas termos_busca
# => [<SPTrans::Linha @...>, <SPTrans::Linha @...>]

Customizar a criação da conexão usando o Faraday:

SPTrans.new token do |faraday|
  faraday.adapter :curb
end

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request