Module: PUBG::Connection
- Included in:
- Client
- Defined in:
- lib/pubg/connection.rb
Overview
Network layer
Instance Method Summary collapse
Instance Method Details
#agent ⇒ Object
8 9 10 11 12 13 |
# File 'lib/pubg/connection.rb', line 8 def agent @agent || Sawyer::Agent.new(api_endpoint, ) do |http| http.headers[:accept] = [:headers][:accept] http. 'Bearer', @access_token end end |
#get(url, options = {}) ⇒ Object
4 5 6 |
# File 'lib/pubg/connection.rb', line 4 def get(url, = {}) request :get, url, end |