Method: Databasedotcom::Client#http_get
- Defined in:
- lib/databasedotcom/client.rb
#http_get(path, parameters = {}, headers = {}) ⇒ Object
Performs an HTTP GET request to the specified path (relative to self.instance_url). Query parameters are included from parameters. The required Authorization
header is automatically included, as are any additional headers specified in headers. Returns the HTTPResult if it is of type HTTPSuccess- raises SalesForceError otherwise.
287 288 289 290 291 |
# File 'lib/databasedotcom/client.rb', line 287 def http_get(path, parameters={}, headers={}) with_encoded_path_and_checked_response(path, parameters) do |encoded_path| https_request.get(encoded_path, {"Authorization" => "OAuth #{self.oauth_token}"}.merge(headers)) end end |