hubspot-api-client 20.0.0.pre.beta.1 → 20.0.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 (180) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +33 -1
  3. data/Gemfile.lock +2 -2
  4. data/lib/hubspot/codegen/crm/companies/api/basic_api.rb +91 -22
  5. data/lib/hubspot/codegen/crm/companies/api/batch_api.rb +25 -17
  6. data/lib/hubspot/codegen/crm/companies/api/search_api.rb +4 -0
  7. data/lib/hubspot/codegen/crm/companies/models/association_spec.rb +12 -0
  8. 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
  9. data/lib/hubspot/codegen/crm/companies/models/batch_read_input_simple_public_object_id.rb +1 -0
  10. data/lib/hubspot/codegen/crm/companies/models/public_associations_for_object.rb +10 -0
  11. data/lib/hubspot/codegen/crm/companies/models/public_merge_input.rb +2 -0
  12. data/lib/hubspot/codegen/crm/companies/models/public_object_id.rb +6 -0
  13. data/lib/hubspot/codegen/crm/companies/models/simple_public_object.rb +10 -1
  14. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_batch_input.rb +4 -0
  15. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_batch_input_for_create.rb +250 -0
  16. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_batch_input_upsert.rb +4 -0
  17. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_input.rb +2 -10
  18. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_input_for_create.rb +2 -10
  19. data/lib/hubspot/codegen/crm/companies/models/simple_public_object_with_associations.rb +10 -1
  20. data/lib/hubspot/codegen/crm/companies/models/simple_public_upsert_object.rb +10 -1
  21. data/lib/hubspot/codegen/crm/contacts/api/basic_api.rb +163 -26
  22. data/lib/hubspot/codegen/crm/contacts/api/batch_api.rb +27 -19
  23. data/lib/hubspot/codegen/crm/contacts/api/search_api.rb +4 -0
  24. data/lib/hubspot/codegen/crm/contacts/models/association_spec.rb +10 -0
  25. 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
  26. data/lib/hubspot/codegen/crm/contacts/models/batch_read_input_simple_public_object_id.rb +1 -0
  27. data/lib/hubspot/codegen/crm/contacts/models/public_associations_for_object.rb +10 -0
  28. data/lib/hubspot/codegen/crm/contacts/models/public_gdpr_delete_input.rb +2 -0
  29. data/lib/hubspot/codegen/crm/contacts/models/public_object_id.rb +5 -0
  30. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object.rb +10 -1
  31. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_batch_input.rb +2 -0
  32. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_batch_input_for_create.rb +250 -0
  33. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_batch_input_upsert.rb +1 -0
  34. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_input.rb +1 -10
  35. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_input_for_create.rb +1 -10
  36. data/lib/hubspot/codegen/crm/contacts/models/simple_public_object_with_associations.rb +13 -1
  37. data/lib/hubspot/codegen/crm/contacts/models/simple_public_upsert_object.rb +10 -1
  38. data/lib/hubspot/codegen/crm/deals/api/basic_api.rb +67 -0
  39. data/lib/hubspot/codegen/crm/deals/api/batch_api.rb +11 -9
  40. data/lib/hubspot/codegen/crm/deals/models/association_spec.rb +10 -0
  41. 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
  42. data/lib/hubspot/codegen/crm/deals/models/batch_read_input_simple_public_object_id.rb +1 -0
  43. data/lib/hubspot/codegen/crm/deals/models/public_associations_for_object.rb +10 -0
  44. data/lib/hubspot/codegen/crm/deals/models/public_object_id.rb +5 -0
  45. data/lib/hubspot/codegen/crm/deals/models/simple_public_object.rb +10 -1
  46. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_batch_input.rb +2 -0
  47. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_batch_input_for_create.rb +250 -0
  48. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_batch_input_upsert.rb +1 -0
  49. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_input.rb +1 -10
  50. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_input_for_create.rb +1 -10
  51. data/lib/hubspot/codegen/crm/deals/models/simple_public_object_with_associations.rb +10 -1
  52. data/lib/hubspot/codegen/crm/deals/models/simple_public_upsert_object.rb +10 -1
  53. data/lib/hubspot/codegen/crm/objects/feedback_submissions/api/basic_api.rb +3 -2
  54. data/lib/hubspot/codegen/crm/objects/feedback_submissions/api/batch_api.rb +2 -0
  55. data/lib/hubspot/codegen/crm/objects/feedback_submissions/models/batch_read_input_simple_public_object_id.rb +1 -0
  56. data/lib/hubspot/codegen/crm/objects/feedback_submissions/models/simple_public_object.rb +10 -1
  57. data/lib/hubspot/codegen/crm/objects/feedback_submissions/models/simple_public_object_with_associations.rb +10 -1
  58. data/lib/hubspot/codegen/crm/objects/goals/api/basic_api.rb +1 -0
  59. data/lib/hubspot/codegen/crm/objects/goals/api/batch_api.rb +11 -9
  60. 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
  61. data/lib/hubspot/codegen/crm/objects/goals/models/batch_read_input_simple_public_object_id.rb +1 -0
  62. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object.rb +10 -1
  63. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_batch_input.rb +2 -0
  64. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_batch_input_for_create.rb +252 -0
  65. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_batch_input_upsert.rb +1 -0
  66. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_input.rb +1 -10
  67. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_input_for_create.rb +1 -15
  68. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_object_with_associations.rb +10 -1
  69. data/lib/hubspot/codegen/crm/objects/goals/models/simple_public_upsert_object.rb +10 -1
  70. data/lib/hubspot/codegen/crm/products/api/basic_api.rb +5 -4
  71. data/lib/hubspot/codegen/crm/products/api/batch_api.rb +11 -9
  72. 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
  73. data/lib/hubspot/codegen/crm/products/models/batch_read_input_simple_public_object_id.rb +1 -1
  74. data/lib/hubspot/codegen/crm/products/models/simple_public_object.rb +10 -1
  75. data/lib/hubspot/codegen/crm/products/models/simple_public_object_batch_input_for_create.rb +250 -0
  76. data/lib/hubspot/codegen/crm/products/models/simple_public_object_input.rb +1 -10
  77. data/lib/hubspot/codegen/crm/products/models/simple_public_object_input_for_create.rb +6 -10
  78. data/lib/hubspot/codegen/crm/products/models/simple_public_object_with_associations.rb +10 -1
  79. data/lib/hubspot/codegen/crm/products/models/simple_public_upsert_object.rb +10 -1
  80. data/lib/hubspot/codegen/crm/tickets/api/basic_api.rb +73 -4
  81. data/lib/hubspot/codegen/crm/tickets/api/batch_api.rb +17 -9
  82. data/lib/hubspot/codegen/crm/tickets/api/search_api.rb +4 -0
  83. data/lib/hubspot/codegen/crm/tickets/models/association_spec.rb +10 -0
  84. 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
  85. data/lib/hubspot/codegen/crm/tickets/models/batch_read_input_simple_public_object_id.rb +1 -0
  86. data/lib/hubspot/codegen/crm/tickets/models/public_associations_for_object.rb +10 -0
  87. data/lib/hubspot/codegen/crm/tickets/models/public_object_id.rb +5 -0
  88. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object.rb +10 -1
  89. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_batch_input.rb +2 -0
  90. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_batch_input_for_create.rb +250 -0
  91. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_batch_input_upsert.rb +1 -0
  92. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_input.rb +1 -10
  93. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_input_for_create.rb +1 -10
  94. data/lib/hubspot/codegen/crm/tickets/models/simple_public_object_with_associations.rb +10 -1
  95. data/lib/hubspot/codegen/crm/tickets/models/simple_public_upsert_object.rb +10 -1
  96. data/lib/hubspot/codegen/files/api/files_api.rb +144 -104
  97. data/lib/hubspot/codegen/files/api/folders_api.rb +142 -57
  98. data/lib/hubspot/codegen/files/api_client.rb +1 -1
  99. data/lib/hubspot/codegen/files/api_error.rb +1 -1
  100. data/lib/hubspot/codegen/files/configuration.rb +1 -1
  101. data/lib/hubspot/codegen/files/models/collection_response_file.rb +2 -1
  102. data/lib/hubspot/codegen/files/models/collection_response_folder.rb +1 -1
  103. data/lib/hubspot/codegen/files/models/error.rb +1 -1
  104. data/lib/hubspot/codegen/files/models/error_detail.rb +1 -1
  105. data/lib/hubspot/codegen/files/models/file.rb +33 -14
  106. data/lib/hubspot/codegen/files/models/file_action_response.rb +1 -1
  107. data/lib/hubspot/codegen/files/models/file_stat.rb +1 -1
  108. data/lib/hubspot/codegen/files/models/file_update_input.rb +15 -5
  109. data/lib/hubspot/codegen/files/models/folder.rb +12 -12
  110. data/lib/hubspot/codegen/files/models/folder_action_response.rb +1 -1
  111. data/lib/hubspot/codegen/files/models/folder_input.rb +2 -1
  112. data/lib/hubspot/codegen/files/models/folder_update_input.rb +6 -20
  113. data/lib/hubspot/codegen/files/models/folder_update_input_with_id.rb +244 -0
  114. data/lib/hubspot/codegen/files/models/folder_update_task_locator.rb +2 -1
  115. data/lib/hubspot/codegen/files/models/import_from_url_input.rb +13 -4
  116. data/lib/hubspot/codegen/files/models/import_from_url_task_locator.rb +2 -1
  117. data/lib/hubspot/codegen/files/models/next_page.rb +1 -1
  118. data/lib/hubspot/codegen/files/models/paging.rb +1 -1
  119. data/lib/hubspot/codegen/files/models/previous_page.rb +1 -1
  120. data/lib/hubspot/codegen/files/models/signed_url.rb +18 -17
  121. data/lib/hubspot/codegen/files/models/standard_error.rb +1 -1
  122. data/lib/hubspot/codegen/oauth/api/access_tokens_api.rb +7 -3
  123. data/lib/hubspot/codegen/oauth/api/refresh_tokens_api.rb +13 -5
  124. data/lib/hubspot/codegen/oauth/api/tokens_api.rb +5 -1
  125. data/lib/hubspot/codegen/oauth/api_client.rb +2 -2
  126. data/lib/hubspot/codegen/oauth/api_error.rb +1 -1
  127. data/lib/hubspot/codegen/oauth/configuration.rb +1 -1
  128. data/lib/hubspot/codegen/oauth/models/access_token_info_response.rb +4 -4
  129. data/lib/hubspot/codegen/oauth/models/error.rb +4 -4
  130. data/lib/hubspot/codegen/oauth/models/error_detail.rb +4 -4
  131. data/lib/hubspot/codegen/oauth/models/refresh_token_info_response.rb +4 -4
  132. data/lib/hubspot/codegen/oauth/models/token_response_if.rb +4 -4
  133. data/lib/hubspot/discovery/cms/client.rb +0 -1
  134. data/lib/hubspot/discovery/crm/companies/client.rb +0 -1
  135. data/lib/hubspot/discovery/crm/contacts/client.rb +0 -2
  136. data/lib/hubspot/discovery/crm/deals/client.rb +0 -1
  137. data/lib/hubspot/discovery/crm/tickets/client.rb +0 -1
  138. data/lib/hubspot/discovery/oauth/api/access_tokens_api.rb +1 -1
  139. data/lib/hubspot/discovery/oauth/api/refresh_tokens_api.rb +1 -1
  140. data/lib/hubspot/discovery/oauth/api/tokens_api.rb +1 -1
  141. data/lib/hubspot/discovery/oauth/client.rb +1 -1
  142. data/lib/hubspot/helpers/camel_case.rb +0 -4
  143. data/lib/hubspot/version.rb +1 -1
  144. data/spec/discovery/cms/client_spec.rb +0 -1
  145. data/spec/discovery/crm/companies/basic_api_spec.rb +1 -0
  146. data/spec/discovery/crm/contacts/basic_api_spec.rb +1 -0
  147. data/spec/discovery/crm/deals/basic_api_spec.rb +1 -0
  148. data/spec/discovery/crm/tickets/basic_api_spec.rb +1 -0
  149. data/spec/discovery/files/files_api_spec.rb +2 -1
  150. data/spec/discovery/files/folders_api_spec.rb +1 -0
  151. data/spec/discovery/oauth/access_tokens_api_spec.rb +1 -1
  152. data/spec/discovery/oauth/refresh_tokens_api_spec.rb +1 -1
  153. data/spec/discovery/oauth/tokens_api_spec.rb +1 -1
  154. metadata +17 -42
  155. data/lib/hubspot/codegen/cms/performance/api/public_performance_api.rb +0 -188
  156. data/lib/hubspot/codegen/cms/performance/api_client.rb +0 -410
  157. data/lib/hubspot/codegen/cms/performance/api_error.rb +0 -61
  158. data/lib/hubspot/codegen/cms/performance/configuration.rb +0 -287
  159. data/lib/hubspot/codegen/cms/performance/models/error.rb +0 -305
  160. data/lib/hubspot/codegen/cms/performance/models/error_detail.rb +0 -271
  161. data/lib/hubspot/codegen/cms/performance/models/performance_view.rb +0 -526
  162. data/lib/hubspot/codegen/cms/performance/models/public_performance_response.rb +0 -345
  163. data/lib/hubspot/codegen/crm/companies/api/merge_api.rb +0 -92
  164. data/lib/hubspot/codegen/crm/contacts/api/gdpr_api.rb +0 -94
  165. data/lib/hubspot/codegen/crm/contacts/api/merge_api.rb +0 -92
  166. data/lib/hubspot/codegen/crm/deals/api/merge_api.rb +0 -92
  167. data/lib/hubspot/codegen/crm/tickets/api/merge_api.rb +0 -92
  168. data/lib/hubspot/discovery/cms/performance/api/public_performance_api.rb +0 -13
  169. data/lib/hubspot/discovery/cms/performance/client.rb +0 -19
  170. data/lib/hubspot/discovery/crm/companies/api/merge_api.rb +0 -13
  171. data/lib/hubspot/discovery/crm/contacts/api/gdpr_api.rb +0 -13
  172. data/lib/hubspot/discovery/crm/contacts/api/merge_api.rb +0 -13
  173. data/lib/hubspot/discovery/crm/deals/api/merge_api.rb +0 -13
  174. data/lib/hubspot/discovery/crm/tickets/api/merge_api.rb +0 -13
  175. data/spec/discovery/cms/performance/public_performance_api_spec.rb +0 -8
  176. data/spec/discovery/crm/companies/merge_api_spec.rb +0 -7
  177. data/spec/discovery/crm/contacts/gdpr_api_spec.rb +0 -7
  178. data/spec/discovery/crm/contacts/merge_api_spec.rb +0 -7
  179. data/spec/discovery/crm/deals/merge_api_spec.rb +0 -7
  180. data/spec/discovery/crm/tickets/merge_api_spec.rb +0 -7
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -20,7 +20,7 @@ module Hubspot
20
20
  def initialize(api_client = ApiClient.default)
