Class: Phyllo::EngagementApi

Inherits:
Object
  • Object
show all
Defined in:
lib/phyllo/api/engagement_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ EngagementApi

Returns a new instance of EngagementApi.



17
18
19
# File 'lib/phyllo/api/engagement_api.rb', line 17

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



15
16
17
# File 'lib/phyllo/api/engagement_api.rb', line 15

def api_client
  @api_client
end

Instance Method Details

#postv1pubcontentssearch(opts = {}) ⇒ ContentSearchList1

Retrieve publication content items in bulk Search content items in bulk by providing the IDs. This is best used in combination with webhooks - you can directly take the IDs from "CONTENTS.ADDED" and "CONTENTS.UPDATED" webhook notifications and pass on to this API to get the updated content items.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:



26
27
28
29
# File 'lib/phyllo/api/engagement_api.rb', line 26

def postv1pubcontentssearch(opts = {})
  data, _status_code, _headers = postv1pubcontentssearch_with_http_info(opts)
  data
end

#postv1pubcontentssearch_with_http_info(opts = {}) ⇒ Array<(ContentSearchList1, Integer, Hash)>

Retrieve publication content items in bulk Search content items in bulk by providing the IDs. This is best used in combination with webhooks - you can directly take the IDs from &quot;CONTENTS.ADDED&quot; and &quot;CONTENTS.UPDATED&quot; webhook notifications and pass on to this API to get the updated content items.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<(ContentSearchList1, Integer, Hash)>)

    ContentSearchList1 data, response status code and response headers



36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# File 'lib/phyllo/api/engagement_api.rb', line 36

def postv1pubcontentssearch_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.postv1pubcontentssearch ..."
  end
  # resource path
  local_var_path = "/v1/publications/contents/search"

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(["application/json", "application/xml"])
  if !content_type.nil?
    header_params["Content-Type"] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:content_search1])

  # return_type
  return_type = opts[:debug_return_type] || "ContentSearchList1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.postv1pubcontentssearch",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#postv1pubcontentssearch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#postv1socialcontentgroupssearch(opts = {}) ⇒ ContentGroupSearchList1

Retrieve content group items in bulk Search content group items in bulk by providing the IDs. This is best used in combination with webhooks - you can directly take the IDs from "CONTENT-GROUPS.ADDED" and "CONTENT-GROUPS.UPDATED" webhook notifications and pass on to this API to get the updated content group items.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:



90
91
92
93
# File 'lib/phyllo/api/engagement_api.rb', line 90

def postv1socialcontentgroupssearch(opts = {})
  data, _status_code, _headers = postv1socialcontentgroupssearch_with_http_info(opts)
  data
end

#postv1socialcontentgroupssearch_with_http_info(opts = {}) ⇒ Array<(ContentGroupSearchList1, Integer, Hash)>

Retrieve content group items in bulk Search content group items in bulk by providing the IDs. This is best used in combination with webhooks - you can directly take the IDs from &quot;CONTENT-GROUPS.ADDED&quot; and &quot;CONTENT-GROUPS.UPDATED&quot; webhook notifications and pass on to this API to get the updated content group items.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<(ContentGroupSearchList1, Integer, Hash)>)

    ContentGroupSearchList1 data, response status code and response headers



100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
# File 'lib/phyllo/api/engagement_api.rb', line 100

def postv1socialcontentgroupssearch_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.postv1socialcontentgroupssearch ..."
  end
  # resource path
  local_var_path = "/v1/social/content-groups/search"

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(["application/json", "application/xml"])
  if !content_type.nil?
    header_params["Content-Type"] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:content_group_search1])

  # return_type
  return_type = opts[:debug_return_type] || "ContentGroupSearchList1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.postv1socialcontentgroupssearch",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#postv1socialcontentgroupssearch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#postv1socialcontentssearch(opts = {}) ⇒ ContentSearchList1

Retrieve content items in bulk Search content items in bulk by providing the IDs. This is best used in combination with webhooks - you can directly take the IDs from "CONTENTS.ADDED" and "CONTENTS.UPDATED" webhook notifications and pass on to this API to get the updated content items.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:



