Class: Restforce::Configuration
- Inherits:
-
Object
- Object
- Restforce::Configuration
- Defined in:
- lib/restforce/config.rb
Instance Attribute Summary collapse
-
#api_version ⇒ Object
Returns the value of attribute api_version.
-
#cache ⇒ Object
Set this to an object that responds to read, write and fetch and all GET requests will be cached.
-
#client_id ⇒ Object
The OAuth client id.
-
#client_secret ⇒ Object
The OAuth client secret.
-
#host ⇒ Object
Set this to true if you’re authenticating with a Sandbox instance.
-
#instance_url ⇒ Object
Returns the value of attribute instance_url.
-
#oauth_token ⇒ Object
Returns the value of attribute oauth_token.
-
#password ⇒ Object
The password to use during login.
-
#refresh_token ⇒ Object
Returns the value of attribute refresh_token.
-
#security_token ⇒ Object
The security token to use during login.
-
#username ⇒ Object
The username to use during login.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #logger ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
63 64 65 66 |
# File 'lib/restforce/config.rb', line 63 def initialize @api_version ||= '24.0' @host ||= 'login.salesforce.com' end |
Instance Attribute Details
#api_version ⇒ Object
Returns the value of attribute api_version.
40 41 42 |
# File 'lib/restforce/config.rb', line 40 def api_version @api_version end |
#cache ⇒ Object
Set this to an object that responds to read, write and fetch and all GET requests will be cached.
61 62 63 |
# File 'lib/restforce/config.rb', line 61 def cache @cache end |
#client_id ⇒ Object
The OAuth client id
48 49 50 |
# File 'lib/restforce/config.rb', line 48 def client_id @client_id end |
#client_secret ⇒ Object
The OAuth client secret
50 51 52 |
# File 'lib/restforce/config.rb', line 50 def client_secret @client_secret end |
#host ⇒ Object
Set this to true if you’re authenticating with a Sandbox instance. Defaults to false.
53 54 55 |
# File 'lib/restforce/config.rb', line 53 def host @host end |
#instance_url ⇒ Object
Returns the value of attribute instance_url.
57 58 59 |
# File 'lib/restforce/config.rb', line 57 def instance_url @instance_url end |
#oauth_token ⇒ Object
Returns the value of attribute oauth_token.
55 56 57 |
# File 'lib/restforce/config.rb', line 55 def oauth_token @oauth_token end |
#password ⇒ Object
The password to use during login.
44 45 46 |
# File 'lib/restforce/config.rb', line 44 def password @password end |
#refresh_token ⇒ Object
Returns the value of attribute refresh_token.
56 57 58 |
# File 'lib/restforce/config.rb', line 56 def refresh_token @refresh_token end |
#security_token ⇒ Object
The security token to use during login.
46 47 48 |
# File 'lib/restforce/config.rb', line 46 def security_token @security_token end |
#username ⇒ Object
The username to use during login.
42 43 44 |
# File 'lib/restforce/config.rb', line 42 def username @username end |
Instance Method Details
#logger ⇒ Object
68 69 70 |
# File 'lib/restforce/config.rb', line 68 def logger @logger ||= ::Logger.new STDOUT end |