21
21
  @api_client = api_client
22
22
  end
23
- # Delete folder.
23
+ # Delete folder by ID
24
24
  # Delete folder by ID.
25
25
  # @param folder_id [String] ID of folder to delete.
26
26
  # @param [Hash] opts the optional parameters
@@ -30,7 +30,7 @@ module Hubspot
30
30
  nil
31
31
  end
32
32
 
33
- # Delete folder.
33
+ # Delete folder by ID
34
34
  # Delete folder by ID.
35
35
  # @param folder_id [String] ID of folder to delete.
36
36
  # @param [Hash] opts the optional parameters
@@ -88,8 +88,8 @@ module Hubspot
88
88
  return data, status_code, headers
89
89
  end
90
90
 
91
- # Delete folder.
92
- # Delete folder by path.
91
+ # Delete folder by path
92
+ # Delete a folder, identified by its path.
93
93
  # @param folder_path [String] Path of folder to delete
94
94
  # @param [Hash] opts the optional parameters
95
95
  # @return [nil]
@@ -98,8 +98,8 @@ module Hubspot
98
98
  nil
99
99
  end
100
100
 
101
- # Delete folder.
102
- # Delete folder by path.
101
+ # Delete folder by path
102
+ # Delete a folder, identified by its path.
103
103
  # @param folder_path [String] Path of folder to delete