154
155
156
157
# File 'lib/phyllo/api/engagement_api.rb', line 154

def postv1socialcontentssearch(opts = {})
  data, _status_code, _headers = postv1socialcontentssearch_with_http_info(opts)
  data
end

#postv1socialcontentssearch_with_http_info(opts = {}) ⇒ Array<(ContentSearchList1, Integer, Hash)>

Retrieve content items in bulk Search content items in bulk by providing the IDs. This is best used in combination with webhooks - you can directly take the IDs from &quot;CONTENTS.ADDED&quot; and &quot;CONTENTS.UPDATED&quot; webhook notifications and pass on to this API to get the updated content items.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<(ContentSearchList1, Integer, Hash)>)

    ContentSearchList1 data, response status code and response headers



164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
# File 'lib/phyllo/api/engagement_api.rb', line 164

def postv1socialcontentssearch_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.postv1socialcontentssearch ..."
  end
  # resource path
  local_var_path = "/v1/social/contents/search"

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(["application/json", "application/xml"])
  if !content_type.nil?
    header_params["Content-Type"] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:content_search1])

  # return_type
  return_type = opts[:debug_return_type] || "ContentSearchList1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.postv1socialcontentssearch",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#postv1socialcontentssearch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_engagement_get_comments(account_id, content_id, opts = {}) ⇒ CommentResponse

Retrieve all comments Lists all comments of the given account.

Parameters:

  • account_id (String)

    Unique ID of the connected account.

  • content_id (String)

    Unique ID of the content item.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :limit (Integer)

    The number of objects to be returned. It can be between 1 to 100. The default value is 10. (default to 10)

  • :offset (Integer)

    The number of objects to skip. Use this argument for pagination. The default value is 0. (default to 0)

  • :to_date (Date)

    Return comments published on or before this date. (YYYY-MM-DD)

  • :from_date (Date)

    Return comments published on or after this date. (YYYY-MM-DD)

Returns:



223
224
225
226
# File 'lib/phyllo/api/engagement_api.rb', line 223

def v1_engagement_get_comments(, content_id, opts = {})
  data, _status_code, _headers = v1_engagement_get_comments_with_http_info(, content_id, opts)
  data
end

#v1_engagement_get_comments_with_http_info(account_id, content_id, opts = {}) ⇒ Array<(CommentResponse, Integer, Hash)>

Retrieve all comments Lists all comments of the given account.

Parameters:

  • account_id (String)

    Unique ID of the connected account.

  • content_id (String)

    Unique ID of the content item.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :limit (Integer)

    The number of objects to be returned. It can be between 1 to 100. The default value is 10. (default to 10)

  • :offset (Integer)

    The number of objects to skip. Use this argument for pagination. The default value is 0. (default to 0)

  • :to_date (Date)

    Return comments published on or before this date. (YYYY-MM-DD)

  • :from_date (Date)

    Return comments published on or after this date. (YYYY-MM-DD)

Returns:

  • (Array<(CommentResponse, Integer, Hash)>)

    CommentResponse data, response status code and response headers



238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
# File 'lib/phyllo/api/engagement_api.rb', line 238

def v1_engagement_get_comments_with_http_info(, content_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_engagement_get_comments ..."
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling EngagementApi.v1_engagement_get_comments"
  end
  # verify the required parameter 'content_id' is set
  if @api_client.config.client_side_validation && content_id.nil?
    fail ArgumentError, "Missing the required parameter 'content_id' when calling EngagementApi.v1_engagement_get_comments"
  end
  # resource path
  local_var_path = "/v1/social/comments"

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:account_id] = 
  query_params[:content_id] = content_id
  query_params[:limit] = opts[:limit] if !opts[:limit].nil?
  query_params[:offset] = opts[:offset] if !opts[:offset].nil?
  query_params[:to_date] = opts[:to_date] if !opts[:to_date].nil?
  query_params[:from_date] = opts[:from_date] if !opts[:from_date].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || "CommentResponse"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_engagement_get_comments",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_engagement_get_comments\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_fetch_historic_social_content_groups(opts = {}) ⇒ FetchHistoric1

