Class: Koho::Client::Customers

Inherits:
Koho::Client show all
Defined in:
lib/koho.rb

Constant Summary

Constants inherited from Koho::Client

API_BASE_URL

Instance Attribute Summary

Attributes inherited from Koho::Client

#company_id, #token

Instance Method Summary collapse

Methods inherited from Koho::Client

#contracts, #customers, #get, #info, #initialize, #invoices, #post, #put

Constructor Details

This class inherits a constructor from Koho::Client

Instance Method Details

#create(params) ⇒ Object



81
82
83
# File 'lib/koho.rb', line 81

def create params
  post '/', customer: params
end

#find(id) ⇒ Object



77
78
79
# File 'lib/koho.rb', line 77

def find id
  get "/#{id}"
end

#listObject



73
74
75
# File 'lib/koho.rb', line 73

def list
  get '/'
end

#update(id, params) ⇒ Object



85
86
87
# File 'lib/koho.rb', line 85

def update id, params
  put "/#{id}", customer: params
end