104
104
  # @param [Hash] opts the optional parameters
105
105
  # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
@@ -156,9 +156,9 @@ module Hubspot
156
156
  return data, status_code, headers
157
157
  end
158
158
 
159
- # Check folder update status.
159
+ # Check folder update status
160
160
  # Check status of folder update. Folder updates happen asynchronously.
161
- # @param task_id [String] TaskId of folder update
161
+ # @param task_id [String] The ID of the folder update task.
162
162
  # @param [Hash] opts the optional parameters
163
163
  # @return [FolderActionResponse]
164
164
  def check_update_status(task_id, opts = {})
@@ -166,9 +166,9 @@ module Hubspot
166
166
  data
167
167
  end
168
168
 
169
- # Check folder update status.
169
+ # Check folder update status
170
170
  # Check status of folder update. Folder updates happen asynchronously.
171
- # @param task_id [String] TaskId of folder update
171
+ # @param task_id [String] The ID of the folder update task.
172
172
  # @param [Hash] opts the optional parameters
173
173
  # @return [Array<(FolderActionResponse, Integer, Hash)>] FolderActionResponse data, response status code and response headers
174
174
  def check_update_status_with_http_info(task_id, opts = {})
@@ -219,7 +219,7 @@ module Hubspot
219
219
  return data, status_code, headers
