Class: Pipedrive::OrganizationsApi
- Inherits:
-
Object
- Object
- Pipedrive::OrganizationsApi
- Defined in:
- lib/pipedrive-openapi-client/api/organizations_api.rb
Instance Attribute Summary collapse
-
#api_client ⇒ Object
Returns the value of attribute api_client.
Instance Method Summary collapse
-
#initialize(api_client = ApiClient.default) ⇒ OrganizationsApi
constructor
A new instance of OrganizationsApi.
-
#organizations_delete(ids, opts = {}) ⇒ nil
Delete multiple organizations in bulk Marks multiple organizations as deleted.
-
#organizations_delete_with_http_info(ids, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete multiple organizations in bulk Marks multiple organizations as deleted.
-
#organizations_find_get(term, opts = {}) ⇒ nil
Find organizations by name <strong>This endpoint is deprecated.
-
#organizations_find_get_with_http_info(term, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Find organizations by name <strong>This endpoint is deprecated.
-
#organizations_get(opts = {}) ⇒ nil
Get all organizations Returns all organizations.
-
#organizations_get_with_http_info(opts = {}) ⇒ Array<(nil, Integer, Hash)>
Get all organizations Returns all organizations.
-
#organizations_id_activities_get(id, opts = {}) ⇒ nil
List activities associated with an organization Lists activities associated with an organization.
-
#organizations_id_activities_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List activities associated with an organization Lists activities associated with an organization.
-
#organizations_id_deals_get(id, opts = {}) ⇒ nil
List deals associated with an organization Lists deals associated with an organization.
-
#organizations_id_deals_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List deals associated with an organization Lists deals associated with an organization.
-
#organizations_id_delete(id, opts = {}) ⇒ nil
Delete an organization Marks an organization as deleted.
-
#organizations_id_delete_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete an organization Marks an organization as deleted.
-
#organizations_id_files_get(id, opts = {}) ⇒ nil
List files attached to an organization Lists files associated with an organization.
-
#organizations_id_files_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List files attached to an organization Lists files associated with an organization.
-
#organizations_id_flow_get(id, opts = {}) ⇒ nil
List updates about an organization Lists updates about an organization.
-
#organizations_id_flow_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List updates about an organization Lists updates about an organization.
-
#organizations_id_followers_follower_id_delete(id, follower_id, opts = {}) ⇒ nil
Delete a follower from an organization Deletes a follower from an organization.
-
#organizations_id_followers_follower_id_delete_with_http_info(id, follower_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a follower from an organization Deletes a follower from an organization.
-
#organizations_id_followers_get(id, opts = {}) ⇒ nil
List followers of an organization Lists the followers of an organization.
-
#organizations_id_followers_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List followers of an organization Lists the followers of an organization.
-
#organizations_id_followers_post(id, user_id, opts = {}) ⇒ nil
Add a follower to an organization Adds a follower to an organization.
-
#organizations_id_followers_post_with_http_info(id, user_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Add a follower to an organization Adds a follower to an organization.
-
#organizations_id_get(id, opts = {}) ⇒ nil
Get details of an organization Returns details of an organization.
-
#organizations_id_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Get details of an organization Returns details of an organization.
-
#organizations_id_mail_messages_get(id, opts = {}) ⇒ nil
List mail messages associated with an organization Lists mail messages associated with an organization.
-
#organizations_id_mail_messages_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List mail messages associated with an organization Lists mail messages associated with an organization.
-
#organizations_id_merge_put(id, merge_with_id, opts = {}) ⇒ nil
Merge two organizations Merges an organization with another organization.
-
#organizations_id_merge_put_with_http_info(id, merge_with_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Merge two organizations Merges an organization with another organization.
-
#organizations_id_permitted_users_get(id, opts = {}) ⇒ nil
List permitted users List users permitted to access an organization.
-
#organizations_id_permitted_users_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List permitted users List users permitted to access an organization.
-
#organizations_id_persons_get(id, opts = {}) ⇒ nil
List persons of an organization Lists persons associated with an organization.
-
#organizations_id_persons_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List persons of an organization Lists persons associated with an organization.
-
#organizations_id_put(id, opts = {}) ⇒ nil
Update an organization Updates the properties of an organization.
-
#organizations_id_put_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Update an organization Updates the properties of an organization.
-
#organizations_post(opts = {}) ⇒ nil
Add an organization Adds a new organization.
-
#organizations_post_with_http_info(opts = {}) ⇒ Array<(nil, Integer, Hash)>
Add an organization Adds a new organization.
-
#organizations_search_get(term, opts = {}) ⇒ BaseResponse
Search organizations Searches all Organizations by name, address, notes and/or custom fields.
-
#organizations_search_get_with_http_info(term, opts = {}) ⇒ Array<(BaseResponse, Integer, Hash)>
Search organizations Searches all Organizations by name, address, notes and/or custom fields.
Constructor Details
#initialize(api_client = ApiClient.default) ⇒ OrganizationsApi
Returns a new instance of OrganizationsApi.
19 20 21 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 19 def initialize(api_client = ApiClient.default) @api_client = api_client end |
Instance Attribute Details
#api_client ⇒ Object
Returns the value of attribute api_client.
17 18 19 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 17 def api_client @api_client end |
Instance Method Details
#organizations_delete(ids, opts = {}) ⇒ nil
Delete multiple organizations in bulk Marks multiple organizations as deleted.
27 28 29 30 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 27 def organizations_delete(ids, opts = {}) organizations_delete_with_http_info(ids, opts) nil end |
#organizations_delete_with_http_info(ids, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete multiple organizations in bulk Marks multiple organizations as deleted.
37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 37 def organizations_delete_with_http_info(ids, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_delete ...' end # verify the required parameter 'ids' is set if @api_client.config.client_side_validation && ids.nil? fail ArgumentError, "Missing the required parameter 'ids' when calling OrganizationsApi.organizations_delete" end # resource path local_var_path = '/organizations' # query parameters query_params = opts[:query_params] || {} query_params[:'ids'] = ids # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_find_get(term, opts = {}) ⇒ nil
Find organizations by name <strong>This endpoint is deprecated. Please use <a href="developers.pipedrive.com/docs/api/v1/#!/Organizations/get_organizations_search">/v1/organizations/search</a> or <<a href="developers.pipedrive.com/docs/api/v1/#!/ItemSearch/get_itemSearch">/v1/itemSearch</a> instead</strong>.
Searches all organizations by their name.
90 91 92 93 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 90 def organizations_find_get(term, opts = {}) organizations_find_get_with_http_info(term, opts) nil end |
#organizations_find_get_with_http_info(term, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Find organizations by name <strong>This endpoint is deprecated. Please use <a href="developers.pipedrive.com/docs/api/v1/#!/Organizations/get_organizations_search">/v1/organizations/search</a> or <<a href="developers.pipedrive.com/docs/api/v1/#!/ItemSearch/get_itemSearch">/v1/itemSearch</a> instead</strong>. <br> Searches all organizations by their name.
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 102 def organizations_find_get_with_http_info(term, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_find_get ...' end # verify the required parameter 'term' is set if @api_client.config.client_side_validation && term.nil? fail ArgumentError, "Missing the required parameter 'term' when calling OrganizationsApi.organizations_find_get" end # resource path local_var_path = '/organizations/find' # query parameters query_params = opts[:query_params] || {} query_params[:'term'] = term query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_find_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_get(opts = {}) ⇒ nil
Get all organizations Returns all organizations
160 161 162 163 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 160 def organizations_get(opts = {}) organizations_get_with_http_info(opts) nil end |
#organizations_get_with_http_info(opts = {}) ⇒ Array<(nil, Integer, Hash)>
Get all organizations Returns all organizations
175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 175 def organizations_get_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_get ...' end # resource path local_var_path = '/organizations' # query parameters query_params = opts[:query_params] || {} query_params[:'user_id'] = opts[:'user_id'] if !opts[:'user_id'].nil? query_params[:'filter_id'] = opts[:'filter_id'] if !opts[:'filter_id'].nil? query_params[:'first_char'] = opts[:'first_char'] if !opts[:'first_char'].nil? query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil? # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_activities_get(id, opts = {}) ⇒ nil
List activities associated with an organization Lists activities associated with an organization.
231 232 233 234 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 231 def organizations_id_activities_get(id, opts = {}) organizations_id_activities_get_with_http_info(id, opts) nil end |
#organizations_id_activities_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List activities associated with an organization Lists activities associated with an organization.
245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 245 def organizations_id_activities_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_activities_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_activities_get" end # resource path local_var_path = '/organizations/{id}/activities'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'done'] = opts[:'done'] if !opts[:'done'].nil? query_params[:'exclude'] = opts[:'exclude'] if !opts[:'exclude'].nil? # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_activities_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_deals_get(id, opts = {}) ⇒ nil
List deals associated with an organization Lists deals associated with an organization.
304 305 306 307 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 304 def organizations_id_deals_get(id, opts = {}) organizations_id_deals_get_with_http_info(id, opts) nil end |
#organizations_id_deals_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List deals associated with an organization Lists deals associated with an organization.
319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 319 def organizations_id_deals_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_deals_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_deals_get" end allowable_values = ["open", "won", "lost", "deleted", "all_not_deleted"] if @api_client.config.client_side_validation && opts[:'status'] && !allowable_values.include?(opts[:'status']) fail ArgumentError, "invalid value for \"status\", must be one of #{allowable_values}" end # resource path local_var_path = '/organizations/{id}/deals'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'status'] = opts[:'status'] if !opts[:'status'].nil? query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil? query_params[:'only_primary_association'] = opts[:'only_primary_association'] if !opts[:'only_primary_association'].nil? # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_deals_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_delete(id, opts = {}) ⇒ nil
Delete an organization Marks an organization as deleted.
378 379 380 381 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 378 def organizations_id_delete(id, opts = {}) organizations_id_delete_with_http_info(id, opts) nil end |
#organizations_id_delete_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete an organization Marks an organization as deleted.
388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 388 def organizations_id_delete_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_delete ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_delete" end # resource path local_var_path = '/organizations/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_files_get(id, opts = {}) ⇒ nil
List files attached to an organization Lists files associated with an organization.
442 443 444 445 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 442 def organizations_id_files_get(id, opts = {}) organizations_id_files_get_with_http_info(id, opts) nil end |
#organizations_id_files_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List files attached to an organization Lists files associated with an organization.
456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 456 def organizations_id_files_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_files_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_files_get" end # resource path local_var_path = '/organizations/{id}/files'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'include_deleted_files'] = opts[:'include_deleted_files'] if !opts[:'include_deleted_files'].nil? query_params[:'sort'] = opts[:'sort'] if !opts[:'sort'].nil? # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_files_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_flow_get(id, opts = {}) ⇒ nil
List updates about an organization Lists updates about an organization.
514 515 516 517 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 514 def organizations_id_flow_get(id, opts = {}) organizations_id_flow_get_with_http_info(id, opts) nil end |
#organizations_id_flow_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List updates about an organization Lists updates about an organization.
528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 528 def organizations_id_flow_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_flow_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_flow_get" end # resource path local_var_path = '/organizations/{id}/flow'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? query_params[:'all_changes'] = opts[:'all_changes'] if !opts[:'all_changes'].nil? query_params[:'items'] = opts[:'items'] if !opts[:'items'].nil? # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_flow_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_followers_follower_id_delete(id, follower_id, opts = {}) ⇒ nil
Delete a follower from an organization Deletes a follower from an organization. You can retrieve the follower_id from the <a href="developers.pipedrive.com/docs/api/v1/#!/Organizations/get_organizations_id_followers">List followers of an organization</a> endpoint.
583 584 585 586 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 583 def organizations_id_followers_follower_id_delete(id, follower_id, opts = {}) organizations_id_followers_follower_id_delete_with_http_info(id, follower_id, opts) nil end |
#organizations_id_followers_follower_id_delete_with_http_info(id, follower_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Delete a follower from an organization Deletes a follower from an organization. You can retrieve the follower_id from the <a href="developers.pipedrive.com/docs/api/v1/#!/Organizations/get_organizations_id_followers">List followers of an organization</a> endpoint.
594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 594 def organizations_id_followers_follower_id_delete_with_http_info(id, follower_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_followers_follower_id_delete ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_followers_follower_id_delete" end # verify the required parameter 'follower_id' is set if @api_client.config.client_side_validation && follower_id.nil? fail ArgumentError, "Missing the required parameter 'follower_id' when calling OrganizationsApi.organizations_id_followers_follower_id_delete" end # resource path local_var_path = '/organizations/{id}/followers/{follower_id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s)).sub('{' + 'follower_id' + '}', CGI.escape(follower_id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_followers_follower_id_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_followers_get(id, opts = {}) ⇒ nil
List followers of an organization Lists the followers of an organization.
648 649 650 651 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 648 def organizations_id_followers_get(id, opts = {}) organizations_id_followers_get_with_http_info(id, opts) nil end |
#organizations_id_followers_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List followers of an organization Lists the followers of an organization.
658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 658 def organizations_id_followers_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_followers_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_followers_get" end # resource path local_var_path = '/organizations/{id}/followers'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_followers_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_followers_post(id, user_id, opts = {}) ⇒ nil
Add a follower to an organization Adds a follower to an organization.
709 710 711 712 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 709 def organizations_id_followers_post(id, user_id, opts = {}) organizations_id_followers_post_with_http_info(id, user_id, opts) nil end |
#organizations_id_followers_post_with_http_info(id, user_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Add a follower to an organization Adds a follower to an organization.
720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 720 def organizations_id_followers_post_with_http_info(id, user_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_followers_post ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_followers_post" end # verify the required parameter 'user_id' is set if @api_client.config.client_side_validation && user_id.nil? fail ArgumentError, "Missing the required parameter 'user_id' when calling OrganizationsApi.organizations_id_followers_post" end # resource path local_var_path = '/organizations/{id}/followers'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/x-www-form-urlencoded']) # form parameters form_params = opts[:form_params] || {} form_params['user_id'] = user_id # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_followers_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_get(id, opts = {}) ⇒ nil
Get details of an organization Returns details of an organization. Note that this also returns some additional fields which are not present when asking for all organizations. Also note that custom fields appear as long hashes in the resulting data. These hashes can be mapped against the ‘key’ value of organizationFields.
777 778 779 780 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 777 def organizations_id_get(id, opts = {}) organizations_id_get_with_http_info(id, opts) nil end |
#organizations_id_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Get details of an organization Returns details of an organization. Note that this also returns some additional fields which are not present when asking for all organizations. Also note that custom fields appear as long hashes in the resulting data. These hashes can be mapped against the 'key' value of organizationFields.
787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 787 def organizations_id_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_get" end # resource path local_var_path = '/organizations/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_mail_messages_get(id, opts = {}) ⇒ nil
List mail messages associated with an organization Lists mail messages associated with an organization.
839 840 841 842 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 839 def (id, opts = {}) (id, opts) nil end |
#organizations_id_mail_messages_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List mail messages associated with an organization Lists mail messages associated with an organization.
851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 851 def (id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_mail_messages_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_mail_messages_get" end # resource path local_var_path = '/organizations/{id}/mailMessages'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_mail_messages_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_merge_put(id, merge_with_id, opts = {}) ⇒ nil
Merge two organizations Merges an organization with another organization. For more information on how to merge two organizations, see <a href="pipedrive.readme.io/docs/merging-two-organizations" target="_blank" rel="noopener noreferrer">this tutorial</a>.
904 905 906 907 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 904 def organizations_id_merge_put(id, merge_with_id, opts = {}) organizations_id_merge_put_with_http_info(id, merge_with_id, opts) nil end |
#organizations_id_merge_put_with_http_info(id, merge_with_id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Merge two organizations Merges an organization with another organization. For more information on how to merge two organizations, see <a href="pipedrive.readme.io/docs/merging-two-organizations" target="_blank" rel="noopener noreferrer">this tutorial</a>.
915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 915 def organizations_id_merge_put_with_http_info(id, merge_with_id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_merge_put ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_merge_put" end # verify the required parameter 'merge_with_id' is set if @api_client.config.client_side_validation && merge_with_id.nil? fail ArgumentError, "Missing the required parameter 'merge_with_id' when calling OrganizationsApi.organizations_id_merge_put" end # resource path local_var_path = '/organizations/{id}/merge'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/x-www-form-urlencoded']) # form parameters form_params = opts[:form_params] || {} form_params['merge_with_id'] = merge_with_id # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:PUT, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_merge_put\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_permitted_users_get(id, opts = {}) ⇒ nil
List permitted users List users permitted to access an organization
972 973 974 975 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 972 def organizations_id_permitted_users_get(id, opts = {}) organizations_id_permitted_users_get_with_http_info(id, opts) nil end |
#organizations_id_permitted_users_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List permitted users List users permitted to access an organization
982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 982 def organizations_id_permitted_users_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_permitted_users_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_permitted_users_get" end # resource path local_var_path = '/organizations/{id}/permittedUsers'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_permitted_users_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_persons_get(id, opts = {}) ⇒ nil
List persons of an organization Lists persons associated with an organization.
1034 1035 1036 1037 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 1034 def organizations_id_persons_get(id, opts = {}) organizations_id_persons_get_with_http_info(id, opts) nil end |
#organizations_id_persons_get_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
List persons of an organization Lists persons associated with an organization.
1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 1046 def organizations_id_persons_get_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_persons_get ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_persons_get" end # resource path local_var_path = '/organizations/{id}/persons'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? # header parameters header_params = opts[:header_params] || {} # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_persons_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_id_put(id, opts = {}) ⇒ nil
Update an organization Updates the properties of an organization.
1101 1102 1103 1104 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 1101 def organizations_id_put(id, opts = {}) organizations_id_put_with_http_info(id, opts) nil end |
#organizations_id_put_with_http_info(id, opts = {}) ⇒ Array<(nil, Integer, Hash)>
Update an organization Updates the properties of an organization.
1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 1114 def organizations_id_put_with_http_info(id, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_id_put ...' end # verify the required parameter 'id' is set if @api_client.config.client_side_validation && id.nil? fail ArgumentError, "Missing the required parameter 'id' when calling OrganizationsApi.organizations_id_put" end # resource path local_var_path = '/organizations/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s)) # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/x-www-form-urlencoded']) # form parameters form_params = opts[:form_params] || {} form_params['name'] = opts[:'name'] if !opts[:'name'].nil? form_params['owner_id'] = opts[:'owner_id'] if !opts[:'owner_id'].nil? form_params['visible_to'] = opts[:'visible_to'] if !opts[:'visible_to'].nil? # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:PUT, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_id_put\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_post(opts = {}) ⇒ nil
Add an organization Adds a new organization. Note that you can supply additional custom fields along with the request that are not described here. These custom fields are different for each Pipedrive account and can be recognized by long hashes as keys. To determine which custom fields exists, fetch the organizationFields and look for ‘key’ values. For more information on how to add an organization, see <a href="pipedrive.readme.io/docs/adding-an-organization" target="_blank" rel="noopener noreferrer">this tutorial</a>.
1168 1169 1170 1171 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 1168 def organizations_post(opts = {}) organizations_post_with_http_info(opts) nil end |
#organizations_post_with_http_info(opts = {}) ⇒ Array<(nil, Integer, Hash)>
Add an organization Adds a new organization. Note that you can supply additional custom fields along with the request that are not described here. These custom fields are different for each Pipedrive account and can be recognized by long hashes as keys. To determine which custom fields exists, fetch the organizationFields and look for 'key' values. For more information on how to add an organization, see <a href="pipedrive.readme.io/docs/adding-an-organization" target="_blank" rel="noopener noreferrer">this tutorial</a>.
1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 1177 def organizations_post_with_http_info(opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_post ...' end # resource path local_var_path = '/organizations' # query parameters query_params = opts[:query_params] || {} # header parameters header_params = opts[:header_params] || {} # HTTP header 'Content-Type' header_params['Content-Type'] = @api_client.select_header_content_type(['application/x-www-form-urlencoded']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:POST, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_post\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |
#organizations_search_get(term, opts = {}) ⇒ BaseResponse
Search organizations Searches all Organizations by name, address, notes and/or custom fields. This endpoint is a wrapper of <a href="developers.pipedrive.com/docs/api/v1/#!/ItemSearch/get_itemSearch">/v1/itemSearch</a> with a narrower OAuth scope.
1229 1230 1231 1232 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 1229 def organizations_search_get(term, opts = {}) data, _status_code, _headers = organizations_search_get_with_http_info(term, opts) data end |
#organizations_search_get_with_http_info(term, opts = {}) ⇒ Array<(BaseResponse, Integer, Hash)>
Search organizations Searches all Organizations by name, address, notes and/or custom fields. This endpoint is a wrapper of <a href="developers.pipedrive.com/docs/api/v1/#!/ItemSearch/get_itemSearch">/v1/itemSearch</a> with a narrower OAuth scope.
1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 |
# File 'lib/pipedrive-openapi-client/api/organizations_api.rb', line 1243 def organizations_search_get_with_http_info(term, opts = {}) if @api_client.config.debugging @api_client.config.logger.debug 'Calling API: OrganizationsApi.organizations_search_get ...' end # verify the required parameter 'term' is set if @api_client.config.client_side_validation && term.nil? fail ArgumentError, "Missing the required parameter 'term' when calling OrganizationsApi.organizations_search_get" end allowable_values = ["address", "custom_fields", "notes", "name"] if @api_client.config.client_side_validation && opts[:'fields'] && !allowable_values.include?(opts[:'fields']) fail ArgumentError, "invalid value for \"fields\", must be one of #{allowable_values}" end allowable_values = ["true", "false"] if @api_client.config.client_side_validation && opts[:'exact_match'] && !allowable_values.include?(opts[:'exact_match']) fail ArgumentError, "invalid value for \"exact_match\", must be one of #{allowable_values}" end # resource path local_var_path = '/organizations/search' # query parameters query_params = opts[:query_params] || {} query_params[:'term'] = term query_params[:'fields'] = opts[:'fields'] if !opts[:'fields'].nil? query_params[:'exact_match'] = opts[:'exact_match'] if !opts[:'exact_match'].nil? query_params[:'start'] = opts[:'start'] if !opts[:'start'].nil? query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil? # header parameters header_params = opts[:header_params] || {} # HTTP header 'Accept' (if needed) header_params['Accept'] = @api_client.select_header_accept(['application/json']) # form parameters form_params = opts[:form_params] || {} # http body (model) post_body = opts[:body] # return_type return_type = opts[:return_type] || 'BaseResponse' # auth_names auth_names = opts[:auth_names] || ['api_key', 'oauth2'] = opts.merge( :header_params => header_params, :query_params => query_params, :form_params => form_params, :body => post_body, :auth_names => auth_names, :return_type => return_type ) data, status_code, headers = @api_client.call_api(:GET, local_var_path, ) if @api_client.config.debugging @api_client.config.logger.debug "API called: OrganizationsApi#organizations_search_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" end return data, status_code, headers end |