class FixerApiClient::Connection

Public Class Methods

connection() click to toggle source
# File lib/fixer_api_client/connection.rb, line 8
def self.connection
  ::Faraday.new(url: url) do |conn|
    conn.request :json
    conn.adapter :net_http
    conn.response :json, content_type: /\bjson$/
  end
end
url() click to toggle source
# File lib/fixer_api_client/connection.rb, line 16
def self.url
  ENV['FIXER_IO_API_URL'] || 'http://data.fixer.io/api'
end