220
220
  end
221
221
 
222
- # Create folder.
222
+ # Create folder
223
223
  # Creates a folder.
224
224
  # @param folder_input [FolderInput] Folder creation options
225
225
  # @param [Hash] opts the optional parameters
@@ -229,7 +229,7 @@ module Hubspot
229
229
  data
230
230
  end
231
231
 
232
- # Create folder.
232
+ # Create folder
233
233
  # Creates a folder.
234
234
  # @param folder_input [FolderInput] Folder creation options
235
235
  # @param [Hash] opts the optional parameters
@@ -291,20 +291,22 @@ module Hubspot
291
291
  # Search for folders. Does not contain hidden or archived folders.
292
292
  # @param [Hash] opts the optional parameters
293
293
  # @option opts [Array<String>] :properties Properties that should be included in the returned folders.
294
- # @option opts [String] :after The maximum offset of items for a given search is 10000. Narrow your search down if you are reaching this limit.
294
+ # @option opts [String] :after Offset search results by this value. The default offset is 0 and the maximum offset of items for a given search is 10,000. Narrow your search down if you are reaching this limit.
295
295
  # @option opts [String] :before
296
- # @option opts [Integer] :limit Limit of results to return. Max limit is 100.
296
+ # @option opts [Integer] :limit Number of items to return. Default limit is 10, maximum limit is 100.
297
297
  # @option opts [Array<String>] :sort Sort results by given property. For example -name sorts by name field descending, name sorts by name field ascending.
298
- # @option opts [String] :id Search folder by given ID.
299
- # @option opts [Time] :created_at Search for folders with the given creation timestamp.
300
- # @option opts [Time] :created_at_lte
301
- # @option opts [Time] :created_at_gte
302
- # @option opts [Time] :updated_at Search for folder at given update timestamp.
303
- # @option opts [Time] :updated_at_lte
304
- # @option opts [Time] :updated_at_gte
298
+ # @option opts [Array<Integer>] :ids
299
+ # @option opts [Integer] :id_lte
300
+ # @option opts [Integer] :id_gte
301
+ # @option opts [Time] :created_at Search folders by exact time of creation. Time must be epoch time in milliseconds.
302
+ # @option opts [Time] :created_at_lte Search folders by less than or equal to time of creation. Can be used with createdAtGte to create a range.
303
+ # @option opts [Time] :created_at_gte Search folders by greater than or equal to time of creation. Can be used with createdAtLte to create a range.
304
+ # @option opts [Time] :updated_at Search folders by exact time of latest updated. Time must be epoch time in milliseconds.
305
+ # @option opts [Time] :updated_at_lte Search folders by less than or equal to time of latest update. Can be used with updatedAtGte to create a range.
306
+ # @option opts [Time] :updated_at_gte Search folders by greater than or equal to time of latest update. Can be used with updatedAtLte to create a range.
305
307
  # @option opts [String] :name Search for folders containing the specified name.
306
- # @option opts [String] :path Search for folders by path.
307
- # @option opts [Integer] :parent_folder_id Search for folders with the given parent folderId.
308
+ # @option opts [String] :path Search folders by path.
309
+ # @option opts [Array<Integer>] :parent_folder_ids Search folders with the given parent folderId.
308
310
  # @return [CollectionResponseFolder]
309
311
  def do_search(opts = {})
310
312
  data, _status_code, _headers = do_search_with_http_info(opts)
@@ -315,20 +317,22 @@ module Hubspot
315
317
  # Search for folders. Does not contain hidden or archived folders.
316
318
  # @param [Hash] opts the optional parameters
317
319
  # @option opts [Array<String>] :properties Properties that should be included in the returned folders.