Fetch historic content groups Fetch content groups for a connected account starting from a specific date till today by providing the ‘from_date`. Once Phyllo processes the request, you can fetch the updated content groups by calling the [retrieve content groups API](../reference/openapi.v1.yml/paths/~1v1~1social~1content-groups/get). Subscribe to the "CONTENT-GROUPS.ADDED" and "CONTENT-GROUPS.UPDATED" webhooks to receive a notification once the request is completed. With webhooks, you should use the [retrieve content groups in bulk API](../reference/openapi.v1.yml/paths/~1v1~1social~1content-groups~1search/post) for optimal performance.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:



301
302
303
304
# File 'lib/phyllo/api/engagement_api.rb', line 301

def v1_fetch_historic_social_content_groups(opts = {})
  data, _status_code, _headers = v1_fetch_historic_social_content_groups_with_http_info(opts)
  data
end

#v1_fetch_historic_social_content_groups_with_http_info(opts = {}) ⇒ Array<(FetchHistoric1, Integer, Hash)>

Fetch historic content groups Fetch content groups for a connected account starting from a specific date till today by providing the &#x60;from_date&#x60;. Once Phyllo processes the request, you can fetch the updated content groups by calling the [retrieve content groups API](../reference/openapi.v1.yml/paths/~1v1~1social~1content-groups/get). Subscribe to the &quot;CONTENT-GROUPS.ADDED&quot; and &quot;CONTENT-GROUPS.UPDATED&quot; webhooks to receive a notification once the request is completed. With webhooks, you should use the [retrieve content groups in bulk API](../reference/openapi.v1.yml/paths/~1v1~1social~1content-groups~1search/post) for optimal performance.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<(FetchHistoric1, Integer, Hash)>)

    FetchHistoric1 data, response status code and response headers



311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
# File 'lib/phyllo/api/engagement_api.rb', line 311

def v1_fetch_historic_social_content_groups_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_fetch_historic_social_content_groups ..."
  end
  # resource path
  local_var_path = "/v1/social/content-groups/fetch-historic"

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(["application/json"])
  if !content_type.nil?
    header_params["Content-Type"] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:fetch_historic1])

  # return_type
  return_type = opts[:debug_return_type] || "FetchHistoric1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_fetch_historic_social_content_groups",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_fetch_historic_social_content_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_fetch_historic_social_contents(opts = {}) ⇒ FetchHistoric1

Fetch historic content items Fetch content items for a connected account starting from a specific date till today by providing the ‘from_date`. Once Phyllo processes the request, you can fetch the updated content items by calling the [retrieve content API](../reference/openapi.v1.yml/paths/~1v1~1social~1contents/get). Subscribe to the "CONTENTS.ADDED" and "CONTENTS.UPDATED" webhooks to receive a notification once the request is completed. With webhooks, you should use the [retrieve content items in bulk API](../reference/openapi.v1.yml/paths/~1v1~1social~1contents~1search/post) for optimal performance.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:



365
366
367
368
# File 'lib/phyllo/api/engagement_api.rb', line 365

def v1_fetch_historic_social_contents(opts = {})
  data, _status_code, _headers = v1_fetch_historic_social_contents_with_http_info(opts)
  data
end

#v1_fetch_historic_social_contents_with_http_info(opts = {}) ⇒ Array<(FetchHistoric1, Integer, Hash)>

Fetch historic content items Fetch content items for a connected account starting from a specific date till today by providing the &#x60;from_date&#x60;. Once Phyllo processes the request, you can fetch the updated content items by calling the [retrieve content API](../reference/openapi.v1.yml/paths/~1v1~1social~1contents/get). Subscribe to the &quot;CONTENTS.ADDED&quot; and &quot;CONTENTS.UPDATED&quot; webhooks to receive a notification once the request is completed. With webhooks, you should use the [retrieve content items in bulk API](../reference/openapi.v1.yml/paths/~1v1~1social~1contents~1search/post) for optimal performance.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<(FetchHistoric1, Integer, Hash)>)

    FetchHistoric1 data, response status code and response headers



375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
# File 'lib/phyllo/api/engagement_api.rb', line 375

