Class: Salesforce::Configuration
Instance Attribute Summary
#base_request_headers, #open_timeout, #read_timeout, #request_types, #user_agent
Instance Method Summary
collapse
#breakers_error_threshold, #breakers_exception_handler, #breakers_matcher, #breakers_service, #create_new_breakers_service, #current_module, #request_options, #service_exception, #service_name
Instance Method Details
#base_path ⇒ Object
5
6
7
|
# File 'lib/salesforce/configuration.rb', line 5
def base_path
"#{self.class::SALESFORCE_INSTANCE_URL}/services/oauth2/token"
end
|
#connection ⇒ Object
9
10
11
12
13
14
15
16
17
|
# File 'lib/salesforce/configuration.rb', line 9
def connection
@conn ||= Faraday.new(base_path) do |faraday|
faraday.use :breakers
faraday.request :url_encoded
faraday.response :json
faraday.response :betamocks if mock_enabled?
faraday.adapter Faraday.default_adapter
end
end
|
#mock_enabled? ⇒ Boolean
19
20
21
|
# File 'lib/salesforce/configuration.rb', line 19
def mock_enabled?
false
end
|