class Mbta::Connection
Public Class Methods
connection()
click to toggle source
# File lib/mbta/connection.rb, line 6 def self.connection @connection = begin Faraday.new(:url => Mbta::Config::BASE_URL, :params => { :api_key => Mbta.api_key, :format => Mbta.format }) do |c| c.request :url_encoded c.request :json c.response :json c.adapter Faraday.default_adapter end end end