def v1_fetch_historic_social_contents_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_fetch_historic_social_contents ..."
  end
  # resource path
  local_var_path = "/v1/social/contents/fetch-historic"

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(["application/json", "application/xml"])
  if !content_type.nil?
    header_params["Content-Type"] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:fetch_historic1])

  # return_type
  return_type = opts[:debug_return_type] || "FetchHistoric1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_fetch_historic_social_contents",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_fetch_historic_social_contents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_refresh_social_content_groups(opts = {}) ⇒ Refresh1

Refresh content groups Refresh content groups for a connected account for the default refresh period, which is T-90 days for content groups. Once Phyllo processes the request, you can fetch the updated content items by calling the [retrieve content groups API](../reference/openapi.v1.yml/paths/~1v1~1social~1content-groups/get). Subscribe to the "CONTENT-GROUPS.ADDED" and "CONTENT-GROUPS.UPDATED" webhooks to receive a notification once the request is completed. With webhooks, you should use the [retrieve content groups in bulk API](../reference/openapi.v1.yml/paths/~1v1~1social~1content-groups~1search/post) for optimal performance.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:



429
430
431
432
# File 'lib/phyllo/api/engagement_api.rb', line 429

def v1_refresh_social_content_groups(opts = {})
  data, _status_code, _headers = v1_refresh_social_content_groups_with_http_info(opts)
  data
end

#v1_refresh_social_content_groups_with_http_info(opts = {}) ⇒ Array<(Refresh1, Integer, Hash)>

Refresh content groups Refresh content groups for a connected account for the default refresh period, which is T-90 days for content groups. Once Phyllo processes the request, you can fetch the updated content items by calling the [retrieve content groups API](../reference/openapi.v1.yml/paths/~1v1~1social~1content-groups/get). Subscribe to the &quot;CONTENT-GROUPS.ADDED&quot; and &quot;CONTENT-GROUPS.UPDATED&quot; webhooks to receive a notification once the request is completed. With webhooks, you should use the [retrieve content groups in bulk API](../reference/openapi.v1.yml/paths/~1v1~1social~1content-groups~1search/post) for optimal performance.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<(Refresh1, Integer, Hash)>)

    Refresh1 data, response status code and response headers



439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
# File 'lib/phyllo/api/engagement_api.rb', line 439

def v1_refresh_social_content_groups_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_refresh_social_content_groups ..."
  end
  # resource path
  local_var_path = "/v1/social/content-groups/refresh"

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(["application/json", "application/xml"])
  if !content_type.nil?
    header_params["Content-Type"] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:refresh1])

  # return_type
  return_type = opts[:debug_return_type] || "Refresh1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_refresh_social_content_groups",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_refresh_social_content_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_refresh_social_contents(opts = {}) ⇒ Refresh1

Refresh content items Refresh content items for a connected account for the default refresh period, which is T-90 days for content items. Once Phyllo processes the request, you can fetch the updated content items by calling the [retrieve content API](../reference/openapi.v1.yml/paths/~1v1~1social~1contents/get). Subscribe to the "CONTENTS.ADDED" and "CONTENTS.UPDATED" webhooks to receive a notification once the request is completed. With webhooks, you should use the [retrieve content items in bulk API](../reference/openapi.v1.yml/paths/~1v1~1social~1contents~1search/post) for optimal performance.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:



493
494
495
496
# File 'lib/phyllo/api/engagement_api.rb', line 493

def v1_refresh_social_contents(opts = {})
  data, _status_code, _headers = v1_refresh_social_contents_with_http_info(opts)
  data
end

#v1_refresh_social_contents_with_http_info(opts = {}) ⇒ Array<(Refresh1, Integer, Hash)>

Refresh content items Refresh content items for a connected account for the default refresh period, which is T-90 days for content items. Once Phyllo processes the request, you can fetch the updated content items by calling the [retrieve content API](../reference/openapi.v1.yml/paths/~1v1~1social~1contents/get). Subscribe to the &quot;CONTENTS.ADDED&quot; and &quot;CONTENTS.UPDATED&quot; webhooks to receive a notification once the request is completed. With webhooks, you should use the [retrieve content items in bulk API](../reference/openapi.v1.yml/paths/~1v1~1social~1contents~1search/post) for optimal performance.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<(Refresh1, Integer, Hash)>)

    Refresh1 data, response status code and response headers