318
- # @option opts [String] :after The maximum offset of items for a given search is 10000. Narrow your search down if you are reaching this limit.
320
+ # @option opts [String] :after Offset search results by this value. The default offset is 0 and the maximum offset of items for a given search is 10,000. Narrow your search down if you are reaching this limit.
319
321
  # @option opts [String] :before
320
- # @option opts [Integer] :limit Limit of results to return. Max limit is 100.
322
+ # @option opts [Integer] :limit Number of items to return. Default limit is 10, maximum limit is 100.
321
323
  # @option opts [Array<String>] :sort Sort results by given property. For example -name sorts by name field descending, name sorts by name field ascending.
322
- # @option opts [String] :id Search folder by given ID.
323
- # @option opts [Time] :created_at Search for folders with the given creation timestamp.
324
- # @option opts [Time] :created_at_lte
325
- # @option opts [Time] :created_at_gte
326
- # @option opts [Time] :updated_at Search for folder at given update timestamp.
327
- # @option opts [Time] :updated_at_lte
328
- # @option opts [Time] :updated_at_gte
324
+ # @option opts [Array<Integer>] :ids
325
+ # @option opts [Integer] :id_lte
326
+ # @option opts [Integer] :id_gte
327
+ # @option opts [Time] :created_at Search folders by exact time of creation. Time must be epoch time in milliseconds.
328
+ # @option opts [Time] :created_at_lte Search folders by less than or equal to time of creation. Can be used with createdAtGte to create a range.
329
+ # @option opts [Time] :created_at_gte Search folders by greater than or equal to time of creation. Can be used with createdAtLte to create a range.
330
+ # @option opts [Time] :updated_at Search folders by exact time of latest updated. Time must be epoch time in milliseconds.
331
+ # @option opts [Time] :updated_at_lte Search folders by less than or equal to time of latest update. Can be used with updatedAtGte to create a range.
332
+ # @option opts [Time] :updated_at_gte Search folders by greater than or equal to time of latest update. Can be used with updatedAtLte to create a range.
329
333
  # @option opts [String] :name Search for folders containing the specified name.
330
- # @option opts [String] :path Search for folders by path.
331
- # @option opts [Integer] :parent_folder_id Search for folders with the given parent folderId.
334
+ # @option opts [String] :path Search folders by path.
335
+ # @option opts [Array<Integer>] :parent_folder_ids Search folders with the given parent folderId.
332
336
  # @return [Array<(CollectionResponseFolder, Integer, Hash)>] CollectionResponseFolder data, response status code and response headers
333
337
  def do_search_with_http_info(opts = {})
334
338
  if @api_client.config.debugging
@@ -344,7 +348,9 @@ module Hubspot
344
348
  query_params[:'before'] = opts[:'before'] if !opts[:'before'].nil?
345
349
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
346
350
  query_params[:'sort'] = @api_client.build_collection_param(opts[:'sort'], :multi) if !opts[:'sort'].nil?
347
- query_params[:'id'] = opts[:'id'] if !opts[:'id'].nil?
351
+ query_params[:'ids'] = @api_client.build_collection_param(opts[:'ids'], :multi) if !opts[:'ids'].nil?
352
+ query_params[:'idLte'] = opts[:'id_lte'] if !opts[:'id_lte'].nil?
353
+ query_params[:'idGte'] = opts[:'id_gte'] if !opts[:'id_gte'].nil?
348
354
  query_params[:'createdAt'] = opts[:'created_at'] if !opts[:'created_at'].nil?
349
355
  query_params[:'createdAtLte'] = opts[:'created_at_lte'] if !opts[:'created_at_lte'].nil?
350
356
  query_params[:'createdAtGte'] = opts[:'created_at_gte'] if !opts[:'created_at_gte'].nil?
@@ -353,7 +359,7 @@ module Hubspot
353
359
  query_params[:'updatedAtGte'] = opts[:'updated_at_gte'] if !opts[:'updated_at_gte'].nil?
354
360
  query_params[:'name'] = opts[:'name'] if !opts[:'name'].nil?
355
361
  query_params[:'path'] = opts[:'path'] if !opts[:'path'].nil?
356
- query_params[:'parentFolderId'] = opts[:'parent_folder_id'] if !opts[:'parent_folder_id'].nil?
362
+ query_params[:'parentFolderIds'] = @api_client.build_collection_param(opts[:'parent_folder_ids'], :multi) if !opts[:'parent_folder_ids'].nil?
357
363
 
358
364
  # header parameters
359
365
  header_params = opts[:header_params] || {}
@@ -389,8 +395,8 @@ module Hubspot
389
395
  return data, status_code, headers
390
396
  end
391
397
 
392
- # Get folder
393
- # Get folder by ID
398
+ # Retrieve folder by ID
399
+ # Retrieve a folder by its ID.
394
400
  # @param folder_id [String] ID of desired folder
395
401
  # @param [Hash] opts the optional parameters
396
402
  # @option opts [Array<String>] :properties Properties to set on returned folder.
@@ -400,8 +406,8 @@ module Hubspot
400
406
  data
401
407
  end
402
408
 
403
- # Get folder
404
- # Get folder by ID
409
+ # Retrieve folder by ID
410
+ # Retrieve a folder by its ID.
405
411
  # @param folder_id [String] ID of desired folder
406
412
  # @param [Hash] opts the optional parameters
407
413
  # @option opts [Array<String>] :properties Properties to set on returned folder.
