hubspot-api-client 20.0.0.pre.beta.1 → 20.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (192) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +42 -1
  3. data/Gemfile.lock +2 -2
  4. data/hubspot-api-client.gemspec +1 -1
  5. data/lib/hubspot/codegen/crm/companies/api/basic_api.rb +91 -22
  6. data/lib/hubspot/codegen/crm/companies/api/batch_api.rb +25 -17
  7. data/lib/hubspot/codegen/crm/companies/api/search_api.rb +4 -0
  8. data/lib/hubspot/codegen/crm/companies/models/association_spec.rb +12 -0
  9. data/lib/hubspot/codegen/crm/companies/models/{batch_input_simple_public_object_input_for_create.rb → batch_input_simple_public_object_batch_input_for_create.rb} +4 -4
  10. data/lib/hubspot/codegen/crm/companies/models/batch_read_input_simple_public_object_id.rb +1 -0
  11. data/lib/hubspot/codegen/crm/companies/models/public_associations_for_object.rb +10 -0
  12. data/lib/hubspot/codegen/crm/companies/models/public_merge_input.rb +2 -0
  13. data/lib/hubspot/codegen/crm/companies/models/public_object_id.rb +6 -0
  14. data/lib/hubspot/codegen/crm/companies/models/simple_public_object.rb +10 -1
  15. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_batch_input.rb +4 -0
  16. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_batch_input_for_create.rb +250 -0
  17. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_batch_input_upsert.rb +4 -0
  18. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_input.rb +2 -10
  19. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_input_for_create.rb +2 -10
  20. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_with_associations.rb +10 -1
  21. data/lib/hubspot/codegen/crm/companies/models/simple_public_upsert_object.rb +10 -1
  22. data/lib/hubspot/codegen/crm/contacts/api/basic_api.rb +163 -26
  23. data/lib/hubspot/codegen/crm/contacts/api/batch_api.rb +27 -19
  24. data/lib/hubspot/codegen/crm/contacts/api/search_api.rb +4 -0
  25. data/lib/hubspot/codegen/crm/contacts/models/association_spec.rb +10 -0
  26. data/lib/hubspot/codegen/crm/contacts/models/{batch_input_simple_public_object_input_for_create.rb → batch_input_simple_public_object_batch_input_for_create.rb} +4 -4
  27. data/lib/hubspot/codegen/crm/contacts/models/batch_read_input_simple_public_object_id.rb +1 -0
  28. data/lib/hubspot/codegen/crm/contacts/models/public_associations_for_object.rb +10 -0
  29. data/lib/hubspot/codegen/crm/contacts/models/public_gdpr_delete_input.rb +2 -0
  30. data/lib/hubspot/codegen/crm/contacts/models/public_object_id.rb +5 -0
  31. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object.rb +10 -1
  32. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_batch_input.rb +2 -0
  33. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_batch_input_for_create.rb +250 -0
  34. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_batch_input_upsert.rb +1 -0
  35. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_input.rb +1 -10
  36. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_input_for_create.rb +1 -10
  37. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_with_associations.rb +13 -1
  38. data/lib/hubspot/codegen/crm/contacts/models/simple_public_upsert_object.rb +10 -1
  39. data/lib/hubspot/codegen/crm/deals/api/basic_api.rb +67 -0
  40. data/lib/hubspot/codegen/crm/deals/api/batch_api.rb +11 -9
  41. data/lib/hubspot/codegen/crm/deals/models/association_spec.rb +10 -0
  42. data/lib/hubspot/codegen/crm/deals/models/{batch_input_simple_public_object_input_for_create.rb → batch_input_simple_public_object_batch_input_for_create.rb} +4 -4
  43. data/lib/hubspot/codegen/crm/deals/models/batch_read_input_simple_public_object_id.rb +1 -0
  44. data/lib/hubspot/codegen/crm/deals/models/public_associations_for_object.rb +10 -0
  45. data/lib/hubspot/codegen/crm/deals/models/public_object_id.rb +5 -0
  46. data/lib/hubspot/codegen/crm/deals/models/simple_public_object.rb +10 -1
  47. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_batch_input.rb +2 -0
  48. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_batch_input_for_create.rb +250 -0
  49. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_batch_input_upsert.rb +1 -0
  50. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_input.rb +1 -10
  51. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_input_for_create.rb +1 -10
  52. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_with_associations.rb +10 -1
  53. data/lib/hubspot/codegen/crm/deals/models/simple_public_upsert_object.rb +10 -1
  54. data/lib/hubspot/codegen/crm/objects/feedback_submissions/api/basic_api.rb +3 -2
  55. data/lib/hubspot/codegen/crm/objects/feedback_submissions/api/batch_api.rb +2 -0
  56. data/lib/hubspot/codegen/crm/objects/feedback_submissions/models/batch_read_input_simple_public_object_id.rb +1 -0
  57. data/lib/hubspot/codegen/crm/objects/feedback_submissions/models/simple_public_object.rb +10 -1
  58. data/lib/hubspot/codegen/crm/objects/feedback_submissions/models/simple_public_object_with_associations.rb +10 -1
  59. data/lib/hubspot/codegen/crm/objects/goals/api/basic_api.rb +1 -0
  60. data/lib/hubspot/codegen/crm/objects/goals/api/batch_api.rb +11 -9
  61. data/lib/hubspot/codegen/crm/objects/goals/models/{batch_input_simple_public_object_input_for_create.rb → batch_input_simple_public_object_batch_input_for_create.rb} +4 -4
  62. data/lib/hubspot/codegen/crm/objects/goals/models/batch_read_input_simple_public_object_id.rb +1 -0
  63. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object.rb +10 -1
  64. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_batch_input.rb +2 -0
  65. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_batch_input_for_create.rb +252 -0
  66. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_batch_input_upsert.rb +1 -0
  67. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_input.rb +1 -10
  68. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_input_for_create.rb +1 -15
  69. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_with_associations.rb +10 -1
  70. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_upsert_object.rb +10 -1
  71. data/lib/hubspot/codegen/crm/products/api/basic_api.rb +5 -4
  72. data/lib/hubspot/codegen/crm/products/api/batch_api.rb +11 -9
  73. data/lib/hubspot/codegen/crm/products/models/{batch_input_simple_public_object_input_for_create.rb → batch_input_simple_public_object_batch_input_for_create.rb} +4 -4
  74. data/lib/hubspot/codegen/crm/products/models/batch_read_input_simple_public_object_id.rb +1 -1
  75. data/lib/hubspot/codegen/crm/products/models/simple_public_object.rb +10 -1
  76. data/lib/hubspot/codegen/crm/products/models/simple_public_object_batch_input_for_create.rb +250 -0
  77. data/lib/hubspot/codegen/crm/products/models/simple_public_object_input.rb +1 -10
  78. data/lib/hubspot/codegen/crm/products/models/simple_public_object_input_for_create.rb +6 -10
  79. data/lib/hubspot/codegen/crm/products/models/simple_public_object_with_associations.rb +10 -1
  80. data/lib/hubspot/codegen/crm/products/models/simple_public_upsert_object.rb +10 -1
  81. data/lib/hubspot/codegen/crm/tickets/api/basic_api.rb +73 -4
  82. data/lib/hubspot/codegen/crm/tickets/api/batch_api.rb +17 -9
  83. data/lib/hubspot/codegen/crm/tickets/api/search_api.rb +4 -0
  84. data/lib/hubspot/codegen/crm/tickets/models/association_spec.rb +10 -0
  85. data/lib/hubspot/codegen/crm/tickets/models/{batch_input_simple_public_object_input_for_create.rb → batch_input_simple_public_object_batch_input_for_create.rb} +4 -4
  86. data/lib/hubspot/codegen/crm/tickets/models/batch_read_input_simple_public_object_id.rb +1 -0
  87. data/lib/hubspot/codegen/crm/tickets/models/public_associations_for_object.rb +10 -0
  88. data/lib/hubspot/codegen/crm/tickets/models/public_object_id.rb +5 -0
  89. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object.rb +10 -1
  90. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_batch_input.rb +2 -0
  91. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_batch_input_for_create.rb +250 -0
  92. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_batch_input_upsert.rb +1 -0
  93. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_input.rb +1 -10
  94. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_input_for_create.rb +1 -10
  95. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_with_associations.rb +10 -1
  96. data/lib/hubspot/codegen/crm/tickets/models/simple_public_upsert_object.rb +10 -1
  97. data/lib/hubspot/codegen/files/api/files_api.rb +144 -104
  98. data/lib/hubspot/codegen/files/api/folders_api.rb +142 -57
  99. data/lib/hubspot/codegen/files/api_client.rb +1 -1
  100. data/lib/hubspot/codegen/files/api_error.rb +1 -1
  101. data/lib/hubspot/codegen/files/configuration.rb +1 -1
  102. data/lib/hubspot/codegen/files/models/collection_response_file.rb +2 -1
  103. data/lib/hubspot/codegen/files/models/collection_response_folder.rb +1 -1
  104. data/lib/hubspot/codegen/files/models/error.rb +1 -1
  105. data/lib/hubspot/codegen/files/models/error_detail.rb +1 -1
  106. data/lib/hubspot/codegen/files/models/file.rb +33 -14
  107. data/lib/hubspot/codegen/files/models/file_action_response.rb +1 -1
  108. data/lib/hubspot/codegen/files/models/file_stat.rb +1 -1
  109. data/lib/hubspot/codegen/files/models/file_update_input.rb +15 -5
  110. data/lib/hubspot/codegen/files/models/folder.rb +12 -12
  111. data/lib/hubspot/codegen/files/models/folder_action_response.rb +1 -1
  112. data/lib/hubspot/codegen/files/models/folder_input.rb +2 -1
  113. data/lib/hubspot/codegen/files/models/folder_update_input.rb +6 -20
  114. data/lib/hubspot/codegen/files/models/folder_update_input_with_id.rb +244 -0
  115. data/lib/hubspot/codegen/files/models/folder_update_task_locator.rb +2 -1
  116. data/lib/hubspot/codegen/files/models/import_from_url_input.rb +13 -4
  117. data/lib/hubspot/codegen/files/models/import_from_url_task_locator.rb +2 -1
  118. data/lib/hubspot/codegen/files/models/next_page.rb +1 -1
  119. data/lib/hubspot/codegen/files/models/paging.rb +1 -1
  120. data/lib/hubspot/codegen/files/models/previous_page.rb +1 -1
  121. data/lib/hubspot/codegen/files/models/signed_url.rb +18 -17
  122. data/lib/hubspot/codegen/files/models/standard_error.rb +1 -1
  123. data/lib/hubspot/codegen/oauth/api/access_tokens_api.rb +7 -3
  124. data/lib/hubspot/codegen/oauth/api/refresh_tokens_api.rb +13 -5
  125. data/lib/hubspot/codegen/oauth/api/tokens_api.rb +5 -1
  126. data/lib/hubspot/codegen/oauth/api_client.rb +2 -2
  127. data/lib/hubspot/codegen/oauth/api_error.rb +1 -1
  128. data/lib/hubspot/codegen/oauth/configuration.rb +1 -1
  129. data/lib/hubspot/codegen/oauth/models/access_token_info_response.rb +4 -4
  130. data/lib/hubspot/codegen/oauth/models/error.rb +4 -4
  131. data/lib/hubspot/codegen/oauth/models/error_detail.rb +4 -4
  132. data/lib/hubspot/codegen/oauth/models/refresh_token_info_response.rb +4 -4
  133. data/lib/hubspot/codegen/oauth/models/token_response_if.rb +4 -4
  134. data/lib/hubspot/codegen/oauth/v3/api/advanced_api.rb +273 -0
  135. data/lib/hubspot/codegen/{cms/performance → oauth/v3}/api_client.rb +5 -5
  136. data/lib/hubspot/codegen/{cms/performance → oauth/v3}/api_error.rb +4 -4
  137. data/lib/hubspot/codegen/{cms/performance → oauth/v3}/configuration.rb +11 -4
  138. data/lib/hubspot/codegen/{cms/performance/models/public_performance_response.rb → oauth/v3/models/access_token_response.rb} +97 -84
  139. data/lib/hubspot/codegen/oauth/v3/models/client_credentials_token_response.rb +344 -0
  140. data/lib/hubspot/codegen/{cms/performance → oauth/v3}/models/error.rb +40 -39
  141. data/lib/hubspot/codegen/{cms/performance → oauth/v3}/models/error_detail.rb +32 -31
  142. data/lib/hubspot/codegen/oauth/v3/models/public_access_token_info_response.rb +438 -0
  143. data/lib/hubspot/codegen/oauth/v3/models/public_refresh_token_info_response.rb +396 -0
  144. data/lib/hubspot/codegen/oauth/v3/models/signed_access_token.rb +452 -0
  145. data/lib/hubspot/codegen/oauth/v3/models/token_info_response_base_if.rb +59 -0
  146. data/lib/hubspot/codegen/oauth/v3/models/token_response_if.rb +59 -0
  147. data/lib/hubspot/discovery/base_api_client.rb +1 -1
  148. data/lib/hubspot/discovery/cms/client.rb +0 -1
  149. data/lib/hubspot/discovery/crm/companies/client.rb +0 -1
  150. data/lib/hubspot/discovery/crm/contacts/client.rb +0 -2
  151. data/lib/hubspot/discovery/crm/deals/client.rb +0 -1
  152. data/lib/hubspot/discovery/crm/tickets/client.rb +0 -1
  153. data/lib/hubspot/discovery/oauth/api/access_tokens_api.rb +1 -1
  154. data/lib/hubspot/discovery/oauth/api/refresh_tokens_api.rb +1 -1
  155. data/lib/hubspot/discovery/oauth/api/tokens_api.rb +1 -1
  156. data/lib/hubspot/discovery/oauth/client.rb +7 -1
  157. data/lib/hubspot/discovery/{crm/deals/api/merge_api.rb → oauth/v3/api/advanced_api.rb} +3 -3
  158. data/lib/hubspot/discovery/{cms/performance → oauth/v3}/client.rb +4 -4
  159. data/lib/hubspot/helpers/association_type.rb +233 -2
  160. data/lib/hubspot/helpers/camel_case.rb +0 -4
  161. data/lib/hubspot/version.rb +1 -1
  162. data/spec/discovery/cms/client_spec.rb +0 -1
  163. data/spec/discovery/crm/companies/basic_api_spec.rb +1 -0
  164. data/spec/discovery/crm/contacts/basic_api_spec.rb +1 -0
  165. data/spec/discovery/crm/deals/basic_api_spec.rb +1 -0
  166. data/spec/discovery/crm/tickets/basic_api_spec.rb +1 -0
  167. data/spec/discovery/files/files_api_spec.rb +2 -1
  168. data/spec/discovery/files/folders_api_spec.rb +1 -0
  169. data/spec/discovery/oauth/access_tokens_api_spec.rb +1 -1
  170. data/spec/discovery/oauth/refresh_tokens_api_spec.rb +1 -1
  171. data/spec/discovery/oauth/tokens_api_spec.rb +1 -1
  172. data/spec/discovery/oauth/v3/advanced_api_spec.rb +36 -0
  173. data/spec/discovery/oauth/v3/client_spec.rb +7 -0
  174. metadata +160 -169
  175. data/lib/hubspot/codegen/cms/performance/api/public_performance_api.rb +0 -188
  176. data/lib/hubspot/codegen/cms/performance/models/performance_view.rb +0 -526
  177. data/lib/hubspot/codegen/crm/companies/api/merge_api.rb +0 -92
  178. data/lib/hubspot/codegen/crm/contacts/api/gdpr_api.rb +0 -94
  179. data/lib/hubspot/codegen/crm/contacts/api/merge_api.rb +0 -92
  180. data/lib/hubspot/codegen/crm/deals/api/merge_api.rb +0 -92
  181. data/lib/hubspot/codegen/crm/tickets/api/merge_api.rb +0 -92
  182. data/lib/hubspot/discovery/cms/performance/api/public_performance_api.rb +0 -13
  183. data/lib/hubspot/discovery/crm/companies/api/merge_api.rb +0 -13
  184. data/lib/hubspot/discovery/crm/contacts/api/gdpr_api.rb +0 -13
  185. data/lib/hubspot/discovery/crm/contacts/api/merge_api.rb +0 -13
  186. data/lib/hubspot/discovery/crm/tickets/api/merge_api.rb +0 -13
  187. data/spec/discovery/cms/performance/public_performance_api_spec.rb +0 -8
  188. data/spec/discovery/crm/companies/merge_api_spec.rb +0 -7
  189. data/spec/discovery/crm/contacts/gdpr_api_spec.rb +0 -7
  190. data/spec/discovery/crm/contacts/merge_api_spec.rb +0 -7
  191. data/spec/discovery/crm/deals/merge_api_spec.rb +0 -7
  192. data/spec/discovery/crm/tickets/merge_api_spec.rb +0 -7
