Class: Io::Flow::V0::Clients::CustomerBundles

Inherits:
Object
  • Object
show all
Defined in:
lib/flow_commerce/flow_api_v0_client.rb

Instance Method Summary collapse

Constructor Details

#initialize(client) ⇒ CustomerBundles

Returns a new instance of CustomerBundles.



5687
5688
5689
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 5687

def initialize(client)
  @client = HttpClient::Preconditions.assert_class('client', client, ::Io::Flow::V0::Client)
end

Instance Method Details

#get_bundle_by_number(organization, number) ⇒ Object

Returns information about a specific customer.



5692
5693
5694
5695
5696
5697
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 5692

def get_bundle_by_number(organization, number)
  HttpClient::Preconditions.assert_class('organization', organization, String)
  HttpClient::Preconditions.assert_class('number', number, String)
  r = @client.request("/#{CGI.escape(organization)}/customers/#{CGI.escape(number)}/bundle").get
  ::Io::Flow::V0::Models::CustomerBundle.new(r)
end