@@ -460,8 +466,8 @@ module Hubspot
460
466
  return data, status_code, headers
461
467
  end
462
468
 
463
- # Get folder.
464
- # Get folder by path.
469
+ # Retrieve folder by path
470
+ # Retrieve a folder, identified by its path.
465
471
  # @param folder_path [String] Path of desired folder.
466
472
  # @param [Hash] opts the optional parameters
467
473
  # @option opts [Array<String>] :properties Properties to set on returned folder.
@@ -471,8 +477,8 @@ module Hubspot
471
477
  data
472
478
  end
473
479
 
474
- # Get folder.
475
- # Get folder by path.
480
+ # Retrieve folder by path
481
+ # Retrieve a folder, identified by its path.
476
482
  # @param folder_path [String] Path of desired folder.
477
483
  # @param [Hash] opts the optional parameters
478
484
  # @option opts [Array<String>] :properties Properties to set on returned folder.
@@ -531,28 +537,107 @@ module Hubspot
531
537
  return data, status_code, headers
532
538
  end
533
539
 
540
+ # Update folder properties by folder ID
541
+ # Update a folder's properties, identified by folder ID.
542
+ # @param folder_id [String] ID of folder to update
543
+ # @param folder_update_input [FolderUpdateInput]
544
+ # @param [Hash] opts the optional parameters
545
+ # @return [Folder]
546
+ def update_properties(folder_id, folder_update_input, opts = {})
547
+ data, _status_code, _headers = update_properties_with_http_info(folder_id, folder_update_input, opts)
548
+ data
549
+ end
550
+
551
+ # Update folder properties by folder ID
552
+ # Update a folder&#39;s properties, identified by folder ID.
553
+ # @param folder_id [String] ID of folder to update
554
+ # @param folder_update_input [FolderUpdateInput]
555
+ # @param [Hash] opts the optional parameters
556
+ # @return [Array<(Folder, Integer, Hash)>] Folder data, response status code and response headers
557
+ def update_properties_with_http_info(folder_id, folder_update_input, opts = {})
558
+ if @api_client.config.debugging
559
+ @api_client.config.logger.debug 'Calling API: FoldersApi.update_properties ...'
560
+ end
561
+ # verify the required parameter 'folder_id' is set
562
+ if @api_client.config.client_side_validation && folder_id.nil?
563
+ fail ArgumentError, "Missing the required parameter 'folder_id' when calling FoldersApi.update_properties"
564
+ end
565
+ pattern = Regexp.new(/\d+/)
566
+ if @api_client.config.client_side_validation && folder_id !~ pattern
567
+ fail ArgumentError, "invalid value for 'folder_id' when calling FoldersApi.update_properties, must conform to the pattern #{pattern}."
568
+ end
569
+
570
+ # verify the required parameter 'folder_update_input' is set
571
+ if @api_client.config.client_side_validation && folder_update_input.nil?
572
+ fail ArgumentError, "Missing the required parameter 'folder_update_input' when calling FoldersApi.update_properties"
573
+ end
574
+ # resource path
575
+ local_var_path = '/files/v3/folders/{folderId}'.sub('{' + 'folderId' + '}', CGI.escape(folder_id.to_s))
576
+
577
+ # query parameters
578
+ query_params = opts[:query_params] || {}
579
+
580
+ # header parameters
581
+ header_params = opts[:header_params] || {}
582
+ # HTTP header 'Accept' (if needed)
583
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
584
+ # HTTP header 'Content-Type'
585
+ content_type = @api_client.select_header_content_type(['application/json'])
586
+ if !content_type.nil?
587
+ header_params['Content-Type'] = content_type
588
+ end
589
+
590
+ # form parameters
591
+ form_params = opts[:form_params] || {}
592
+
593
+ # http body (model)
594
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(folder_update_input)
595
+
596
+ # return_type
597
+ return_type = opts[:debug_return_type] || 'Folder'
598
+
599
+ # auth_names
600
+ auth_names = opts[:debug_auth_names] || ['oauth2']
601
+
602
+ new_options = opts.merge(
603
+ :operation => :"FoldersApi.update_properties",
604
+ :header_params => header_params,
605
+ :query_params => query_params,
606
+ :form_params => form_params,
607
+ :body => post_body,
608
+ :auth_names => auth_names,
609
+ :return_type => return_type
610
+ )
611
+
612
+ data, status_code, headers = @api_client.call_api(:PATCH, local_var_path, new_options)
613
+ if @api_client.config.debugging
614
+ @api_client.config.logger.debug "API called: FoldersApi#update_properties\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
615
+ end
616
+ return data, status_code, headers
617
+ end
618
+
534
619
  # Update folder properties
535
620
  # Update properties of folder by given ID. This action happens asynchronously and will update all of the folder's children as well.
536
- # @param folder_update_input [FolderUpdateInput] Properties to change in the folder
621
+ # @param folder_update_input_with_id [FolderUpdateInputWithId]
537
622
  # @param [Hash] opts the optional parameters
538
623
  # @return [FolderUpdateTaskLocator]
539
- def update_properties(folder_update_input, opts = {})
540
- data, _status_code, _headers = update_properties_with_http_info(folder_update_input, opts)
624
+ def update_properties_recursively(folder_update_input_with_id, opts = {})
625
+ data, _status_code, _headers = update_properties_recursively_with_http_info(folder_update_input_with_id, opts)
541
626
  data
542
627
  end
543
628
 