@@ -1,94 +0,0 @@
1
- =begin
2
- #Contacts
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: v3
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.2.1
10
-
11
- =end
12
-
13
- require 'cgi'
14
-
15
- module Hubspot
16
- module Crm
17
- module Contacts
18
- class GDPRApi
19
- attr_accessor :api_client
20
-
21
- def initialize(api_client = ApiClient.default)
22
- @api_client = api_client
23
- end
24
- # GDPR DELETE
25
- # Permanently delete a contact and all associated content to follow GDPR. Use optional property 'idProperty' set to 'email' to identify contact by email address. If email address is not found, the email address will be added to a blocklist and prevent it from being used in the future.
26
- # @param public_gdpr_delete_input [PublicGdprDeleteInput]
27
- # @param [Hash] opts the optional parameters
28
- # @return [nil]
29
- def purge(public_gdpr_delete_input, opts = {})
30
- purge_with_http_info(public_gdpr_delete_input, opts)
31
- nil
32
- end
33
-
34
- # GDPR DELETE
35
- # Permanently delete a contact and all associated content to follow GDPR. Use optional property 'idProperty' set to 'email' to identify contact by email address. If email address is not found, the email address will be added to a blocklist and prevent it from being used in the future.
36
- # @param public_gdpr_delete_input [PublicGdprDeleteInput]
37
- # @param [Hash] opts the optional parameters
38
- # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
39
- def purge_with_http_info(public_gdpr_delete_input, opts = {})
40
- if @api_client.config.debugging
41
- @api_client.config.logger.debug 'Calling API: GDPRApi.purge ...'
42
- end
43
- # verify the required parameter 'public_gdpr_delete_input' is set
44
- if @api_client.config.client_side_validation && public_gdpr_delete_input.nil?
45
- fail ArgumentError, "Missing the required parameter 'public_gdpr_delete_input' when calling GDPRApi.purge"
46
- end
47
- # resource path
48
- local_var_path = '/crm/v3/objects/contacts/gdpr-delete'
49
-
50
- # query parameters
51
- query_params = opts[:query_params] || {}
52
-
53
- # header parameters
54
- header_params = opts[:header_params] || {}
55
- # HTTP header 'Accept' (if needed)
56
- header_params['Accept'] = @api_client.select_header_accept(['*/*'])
57
- # HTTP header 'Content-Type'
58
- content_type = @api_client.select_header_content_type(['application/json'])
59
- if !content_type.nil?
60
- header_params['Content-Type'] = content_type
61
- end
62
-
63
- # form parameters
64
- form_params = opts[:form_params] || {}
65
-
66
- # http body (model)
67
- post_body = opts[:debug_body] || @api_client.object_to_http_body(public_gdpr_delete_input)
68
-
69
- # return_type
70
- return_type = opts[:debug_return_type]
71
-
72
- # auth_names
73
- auth_names = opts[:debug_auth_names] || ['oauth2']
74
-
75
- new_options = opts.merge(
76
- :operation => :"GDPRApi.purge",
77
- :header_params => header_params,
78
- :query_params => query_params,
79
- :form_params => form_params,
80
- :body => post_body,
81
- :auth_names => auth_names,
82
- :return_type => return_type
83
- )
84
-
85
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
86
- if @api_client.config.debugging
87
- @api_client.config.logger.debug "API called: GDPRApi#purge\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
88
- end
89
- return data, status_code, headers
90
- end
91
- end
92
- end
93
- end
94
- end
@@ -1,92 +0,0 @@
1
- =begin
2
- #Contacts
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: v3
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.2.1
10
-
11
- =end
12
-
13
- require 'cgi'
14
-
15
- module Hubspot
16
- module Crm
17
- module Contacts
18
- class MergeApi
19
- attr_accessor :api_client
20
-
21
- def initialize(api_client = ApiClient.default)
22
- @api_client = api_client
23
- end
24
- # Merge two contacts with same type
25
- # @param public_merge_input [PublicMergeInput]
26
- # @param [Hash] opts the optional parameters
27
- # @return [SimplePublicObject]
28
- def merge(public_merge_input, opts = {})
29
- data, _status_code, _headers = merge_with_http_info(public_merge_input, opts)
30
- data
31
- end
32
-
33
- # Merge two contacts with same type
34
- # @param public_merge_input [PublicMergeInput]
35
- # @param [Hash] opts the optional parameters
36
- # @return [Array<(SimplePublicObject, Integer, Hash)>] SimplePublicObject data, response status code and response headers
37
- def merge_with_http_info(public_merge_input, opts = {})
38
- if @api_client.config.debugging
39
- @api_client.config.logger.debug 'Calling API: MergeApi.merge ...'
40
- end
41
- # verify the required parameter 'public_merge_input' is set
42
- if @api_client.config.client_side_validation && public_merge_input.nil?
43
- fail ArgumentError, "Missing the required parameter 'public_merge_input' when calling MergeApi.merge"
44
- end
45
- # resource path
46
- local_var_path = '/crm/v3/objects/contacts/merge'
47
-
48
- # query parameters
49
- query_params = opts[:query_params] || {}
50
-
51
- # header parameters
52
- header_params = opts[:header_params] || {}
53
- # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
55
- # HTTP header 'Content-Type'
56
- content_type = @api_client.select_header_content_type(['application/json'])
57
- if !content_type.nil?
58
- header_params['Content-Type'] = content_type
59
- end
60
-
61
- # form parameters
62
- form_params = opts[:form_params] || {}
63
-
64
- # http body (model)
65
- post_body = opts[:debug_body] || @api_client.object_to_http_body(public_merge_input)
66
-
67
- # return_type
68
- return_type = opts[:debug_return_type] || 'SimplePublicObject'
69
-
70
- # auth_names
71
- auth_names = opts[:debug_auth_names] || ['oauth2']
72
-
73
- new_options = opts.merge(
74
- :operation => :"MergeApi.merge",
75
- :header_params => header_params,
76
- :query_params => query_params,
77
- :form_params => form_params,
78
- :body => post_body,
79
- :auth_names => auth_names,
80
- :return_type => return_type
81
- )
82
-
83
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
84
- if @api_client.config.debugging
85
- @api_client.config.logger.debug "API called: MergeApi#merge\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
86
- end
87
- return data, status_code, headers
88
- end
89
- end
90
- end
91
- end
92
- end
@@ -1,92 +0,0 @@
1
- =begin
2
- #Deals
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: v3
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.2.1
10
-
11
- =end
12
-
13
- require 'cgi'
14
-
15
- module Hubspot
16
- module Crm
17
- module Deals
18
- class MergeApi
19
- attr_accessor :api_client
20
-
21
- def initialize(api_client = ApiClient.default)
22
- @api_client = api_client
23
- end
24
- # Merge two deals
25
- # @param public_merge_input [PublicMergeInput]
26
- # @param [Hash] opts the optional parameters
27
- # @return [SimplePublicObject]
28
- def merge(public_merge_input, opts = {})
29
- data, _status_code, _headers = merge_with_http_info(public_merge_input, opts)
30
- data
31
- end
32
-
33
- # Merge two deals
34
- # @param public_merge_input [PublicMergeInput]
35
- # @param [Hash] opts the optional parameters
36
- # @return [Array<(SimplePublicObject, Integer, Hash)>] SimplePublicObject data, response status code and response headers
37
- def merge_with_http_info(public_merge_input, opts = {})
38
- if @api_client.config.debugging
39
- @api_client.config.logger.debug 'Calling API: MergeApi.merge ...'
40
- end
41
- # verify the required parameter 'public_merge_input' is set
42
- if @api_client.config.client_side_validation && public_merge_input.nil?
43
- fail ArgumentError, "Missing the required parameter 'public_merge_input' when calling MergeApi.merge"
44
- end
45
- # resource path
46
- local_var_path = '/crm/v3/objects/deals/merge'
47
-
48
- # query parameters
49
- query_params = opts[:query_params] || {}
50
-
51
- # header parameters
52
- header_params = opts[:header_params] || {}
53
- # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
55
- # HTTP header 'Content-Type'
56
- content_type = @api_client.select_header_content_type(['application/json'])
57
- if !content_type.nil?
58
- header_params['Content-Type'] = content_type
59
- end
60
-
61
- # form parameters
62
- form_params = opts[:form_params] || {}
63
-
64
- # http body (model)
65
- post_body = opts[:debug_body] || @api_client.object_to_http_body(public_merge_input)
66
-
67
- # return_type
68
- return_type = opts[:debug_return_type] || 'SimplePublicObject'
69
-
70
- # auth_names
71
- auth_names = opts[:debug_auth_names] || ['oauth2']
72
-
73
- new_options = opts.merge(
74
- :operation => :"MergeApi.merge",
75
- :header_params => header_params,
76
- :query_params => query_params,
77
- :form_params => form_params,
78
- :body => post_body,
79
- :auth_names => auth_names,
80
- :return_type => return_type
81
- )
82
-
83
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
84
- if @api_client.config.debugging
85
- @api_client.config.logger.debug "API called: MergeApi#merge\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
86
- end
87
- return data, status_code, headers
88
- end
89
- end
90
- end
91
- end
92
- end
@@ -1,92 +0,0 @@
1
- =begin
2
- #Tickets
3
-
4
- #No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5
-
6
- The version of the OpenAPI document: v3
7
-
8
- Generated by: https://openapi-generator.tech
9
- OpenAPI Generator version: 6.2.1
10
-
11
- =end
12
-
13
- require 'cgi'
14
-
15
- module Hubspot
16
- module Crm
17
- module Tickets
18
- class MergeApi
19
- attr_accessor :api_client
20
-
21
- def initialize(api_client = ApiClient.default)
22
- @api_client = api_client
23
- end
24
- # Merge two tickets with same type
25
- # @param public_merge_input [PublicMergeInput]
26
- # @param [Hash] opts the optional parameters
27
- # @return [SimplePublicObject]
28
- def merge(public_merge_input, opts = {})
29
- data, _status_code, _headers = merge_with_http_info(public_merge_input, opts)
30
- data
31
- end
32
-
33
- # Merge two tickets with same type
34
- # @param public_merge_input [PublicMergeInput]
35
- # @param [Hash] opts the optional parameters
36
- # @return [Array<(SimplePublicObject, Integer, Hash)>] SimplePublicObject data, response status code and response headers
37
- def merge_with_http_info(public_merge_input, opts = {})
38
- if @api_client.config.debugging
39
- @api_client.config.logger.debug 'Calling API: MergeApi.merge ...'
40
- end
41
- # verify the required parameter 'public_merge_input' is set
42
- if @api_client.config.client_side_validation && public_merge_input.nil?
43
- fail ArgumentError, "Missing the required parameter 'public_merge_input' when calling MergeApi.merge"
44
- end
45
- # resource path
46
- local_var_path = '/crm/v3/objects/tickets/merge'
47
-
48
- # query parameters
49
- query_params = opts[:query_params] || {}
50
-
51
- # header parameters
52
- header_params = opts[:header_params] || {}
53
- # HTTP header 'Accept' (if needed)
54
- header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
55
- # HTTP header 'Content-Type'
56
- content_type = @api_client.select_header_content_type(['application/json'])
57
- if !content_type.nil?
58
- header_params['Content-Type'] = content_type
59
- end
60
-
61
- # form parameters
62
- form_params = opts[:form_params] || {}
63
-
64
- # http body (model)
65
- post_body = opts[:debug_body] || @api_client.object_to_http_body(public_merge_input)
66
-
67
- # return_type
68
- return_type = opts[:debug_return_type] || 'SimplePublicObject'
69
-
70
- # auth_names
71
- auth_names = opts[:debug_auth_names] || ['oauth2']
72
-
73
- new_options = opts.merge(
74
- :operation => :"MergeApi.merge",
75
- :header_params => header_params,
76
- :query_params => query_params,
77
- :form_params => form_params,
78
- :body => post_body,
79
- :auth_names => auth_names,
80
- :return_type => return_type
81
- )
82
-
83
- data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
84
- if @api_client.config.debugging
85
- @api_client.config.logger.debug "API called: MergeApi#merge\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
86
- end
87
- return data, status_code, headers
88
- end
89
- end
90
- end
91
- end
92
- end
@@ -1,13 +0,0 @@
1
- require_relative '../../../base_api_client'
2
-
3
- module Hubspot
4
- module Discovery
5
- module Cms
6
- module Performance
7
- class PublicPerformanceApi
8
- include Hubspot::Discovery::BaseApiClient
9
- end
10
- end
11
- end
12
- end
13
- end
@@ -1,13 +0,0 @@
1
- require_relative '../../../base_api_client'
2
-
3
- module Hubspot
4
- module Discovery
5
- module Crm
6
- module Companies
7
- class MergeApi
8
- include Hubspot::Discovery::BaseApiClient
9
- end
10
- end
11
- end
12
- end
13
- end
@@ -1,13 +0,0 @@
1
- require_relative '../../../base_api_client'
2
-
3
- module Hubspot
4
- module Discovery
5
- module Crm
6
- module Contacts
7
- class GDPRApi
8
- include Hubspot::Discovery::BaseApiClient
9
- end
10
- end
11
- end
12
- end
13
- end
@@ -1,13 +0,0 @@
1
- require_relative '../../../base_api_client'
2
-
3
- module Hubspot
4
- module Discovery
5
- module Crm
6
- module Contacts
7
- class MergeApi
8
- include Hubspot::Discovery::BaseApiClient
9
- end
10
- end
11
- end
12
- end
13
- end
@@ -1,13 +0,0 @@
1
- require_relative '../../../base_api_client'
2
-
3
- module Hubspot
4
- module Discovery
5
- module Crm
6
- module Tickets
7
- class MergeApi
8
- include Hubspot::Discovery::BaseApiClient
9
- end
10
- end
11
- end
12
- end
13
- end
@@ -1,8 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe 'Hubspot::Discovery::Cms::Performance::PublicPerformanceApi' do
4
- subject(:api) { Hubspot::Client.new(access_token: 'test').cms.performance.public_performance_api }
5
-
6
- it { is_expected.to respond_to(:get_page) }
7
- it { is_expected.to respond_to(:get_uptime) }
8
- end
@@ -1,7 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe 'Hubspot::Discovery::Crm::Companies::MergeApi' do
4
- subject(:public_object_api) { Hubspot::Client.new(access_token: 'test').crm.companies.merge_api }
5
-
6
- it { is_expected.to respond_to(:merge) }
7
- end
@@ -1,7 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe 'Hubspot::Discovery::Crm::Contacts::GDPRApi' do
4
- subject(:api) { Hubspot::Client.new(access_token: 'test').crm.contacts.gdpr_api }
5
-
6
- it { is_expected.to respond_to(:purge) }
7
- end
@@ -1,7 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe 'Hubspot::Discovery::Crm::Contacts::MergeApi' do
4
- subject(:public_object_api) { Hubspot::Client.new(access_token: 'test').crm.contacts.merge_api }
5
-
6
- it { is_expected.to respond_to(:merge) }
7
- end
@@ -1,7 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe 'Hubspot::Discovery::Crm::Deals::MergeApi' do
4
- subject(:public_object_api) { Hubspot::Client.new(access_token: 'test').crm.deals.merge_api }
5
-
6
- it { is_expected.to respond_to(:merge) }
7
- end
@@ -1,7 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe 'Hubspot::Discovery::Crm::Tickets::MergeApi' do
4
- subject(:api) { Hubspot::Client.new(access_token: 'test').crm.tickets.merge_api }
5
-
6
- it { is_expected.to respond_to(:merge) }
7
- end