503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
# File 'lib/phyllo/api/engagement_api.rb', line 503

def v1_refresh_social_contents_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_refresh_social_contents ..."
  end
  # resource path
  local_var_path = "/v1/social/contents/refresh"

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])
  # HTTP header 'Content-Type'
  content_type = @api_client.select_header_content_type(["application/json", "application/xml"])
  if !content_type.nil?
    header_params["Content-Type"] = content_type
  end

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body] || @api_client.object_to_http_body(opts[:refresh1])

  # return_type
  return_type = opts[:debug_return_type] || "Refresh1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_refresh_social_contents",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_refresh_social_contents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_stream_get_content_groups(account_id, opts = {}) ⇒ ContentGroupList1

Retrieve all content groups Returns all Content Groups objects.

Parameters:

  • account_id (String)

    Unique ID of the connected account.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The number of objects to skip. Use this argument for pagination. The default value is 0. (default to 0)

  • :limit (Integer)

    The number of objects to be returned. It can be between 1 to 100. The default value is 10. (default to 10)

  • :from_date (Date)

    Return content items published on or after this date. (YYYY-MM-DD)

  • :to_date (Date)

    Return content items published on or before this date. (YYYY-MM-DD)

Returns:



561
562
563
564
# File 'lib/phyllo/api/engagement_api.rb', line 561

def v1_stream_get_content_groups(, opts = {})
  data, _status_code, _headers = v1_stream_get_content_groups_with_http_info(, opts)
  data
end

#v1_stream_get_content_groups_by_id(id, opts = {}) ⇒ ContentGroup1

Retrieve a content group Retrieve the information of the Content Group with the supplied Content Group id.

Parameters:

  • id (String)

    Unique identifier for the content group

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:



633
634
635
636
# File 'lib/phyllo/api/engagement_api.rb', line 633

def v1_stream_get_content_groups_by_id(id, opts = {})
  data, _status_code, _headers = v1_stream_get_content_groups_by_id_with_http_info(id, opts)
  data
end

#v1_stream_get_content_groups_by_id_with_http_info(id, opts = {}) ⇒ Array<(ContentGroup1, Integer, Hash)>

Retrieve a content group Retrieve the information of the Content Group with the supplied Content Group id.

Parameters:

  • id (String)

    Unique identifier for the content group

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(ContentGroup1, Integer, Hash)>)

    ContentGroup1 data, response status code and response headers



643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
# File 'lib/phyllo/api/engagement_api.rb', line 643

