Class: LinkedIn::API
- Inherits:
-
Object
- Object
- LinkedIn::API
- Extended by:
- Forwardable
- Defined in:
- lib/linked_in/api.rb
Instance Attribute Summary collapse
-
#access_token ⇒ Object
Returns the value of attribute access_token.
Instance Method Summary collapse
-
#initialize(access_token = nil) ⇒ API
constructor
A new instance of API.
Constructor Details
#initialize(access_token = nil) ⇒ API
Returns a new instance of API.
6 7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/linked_in/api.rb', line 6 def initialize(access_token=nil) access_token = parse_access_token(access_token) verify_access_token!(access_token) @access_token = access_token @connection = LinkedIn::Connection.new params: default_params, headers: default_headers do |conn| conn.request :multipart conn.adapter Faraday.default_adapter end initialize_endpoints end |
Instance Attribute Details
#access_token ⇒ Object
Returns the value of attribute access_token.
4 5 6 |
# File 'lib/linked_in/api.rb', line 4 def access_token @access_token end |