Class: BrightData::Client
- Inherits:
-
Object
- Object
- BrightData::Client
- Defined in:
- lib/brightdata/client.rb
Overview
Top-level Bright Data API client.
Instance Attribute Summary collapse
-
#http ⇒ BrightData::HTTP
readonly
Underlying HTTP wrapper.
-
#linkedin ⇒ BrightData::LinkedIn::Namespace
readonly
LinkedIn endpoint namespace.
Instance Method Summary collapse
-
#initialize(api_token:, base_url: BrightData::HTTP::BASE_URL, logger: nil) ⇒ Client
constructor
A new instance of Client.
Constructor Details
#initialize(api_token:, base_url: BrightData::HTTP::BASE_URL, logger: nil) ⇒ Client
Returns a new instance of Client.
20 21 22 23 |
# File 'lib/brightdata/client.rb', line 20 def initialize(api_token:, base_url: BrightData::HTTP::BASE_URL, logger: nil) @http = HTTP.new(api_token:, base_url:, logger:) @linkedin = LinkedIn::Namespace.new(http: @http) end |
Instance Attribute Details
#http ⇒ BrightData::HTTP (readonly)
Returns underlying HTTP wrapper.
11 12 13 |
# File 'lib/brightdata/client.rb', line 11 def http @http end |
#linkedin ⇒ BrightData::LinkedIn::Namespace (readonly)
Returns LinkedIn endpoint namespace.
14 15 16 |
# File 'lib/brightdata/client.rb', line 14 def linkedin @linkedin end |