module Sightengine::Connection

Public Instance Methods

connection() click to toggle source
# File lib/sightengine/connection.rb, line 6
def connection
  Faraday::Connection.new({
    headers: {'Content-Type' => 'application/json'}
  }) do |conn|
    conn.use Faraday::Request::UrlEncoded
    conn.use FaradayMiddleware::ParseJson
    conn.adapter(Faraday.default_adapter)
  end
end