hubspot-api-client 16.0.4 → 16.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (64) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +13 -1
  3. data/Gemfile.lock +1 -1
  4. data/lib/hubspot/codegen/crm/objects/postal_mail/api/associations_api.rb +264 -0
  5. data/lib/hubspot/codegen/crm/objects/postal_mail/api/basic_api.rb +391 -0
  6. data/lib/hubspot/codegen/crm/objects/postal_mail/api/batch_api.rb +295 -0
  7. data/lib/hubspot/codegen/crm/objects/postal_mail/api/public_object_api.rb +94 -0
  8. data/lib/hubspot/codegen/crm/objects/postal_mail/api/search_api.rb +92 -0
  9. data/lib/hubspot/codegen/crm/objects/postal_mail/api_client.rb +412 -0
  10. data/lib/hubspot/codegen/crm/objects/postal_mail/api_error.rb +63 -0
  11. data/lib/hubspot/codegen/crm/objects/postal_mail/configuration.rb +296 -0
  12. data/lib/hubspot/codegen/crm/objects/postal_mail/models/associated_id.rb +244 -0
  13. data/lib/hubspot/codegen/crm/objects/postal_mail/models/association_spec.rb +278 -0
  14. data/lib/hubspot/codegen/crm/objects/postal_mail/models/association_spec_with_label.rb +287 -0
  15. data/lib/hubspot/codegen/crm/objects/postal_mail/models/batch_input_simple_public_object_batch_input.rb +232 -0
  16. data/lib/hubspot/codegen/crm/objects/postal_mail/models/batch_input_simple_public_object_id.rb +232 -0
  17. data/lib/hubspot/codegen/crm/objects/postal_mail/models/batch_input_simple_public_object_input.rb +232 -0
  18. data/lib/hubspot/codegen/crm/objects/postal_mail/models/batch_read_input_simple_public_object_id.rb +273 -0
  19. data/lib/hubspot/codegen/crm/objects/postal_mail/models/batch_response_simple_public_object.rb +328 -0
  20. data/lib/hubspot/codegen/crm/objects/postal_mail/models/batch_response_simple_public_object_with_errors.rb +348 -0
  21. data/lib/hubspot/codegen/crm/objects/postal_mail/models/collection_response_associated_id.rb +241 -0
  22. data/lib/hubspot/codegen/crm/objects/postal_mail/models/collection_response_multi_associated_object_with_label_forward_paging.rb +241 -0
  23. data/lib/hubspot/codegen/crm/objects/postal_mail/models/collection_response_simple_public_object_with_associations_forward_paging.rb +241 -0
  24. data/lib/hubspot/codegen/crm/objects/postal_mail/models/collection_response_with_total_simple_public_object_forward_paging.rb +255 -0
  25. data/lib/hubspot/codegen/crm/objects/postal_mail/models/error.rb +307 -0
  26. data/lib/hubspot/codegen/crm/objects/postal_mail/models/error_category.rb +278 -0
  27. data/lib/hubspot/codegen/crm/objects/postal_mail/models/error_detail.rb +273 -0
  28. data/lib/hubspot/codegen/crm/objects/postal_mail/models/filter.rb +299 -0
  29. data/lib/hubspot/codegen/crm/objects/postal_mail/models/filter_group.rb +232 -0
  30. data/lib/hubspot/codegen/crm/objects/postal_mail/models/forward_paging.rb +225 -0
  31. data/lib/hubspot/codegen/crm/objects/postal_mail/models/labels_between_object_pair.rb +288 -0
  32. data/lib/hubspot/codegen/crm/objects/postal_mail/models/multi_associated_object_with_label.rb +246 -0
  33. data/lib/hubspot/codegen/crm/objects/postal_mail/models/next_page.rb +239 -0
  34. data/lib/hubspot/codegen/crm/objects/postal_mail/models/paging.rb +234 -0
  35. data/lib/hubspot/codegen/crm/objects/postal_mail/models/previous_page.rb +239 -0
  36. data/lib/hubspot/codegen/crm/objects/postal_mail/models/public_merge_input.rb +244 -0
  37. data/lib/hubspot/codegen/crm/objects/postal_mail/models/public_object_search_request.rb +301 -0
  38. data/lib/hubspot/codegen/crm/objects/postal_mail/models/simple_public_object.rb +303 -0
  39. data/lib/hubspot/codegen/crm/objects/postal_mail/models/simple_public_object_batch_input.rb +246 -0
  40. data/lib/hubspot/codegen/crm/objects/postal_mail/models/simple_public_object_id.rb +230 -0
  41. data/lib/hubspot/codegen/crm/objects/postal_mail/models/simple_public_object_input.rb +232 -0
  42. data/lib/hubspot/codegen/crm/objects/postal_mail/models/simple_public_object_with_associations.rb +314 -0
  43. data/lib/hubspot/codegen/crm/objects/postal_mail/models/standard_error.rb +324 -0
  44. data/lib/hubspot/codegen/crm/objects/postal_mail/models/value_with_timestamp.rb +285 -0
  45. data/lib/hubspot/codegen/marketing/events/models/property_value.rb +13 -4
  46. data/lib/hubspot/discovery/crm/objects/client.rb +1 -0
  47. data/lib/hubspot/discovery/crm/objects/postal_mail/api/associations_api.rb +15 -0
  48. data/lib/hubspot/discovery/crm/objects/postal_mail/api/basic_api.rb +15 -0
  49. data/lib/hubspot/discovery/crm/objects/postal_mail/api/batch_api.rb +15 -0
  50. data/lib/hubspot/discovery/crm/objects/postal_mail/api/public_object_api.rb +15 -0
  51. data/lib/hubspot/discovery/crm/objects/postal_mail/api/search_api.rb +15 -0
  52. data/lib/hubspot/discovery/crm/objects/postal_mail/client.rb +25 -0
  53. data/lib/hubspot/discovery/crm/pipelines/api/pipeline_audits_api.rb +13 -0
  54. data/lib/hubspot/discovery/crm/pipelines/api/pipeline_stage_audits_api.rb +13 -0
  55. data/lib/hubspot/discovery/crm/pipelines/client.rb +2 -0
  56. data/lib/hubspot/version.rb +1 -1
  57. data/spec/discovery/crm/objects/postal_mail/associations_api_spec.rb +9 -0
  58. data/spec/discovery/crm/objects/postal_mail/basic_api_spec.rb +10 -0
  59. data/spec/discovery/crm/objects/postal_mail/batch_api_spec.rb +10 -0
  60. data/spec/discovery/crm/objects/postal_mail/public_object_api_spec.rb +7 -0
  61. data/spec/discovery/crm/objects/postal_mail/search_api_spec.rb +7 -0
  62. data/spec/discovery/crm/pipelines/pipeline_audits_api_spec.rb +8 -0
  63. data/spec/discovery/crm/pipelines/pipeline_stage_audits_api_spec.rb +8 -0
  64. metadata +66 -3
