module Restforce::Concerns::Base

def initialize(opts = {})

after a successful authentication.
:authentication_callback - A Proc that is called with the response body

'http://user@pass:proxy.example.com:port'
:proxy_uri - Proxy URI: 'http://proxy.example.com:port' or

(default: nil).
:timeout - Faraday connection request read/open timeout.
Restforce::Collections. (default: nil).
Salesforce responses to Restforce::Sobjects and
:mashify - Set to false to skip the conversion of
response (default: false).
:compress - Set to true to have Salesforce compress the

before raising an exception (default: 3).
should attempt to reauthenticate
:authentication_retries - The number of times that client

(default: '24.0')
:api_version - The String REST api version to use

(default: 'login.salesforce.com').
authentication requests
:host - The String hostname to use during

:client_secret - The oauth client secret to use.
password and oauth authentication
:client_id - The oauth client id to use. Needed for both

(required if oauth authentication is used).
:instance_url - The String base url for all api requests
authentication is used).
OAuth access tokens (required if oauth
:refresh_token - The String refresh token to obtain fresh
authentication is used).
API calls (required unless password
:oauth_token - The String oauth access token to authenticate

password authentication).
:security_token - The String security token to use (required for
password authentication).
:password - The String password to use (required for
password authentication).
:username - The String username to use (required for
opts - A hash of options to be passed in (default: {}).

Public: Creates a new client instance
def initialize(opts = {})
  raise ArgumentError, 'Please specify a hash of options' unless opts.is_a?(Hash)
  @options = Hash[Restforce.configuration.options.map do |option|
    [option, Restforce.configuration.send(option)]
  end]
  @options.merge! opts
  yield builder if block_given?
end