def v1_stream_get_content_groups_by_id_with_http_info(id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_stream_get_content_groups_by_id ..."
  end
  # verify the required parameter 'id' is set
  if @api_client.config.client_side_validation && id.nil?
    fail ArgumentError, "Missing the required parameter 'id' when calling EngagementApi.v1_stream_get_content_groups_by_id"
  end
  # resource path
  local_var_path = "/v1/social/content-groups/{id}".sub("{" + "id" + "}", CGI.escape(id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || "ContentGroup1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_stream_get_content_groups_by_id",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_stream_get_content_groups_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_stream_get_content_groups_with_http_info(account_id, opts = {}) ⇒ Array<(ContentGroupList1, Integer, Hash)>

Retrieve all content groups Returns all Content Groups objects.

Parameters:

  • account_id (String)

    Unique ID of the connected account.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The number of objects to skip. Use this argument for pagination. The default value is 0. (default to 0)

  • :limit (Integer)

    The number of objects to be returned. It can be between 1 to 100. The default value is 10. (default to 10)

  • :from_date (Date)

    Return content items published on or after this date. (YYYY-MM-DD)

  • :to_date (Date)

    Return content items published on or before this date. (YYYY-MM-DD)

Returns:

  • (Array<(ContentGroupList1, Integer, Hash)>)

    ContentGroupList1 data, response status code and response headers



575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
# File 'lib/phyllo/api/engagement_api.rb', line 575

def v1_stream_get_content_groups_with_http_info(, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_stream_get_content_groups ..."
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling EngagementApi.v1_stream_get_content_groups"
  end
  # resource path
  local_var_path = "/v1/social/content-groups"

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:account_id] = 
  query_params[:offset] = opts[:offset] if !opts[:offset].nil?
  query_params[:limit] = opts[:limit] if !opts[:limit].nil?
  query_params[:from_date] = opts[:from_date] if !opts[:from_date].nil?
  query_params[:to_date] = opts[:to_date] if !opts[:to_date].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || "ContentGroupList1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_stream_get_content_groups",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_stream_get_content_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_stream_get_contents(account_id, opts = {}) ⇒ ContentList1

Retrieve all content items Lists all Contents.

Parameters:

  • account_id (String)

    Unique ID of the connected account.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The number of objects to skip. Use this argument for pagination. The default value is 0. (default to 0)

  • :limit (Integer)

    The number of objects to be returned. It can be between 1 to 100. The default value is 10. (default to 10)

  • :from_date (Date)

    Return content items published on or after this date. (YYYY-MM-DD)

  • :to_date (Date)

    Return content items published on or before this date. (YYYY-MM-DD)

Returns:



700
701
702
703
# File 'lib/phyllo/api/engagement_api.rb', line 700

def v1_stream_get_contents(, opts = {})
  data, _status_code, _headers = v1_stream_get_contents_with_http_info(, opts)
  data
end

#v1_stream_get_contents_by_id(id, opts = {}) ⇒ Content1

Retrieve a content item Retrieve the information of the Content with the supplied Content id.

Parameters:

  • id (String)

    Unique identifier for the content

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:



772
773
774
775
# File 'lib/phyllo/api/engagement_api.rb', line 772

def v1_stream_get_contents_by_id(id, opts = {})
  data, _status_code, _headers = v1_stream_get_contents_by_id_with_http_info(id, opts)
  data
end

#v1_stream_get_contents_by_id_with_http_info(id, opts = {}) ⇒ Array<(Content1, Integer, Hash)>

Retrieve a content item Retrieve the information of the Content with the supplied Content id.

Parameters:

  • id (String)

    Unique identifier for the content

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Content1, Integer, Hash)>)

    Content1 data, response status code and response headers



782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
# File 'lib/phyllo/api/engagement_api.rb', line 782

def v1_stream_get_contents_by_id_with_http_info(id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_stream_get_contents_by_id ..."
  end
  # verify the required parameter 'id' is set
  if @api_client.config.client_side_validation && id.nil?
    fail ArgumentError, "Missing the required parameter 'id' when calling EngagementApi.v1_stream_get_contents_by_id"
  end
  # resource path
  local_var_path = "/v1/social/contents/{id}".sub("{" + "id" + "}", CGI.escape(id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || "Content1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_stream_get_contents_by_id",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_stream_get_contents_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_stream_get_contents_with_http_info(account_id, opts = {}) ⇒ Array<(ContentList1, Integer, Hash)>

Retrieve all content items Lists all Contents.

Parameters:

  • account_id (String)

    Unique ID of the connected account.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The number of objects to skip. Use this argument for pagination. The default value is 0. (default to 0)

  • :limit (Integer)

    The number of objects to be returned. It can be between 1 to 100. The default value is 10. (default to 10)

  • :from_date (Date)

    Return content items published on or after this date. (YYYY-MM-DD)

  • :to_date (Date)

    Return content items published on or before this date. (YYYY-MM-DD)

Returns:

  • (Array<(ContentList1, Integer, Hash)>)

    ContentList1 data, response status code and response headers



714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
# File 'lib/phyllo/api/engagement_api.rb', line 714

def v1_stream_get_contents_with_http_info(, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_stream_get_contents ..."
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling EngagementApi.v1_stream_get_contents"
  end
  # resource path
  local_var_path = "/v1/social/contents"

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:account_id] = 
  query_params[:offset] = opts[:offset] if !opts[:offset].nil?
  query_params[:limit] = opts[:limit] if !opts[:limit].nil?
  query_params[:from_date] = opts[:from_date] if !opts[:from_date].nil?
  query_params[:to_date] = opts[:to_date] if !opts[:to_date].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || "ContentList1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_stream_get_contents",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_stream_get_contents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_streampub_get_contents(account_id, opts = {}) ⇒ ContentList1

Retrieve all publication content items Lists all publication posts.

Parameters:

  • account_id (String)

    Unique ID of the connected account.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The number of objects to skip. Use this argument for pagination. The default value is 0. (default to 0)

  • :limit (Integer)

    The number of objects to be returned. It can be between 1 to 100. The default value is 10. (default to 10)

Returns:



837
838
839
840
# File 'lib/phyllo/api/engagement_api.rb', line 837

def v1_streampub_get_contents(, opts = {})
  data, _status_code, _headers = v1_streampub_get_contents_with_http_info(, opts)
  data
end

#v1_streampub_get_contents_by_id(id, opts = {}) ⇒ Content1

Retrieve a publication content item Retrieve the engagement information of the newsletter publication with the supplied content id.

Parameters:

  • id (String)

    Unique identifier for the content

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:



905
906
907
908
# File 'lib/phyllo/api/engagement_api.rb', line 905

def v1_streampub_get_contents_by_id(id, opts = {})
  data, _status_code, _headers = v1_streampub_get_contents_by_id_with_http_info(id, opts)
  data
end

#v1_streampub_get_contents_by_id_with_http_info(id, opts = {}) ⇒ Array<(Content1, Integer, Hash)>

Retrieve a publication content item Retrieve the engagement information of the newsletter publication with the supplied content id.

Parameters:

  • id (String)

    Unique identifier for the content

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(Content1, Integer, Hash)>)

    Content1 data, response status code and response headers



915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
# File 'lib/phyllo/api/engagement_api.rb', line 915

def v1_streampub_get_contents_by_id_with_http_info(id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_streampub_get_contents_by_id ..."
  end
  # verify the required parameter 'id' is set
  if @api_client.config.client_side_validation && id.nil?
    fail ArgumentError, "Missing the required parameter 'id' when calling EngagementApi.v1_streampub_get_contents_by_id"
  end
  # resource path
  local_var_path = "/v1/publications/contents/{id}".sub("{" + "id" + "}", CGI.escape(id.to_s))

  # query parameters
  query_params = opts[:query_params] || {}

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || "Content1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_streampub_get_contents_by_id",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_streampub_get_contents_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end

#v1_streampub_get_contents_with_http_info(account_id, opts = {}) ⇒ Array<(ContentList1, Integer, Hash)>

Retrieve all publication content items Lists all publication posts.

Parameters:

  • account_id (String)

    Unique ID of the connected account.

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The number of objects to skip. Use this argument for pagination. The default value is 0. (default to 0)

  • :limit (Integer)

    The number of objects to be returned. It can be between 1 to 100. The default value is 10. (default to 10)

Returns:

  • (Array<(ContentList1, Integer, Hash)>)

    ContentList1 data, response status code and response headers



849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
# File 'lib/phyllo/api/engagement_api.rb', line 849

def v1_streampub_get_contents_with_http_info(, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug "Calling API: EngagementApi.v1_streampub_get_contents ..."
  end
  # verify the required parameter 'account_id' is set
  if @api_client.config.client_side_validation && .nil?
    fail ArgumentError, "Missing the required parameter 'account_id' when calling EngagementApi.v1_streampub_get_contents"
  end
  # resource path
  local_var_path = "/v1/publications/contents"

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:account_id] = 
  query_params[:offset] = opts[:offset] if !opts[:offset].nil?
  query_params[:limit] = opts[:limit] if !opts[:limit].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params["Accept"] = @api_client.select_header_accept(["application/json"])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || "ContentList1"

  # auth_names
  auth_names = opts[:debug_auth_names] || ["Basic Authentication"]

  new_options = opts.merge(
    operation: :"EngagementApi.v1_streampub_get_contents",
    header_params: header_params,
    query_params: query_params,
    form_params: form_params,
    body: post_body,
    auth_names: auth_names,
    return_type: return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: EngagementApi#v1_streampub_get_contents\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  [data, status_code, headers]
end