@@ -0,0 +1,295 @@
1
+ =begin
2
+ #Postal Mail
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 Objects
18
+ module PostalMail
19
+ class BatchApi
20
+ attr_accessor :api_client
21
+
22
+ def initialize(api_client = ApiClient.default)
23
+ @api_client = api_client
24
+ end
25
+ # Archive a batch of postal mail by ID
26
+ # @param batch_input_simple_public_object_id [BatchInputSimplePublicObjectId]
27
+ # @param [Hash] opts the optional parameters
28
+ # @return [nil]
29
+ def archive(batch_input_simple_public_object_id, opts = {})
30
+ archive_with_http_info(batch_input_simple_public_object_id, opts)
31
+ nil
32
+ end
33
+
34
+ # Archive a batch of postal mail by ID
35
+ # @param batch_input_simple_public_object_id [BatchInputSimplePublicObjectId]
36
+ # @param [Hash] opts the optional parameters
37
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
38
+ def archive_with_http_info(batch_input_simple_public_object_id, opts = {})
39
+ if @api_client.config.debugging
40
+ @api_client.config.logger.debug 'Calling API: BatchApi.archive ...'
41
+ end
42
+ # verify the required parameter 'batch_input_simple_public_object_id' is set
43
+ if @api_client.config.client_side_validation && batch_input_simple_public_object_id.nil?
44
+ fail ArgumentError, "Missing the required parameter 'batch_input_simple_public_object_id' when calling BatchApi.archive"
45
+ end
46
+ # resource path
47
+ local_var_path = '/crm/v3/objects/postal_mail/batch/archive'
48
+
49
+ # query parameters
50
+ query_params = opts[:query_params] || {}
51
+
52
+ # header parameters
53
+ header_params = opts[:header_params] || {}
54
+ # HTTP header 'Accept' (if needed)
55
+ header_params['Accept'] = @api_client.select_header_accept(['*/*'])
56
+ # HTTP header 'Content-Type'
57
+ content_type = @api_client.select_header_content_type(['application/json'])
58
+ if !content_type.nil?
59
+ header_params['Content-Type'] = content_type
60
+ end
61
+
62
+ # form parameters
63
+ form_params = opts[:form_params] || {}
64
+
65
+ # http body (model)
66
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(batch_input_simple_public_object_id)
67
+
68
+ # return_type
69
+ return_type = opts[:debug_return_type]
70
+
71
+ # auth_names
72
+ auth_names = opts[:debug_auth_names] || ['hapikey', 'oauth2']
73
+
74
+ new_options = opts.merge(
75
+ :operation => :"BatchApi.archive",
76
+ :header_params => header_params,
77
+ :query_params => query_params,
78
+ :form_params => form_params,
79
+ :body => post_body,
80
+ :auth_names => auth_names,
81
+ :return_type => return_type
82
+ )
83
+
84
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
85
+ if @api_client.config.debugging
86
+ @api_client.config.logger.debug "API called: BatchApi#archive\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
87
+ end
88
+ return data, status_code, headers
89
+ end
90
+
91
+ # Create a batch of postal mail
92
+ # @param batch_input_simple_public_object_input [BatchInputSimplePublicObjectInput]
93
+ # @param [Hash] opts the optional parameters
94
+ # @return [BatchResponseSimplePublicObject]
95
+ def create(batch_input_simple_public_object_input, opts = {})
96
+ data, _status_code, _headers = create_with_http_info(batch_input_simple_public_object_input, opts)
97
+ data
98
+ end
99
+
100
+ # Create a batch of postal mail
101
+ # @param batch_input_simple_public_object_input [BatchInputSimplePublicObjectInput]
102
+ # @param [Hash] opts the optional parameters
103
+ # @return [Array<(BatchResponseSimplePublicObject, Integer, Hash)>] BatchResponseSimplePublicObject data, response status code and response headers
104
+ def create_with_http_info(batch_input_simple_public_object_input, opts = {})
105
+ if @api_client.config.debugging
106
+ @api_client.config.logger.debug 'Calling API: BatchApi.create ...'
107
+ end
108
+ # verify the required parameter 'batch_input_simple_public_object_input' is set
109
+ if @api_client.config.client_side_validation && batch_input_simple_public_object_input.nil?
110
+ fail ArgumentError, "Missing the required parameter 'batch_input_simple_public_object_input' when calling BatchApi.create"
111
+ end
112
+ # resource path
113
+ local_var_path = '/crm/v3/objects/postal_mail/batch/create'
114
+
115
+ # query parameters
116
+ query_params = opts[:query_params] || {}
117
+
118
+ # header parameters
119
+ header_params = opts[:header_params] || {}
120
+ # HTTP header 'Accept' (if needed)
121
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
122
+ # HTTP header 'Content-Type'
123
+ content_type = @api_client.select_header_content_type(['application/json'])
124
+ if !content_type.nil?
125
+ header_params['Content-Type'] = content_type
126
+ end
127
+
128
+ # form parameters
129
+ form_params = opts[:form_params] || {}
130
+
131
+ # http body (model)
132
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(batch_input_simple_public_object_input)
133
+
134
+ # return_type
135
+ return_type = opts[:debug_return_type] || 'BatchResponseSimplePublicObject'
136
+
137
+ # auth_names
138
+ auth_names = opts[:debug_auth_names] || ['hapikey', 'oauth2']
139
+
140
+ new_options = opts.merge(
141
+ :operation => :"BatchApi.create",
142
+ :header_params => header_params,
143
+ :query_params => query_params,
144
+ :form_params => form_params,
145
+ :body => post_body,
146
+ :auth_names => auth_names,
147
+ :return_type => return_type
148
+ )
149
+
150
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
151
+ if @api_client.config.debugging
152
+ @api_client.config.logger.debug "API called: BatchApi#create\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
153
+ end
154
+ return data, status_code, headers
155
+ end
156
+
157
+ # Read a batch of postal mail by internal ID, or unique property values
158
+ # @param batch_read_input_simple_public_object_id [BatchReadInputSimplePublicObjectId]
159
+ # @param [Hash] opts the optional parameters
160
+ # @option opts [Boolean] :archived Whether to return only results that have been archived. (default to false)
161
+ # @return [BatchResponseSimplePublicObject]
162
+ def read(batch_read_input_simple_public_object_id, opts = {})
163
+ data, _status_code, _headers = read_with_http_info(batch_read_input_simple_public_object_id, opts)
164
+ data
165
+ end
166
+
167
+ # Read a batch of postal mail by internal ID, or unique property values
168
+ # @param batch_read_input_simple_public_object_id [BatchReadInputSimplePublicObjectId]
169
+ # @param [Hash] opts the optional parameters
170
+ # @option opts [Boolean] :archived Whether to return only results that have been archived. (default to false)
171
+ # @return [Array<(BatchResponseSimplePublicObject, Integer, Hash)>] BatchResponseSimplePublicObject data, response status code and response headers
172
+ def read_with_http_info(batch_read_input_simple_public_object_id, opts = {})
173
+ if @api_client.config.debugging
174
+ @api_client.config.logger.debug 'Calling API: BatchApi.read ...'
175
+ end
176
+ # verify the required parameter 'batch_read_input_simple_public_object_id' is set
177
+ if @api_client.config.client_side_validation && batch_read_input_simple_public_object_id.nil?
178
+ fail ArgumentError, "Missing the required parameter 'batch_read_input_simple_public_object_id' when calling BatchApi.read"
179
+ end
180
+ # resource path
181
+ local_var_path = '/crm/v3/objects/postal_mail/batch/read'
182
+
183
+ # query parameters
184
+ query_params = opts[:query_params] || {}
185
+ query_params[:'archived'] = opts[:'archived'] if !opts[:'archived'].nil?
186
+
187
+ # header parameters
188
+ header_params = opts[:header_params] || {}
189
+ # HTTP header 'Accept' (if needed)
190
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
191
+ # HTTP header 'Content-Type'
192
+ content_type = @api_client.select_header_content_type(['application/json'])
193
+ if !content_type.nil?
194
+ header_params['Content-Type'] = content_type
195
+ end
196
+
197
+ # form parameters
198
+ form_params = opts[:form_params] || {}
199
+
200
+ # http body (model)
201
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(batch_read_input_simple_public_object_id)
202
+
203
+ # return_type
204
+ return_type = opts[:debug_return_type] || 'BatchResponseSimplePublicObject'
205
+
206
+ # auth_names
207
+ auth_names = opts[:debug_auth_names] || ['hapikey', 'oauth2']
208
+
209
+ new_options = opts.merge(
210
+ :operation => :"BatchApi.read",
211
+ :header_params => header_params,
212
+ :query_params => query_params,
213
+ :form_params => form_params,
214
+ :body => post_body,
215
+ :auth_names => auth_names,
216
+ :return_type => return_type
217
+ )
218
+
219
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
220
+ if @api_client.config.debugging
221
+ @api_client.config.logger.debug "API called: BatchApi#read\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
222
+ end
223
+ return data, status_code, headers
224
+ end
225
+
226
+ # Update a batch of postal mail
227
+ # @param batch_input_simple_public_object_batch_input [BatchInputSimplePublicObjectBatchInput]
228
+ # @param [Hash] opts the optional parameters
229
+ # @return [BatchResponseSimplePublicObject]
230
+ def update(batch_input_simple_public_object_batch_input, opts = {})
231
+ data, _status_code, _headers = update_with_http_info(batch_input_simple_public_object_batch_input, opts)
232
+ data
233
+ end
234
+
235
+ # Update a batch of postal mail
236
+ # @param batch_input_simple_public_object_batch_input [BatchInputSimplePublicObjectBatchInput]
237
+ # @param [Hash] opts the optional parameters
238
+ # @return [Array<(BatchResponseSimplePublicObject, Integer, Hash)>] BatchResponseSimplePublicObject data, response status code and response headers
239
+ def update_with_http_info(batch_input_simple_public_object_batch_input, opts = {})
240
+ if @api_client.config.debugging
241
+ @api_client.config.logger.debug 'Calling API: BatchApi.update ...'
242
+ end
243
+ # verify the required parameter 'batch_input_simple_public_object_batch_input' is set
244
+ if @api_client.config.client_side_validation && batch_input_simple_public_object_batch_input.nil?
245
+ fail ArgumentError, "Missing the required parameter 'batch_input_simple_public_object_batch_input' when calling BatchApi.update"
246
+ end
247
+ # resource path
248
+ local_var_path = '/crm/v3/objects/postal_mail/batch/update'
249
+
250
+ # query parameters
251
+ query_params = opts[:query_params] || {}
252
+
253
+ # header parameters
254
+ header_params = opts[:header_params] || {}
255
+ # HTTP header 'Accept' (if needed)
256
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
257
+ # HTTP header 'Content-Type'
258
+ content_type = @api_client.select_header_content_type(['application/json'])
259
+ if !content_type.nil?
260
+ header_params['Content-Type'] = content_type
261
+ end
262
+
263
+ # form parameters
264
+ form_params = opts[:form_params] || {}
265
+
266
+ # http body (model)
267
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(batch_input_simple_public_object_batch_input)
268
+
269
+ # return_type
270
+ return_type = opts[:debug_return_type] || 'BatchResponseSimplePublicObject'
271
+
272
+ # auth_names
273
+ auth_names = opts[:debug_auth_names] || ['hapikey', 'oauth2']
274
+
275
+ new_options = opts.merge(
276
+ :operation => :"BatchApi.update",
277
+ :header_params => header_params,
278
+ :query_params => query_params,
279
+ :form_params => form_params,
280
+ :body => post_body,
281
+ :auth_names => auth_names,
282
+ :return_type => return_type
283
+ )
284
+
285
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
286
+ if @api_client.config.debugging
287
+ @api_client.config.logger.debug "API called: BatchApi#update\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
288
+ end
289
+ return data, status_code, headers
290
+ end
291
+ end
292
+ end
293
+ end
294
+ end
295
+ end
@@ -0,0 +1,94 @@
1
+ =begin
2
+ #Postal Mail
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 Objects
18
+ module PostalMail
19
+ class PublicObjectApi
20
+ attr_accessor :api_client
21
+
22
+ def initialize(api_client = ApiClient.default)
23
+ @api_client = api_client
24
+ end
25
+ # Merge two postal mail with same type
26
+ # @param public_merge_input [PublicMergeInput]
27
+ # @param [Hash] opts the optional parameters
28
+ # @return [SimplePublicObject]
29
+ def merge(public_merge_input, opts = {})
30
+ data, _status_code, _headers = merge_with_http_info(public_merge_input, opts)
31
+ data
32
+ end
33
+
34
+ # Merge two postal mail with same type
35
+ # @param public_merge_input [PublicMergeInput]
36
+ # @param [Hash] opts the optional parameters
37
+ # @return [Array<(SimplePublicObject, Integer, Hash)>] SimplePublicObject data, response status code and response headers
38
+ def merge_with_http_info(public_merge_input, opts = {})
39
+ if @api_client.config.debugging
40
+ @api_client.config.logger.debug 'Calling API: PublicObjectApi.merge ...'
41
+ end
42
+ # verify the required parameter 'public_merge_input' is set
43
+ if @api_client.config.client_side_validation && public_merge_input.nil?
44
+ fail ArgumentError, "Missing the required parameter 'public_merge_input' when calling PublicObjectApi.merge"
45
+ end
46
+ # resource path
47
+ local_var_path = '/crm/v3/objects/postal_mail/merge'
48
+
49
+ # query parameters
50
+ query_params = opts[:query_params] || {}
51
+
52
+ # header parameters
53
+ header_params = opts[:header_params] || {}
54
+ # HTTP header 'Accept' (if needed)
55
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
56
+ # HTTP header 'Content-Type'
57
+ content_type = @api_client.select_header_content_type(['application/json'])
58
+ if !content_type.nil?
59
+ header_params['Content-Type'] = content_type
60
+ end
61
+
62
+ # form parameters
63
+ form_params = opts[:form_params] || {}
64
+
65
+ # http body (model)
66
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(public_merge_input)
67
+
68
+ # return_type
69
+ return_type = opts[:debug_return_type] || 'SimplePublicObject'
70
+
71
+ # auth_names
72
+ auth_names = opts[:debug_auth_names] || ['hapikey', 'oauth2']
73
+
74
+ new_options = opts.merge(
75
+ :operation => :"PublicObjectApi.merge",
76
+ :header_params => header_params,
77
+ :query_params => query_params,
78
+ :form_params => form_params,
79
+ :body => post_body,
80
+ :auth_names => auth_names,
81
+ :return_type => return_type
82
+ )
83
+
84
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
85
+ if @api_client.config.debugging
86
+ @api_client.config.logger.debug "API called: PublicObjectApi#merge\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
87
+ end
88
+ return data, status_code, headers
89
+ end
90
+ end
91
+ end
92
+ end
93
+ end
94
+ end
@@ -0,0 +1,92 @@
1
+ =begin
2
+ #Postal Mail
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 Objects
18
+ module PostalMail
19
+ class SearchApi
20
+ attr_accessor :api_client
21
+
22
+ def initialize(api_client = ApiClient.default)
23
+ @api_client = api_client
24
+ end
25
+ # @param public_object_search_request [PublicObjectSearchRequest]
26
+ # @param [Hash] opts the optional parameters
27
+ # @return [CollectionResponseWithTotalSimplePublicObjectForwardPaging]
28
+ def do_search(public_object_search_request, opts = {})
29
+ data, _status_code, _headers = do_search_with_http_info(public_object_search_request, opts)
30
+ data
31
+ end
32
+
33
+ # @param public_object_search_request [PublicObjectSearchRequest]
34
+ # @param [Hash] opts the optional parameters
35
+ # @return [Array<(CollectionResponseWithTotalSimplePublicObjectForwardPaging, Integer, Hash)>] CollectionResponseWithTotalSimplePublicObjectForwardPaging data, response status code and response headers
36
+ def do_search_with_http_info(public_object_search_request, opts = {})
37
+ if @api_client.config.debugging
38
+ @api_client.config.logger.debug 'Calling API: SearchApi.do_search ...'
39
+ end
40
+ # verify the required parameter 'public_object_search_request' is set
41
+ if @api_client.config.client_side_validation && public_object_search_request.nil?
42
+ fail ArgumentError, "Missing the required parameter 'public_object_search_request' when calling SearchApi.do_search"
43
+ end
44
+ # resource path
45
+ local_var_path = '/crm/v3/objects/postal_mail/search'
46
+
47
+ # query parameters
48
+ query_params = opts[:query_params] || {}
49
+
50
+ # header parameters
51
+ header_params = opts[:header_params] || {}
52
+ # HTTP header 'Accept' (if needed)
53
+ header_params['Accept'] = @api_client.select_header_accept(['application/json', '*/*'])
54
+ # HTTP header 'Content-Type'
55
+ content_type = @api_client.select_header_content_type(['application/json'])
56
+ if !content_type.nil?
57
+ header_params['Content-Type'] = content_type
58
+ end
59
+
60
+ # form parameters
61
+ form_params = opts[:form_params] || {}
62
+
63
+ # http body (model)
64
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(public_object_search_request)
65
+
66
+ # return_type
67
+ return_type = opts[:debug_return_type] || 'CollectionResponseWithTotalSimplePublicObjectForwardPaging'
68
+
69
+ # auth_names
70
+ auth_names = opts[:debug_auth_names] || ['hapikey', 'oauth2']
71
+
72
+ new_options = opts.merge(
73
+ :operation => :"SearchApi.do_search",
74
+ :header_params => header_params,
75
+ :query_params => query_params,
76
+ :form_params => form_params,
77
+ :body => post_body,
78
+ :auth_names => auth_names,
79
+ :return_type => return_type
80
+ )
81
+
82
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
83
+ if @api_client.config.debugging
84
+ @api_client.config.logger.debug "API called: SearchApi#do_search\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
85
+ end
86
+ return data, status_code, headers
87
+ end
88
+ end
89
+ end
90
+ end
91
+ end
92
+ end