Class: Yield::SDK::BaseClient

Inherits:
Object
  • Object
show all
Defined in:
lib/yield/sdk/base_client.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_key, base_url: nil, faraday_conn: nil) ⇒ BaseClient

Returns a new instance of BaseClient.



15
16
17
18
19
20
# File 'lib/yield/sdk/base_client.rb', line 15

def initialize(api_key, base_url: nil, faraday_conn: nil)
  @api = API::Client.new(api_key, base_url:, faraday_conn:)

  @self = Self::BaseClient.new(@api)
  @order = Order::BaseClient.new(@api)
end

Instance Attribute Details

#apiObject (readonly)

Returns the value of attribute api.



10
11
12
# File 'lib/yield/sdk/base_client.rb', line 10

def api
  @api
end

#orderObject (readonly)

Returns the value of attribute order.



13
14
15
# File 'lib/yield/sdk/base_client.rb', line 13

def order
  @order
end

#selfObject (readonly)

Returns the value of attribute self.



12
13
14
# File 'lib/yield/sdk/base_client.rb', line 12

def self
  @self
end