544
629
  # Update folder properties
545
630
  # Update properties of folder by given ID. This action happens asynchronously and will update all of the folder&#39;s children as well.
546
- # @param folder_update_input [FolderUpdateInput] Properties to change in the folder
631
+ # @param folder_update_input_with_id [FolderUpdateInputWithId]
547
632
  # @param [Hash] opts the optional parameters
548
633
  # @return [Array<(FolderUpdateTaskLocator, Integer, Hash)>] FolderUpdateTaskLocator data, response status code and response headers
549
- def update_properties_with_http_info(folder_update_input, opts = {})
634
+ def update_properties_recursively_with_http_info(folder_update_input_with_id, opts = {})
550
635
  if @api_client.config.debugging
551
- @api_client.config.logger.debug 'Calling API: FoldersApi.update_properties ...'
636
+ @api_client.config.logger.debug 'Calling API: FoldersApi.update_properties_recursively ...'
552
637
  end
553
- # verify the required parameter 'folder_update_input' is set
554
- if @api_client.config.client_side_validation && folder_update_input.nil?
555
- fail ArgumentError, "Missing the required parameter 'folder_update_input' when calling FoldersApi.update_properties"
638
+ # verify the required parameter 'folder_update_input_with_id' is set
639
+ if @api_client.config.client_side_validation && folder_update_input_with_id.nil?
640
+ fail ArgumentError, "Missing the required parameter 'folder_update_input_with_id' when calling FoldersApi.update_properties_recursively"
556
641
  end
557
642
  # resource path
558
643
  local_var_path = '/files/v3/folders/update/async'
@@ -574,7 +659,7 @@ module Hubspot
574
659
  form_params = opts[:form_params] || {}
575
660
 
576
661
  # http body (model)
577
- post_body = opts[:debug_body] || @api_client.object_to_http_body(folder_update_input)
662
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(folder_update_input_with_id)
578
663
 
579
664
  # return_type
580
665
  return_type = opts[:debug_return_type] || 'FolderUpdateTaskLocator'
@@ -583,7 +668,7 @@ module Hubspot
583
668
  auth_names = opts[:debug_auth_names] || ['oauth2']
584
669
 
