Class: BaseCRM::Client
- Inherits:
-
Object
- Object
- BaseCRM::Client
- Defined in:
- lib/basecrm.rb
Instance Attribute Summary collapse
-
#config ⇒ Object
readonly
Returns the value of attribute config.
-
#http_client ⇒ Object
readonly
Returns the value of attribute http_client.
Instance Method Summary collapse
-
#accounts ⇒ AccountsService
Access all Accounts related actions.
-
#associated_contacts ⇒ AssociatedContactsService
Access all AssociatedContacts related actions.
-
#call_outcomes ⇒ CallOutcomesService
Access all CallOutcomes related actions.
-
#calls ⇒ CallsService
Access all Calls related actions.
-
#contacts ⇒ ContactsService
Access all Contacts related actions.
-
#deal_sources ⇒ DealSourcesService
Access all DealSources related actions.
-
#deal_unqualified_reasons ⇒ DealUnqualifiedReasonsService
Access all DealUnqualifiedReasons related actions.
-
#deals ⇒ DealsService
Access all Deals related actions.
-
#initialize(options = {}) ⇒ Client
constructor
Instantiate a new BaseCRM API V2 client.
-
#lead_sources ⇒ LeadSourcesService
Access all LeadSources related actions.
-
#lead_unqualified_reasons ⇒ LeadUnqualifiedReasonsService
Access all LeadUnqualifiedReasons related actions.
-
#leads ⇒ LeadsService
Access all Leads related actions.
-
#line_items ⇒ LineItemsService
Access all LineItems related actions.
-
#loss_reasons ⇒ LossReasonsService
Access all LossReasons related actions.
-
#notes ⇒ NotesService
Access all Notes related actions.
-
#orders ⇒ OrdersService
Access all Orders related actions.
-
#pipelines ⇒ PipelinesService
Access all Pipelines related actions.
-
#products ⇒ ProductsService
Access all Products related actions.
-
#sources ⇒ SourcesService
Access all Sources related actions.
-
#stages ⇒ StagesService
Access all Stages related actions.
-
#sync ⇒ SyncService
Access Sync API related low-level actions.
-
#tags ⇒ TagsService
Access all Tags related actions.
-
#tasks ⇒ TasksService
Access all Tasks related actions.
-
#text_messages ⇒ TextMessagesService
Access all TextMessages related actions.
-
#users ⇒ UsersService
Access all Users related actions.
-
#visit_outcomes ⇒ VisitOutcomesService
Access all VisitOutcomes related actions.
-
#visits ⇒ VisitsService
Access all Visits related actions.
Constructor Details
#initialize(options = {}) ⇒ Client
Instantiate a new BaseCRM API V2 client
96 97 98 99 100 101 |
# File 'lib/basecrm.rb', line 96 def initialize(={}) @config = Configuration.new() @config.validate! @http_client = HttpClient.new(@config) end |
Instance Attribute Details
#config ⇒ Object (readonly)
Returns the value of attribute config.
77 78 79 |
# File 'lib/basecrm.rb', line 77 def config @config end |
#http_client ⇒ Object (readonly)
Returns the value of attribute http_client.
78 79 80 |
# File 'lib/basecrm.rb', line 78 def http_client @http_client end |
Instance Method Details
#accounts ⇒ AccountsService
Access all Accounts related actions.
108 109 110 |
# File 'lib/basecrm.rb', line 108 def accounts @accounts ||= AccountsService.new(@http_client) end |
#associated_contacts ⇒ AssociatedContactsService
Access all AssociatedContacts related actions.
117 118 119 |
# File 'lib/basecrm.rb', line 117 def associated_contacts @associated_contacts ||= AssociatedContactsService.new(@http_client) end |
#call_outcomes ⇒ CallOutcomesService
Access all CallOutcomes related actions.
135 136 137 |
# File 'lib/basecrm.rb', line 135 def call_outcomes @call_outcomes ||= CallOutcomesService.new(@http_client) end |
#calls ⇒ CallsService
Access all Calls related actions.
126 127 128 |
# File 'lib/basecrm.rb', line 126 def calls @calls ||= CallsService.new(@http_client) end |
#contacts ⇒ ContactsService
Access all Contacts related actions.
144 145 146 |
# File 'lib/basecrm.rb', line 144 def contacts @contacts ||= ContactsService.new(@http_client) end |
#deal_sources ⇒ DealSourcesService
Access all DealSources related actions.
162 163 164 |
# File 'lib/basecrm.rb', line 162 def deal_sources @deal_sources ||= DealSourcesService.new(@http_client) end |
#deal_unqualified_reasons ⇒ DealUnqualifiedReasonsService
Access all DealUnqualifiedReasons related actions.
171 172 173 |
# File 'lib/basecrm.rb', line 171 def deal_unqualified_reasons @deal_unqualified_reasons ||= DealUnqualifiedReasonsService.new(@http_client) end |
#deals ⇒ DealsService
Access all Deals related actions.
153 154 155 |
# File 'lib/basecrm.rb', line 153 def deals @deals ||= DealsService.new(@http_client) end |
#lead_sources ⇒ LeadSourcesService
Access all LeadSources related actions.
189 190 191 |
# File 'lib/basecrm.rb', line 189 def lead_sources @lead_sources ||= LeadSourcesService.new(@http_client) end |
#lead_unqualified_reasons ⇒ LeadUnqualifiedReasonsService
Access all LeadUnqualifiedReasons related actions.
198 199 200 |
# File 'lib/basecrm.rb', line 198 def lead_unqualified_reasons @lead_unqualified_reasons ||= LeadUnqualifiedReasonsService.new(@http_client) end |
#leads ⇒ LeadsService
Access all Leads related actions.
180 181 182 |
# File 'lib/basecrm.rb', line 180 def leads @leads ||= LeadsService.new(@http_client) end |
#line_items ⇒ LineItemsService
Access all LineItems related actions.
207 208 209 |
# File 'lib/basecrm.rb', line 207 def line_items @line_items ||= LineItemsService.new(@http_client) end |
#loss_reasons ⇒ LossReasonsService
Access all LossReasons related actions.
216 217 218 |
# File 'lib/basecrm.rb', line 216 def loss_reasons @loss_reasons ||= LossReasonsService.new(@http_client) end |
#notes ⇒ NotesService
Access all Notes related actions.
225 226 227 |
# File 'lib/basecrm.rb', line 225 def notes @notes ||= NotesService.new(@http_client) end |
#orders ⇒ OrdersService
Access all Orders related actions.
234 235 236 |
# File 'lib/basecrm.rb', line 234 def orders @orders ||= OrdersService.new(@http_client) end |
#pipelines ⇒ PipelinesService
Access all Pipelines related actions.
243 244 245 |
# File 'lib/basecrm.rb', line 243 def pipelines @pipelines ||= PipelinesService.new(@http_client) end |
#products ⇒ ProductsService
Access all Products related actions.
252 253 254 |
# File 'lib/basecrm.rb', line 252 def products @products ||= ProductsService.new(@http_client) end |
#sources ⇒ SourcesService
Access all Sources related actions.
261 262 263 |
# File 'lib/basecrm.rb', line 261 def sources @sources ||= SourcesService.new(@http_client) end |
#stages ⇒ StagesService
Access all Stages related actions.
270 271 272 |
# File 'lib/basecrm.rb', line 270 def stages @stages ||= StagesService.new(@http_client) end |
#sync ⇒ SyncService
Access Sync API related low-level actions.
332 333 334 |
# File 'lib/basecrm.rb', line 332 def sync @sync ||= SyncService.new(@http_client) end |
#tags ⇒ TagsService
Access all Tags related actions.
279 280 281 |
# File 'lib/basecrm.rb', line 279 def @tags ||= TagsService.new(@http_client) end |
#tasks ⇒ TasksService
Access all Tasks related actions.
288 289 290 |
# File 'lib/basecrm.rb', line 288 def tasks @tasks ||= TasksService.new(@http_client) end |
#text_messages ⇒ TextMessagesService
Access all TextMessages related actions.
297 298 299 |
# File 'lib/basecrm.rb', line 297 def @text_messages ||= TextMessagesService.new(@http_client) end |
#users ⇒ UsersService
Access all Users related actions.
306 307 308 |
# File 'lib/basecrm.rb', line 306 def users @users ||= UsersService.new(@http_client) end |
#visit_outcomes ⇒ VisitOutcomesService
Access all VisitOutcomes related actions.
324 325 326 |
# File 'lib/basecrm.rb', line 324 def visit_outcomes @visit_outcomes ||= VisitOutcomesService.new(@http_client) end |
#visits ⇒ VisitsService
Access all Visits related actions.
315 316 317 |
# File 'lib/basecrm.rb', line 315 def visits @visits ||= VisitsService.new(@http_client) end |