Class: RusticiSoftwareCloudV2::DispatchApi

Inherits:
Object
  • Object
show all
Extended by:
Gem::Deprecate
Defined in:
lib/rustici_software_cloud_v2/api/dispatch_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ DispatchApi

Returns a new instance of DispatchApi.



18
19
20
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 18

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

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



16
17
18
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 16

def api_client
  @api_client
end

Instance Method Details

#create_destinations(destinations_list, opts = {}) ⇒ nil

Create a group of Destinations Creates a group of destinations. A destination is a label used to identify an entity outside of SCORM Cloud, such as an LMS. Used in conjunction with dispatches to provide access control mechanisms for the courses distributed to the destination.

Parameters:

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

    the optional parameters

Returns:

  • (nil)


29
30
31
32
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 29

def create_destinations(destinations_list, opts = {})
  create_destinations_with_http_info(destinations_list, opts)
  nil
end

#create_destinations_with_http_info(destinations_list, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Create a group of Destinations Creates a group of destinations. A destination is a label used to identify an entity outside of SCORM Cloud, such as an LMS. Used in conjunction with dispatches to provide access control mechanisms for the courses distributed to the destination.

Parameters:

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



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
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 39

def create_destinations_with_http_info(destinations_list, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.create_destinations ...'
  end
  # verify the required parameter 'destinations_list' is set
  if destinations_list.nil?
    fail ArgumentError, "Missing the required parameter 'destinations_list' when calling DispatchApi.create_destinations"
  end
  # resource path
  local_var_path = '/dispatch/destinations'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(destinations_list)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#create_destinations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#create_dispatches(dispatch_list, opts = {}) ⇒ nil

Create a group of Dispatches Creates a group of dispatches. Dispatches are the connection between a course and a destination. A dispatch zip package is a distributable course stub which, upon launch in a third-party LMS, will reference and launch the underlying course in SCORM Cloud. As an extension, dispatches allow for limiting access control even after the zip file has been given to the destination. >Caution: >Only one dispatch can exist for a given course-destination combination. If calling this method with the same course and destination supplied, the old one will be loaded for modification. An exception to this is if a dispatchId is passed in the body, the request will fail with a 400 response warning that the dispatch already exists. This is to prevent confusion over which dispatchId is to be used in future requests.

Parameters:

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

    the optional parameters

Returns:

  • (nil)


83
84
85
86
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 83

def create_dispatches(dispatch_list, opts = {})
  create_dispatches_with_http_info(dispatch_list, opts)
  nil
end

#create_dispatches_with_http_info(dispatch_list, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Create a group of Dispatches Creates a group of dispatches. Dispatches are the connection between a course and a destination. A dispatch zip package is a distributable course stub which, upon launch in a third-party LMS, will reference and launch the underlying course in SCORM Cloud. As an extension, dispatches allow for limiting access control even after the zip file has been given to the destination. &gt;Caution: &gt;Only one dispatch can exist for a given course-destination combination. If calling this method with the same course and destination supplied, the old one will be loaded for modification. An exception to this is if a dispatchId is passed in the body, the request will fail with a 400 response warning that the dispatch already exists. This is to prevent confusion over which dispatchId is to be used in future requests.

Parameters:

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



93
94
95
96
97
98
99
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
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 93

def create_dispatches_with_http_info(dispatch_list, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.create_dispatches ...'
  end
  # verify the required parameter 'dispatch_list' is set
  if dispatch_list.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_list' when calling DispatchApi.create_dispatches"
  end
  # resource path
  local_var_path = '/dispatch/dispatches'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(dispatch_list)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#create_dispatches\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_destination(destination_id, opts = {}) ⇒ nil

Delete a Destination Deletes the specified destination. >Caution: >This will also delete all dispatches belonging to the destination.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


137
138
139
140
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 137

def delete_destination(destination_id, opts = {})
  delete_destination_with_http_info(destination_id, opts)
  nil
end

#delete_destination_dispatches(destination_id, opts = {}) ⇒ nil

Delete a Destination’s Dispatches Deletes all the dispatches from the destination. >Caution: >This will invalidate any existing dispatch packages, rendering them unlaunchable.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


191
192
193
194
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 191

def delete_destination_dispatches(destination_id, opts = {})
  delete_destination_dispatches_with_http_info(destination_id, opts)
  nil
end

#delete_destination_dispatches_with_http_info(destination_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Delete a Destination&#39;s Dispatches Deletes all the dispatches from the destination. &gt;Caution: &gt;This will invalidate any existing dispatch packages, rendering them unlaunchable.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 201

def delete_destination_dispatches_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.delete_destination_dispatches ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.delete_destination_dispatches"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#delete_destination_dispatches\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_destination_tags(destination_id, tags, opts = {}) ⇒ nil

Delete tags from a Destination Deletes the specified tags from the destination. Deleting tags that do not exist will still result in a success.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


246
247
248
249
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 246

def delete_destination_tags(destination_id, tags, opts = {})
  delete_destination_tags_with_http_info(destination_id, tags, opts)
  nil
end

#delete_destination_tags_with_http_info(destination_id, tags, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Delete tags from a Destination Deletes the specified tags from the destination. Deleting tags that do not exist will still result in a success.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



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
295
296
297
298
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 257

def delete_destination_tags_with_http_info(destination_id, tags, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.delete_destination_tags ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.delete_destination_tags"
  end
  # verify the required parameter 'tags' is set
  if tags.nil?
    fail ArgumentError, "Missing the required parameter 'tags' when calling DispatchApi.delete_destination_tags"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/tags'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tags)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#delete_destination_tags\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_destination_with_http_info(destination_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Delete a Destination Deletes the specified destination. &gt;Caution: &gt;This will also delete all dispatches belonging to the destination.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 147

def delete_destination_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.delete_destination ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.delete_destination"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#delete_destination\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_dispatch(dispatch_id, opts = {}) ⇒ nil

Delete a Dispatch Deletes the specified dispatch. >Caution: >This will invalidate any existing dispatch packages, rendering them unlaunchable.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (nil)


305
306
307
308
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 305

def delete_dispatch(dispatch_id, opts = {})
  delete_dispatch_with_http_info(dispatch_id, opts)
  nil
end

#delete_dispatch_postback_info(dispatch_id, opts = {}) ⇒ nil

Delete postback information from a Dispatch Clears the postback settings from the dispatch. This causes the postback settings to inherit a value from a higher level (e.g. application). If there is no setting at the application level, this will disable postbacks for the dispatch.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (nil)


359
360
361
362
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 359

def delete_dispatch_postback_info(dispatch_id, opts = {})
  delete_dispatch_postback_info_with_http_info(dispatch_id, opts)
  nil
end

#delete_dispatch_postback_info_with_http_info(dispatch_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Delete postback information from a Dispatch Clears the postback settings from the dispatch. This causes the postback settings to inherit a value from a higher level (e.g. application). If there is no setting at the application level, this will disable postbacks for the dispatch.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



369
370
371
372
373
374
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
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 369

def delete_dispatch_postback_info_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.delete_dispatch_postback_info ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.delete_dispatch_postback_info"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/postback'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#delete_dispatch_postback_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_dispatch_tags(dispatch_id, tags, opts = {}) ⇒ nil

Delete tags from a Dispatch Deletes the specified tags from the dispatch. Deleting tags that do not exist will still result in a success.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (nil)


414
415
416
417
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 414

def delete_dispatch_tags(dispatch_id, tags, opts = {})
  delete_dispatch_tags_with_http_info(dispatch_id, tags, opts)
  nil
end

#delete_dispatch_tags_with_http_info(dispatch_id, tags, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Delete tags from a Dispatch Deletes the specified tags from the dispatch. Deleting tags that do not exist will still result in a success.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



425
426
427
428
429
430
431
432
433
434
435
436
437
438
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
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 425

def delete_dispatch_tags_with_http_info(dispatch_id, tags, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.delete_dispatch_tags ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.delete_dispatch_tags"
  end
  # verify the required parameter 'tags' is set
  if tags.nil?
    fail ArgumentError, "Missing the required parameter 'tags' when calling DispatchApi.delete_dispatch_tags"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/tags'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tags)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#delete_dispatch_tags\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_dispatch_with_http_info(dispatch_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Delete a Dispatch Deletes the specified dispatch. &gt;Caution: &gt;This will invalidate any existing dispatch packages, rendering them unlaunchable.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



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
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 315

def delete_dispatch_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.delete_dispatch ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.delete_dispatch"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#delete_dispatch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_dispatches(opts = {}) ⇒ nil

Delete a group of Dispatches Deletes the specified group of dispatches. Can be filtered using the request parameters to provide a subset of results. >Caution: >This will invalidate any existing dispatch packages, rendering them unlaunchable. >Note: >One of the filter parameters (i.e. ‘courseId`, `since`/`until`, `tags`, or `filter`) needs to be provided. This is to prevent accidental deletion of all dispatches. If you do wish to update all dispatches, try setting the since parameter to a value prior to the creation of any dispatches. >Info: >If using one of our client libraries, refer to its README for additional information on how to work with the `X-Total-Count` header.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against (default to updated)

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter. (default to dispatch_id)

Returns:

  • (nil)


479
480
481
482
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 479

def delete_dispatches(opts = {})
  delete_dispatches_with_http_info(opts)
  nil
end

#delete_dispatches_with_http_info(opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Delete a group of Dispatches Deletes the specified group of dispatches. Can be filtered using the request parameters to provide a subset of results. &gt;Caution: &gt;This will invalidate any existing dispatch packages, rendering them unlaunchable. &gt;Note: &gt;One of the filter parameters (i.e. &#x60;courseId&#x60;, &#x60;since&#x60;/&#x60;until&#x60;, &#x60;tags&#x60;, or &#x60;filter&#x60;) needs to be provided. This is to prevent accidental deletion of all dispatches. If you do wish to update all dispatches, try setting the since parameter to a value prior to the creation of any dispatches. &gt;Info: &gt;If using one of our client libraries, refer to its README for additional information on how to work with the &#x60;X-Total-Count&#x60; header.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter.

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



495
496
497
498
499
500
501
502
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
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 495

def delete_dispatches_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.delete_dispatches ...'
  end
  # resource path
  local_var_path = '/dispatch/dispatches'

  # query parameters
  query_params = {}
  query_params[:'courseId'] = opts[:'course_id'] if !opts[:'course_id'].nil?
  query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
  query_params[:'until'] = opts[:'_until'] if !opts[:'_until'].nil?
  query_params[:'datetimeFilter'] = opts[:'datetime_filter'] if !opts[:'datetime_filter'].nil?
  query_params[:'tags'] = @api_client.build_collection_param(opts[:'tags'], :csv) if !opts[:'tags'].nil?
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'filterBy'] = opts[:'filter_by'] if !opts[:'filter_by'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#delete_dispatches\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#enable_registration_instancing(destination_id, enabled, opts = {}) ⇒ nil

Update registration instancing status for a Destination’s Dispatches Updates the restration instancing status for all dispatches distributed to the destination. Registration instancing is the default for dispatches, in order to support versioning of dispatches. A small portion of users may experience duplicate registrations with content dispatched to some LMS platforms. If you happen to be dispatching content to an LMS with this issue, disabling registration instancing here will resolve the problems. However, dispatch versioning will also be disabled.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


543
544
545
546
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 543

def enable_registration_instancing(destination_id, enabled, opts = {})
  enable_registration_instancing_with_http_info(destination_id, enabled, opts)
  nil
end

#enable_registration_instancing_with_http_info(destination_id, enabled, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Update registration instancing status for a Destination&#39;s Dispatches Updates the restration instancing status for all dispatches distributed to the destination. Registration instancing is the default for dispatches, in order to support versioning of dispatches. A small portion of users may experience duplicate registrations with content dispatched to some LMS platforms. If you happen to be dispatching content to an LMS with this issue, disabling registration instancing here will resolve the problems. However, dispatch versioning will also be disabled.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 554

def enable_registration_instancing_with_http_info(destination_id, enabled, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.enable_registration_instancing ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.enable_registration_instancing"
  end
  # verify the required parameter 'enabled' is set
  if enabled.nil?
    fail ArgumentError, "Missing the required parameter 'enabled' when calling DispatchApi.enable_registration_instancing"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches/registrationInstancing'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(enabled)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#enable_registration_instancing\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_destination(destination_id, opts = {}) ⇒ DestinationInfoSchema

Get detailed information about a Destination Returns detailed information about the destination. This includes name, tags, and launchAuth information.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Options Hash (opts):

  • :include_dispatch_count (BOOLEAN)

    Include a count of dispatches for the destination. (default to false)

Returns:



603
604
605
606
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 603

def get_destination(destination_id, opts = {})
  data, _status_code, _headers = get_destination_with_http_info(destination_id, opts)
  data
end

#get_destination_dispatch_registration_count(destination_id, opts = {}) ⇒ IntegerResultSchema

Get registration count for a Destination’s Dispatches Returns the registration count for all dispatches distributed to the destination. >Note: >The count here is a convenience counter. Since it has the capability of being reset, it may not match the actual billed registration count for a dispatch.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:



660
661
662
663
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 660

def get_destination_dispatch_registration_count(destination_id, opts = {})
  data, _status_code, _headers = get_destination_dispatch_registration_count_with_http_info(destination_id, opts)
  data
end

#get_destination_dispatch_registration_count_with_http_info(destination_id, opts = {}) ⇒ Array<(IntegerResultSchema, Fixnum, Hash)>

Get registration count for a Destination&#39;s Dispatches Returns the registration count for all dispatches distributed to the destination. &gt;Note: &gt;The count here is a convenience counter. Since it has the capability of being reset, it may not match the actual billed registration count for a dispatch.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(IntegerResultSchema, Fixnum, Hash)>)

    IntegerResultSchema data, response status code and response headers



670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 670

def get_destination_dispatch_registration_count_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_destination_dispatch_registration_count ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.get_destination_dispatch_registration_count"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches/registrationCount'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'IntegerResultSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_destination_dispatch_registration_count\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_destination_dispatch_zip(destination_id, opts = {}) ⇒ File

Download a zip file for a Destination’s Dispatches Downloads a zip file containing all of the dispatch packages for the destination. A dispatch zip package is a distributable course stub which, upon launch in a third-party LMS, will reference and launch the underlying course in SCORM Cloud.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Options Hash (opts):

  • :type (String)

    The type of dispatch package to export (SCORM_12 only supported in SCORM Cloud today) (default to SCORM_12)

  • :css_url (String)
  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

Returns:

  • (File)


718
719
720
721
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 718

def get_destination_dispatch_zip(destination_id, opts = {})
  data, _status_code, _headers = get_destination_dispatch_zip_with_http_info(destination_id, opts)
  data
end

#get_destination_dispatch_zip_with_http_info(destination_id, opts = {}) ⇒ Array<(File, Fixnum, Hash)>

Download a zip file for a Destination&#39;s Dispatches Downloads a zip file containing all of the dispatch packages for the destination. A dispatch zip package is a distributable course stub which, upon launch in a third-party LMS, will reference and launch the underlying course in SCORM Cloud.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Options Hash (opts):

  • :type (String)

    The type of dispatch package to export (SCORM_12 only supported in SCORM Cloud today)

  • :css_url (String)
  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

Returns:

  • (Array<(File, Fixnum, Hash)>)

    File data, response status code and response headers



731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 731

def get_destination_dispatch_zip_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_destination_dispatch_zip ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.get_destination_dispatch_zip"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches/zip'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
  query_params[:'cssUrl'] = opts[:'css_url'] if !opts[:'css_url'].nil?
  query_params[:'tags'] = @api_client.build_collection_param(opts[:'tags'], :csv) if !opts[:'tags'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/zip'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_destination_dispatch_zip\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_destination_dispatches(destination_id, opts = {}) ⇒ DispatchListSchema

Get a list of a Destination’s Dispatches Returns a list of dispatches belonging to the destination. Can be filtered using the request parameters to provide a subset of results. Using the ‘courseId` filter should only ever yield 0 or 1 results, as a dispatch is the intersection of a course and a destination. This can be useful for identifying if a certain course is dispatched to the destination. >Note: >This request is paginated and will only provide a limited amount of resources at a time. If there are more results to be collected, a `more` token provided with the response which can be passed to get the next page of results. When passing this token, no other filter parameters can be sent as part of the request. The resources will continue to respect the filters passed in by the original request.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against (default to updated)

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter. (default to dispatch_id)

  • :order_by (String)

    Optional enum parameter for specifying the field and order by which to sort the results. (default to updated_asc)

  • :more (String)

    Pagination token returned as &#x60;more&#x60; property of multi page list requests

  • :include_total_count (BOOLEAN)

    Include the total count of results matching the provided filters as a header on the initial request. The header will not be present on subsequent requests resulting from passing the &#x60;more&#x60; token. (default to false)

Returns:



789
790
791
792
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 789

def get_destination_dispatches(destination_id, opts = {})
  data, _status_code, _headers = get_destination_dispatches_with_http_info(destination_id, opts)
  data
end

#get_destination_dispatches_with_http_info(destination_id, opts = {}) ⇒ Array<(DispatchListSchema, Fixnum, Hash)>

Get a list of a Destination&#39;s Dispatches Returns a list of dispatches belonging to the destination. Can be filtered using the request parameters to provide a subset of results. Using the &#x60;courseId&#x60; filter should only ever yield 0 or 1 results, as a dispatch is the intersection of a course and a destination. This can be useful for identifying if a certain course is dispatched to the destination. &gt;Note: &gt;This request is paginated and will only provide a limited amount of resources at a time. If there are more results to be collected, a &#x60;more&#x60; token provided with the response which can be passed to get the next page of results. When passing this token, no other filter parameters can be sent as part of the request. The resources will continue to respect the filters passed in by the original request.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter.

  • :order_by (String)

    Optional enum parameter for specifying the field and order by which to sort the results.

  • :more (String)

    Pagination token returned as &#x60;more&#x60; property of multi page list requests

  • :include_total_count (BOOLEAN)

    Include the total count of results matching the provided filters as a header on the initial request. The header will not be present on subsequent requests resulting from passing the &#x60;more&#x60; token.

Returns:

  • (Array<(DispatchListSchema, Fixnum, Hash)>)

    DispatchListSchema data, response status code and response headers



809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 809

def get_destination_dispatches_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_destination_dispatches ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.get_destination_dispatches"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'courseId'] = opts[:'course_id'] if !opts[:'course_id'].nil?
  query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
  query_params[:'until'] = opts[:'_until'] if !opts[:'_until'].nil?
  query_params[:'datetimeFilter'] = opts[:'datetime_filter'] if !opts[:'datetime_filter'].nil?
  query_params[:'tags'] = @api_client.build_collection_param(opts[:'tags'], :csv) if !opts[:'tags'].nil?
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'filterBy'] = opts[:'filter_by'] if !opts[:'filter_by'].nil?
  query_params[:'orderBy'] = opts[:'order_by'] if !opts[:'order_by'].nil?
  query_params[:'more'] = opts[:'more'] if !opts[:'more'].nil?
  query_params[:'includeTotalCount'] = opts[:'include_total_count'] if !opts[:'include_total_count'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'DispatchListSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_destination_dispatches\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_destination_hash_user_info(destination_id, opts = {}) ⇒ EnabledSchema

Get user PII hashing status for a Destination Returns whether or not user PII hashing is enabled for the destination. Enabling it will cause all user PII to be hashed. Hashing PII will anonymize the learner data from the dispatched course. This will make looking up specific details about a learner difficult.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:



864
865
866
867
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 864

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

#get_destination_hash_user_info_with_http_info(destination_id, opts = {}) ⇒ Array<(EnabledSchema, Fixnum, Hash)>

Get user PII hashing status for a Destination Returns whether or not user PII hashing is enabled for the destination. Enabling it will cause all user PII to be hashed. Hashing PII will anonymize the learner data from the dispatched course. This will make looking up specific details about a learner difficult.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(EnabledSchema, Fixnum, Hash)>)

    EnabledSchema data, response status code and response headers



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
899
900
901
902
903
904
905
906
907
908
909
910
911
912
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 874

def (destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_destination_hash_user_info ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.get_destination_hash_user_info"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches/hashUserInfo'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'EnabledSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_destination_hash_user_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_destination_tags(destination_id, opts = {}) ⇒ TagListSchema

Get tags for a Destination Returns the tags for the destination.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:



919
920
921
922
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 919

def get_destination_tags(destination_id, opts = {})
  data, _status_code, _headers = get_destination_tags_with_http_info(destination_id, opts)
  data
end

#get_destination_tags_with_http_info(destination_id, opts = {}) ⇒ Array<(TagListSchema, Fixnum, Hash)>

Get tags for a Destination Returns the tags for the destination.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(TagListSchema, Fixnum, Hash)>)

    TagListSchema data, response status code and response headers



929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 929

def get_destination_tags_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_destination_tags ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.get_destination_tags"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/tags'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TagListSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_destination_tags\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_destination_with_http_info(destination_id, opts = {}) ⇒ Array<(DestinationInfoSchema, Fixnum, Hash)>

Get detailed information about a Destination Returns detailed information about the destination. This includes name, tags, and launchAuth information.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Options Hash (opts):

  • :include_dispatch_count (BOOLEAN)

    Include a count of dispatches for the destination.

Returns:

  • (Array<(DestinationInfoSchema, Fixnum, Hash)>)

    DestinationInfoSchema data, response status code and response headers



614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 614

def get_destination_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_destination ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.get_destination"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'includeDispatchCount'] = opts[:'include_dispatch_count'] if !opts[:'include_dispatch_count'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'DestinationInfoSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_destination\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_destinations(opts = {}) ⇒ DestinationInfoListSchema

Get a list of Destinations Returns a list of destinations. Can be filtered using the request parameters to provide a subset of results. >Note: >This request is paginated and will only provide a limited amount of resources at a time. If there are more results to be collected, a ‘more` token provided with the response which can be passed to get the next page of results. When passing this token, no other filter parameters can be sent as part of the request. The resources will continue to respect the filters passed in by the original request. >Info: >This endpoint caches the dispatch count of a destination for 24 hours if the `includeDispatchCount` parameter is set to `true`. Since this value is cached for an extended period, any changes made to the number of dispatches for a destination will not be reflected in the results of this endpoint until the caching period has passed. >If you want to get an up-to-date value of the dispatch count for a single destination within the caching period, use the GetDestination endpoint with `includeDispatchCount` set to `true`. GetDestination always gathers the most up-to-date values and overwrites them in the cache, resetting the caching period for that destination.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against (default to updated)

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter. (default to destination_id)

  • :order_by (String)

    Optional enum parameter for specifying the field and order by which to sort the results. (default to updated_asc)

  • :more (String)

    Pagination token returned as &#x60;more&#x60; property of multi page list requests

  • :include_dispatch_count (BOOLEAN)

    Include a count of dispatches for each destination. (default to false)

  • :include_total_count (BOOLEAN)

    Include the total count of results matching the provided filters as a header on the initial request. The header will not be present on subsequent requests resulting from passing the &#x60;more&#x60; token. (default to false)

Returns:



984
985
986
987
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 984

def get_destinations(opts = {})
  data, _status_code, _headers = get_destinations_with_http_info(opts)
  data
end

#get_destinations_with_http_info(opts = {}) ⇒ Array<(DestinationInfoListSchema, Fixnum, Hash)>

Get a list of Destinations Returns a list of destinations. Can be filtered using the request parameters to provide a subset of results. &gt;Note: &gt;This request is paginated and will only provide a limited amount of resources at a time. If there are more results to be collected, a &#x60;more&#x60; token provided with the response which can be passed to get the next page of results. When passing this token, no other filter parameters can be sent as part of the request. The resources will continue to respect the filters passed in by the original request. &gt;Info: &gt;This endpoint caches the dispatch count of a destination for 24 hours if the &#x60;includeDispatchCount&#x60; parameter is set to &#x60;true&#x60;. Since this value is cached for an extended period, any changes made to the number of dispatches for a destination will not be reflected in the results of this endpoint until the caching period has passed. &gt;If you want to get an up-to-date value of the dispatch count for a single destination within the caching period, use the GetDestination endpoint with &#x60;includeDispatchCount&#x60; set to &#x60;true&#x60;. GetDestination always gathers the most up-to-date values and overwrites them in the cache, resetting the caching period for that destination.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter.

  • :order_by (String)

    Optional enum parameter for specifying the field and order by which to sort the results.

  • :more (String)

    Pagination token returned as &#x60;more&#x60; property of multi page list requests

  • :include_dispatch_count (BOOLEAN)

    Include a count of dispatches for each destination.

  • :include_total_count (BOOLEAN)

    Include the total count of results matching the provided filters as a header on the initial request. The header will not be present on subsequent requests resulting from passing the &#x60;more&#x60; token.

Returns:

  • (Array<(DestinationInfoListSchema, Fixnum, Hash)>)

    DestinationInfoListSchema data, response status code and response headers



1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1004

def get_destinations_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_destinations ...'
  end
  # resource path
  local_var_path = '/dispatch/destinations'

  # query parameters
  query_params = {}
  query_params[:'courseId'] = opts[:'course_id'] if !opts[:'course_id'].nil?
  query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
  query_params[:'until'] = opts[:'_until'] if !opts[:'_until'].nil?
  query_params[:'datetimeFilter'] = opts[:'datetime_filter'] if !opts[:'datetime_filter'].nil?
  query_params[:'tags'] = @api_client.build_collection_param(opts[:'tags'], :csv) if !opts[:'tags'].nil?
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'filterBy'] = opts[:'filter_by'] if !opts[:'filter_by'].nil?
  query_params[:'orderBy'] = opts[:'order_by'] if !opts[:'order_by'].nil?
  query_params[:'more'] = opts[:'more'] if !opts[:'more'].nil?
  query_params[:'includeDispatchCount'] = opts[:'include_dispatch_count'] if !opts[:'include_dispatch_count'].nil?
  query_params[:'includeTotalCount'] = opts[:'include_total_count'] if !opts[:'include_total_count'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'DestinationInfoListSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_destinations\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_dispatch(dispatch_id, opts = {}) ⇒ DispatchSchema

Get detailed information about a Dispatch Returns detailed information about the dispatch. This includes destination and course IDs, as well as registration count.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:



1056
1057
1058
1059
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1056

def get_dispatch(dispatch_id, opts = {})
  data, _status_code, _headers = get_dispatch_with_http_info(dispatch_id, opts)
  data
end

#get_dispatch_enabled(dispatch_id, opts = {}) ⇒ EnabledSchema

Get enabled status of a Dispatch Returns the enabled status for the dispatch. This is an access control measure allowing you to turn access to a previously distributed dispatch packages on or off.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:



1111
1112
1113
1114
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1111

def get_dispatch_enabled(dispatch_id, opts = {})
  data, _status_code, _headers = get_dispatch_enabled_with_http_info(dispatch_id, opts)
  data
end

#get_dispatch_enabled_with_http_info(dispatch_id, opts = {}) ⇒ Array<(EnabledSchema, Fixnum, Hash)>

Get enabled status of a Dispatch Returns the enabled status for the dispatch. This is an access control measure allowing you to turn access to a previously distributed dispatch packages on or off.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(EnabledSchema, Fixnum, Hash)>)

    EnabledSchema data, response status code and response headers



1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1121

def get_dispatch_enabled_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_dispatch_enabled ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_dispatch_enabled"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/enabled'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'EnabledSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_dispatch_enabled\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_dispatch_hash_user_info(dispatch_id, opts = {}) ⇒ EnabledSchema

Get user PII hashing status for a Dispatch Returns whether or not user PII hashing is enabled for the dispatch. Enabling it will cause all user PII to be hashed. Hashing PII will anonymize the learner data from the dispatched course. This will make looking up specific details about a learner difficult.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:



1166
1167
1168
1169
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1166

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

#get_dispatch_hash_user_info_with_http_info(dispatch_id, opts = {}) ⇒ Array<(EnabledSchema, Fixnum, Hash)>

Get user PII hashing status for a Dispatch Returns whether or not user PII hashing is enabled for the dispatch. Enabling it will cause all user PII to be hashed. Hashing PII will anonymize the learner data from the dispatched course. This will make looking up specific details about a learner difficult.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(EnabledSchema, Fixnum, Hash)>)

    EnabledSchema data, response status code and response headers



1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1176

def (dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_dispatch_hash_user_info ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_dispatch_hash_user_info"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/hashUserInfo'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'EnabledSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_dispatch_hash_user_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_dispatch_registration_count(dispatch_id, opts = {}) ⇒ DispatchRegistrationCountSchema

Get registration count for a Dispatch Returns the registration count for the dispatch, as well as the date and time of the last count reset, if any. >Note: >The count here is a convenience counter. Since it has the capability of being reset, it may not match the actual billed registration count for a dispatch.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:



1221
1222
1223
1224
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1221

def get_dispatch_registration_count(dispatch_id, opts = {})
  data, _status_code, _headers = get_dispatch_registration_count_with_http_info(dispatch_id, opts)
  data
end

#get_dispatch_registration_count_with_http_info(dispatch_id, opts = {}) ⇒ Array<(DispatchRegistrationCountSchema, Fixnum, Hash)>

Get registration count for a Dispatch Returns the registration count for the dispatch, as well as the date and time of the last count reset, if any. &gt;Note: &gt;The count here is a convenience counter. Since it has the capability of being reset, it may not match the actual billed registration count for a dispatch.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:



1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1231

def get_dispatch_registration_count_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_dispatch_registration_count ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_dispatch_registration_count"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/registrationCount'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'DispatchRegistrationCountSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_dispatch_registration_count\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_dispatch_tags(dispatch_id, opts = {}) ⇒ TagListSchema

Get tags for a Dispatch Returns the tags for the dispatch.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:



1276
1277
1278
1279
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1276

def get_dispatch_tags(dispatch_id, opts = {})
  data, _status_code, _headers = get_dispatch_tags_with_http_info(dispatch_id, opts)
  data
end

#get_dispatch_tags_with_http_info(dispatch_id, opts = {}) ⇒ Array<(TagListSchema, Fixnum, Hash)>

Get tags for a Dispatch Returns the tags for the dispatch.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(TagListSchema, Fixnum, Hash)>)

    TagListSchema data, response status code and response headers



1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1286

def get_dispatch_tags_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_dispatch_tags ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_dispatch_tags"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/tags'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'TagListSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_dispatch_tags\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_dispatch_with_http_info(dispatch_id, opts = {}) ⇒ Array<(DispatchSchema, Fixnum, Hash)>

Get detailed information about a Dispatch Returns detailed information about the dispatch. This includes destination and course IDs, as well as registration count.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(DispatchSchema, Fixnum, Hash)>)

    DispatchSchema data, response status code and response headers



1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1066

def get_dispatch_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_dispatch ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_dispatch"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'DispatchSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_dispatch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_dispatch_zip(dispatch_id, opts = {}) ⇒ File

Download a zip package for a Dispatch Downloads a zip package for the dispatch. A dispatch zip package is a distributable course stub which, upon launch in a third-party LMS, will reference and launch the underlying course in SCORM Cloud. As an extension, dispatches allow for limiting access control even after the zip file has been given to the destination.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Options Hash (opts):

  • :type (String)

    The type of dispatch package to export (currently only SCORM_12 available) (default to SCORM_12)

  • :css_url (String)

    Custom CSS to apply to the dispatch package

Returns:

  • (File)


1333
1334
1335
1336
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1333

def get_dispatch_zip(dispatch_id, opts = {})
  data, _status_code, _headers = get_dispatch_zip_with_http_info(dispatch_id, opts)
  data
end

#get_dispatch_zip_with_http_info(dispatch_id, opts = {}) ⇒ Array<(File, Fixnum, Hash)>

Download a zip package for a Dispatch Downloads a zip package for the dispatch. A dispatch zip package is a distributable course stub which, upon launch in a third-party LMS, will reference and launch the underlying course in SCORM Cloud. As an extension, dispatches allow for limiting access control even after the zip file has been given to the destination.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Options Hash (opts):

  • :type (String)

    The type of dispatch package to export (currently only SCORM_12 available)

  • :css_url (String)

    Custom CSS to apply to the dispatch package

Returns:

  • (Array<(File, Fixnum, Hash)>)

    File data, response status code and response headers



1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1345

def get_dispatch_zip_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_dispatch_zip ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_dispatch_zip"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/zip'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'type'] = opts[:'type'] if !opts[:'type'].nil?
  query_params[:'cssUrl'] = opts[:'css_url'] if !opts[:'css_url'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/zip'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'File')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_dispatch_zip\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_dispatches(opts = {}) ⇒ DispatchListSchema

Get a list of Dispatches Returns a list of dispatches. Can be filtered using the request parameters to provide a subset of results. Using the ‘courseId` filter will allow for viewing which destinations the course has been dispatched to. >Note: >This request is paginated and will only provide a limited amount of resources at a time. If there are more results to be collected, a `more` token provided with the response which can be passed to get the next page of results. When passing this token, no other filter parameters can be sent as part of the request. The resources will continue to respect the filters passed in by the original request.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against (default to updated)

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter. (default to dispatch_id)

  • :order_by (String)

    Optional enum parameter for specifying the field and order by which to sort the results. (default to updated_asc)

  • :more (String)

    Pagination token returned as &#x60;more&#x60; property of multi page list requests

  • :include_total_count (BOOLEAN)

    Include the total count of results matching the provided filters as a header on the initial request. The header will not be present on subsequent requests resulting from passing the &#x60;more&#x60; token. (default to false)

Returns:



1401
1402
1403
1404
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1401

def get_dispatches(opts = {})
  data, _status_code, _headers = get_dispatches_with_http_info(opts)
  data
end

#get_dispatches_with_http_info(opts = {}) ⇒ Array<(DispatchListSchema, Fixnum, Hash)>

Get a list of Dispatches Returns a list of dispatches. Can be filtered using the request parameters to provide a subset of results. Using the &#x60;courseId&#x60; filter will allow for viewing which destinations the course has been dispatched to. &gt;Note: &gt;This request is paginated and will only provide a limited amount of resources at a time. If there are more results to be collected, a &#x60;more&#x60; token provided with the response which can be passed to get the next page of results. When passing this token, no other filter parameters can be sent as part of the request. The resources will continue to respect the filters passed in by the original request.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter.

  • :order_by (String)

    Optional enum parameter for specifying the field and order by which to sort the results.

  • :more (String)

    Pagination token returned as &#x60;more&#x60; property of multi page list requests

  • :include_total_count (BOOLEAN)

    Include the total count of results matching the provided filters as a header on the initial request. The header will not be present on subsequent requests resulting from passing the &#x60;more&#x60; token.

Returns:

  • (Array<(DispatchListSchema, Fixnum, Hash)>)

    DispatchListSchema data, response status code and response headers



1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1420

def get_dispatches_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_dispatches ...'
  end
  # resource path
  local_var_path = '/dispatch/dispatches'

  # query parameters
  query_params = {}
  query_params[:'courseId'] = opts[:'course_id'] if !opts[:'course_id'].nil?
  query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
  query_params[:'until'] = opts[:'_until'] if !opts[:'_until'].nil?
  query_params[:'datetimeFilter'] = opts[:'datetime_filter'] if !opts[:'datetime_filter'].nil?
  query_params[:'tags'] = @api_client.build_collection_param(opts[:'tags'], :csv) if !opts[:'tags'].nil?
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'filterBy'] = opts[:'filter_by'] if !opts[:'filter_by'].nil?
  query_params[:'orderBy'] = opts[:'order_by'] if !opts[:'order_by'].nil?
  query_params[:'more'] = opts[:'more'] if !opts[:'more'].nil?
  query_params[:'includeTotalCount'] = opts[:'include_total_count'] if !opts[:'include_total_count'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'DispatchListSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_dispatches\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_lti13_dispatch(dispatch_id, opts = {}) ⇒ DispatchLti13InfoSchema

Get the information necessary to import this dispatch as a resource link according to the IMS LTI 1.3 specification. Get the information necessary to import this dispatch as a resource link according to the IMS LTI 1.3 specification. The information from this call will be provided to the platform during the configuration step.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:



1471
1472
1473
1474
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1471

def get_lti13_dispatch(dispatch_id, opts = {})
  data, _status_code, _headers = get_lti13_dispatch_with_http_info(dispatch_id, opts)
  data
end

#get_lti13_dispatch_launch(dispatch_id, external_config, jwt, opts = {}) ⇒ nil

Launch this dispatch using the IMS LTI 1.3 specification. Launch this dispatch using the IMS LTI 1.3 specification. This is the final step in the LTI 1.3 launch process, and is the request that redirects to the resource link (i.e. course).

Parameters:

  • dispatch_id

    Identifier for the dispatch

  • external_config

    External configuration object

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

    the optional parameters

Returns:

  • (nil)


1528
1529
1530
1531
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1528

def get_lti13_dispatch_launch(dispatch_id, external_config, jwt, opts = {})
  get_lti13_dispatch_launch_with_http_info(dispatch_id, external_config, jwt, opts)
  nil
end

#get_lti13_dispatch_launch_with_http_info(dispatch_id, external_config, jwt, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Launch this dispatch using the IMS LTI 1.3 specification. Launch this dispatch using the IMS LTI 1.3 specification. This is the final step in the LTI 1.3 launch process, and is the request that redirects to the resource link (i.e. course).

Parameters:

  • dispatch_id

    Identifier for the dispatch

  • external_config

    External configuration object

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1540

def get_lti13_dispatch_launch_with_http_info(dispatch_id, external_config, jwt, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_lti13_dispatch_launch ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_lti13_dispatch_launch"
  end
  # verify the required parameter 'external_config' is set
  if external_config.nil?
    fail ArgumentError, "Missing the required parameter 'external_config' when calling DispatchApi.get_lti13_dispatch_launch"
  end
  # verify the required parameter 'jwt' is set
  if jwt.nil?
    fail ArgumentError, "Missing the required parameter 'jwt' when calling DispatchApi.get_lti13_dispatch_launch"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/launches'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}
  query_params[:'externalConfig'] = external_config
  query_params[:'jwt'] = jwt

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = []
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_lti13_dispatch_launch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_lti13_dispatch_with_http_info(dispatch_id, opts = {}) ⇒ Array<(DispatchLti13InfoSchema, Fixnum, Hash)>

Get the information necessary to import this dispatch as a resource link according to the IMS LTI 1.3 specification. Get the information necessary to import this dispatch as a resource link according to the IMS LTI 1.3 specification. The information from this call will be provided to the platform during the configuration step.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(DispatchLti13InfoSchema, Fixnum, Hash)>)

    DispatchLti13InfoSchema data, response status code and response headers



1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1481

def get_lti13_dispatch_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_lti13_dispatch ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_lti13_dispatch"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/lti13'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'DispatchLti13InfoSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_lti13_dispatch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_lti13_tool_configuration_schema(destination_id, opts = {}) ⇒ Lti13ToolConfigurationSchema

Get the information needed to configure a LTI 1.3 platform with the destination id ‘destinationId`

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:



1593
1594
1595
1596
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1593

def get_lti13_tool_configuration_schema(destination_id, opts = {})
  data, _status_code, _headers = get_lti13_tool_configuration_schema_with_http_info(destination_id, opts)
  data
end

#get_lti13_tool_configuration_schema_with_http_info(destination_id, opts = {}) ⇒ Array<(Lti13ToolConfigurationSchema, Fixnum, Hash)>

Get the information needed to configure a LTI 1.3 platform with the destination id &#x60;destinationId&#x60;

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:



1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1602

def get_lti13_tool_configuration_schema_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_lti13_tool_configuration_schema ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.get_lti13_tool_configuration_schema"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/lti13'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'Lti13ToolConfigurationSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_lti13_tool_configuration_schema\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_lti_dispatch(dispatch_id, opts = {}) ⇒ DispatchLtiInfoSchema

Get the information necessary to launch this dispatch using the IMS LTI 1.1 specification. Retrieve the information needed to launch this dispatch using the IMS LTI 1.1 specification. This information is then provided to the platform so it can launch this dispatch.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:



1647
1648
1649
1650
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1647

def get_lti_dispatch(dispatch_id, opts = {})
  data, _status_code, _headers = get_lti_dispatch_with_http_info(dispatch_id, opts)
  data
end

#get_lti_dispatch_with_http_info(dispatch_id, opts = {}) ⇒ Array<(DispatchLtiInfoSchema, Fixnum, Hash)>

Get the information necessary to launch this dispatch using the IMS LTI 1.1 specification. Retrieve the information needed to launch this dispatch using the IMS LTI 1.1 specification. This information is then provided to the platform so it can launch this dispatch.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(DispatchLtiInfoSchema, Fixnum, Hash)>)

    DispatchLtiInfoSchema data, response status code and response headers



1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1657

def get_lti_dispatch_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.get_lti_dispatch ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.get_lti_dispatch"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/lti'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:GET, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => 'DispatchLtiInfoSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#get_lti_dispatch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_destination_tags(destination_id, tags, opts = {}) ⇒ nil

Add tags to a Destination Applies the provided tags to the destination. Tags are used to easily identify resources. Adding tags can enable more refined searches when making calls to certain endpoints (e.g. GetDestinations).

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


1703
1704
1705
1706
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1703

def put_destination_tags(destination_id, tags, opts = {})
  put_destination_tags_with_http_info(destination_id, tags, opts)
  nil
end

#put_destination_tags_batch(batch, opts = {}) ⇒ nil

Add a group of tags to a group of Destinations Applies all of the provided tags on all of the provided destinations. Tags are used to easily identify resources. Adding tags can enable more refined searches when making calls to certain endpoints (e.g. GetDestinations).

Parameters:

  • batch

    Array of ids, and array of tags for bulk tag operations

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

    the optional parameters

Returns:

  • (nil)


1762
1763
1764
1765
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1762

def put_destination_tags_batch(batch, opts = {})
  put_destination_tags_batch_with_http_info(batch, opts)
  nil
end

#put_destination_tags_batch_with_http_info(batch, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Add a group of tags to a group of Destinations Applies all of the provided tags on all of the provided destinations. Tags are used to easily identify resources. Adding tags can enable more refined searches when making calls to certain endpoints (e.g. GetDestinations).

Parameters:

  • batch

    Array of ids, and array of tags for bulk tag operations

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1772

def put_destination_tags_batch_with_http_info(batch, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.put_destination_tags_batch ...'
  end
  # verify the required parameter 'batch' is set
  if batch.nil?
    fail ArgumentError, "Missing the required parameter 'batch' when calling DispatchApi.put_destination_tags_batch"
  end
  # resource path
  local_var_path = '/dispatch/destinations/tags'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(batch)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#put_destination_tags_batch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_destination_tags_with_http_info(destination_id, tags, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Add tags to a Destination Applies the provided tags to the destination. Tags are used to easily identify resources. Adding tags can enable more refined searches when making calls to certain endpoints (e.g. GetDestinations).

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1714

def put_destination_tags_with_http_info(destination_id, tags, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.put_destination_tags ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.put_destination_tags"
  end
  # verify the required parameter 'tags' is set
  if tags.nil?
    fail ArgumentError, "Missing the required parameter 'tags' when calling DispatchApi.put_destination_tags"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/tags'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tags)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#put_destination_tags\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_dispatch_tags(dispatch_id, tags, opts = {}) ⇒ nil

Add tags to a Dispatch Applies the provided tags to the dispatch. Tags are used to easily identify resources. Adding tags can enable more refined searches when making calls to certain endpoints (e.g. GetDispatches).

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (nil)


1817
1818
1819
1820
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1817

def put_dispatch_tags(dispatch_id, tags, opts = {})
  put_dispatch_tags_with_http_info(dispatch_id, tags, opts)
  nil
end

#put_dispatch_tags_batch(batch, opts = {}) ⇒ nil

Add a group of tags to a group of Dispatches Applies all of the provided tags on all of the provided dispatches. Tags are used to easily identify resources. Adding tags can enable more refined searches when making calls to certain endpoints (e.g. GetDispatches).

Parameters:

  • batch

    Array of ids, and array of tags for bulk tag operations

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

    the optional parameters

Returns:

  • (nil)


1876
1877
1878
1879
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1876

def put_dispatch_tags_batch(batch, opts = {})
  put_dispatch_tags_batch_with_http_info(batch, opts)
  nil
end

#put_dispatch_tags_batch_with_http_info(batch, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Add a group of tags to a group of Dispatches Applies all of the provided tags on all of the provided dispatches. Tags are used to easily identify resources. Adding tags can enable more refined searches when making calls to certain endpoints (e.g. GetDispatches).

Parameters:

  • batch

    Array of ids, and array of tags for bulk tag operations

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1886

def put_dispatch_tags_batch_with_http_info(batch, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.put_dispatch_tags_batch ...'
  end
  # verify the required parameter 'batch' is set
  if batch.nil?
    fail ArgumentError, "Missing the required parameter 'batch' when calling DispatchApi.put_dispatch_tags_batch"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/tags'

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(batch)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#put_dispatch_tags_batch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#put_dispatch_tags_with_http_info(dispatch_id, tags, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Add tags to a Dispatch Applies the provided tags to the dispatch. Tags are used to easily identify resources. Adding tags can enable more refined searches when making calls to certain endpoints (e.g. GetDispatches).

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1828

def put_dispatch_tags_with_http_info(dispatch_id, tags, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.put_dispatch_tags ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.put_dispatch_tags"
  end
  # verify the required parameter 'tags' is set
  if tags.nil?
    fail ArgumentError, "Missing the required parameter 'tags' when calling DispatchApi.put_dispatch_tags"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/tags'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(tags)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#put_dispatch_tags\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#reset_destination_dispatch_registration_count(destination_id, opts = {}) ⇒ nil

Reset registration counts for a Destination’s Dispatches Clears the registration count for all dispatches distributed to the destination. This resets the registration counter on the dispatch itself, but has no effect on the existing registrations. Can be used in situations where the license for the course material has been renewed.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


1930
1931
1932
1933
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1930

def reset_destination_dispatch_registration_count(destination_id, opts = {})
  reset_destination_dispatch_registration_count_with_http_info(destination_id, opts)
  nil
end

#reset_destination_dispatch_registration_count_with_http_info(destination_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Reset registration counts for a Destination&#39;s Dispatches Clears the registration count for all dispatches distributed to the destination. This resets the registration counter on the dispatch itself, but has no effect on the existing registrations. Can be used in situations where the license for the course material has been renewed.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1940

def reset_destination_dispatch_registration_count_with_http_info(destination_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.reset_destination_dispatch_registration_count ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.reset_destination_dispatch_registration_count"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches/registrationCount'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#reset_destination_dispatch_registration_count\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#reset_dispatch_registration_count(dispatch_id, opts = {}) ⇒ nil

Reset registration count for a Dispatch Clears the registration count for the dispatch. This resets the registration counter on the dispatch itself, but has no effect on the existing registrations. Can be used in situations where the license for the course material has been renewed.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (nil)


1984
1985
1986
1987
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1984

def reset_dispatch_registration_count(dispatch_id, opts = {})
  reset_dispatch_registration_count_with_http_info(dispatch_id, opts)
  nil
end

#reset_dispatch_registration_count_with_http_info(dispatch_id, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Reset registration count for a Dispatch Clears the registration count for the dispatch. This resets the registration counter on the dispatch itself, but has no effect on the existing registrations. Can be used in situations where the license for the course material has been renewed.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 1994

def reset_dispatch_registration_count_with_http_info(dispatch_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.reset_dispatch_registration_count ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.reset_dispatch_registration_count"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/registrationCount'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = nil
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#reset_dispatch_registration_count\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#set_destination(destination_id, destination, opts = {}) ⇒ nil

Create or update a Destination Creates or updates information about the destination. -If the destination is being created, a name should be provided in the DestinationSchema. If one is not present in the request an error will be thrown. -If the destination is instead being updated, only non-null values that are provided will be updated. You may also optionally supply the e-mail address of the user to be associated with this destination. This e-mail address should correspond to a SCORM Cloud user account. >Note: >While the "updated" and "created" values are present in the destination schema, any attempts to manually change those values with SetDestination will be ignored.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


2039
2040
2041
2042
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2039

def set_destination(destination_id, destination, opts = {})
  set_destination_with_http_info(destination_id, destination, opts)
  nil
end

#set_destination_dispatch_enabled(destination_id, enabled, opts = {}) ⇒ nil

Update enabled status for a Destination’s Dispatches Updates the enabled status for all dispatches distributed to the destination. This is an access control measure allowing you to turn access to a previously distributed dispatch packages on or off.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


2099
2100
2101
2102
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2099

def set_destination_dispatch_enabled(destination_id, enabled, opts = {})
  set_destination_dispatch_enabled_with_http_info(destination_id, enabled, opts)
  nil
end

#set_destination_dispatch_enabled_with_http_info(destination_id, enabled, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Update enabled status for a Destination&#39;s Dispatches Updates the enabled status for all dispatches distributed to the destination. This is an access control measure allowing you to turn access to a previously distributed dispatch packages on or off.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2110

def set_destination_dispatch_enabled_with_http_info(destination_id, enabled, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.set_destination_dispatch_enabled ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.set_destination_dispatch_enabled"
  end
  # verify the required parameter 'enabled' is set
  if enabled.nil?
    fail ArgumentError, "Missing the required parameter 'enabled' when calling DispatchApi.set_destination_dispatch_enabled"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches/enabled'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(enabled)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:POST, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#set_destination_dispatch_enabled\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#set_destination_with_http_info(destination_id, destination, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Create or update a Destination Creates or updates information about the destination. -If the destination is being created, a name should be provided in the DestinationSchema. If one is not present in the request an error will be thrown. -If the destination is instead being updated, only non-null values that are provided will be updated. You may also optionally supply the e-mail address of the user to be associated with this destination. This e-mail address should correspond to a SCORM Cloud user account. &gt;Note: &gt;While the &quot;updated&quot; and &quot;created&quot; values are present in the destination schema, any attempts to manually change those values with SetDestination will be ignored.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2050

def set_destination_with_http_info(destination_id, destination, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.set_destination ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.set_destination"
  end
  # verify the required parameter 'destination' is set
  if destination.nil?
    fail ArgumentError, "Missing the required parameter 'destination' when calling DispatchApi.set_destination"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(destination)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#set_destination\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#set_dispatch_enabled(dispatch_id, enabled, opts = {}) ⇒ nil

Update enabled status for a Dispatch Updates the enabled status for the dispatch. This is an access control measure allowing you to turn access to a previously distributed dispatch packages on or off.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (nil)


2159
2160
2161
2162
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2159

def set_dispatch_enabled(dispatch_id, enabled, opts = {})
  set_dispatch_enabled_with_http_info(dispatch_id, enabled, opts)
  nil
end

#set_dispatch_enabled_with_http_info(dispatch_id, enabled, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Update enabled status for a Dispatch Updates the enabled status for the dispatch. This is an access control measure allowing you to turn access to a previously distributed dispatch packages on or off.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2170

def set_dispatch_enabled_with_http_info(dispatch_id, enabled, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.set_dispatch_enabled ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.set_dispatch_enabled"
  end
  # verify the required parameter 'enabled' is set
  if enabled.nil?
    fail ArgumentError, "Missing the required parameter 'enabled' when calling DispatchApi.set_dispatch_enabled"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/enabled'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(enabled)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#set_dispatch_enabled\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#update_destination_hash_user_info(destination_id, enabled, opts = {}) ⇒ nil

Update user PII hashing status for a Destination Updates user PII hashing status for the destination. Enabling it will cause all user PII to be hashed. Hashing PII will anonymize the learner data from the dispatched course. This will make looking up specific details about a learner difficult.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (nil)


2219
2220
2221
2222
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2219

def (destination_id, enabled, opts = {})
  (destination_id, enabled, opts)
  nil
end

#update_destination_hash_user_info_with_http_info(destination_id, enabled, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Update user PII hashing status for a Destination Updates user PII hashing status for the destination. Enabling it will cause all user PII to be hashed. Hashing PII will anonymize the learner data from the dispatched course. This will make looking up specific details about a learner difficult.

Parameters:

  • destination_id

    Identifier for the destination

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2230

def (destination_id, enabled, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.update_destination_hash_user_info ...'
  end
  # verify the required parameter 'destination_id' is set
  if destination_id.nil?
    fail ArgumentError, "Missing the required parameter 'destination_id' when calling DispatchApi.update_destination_hash_user_info"
  end
  # verify the required parameter 'enabled' is set
  if enabled.nil?
    fail ArgumentError, "Missing the required parameter 'enabled' when calling DispatchApi.update_destination_hash_user_info"
  end
  # resource path
  local_var_path = '/dispatch/destinations/{destinationId}/dispatches/hashUserInfo'.sub('{' + 'destinationId' + '}', destination_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(enabled)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#update_destination_hash_user_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#update_dispatch(dispatch_id, dispatch_properties, opts = {}) ⇒ nil

Update information about a Dispatch Updates information about the dispatch, such as the expiration date and registration cap. Only non-null values that are provided will be updated.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (nil)


2279
2280
2281
2282
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2279

def update_dispatch(dispatch_id, dispatch_properties, opts = {})
  update_dispatch_with_http_info(dispatch_id, dispatch_properties, opts)
  nil
end

#update_dispatch_hash_user_info(dispatch_id, enabled, opts = {}) ⇒ nil

Update user PII hashing status for a Dispatch Updates user PII hashing status for the dispatch. Enabling it will cause all user PII to be hashed. Hashing PII will anonymize the learner data from the dispatched course. This will make looking up specific details about a learner difficult.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (nil)


2339
2340
2341
2342
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2339

def (dispatch_id, enabled, opts = {})
  (dispatch_id, enabled, opts)
  nil
end

#update_dispatch_hash_user_info_with_http_info(dispatch_id, enabled, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Update user PII hashing status for a Dispatch Updates user PII hashing status for the dispatch. Enabling it will cause all user PII to be hashed. Hashing PII will anonymize the learner data from the dispatched course. This will make looking up specific details about a learner difficult.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2350

def (dispatch_id, enabled, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.update_dispatch_hash_user_info ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.update_dispatch_hash_user_info"
  end
  # verify the required parameter 'enabled' is set
  if enabled.nil?
    fail ArgumentError, "Missing the required parameter 'enabled' when calling DispatchApi.update_dispatch_hash_user_info"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}/hashUserInfo'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(enabled)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#update_dispatch_hash_user_info\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#update_dispatch_with_http_info(dispatch_id, dispatch_properties, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Update information about a Dispatch Updates information about the dispatch, such as the expiration date and registration cap. Only non-null values that are provided will be updated.

Parameters:

  • dispatch_id

    Identifier for the dispatch

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

    the optional parameters

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2290

def update_dispatch_with_http_info(dispatch_id, dispatch_properties, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.update_dispatch ...'
  end
  # verify the required parameter 'dispatch_id' is set
  if dispatch_id.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_id' when calling DispatchApi.update_dispatch"
  end
  # verify the required parameter 'dispatch_properties' is set
  if dispatch_properties.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_properties' when calling DispatchApi.update_dispatch"
  end
  # resource path
  local_var_path = '/dispatch/dispatches/{dispatchId}'.sub('{' + 'dispatchId' + '}', dispatch_id.to_s)

  # query parameters
  query_params = {}

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(dispatch_properties)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#update_dispatch\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#update_dispatches(dispatch_properties, opts = {}) ⇒ nil

Update a group of Dispatches Updates information about a group of dispatches, such as registration cap, expiration date, and postback information. Can be filtered using the request parameters to provide a subset of results. >Note: >One of the filter parameters (i.e. ‘courseId`, `since`/`until`, `tags`, or `filter`) needs to be provided. This is to prevent accidental modification of all dispatches. If you do wish to update all dispatches, try setting the since parameter to a value prior to the creation of any dispatches. >Info: >If using one of our client libraries, refer to its README for additional information on how to work with the `X-Total-Count` header.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against (default to updated)

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter. (default to dispatch_id)

Returns:

  • (nil)


2405
2406
2407
2408
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2405

def update_dispatches(dispatch_properties, opts = {})
  update_dispatches_with_http_info(dispatch_properties, opts)
  nil
end

#update_dispatches_with_http_info(dispatch_properties, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Update a group of Dispatches Updates information about a group of dispatches, such as registration cap, expiration date, and postback information. Can be filtered using the request parameters to provide a subset of results. &gt;Note: &gt;One of the filter parameters (i.e. &#x60;courseId&#x60;, &#x60;since&#x60;/&#x60;until&#x60;, &#x60;tags&#x60;, or &#x60;filter&#x60;) needs to be provided. This is to prevent accidental modification of all dispatches. If you do wish to update all dispatches, try setting the since parameter to a value prior to the creation of any dispatches. &gt;Info: &gt;If using one of our client libraries, refer to its README for additional information on how to work with the &#x60;X-Total-Count&#x60; header.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :course_id (String)

    Only retrieve resources having &#x60;courseId&#x60;

  • :since (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :_until (DateTime)

    Filter by ISO 8601 TimeStamp inclusive (defaults to UTC)

  • :datetime_filter (String)

    Specifies field that &#x60;since&#x60; and &#x60;until&#x60; parameters are applied against

  • :tags (Array<String>)

    Filter items matching any tag provided (not all)

  • :filter (String)

    Optional string which filters results by a specified field (described by filterBy).

  • :filter_by (String)

    Optional enum parameter for specifying the field on which to run the filter.

Returns:

  • (Array<(nil, Fixnum, Hash)>)

    nil, response status code and response headers



2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
# File 'lib/rustici_software_cloud_v2/api/dispatch_api.rb', line 2422

def update_dispatches_with_http_info(dispatch_properties, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: DispatchApi.update_dispatches ...'
  end
  # verify the required parameter 'dispatch_properties' is set
  if dispatch_properties.nil?
    fail ArgumentError, "Missing the required parameter 'dispatch_properties' when calling DispatchApi.update_dispatches"
  end
  # resource path
  local_var_path = '/dispatch/dispatches'

  # query parameters
  query_params = {}
  query_params[:'courseId'] = opts[:'course_id'] if !opts[:'course_id'].nil?
  query_params[:'since'] = opts[:'since'] if !opts[:'since'].nil?
  query_params[:'until'] = opts[:'_until'] if !opts[:'_until'].nil?
  query_params[:'datetimeFilter'] = opts[:'datetime_filter'] if !opts[:'datetime_filter'].nil?
  query_params[:'tags'] = @api_client.build_collection_param(opts[:'tags'], :csv) if !opts[:'tags'].nil?
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'filterBy'] = opts[:'filter_by'] if !opts[:'filter_by'].nil?

  # header parameters
  header_params = {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])
  # HTTP header 'Content-Type'
  header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])

  # form parameters
  form_params = {}

  # http body (model)
  post_body = @api_client.object_to_http_body(dispatch_properties)
  auth_names = ['APP_NORMAL', 'OAUTH']
  data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: DispatchApi#update_dispatches\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end