585
670
  new_options = opts.merge(
586
- :operation => :"FoldersApi.update_properties",
671
+ :operation => :"FoldersApi.update_properties_recursively",
587
672
  :header_params => header_params,
588
673
  :query_params => query_params,
589
674
  :form_params => form_params,
@@ -594,7 +679,7 @@ module Hubspot
594
679
 
595
680
  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
596
681
  if @api_client.config.debugging
597
- @api_client.config.logger.debug "API called: FoldersApi#update_properties\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
682
+ @api_client.config.logger.debug "API called: FoldersApi#update_properties_recursively\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
598
683
  end
599
684
  return data, status_code, headers
600
685
  end
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -15,6 +15,7 @@ require 'time'
15
15
 
16
16
  module Hubspot
17
17
  module Files
18
+ # Collections of files
18
19
  class CollectionResponseFile
19
20
  attr_accessor :paging
20
21
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -15,6 +15,7 @@ require 'time'
15
15
 
16
16
  module Hubspot
17
17
  module Files
18
+ # File
18
19
  class File
19
20
  # Extension of the file. ex: .jpg, .png, .gif, .pdf, etc.
20
21
  attr_accessor :extension
@@ -25,6 +26,10 @@ module Hubspot
25
26
  # ID of the folder the file is in.
26
27
  attr_accessor :parent_folder_id
27
28
 
29
+ attr_accessor :source_group
30
+
31
+ attr_accessor :file_md5
32
+
28
33
  # Encoding of the file.
29
34
  attr_accessor :encoding
30
35
 
@@ -45,12 +50,12 @@ module Hubspot
45
50
  # Deletion time of the file object.
46
51
  attr_accessor :archived_at
47
52
 
48
- # If the file is deleted.
49
- attr_accessor :archived
50
-
51
53
  # Path of the file in the file manager.
52
54
  attr_accessor :path
53
55
 
56
+ # If the file is deleted.
57
+ attr_accessor :archived
58
+
54
59
  # Size of the file in bytes.
55
60
  attr_accessor :size
56
61
 
@@ -100,6 +105,8 @@ module Hubspot
100
105
  :'extension' => :'extension',
101
106
  :'access' => :'access',
102
107
  :'parent_folder_id' => :'parentFolderId',
108
+ :'source_group' => :'sourceGroup',
109
+ :'file_md5' => :'fileMd5',
103
110
  :'encoding' => :'encoding',
104
111
  :'type' => :'type',
105
112
  :'is_usable_in_content' => :'isUsableInContent',
@@ -107,8 +114,8 @@ module Hubspot
107
114
  :'expires_at' => :'expiresAt',
108
115
  :'created_at' => :'createdAt',
109
116
  :'archived_at' => :'archivedAt',
110
- :'archived' => :'archived',
111
117
  :'path' => :'path',
118
+ :'archived' => :'archived',
112
119
  :'size' => :'size',
113
120
  :'name' => :'name',
114
121
  :'width' => :'width',
@@ -130,6 +137,8 @@ module Hubspot
130
137
  :'extension' => :'String',
131
138
  :'access' => :'String',
132
139
  :'parent_folder_id' => :'String',
140
+ :'source_group' => :'String',
141
+ :'file_md5' => :'String',
133
142
  :'encoding' => :'String',
134
143
  :'type' => :'String',
135
144
  :'is_usable_in_content' => :'Boolean',
@@ -137,8 +146,8 @@ module Hubspot
137
146
  :'expires_at' => :'Integer',
138
147
  :'created_at' => :'Time',
139
148
  :'archived_at' => :'Time',
140
- :'archived' => :'Boolean',
141
149
  :'path' => :'String',
150
+ :'archived' => :'Boolean',
142
151
  :'size' => :'Integer',
143
152
  :'name' => :'String',
144
153
  :'width' => :'Integer',
@@ -182,6 +191,14 @@ module Hubspot
182
191
  self.parent_folder_id = attributes[:'parent_folder_id']
183
192
  end
184
193
 
194
+ if attributes.key?(:'source_group')
195
+ self.source_group = attributes[:'source_group']
196
+ end
197
+
198
+ if attributes.key?(:'file_md5')
199
+ self.file_md5 = attributes[:'file_md5']
200
+ end
201
+
185
202
  if attributes.key?(:'encoding')
186
203
  self.encoding = attributes[:'encoding']
187
204
  end
@@ -210,14 +227,14 @@ module Hubspot
210
227
  self.archived_at = attributes[:'archived_at']
211
228
  end
212
229
 
213
- if attributes.key?(:'archived')
214
- self.archived = attributes[:'archived']
215
- end
216
-
217
230
  if attributes.key?(:'path')
218
231
  self.path = attributes[:'path']
219
232
  end
220
233
 
234
+ if attributes.key?(:'archived')
235
+ self.archived = attributes[:'archived']
236
+ end
237
+
221
238
  if attributes.key?(:'size')
222
239
  self.size = attributes[:'size']
223
240
  end
@@ -278,7 +295,7 @@ module Hubspot
278
295
  # @return true if the model is valid
279
296
  def valid?
280
297
  return false if @access.nil?
281
- access_validator = EnumAttributeValidator.new('String', ["PUBLIC_INDEXABLE", "PUBLIC_NOT_INDEXABLE", "HIDDEN_INDEXABLE", "HIDDEN_NOT_INDEXABLE", "HIDDEN_PRIVATE", "PRIVATE"])
298
+ access_validator = EnumAttributeValidator.new('String', ["PUBLIC_INDEXABLE", "PUBLIC_NOT_INDEXABLE", "HIDDEN_INDEXABLE", "HIDDEN_NOT_INDEXABLE", "HIDDEN_PRIVATE", "PRIVATE", "HIDDEN_SENSITIVE", "SENSITIVE"])
282
299
  return false unless access_validator.valid?(@access)
283
300
  return false if @created_at.nil?
284
301
  return false if @archived.nil?
@@ -290,7 +307,7 @@ module Hubspot
290
307
  # Custom attribute writer method checking allowed values (enum).
291
308
  # @param [Object] access Object to be assigned
292
309
  def access=(access)
293
- validator = EnumAttributeValidator.new('String', ["PUBLIC_INDEXABLE", "PUBLIC_NOT_INDEXABLE", "HIDDEN_INDEXABLE", "HIDDEN_NOT_INDEXABLE", "HIDDEN_PRIVATE", "PRIVATE"])
310
+ validator = EnumAttributeValidator.new('String', ["PUBLIC_INDEXABLE", "PUBLIC_NOT_INDEXABLE", "HIDDEN_INDEXABLE", "HIDDEN_NOT_INDEXABLE", "HIDDEN_PRIVATE", "PRIVATE", "HIDDEN_SENSITIVE", "SENSITIVE"])
294
311
  unless validator.valid?(access)
295
312
  fail ArgumentError, "invalid value for \"access\", must be one of #{validator.allowable_values}."
296
313
  end
@@ -305,6 +322,8 @@ module Hubspot
305
322
  extension == o.extension &&
306
323
  access == o.access &&
307
324
  parent_folder_id == o.parent_folder_id &&
325
+ source_group == o.source_group &&
326
+ file_md5 == o.file_md5 &&
308
327
  encoding == o.encoding &&
309
328
  type == o.type &&
310
329
  is_usable_in_content == o.is_usable_in_content &&
@@ -312,8 +331,8 @@ module Hubspot
312
331
  expires_at == o.expires_at &&
313
332
  created_at == o.created_at &&
314
333
  archived_at == o.archived_at &&
315
- archived == o.archived &&
316
334
  path == o.path &&
335
+ archived == o.archived &&
317
336
  size == o.size &&
318
337
  name == o.name &&
319
338
  width == o.width &&
@@ -332,7 +351,7 @@ module Hubspot
332
351
  # Calculates hash code according to all attributes.
333
352
  # @return [Integer] Hash code
334
353
  def hash
335
- [extension, access, parent_folder_id, encoding, type, is_usable_in_content, url, expires_at, created_at, archived_at, archived, path, size, name, width, id, default_hosting_url, updated_at, height].hash
354
+ [extension, access, parent_folder_id, source_group, file_md5, encoding, type, is_usable_in_content, url, expires_at, created_at, archived_at, path, archived, size, name, width, id, default_hosting_url, updated_at, height].hash
336
355
  end
337
356
 
338
357
  # Builds the object from hash
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5
 
@@ -1,5 +1,5 @@
1
1
  =begin
2
- #Files Files
2
+ #Files
3
3
 
4
4
  #Upload and manage files.
5
5