Class: RusticiSoftwareCloudV2::XapiApi

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ XapiApi

Returns a new instance of XapiApi.



18
19
20
# File 'lib/rustici_software_cloud_v2/api/xapi_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/xapi_api.rb', line 16

def api_client
  @api_client
end

Instance Method Details

#create_statement_pipe(xapi_statement_pipe, opts = {}) ⇒ StringResultSchema

Create an xAPI Statement Pipe Creates an xAPI statement pipe. >Note: >This method is asynchronous. A returned success status indicates a background process has been started, but there will still be a delay before the creation of the xAPI statement pipe takes place.

Parameters:

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

    the optional parameters

Returns:



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

def create_statement_pipe(xapi_statement_pipe, opts = {})
  data, _status_code, _headers = create_statement_pipe_with_http_info(xapi_statement_pipe, opts)
  data
end

#create_statement_pipe_with_http_info(xapi_statement_pipe, opts = {}) ⇒ Array<(StringResultSchema, Fixnum, Hash)>

Create an xAPI Statement Pipe Creates an xAPI statement pipe. &gt;Note: &gt;This method is asynchronous. A returned success status indicates a background process has been started, but there will still be a delay before the creation of the xAPI statement pipe takes place.

Parameters:

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

    the optional parameters

Returns:

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

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

def create_statement_pipe_with_http_info(xapi_statement_pipe, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.create_statement_pipe ...'
  end
  # verify the required parameter 'xapi_statement_pipe' is set
  if xapi_statement_pipe.nil?
    fail ArgumentError, "Missing the required parameter 'xapi_statement_pipe' when calling XapiApi.create_statement_pipe"
  end
  # resource path
  local_var_path = '/xapi/statementPipes'

  # 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(xapi_statement_pipe)
  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,
    :return_type => 'StringResultSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XapiApi#create_statement_pipe\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#create_xapi_credential(xapi_credential, opts = {}) ⇒ StringResultSchema

Create xAPI Credentials Creates an xAPI credential combination from the provided secret and a generated ID.

Parameters:

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

    the optional parameters

Returns:



84
85
86
87
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 84

def create_xapi_credential(xapi_credential, opts = {})
  data, _status_code, _headers = create_xapi_credential_with_http_info(xapi_credential, opts)
  data
end

#create_xapi_credential_with_http_info(xapi_credential, opts = {}) ⇒ Array<(StringResultSchema, Fixnum, Hash)>

Create xAPI Credentials Creates an xAPI credential combination from the provided secret and a generated ID.

Parameters:

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

    the optional parameters

Returns:

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

    StringResultSchema data, response status code and response headers



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
131
132
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 94

def create_xapi_credential_with_http_info(xapi_credential, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.create_xapi_credential ...'
  end
  # verify the required parameter 'xapi_credential' is set
  if xapi_credential.nil?
    fail ArgumentError, "Missing the required parameter 'xapi_credential' when calling XapiApi.create_xapi_credential"
  end
  # resource path
  local_var_path = '/xapi/credentials'

  # 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(xapi_credential)
  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,
    :return_type => 'StringResultSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XapiApi#create_xapi_credential\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_statement_pipe(statement_pipe_id, opts = {}) ⇒ nil

Delete an xAPI Statement Pipe Deletes the specified xAPI statement pipe >Note: >This method is asynchronous. A returned success status indicates a background process has been started, but there will still be a delay before the deletion takes place. Recreating a statement pipe with the same ID too quickly could cause the statement pipe to end up in a faulty state.

Parameters:

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

    the optional parameters

Returns:

  • (nil)


139
140
141
142
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 139

def delete_statement_pipe(statement_pipe_id, opts = {})
  delete_statement_pipe_with_http_info(statement_pipe_id, opts)
  nil
end

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

Delete an xAPI Statement Pipe Deletes the specified xAPI statement pipe &gt;Note: &gt;This method is asynchronous. A returned success status indicates a background process has been started, but there will still be a delay before the deletion takes place. Recreating a statement pipe with the same ID too quickly could cause the statement pipe to end up in a faulty state.

Parameters:

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

    the optional parameters

Returns:

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

    nil, response status code and response headers



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
185
186
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 149

def delete_statement_pipe_with_http_info(statement_pipe_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.delete_statement_pipe ...'
  end
  # verify the required parameter 'statement_pipe_id' is set
  if statement_pipe_id.nil?
    fail ArgumentError, "Missing the required parameter 'statement_pipe_id' when calling XapiApi.delete_statement_pipe"
  end
  # resource path
  local_var_path = '/xapi/statementPipes/{statementPipeId}'.sub('{' + 'statementPipeId' + '}', statement_pipe_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: XapiApi#delete_statement_pipe\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#delete_xapi_credential(xapi_credential_id, opts = {}) ⇒ nil

Delete xAPI Credentials Deletes the specified xAPI credentials.

Parameters:

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

    the optional parameters

Returns:

  • (nil)


193
194
195
196
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 193

def delete_xapi_credential(xapi_credential_id, opts = {})
  delete_xapi_credential_with_http_info(xapi_credential_id, opts)
  nil
end

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

Delete xAPI Credentials Deletes the specified xAPI credentials.

Parameters:

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

    the optional parameters

Returns:

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

    nil, response status code and response headers



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
239
240
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 203

def delete_xapi_credential_with_http_info(xapi_credential_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.delete_xapi_credential ...'
  end
  # verify the required parameter 'xapi_credential_id' is set
  if xapi_credential_id.nil?
    fail ArgumentError, "Missing the required parameter 'xapi_credential_id' when calling XapiApi.delete_xapi_credential"
  end
  # resource path
  local_var_path = '/xapi/credentials/{xapiCredentialId}'.sub('{' + 'xapiCredentialId' + '}', xapi_credential_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: XapiApi#delete_xapi_credential\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_statement_pipe(statement_pipe_id, opts = {}) ⇒ XapiStatementPipeSchema

Get detailed information about an xAPI Statement Pipe Returns detailed information about the xAPI pipe. This includes source and target urls, the last time a statement was successfully forwarded, and how many attempts have been made to send data to the target url.

Parameters:

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

    the optional parameters

Returns:



247
248
249
250
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 247

def get_statement_pipe(statement_pipe_id, opts = {})
  data, _status_code, _headers = get_statement_pipe_with_http_info(statement_pipe_id, opts)
  data
end

#get_statement_pipe_with_http_info(statement_pipe_id, opts = {}) ⇒ Array<(XapiStatementPipeSchema, Fixnum, Hash)>

Get detailed information about an xAPI Statement Pipe Returns detailed information about the xAPI pipe. This includes source and target urls, the last time a statement was successfully forwarded, and how many attempts have been made to send data to the target url.

Parameters:

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

    the optional parameters

Returns:

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

    XapiStatementPipeSchema data, 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
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 257

def get_statement_pipe_with_http_info(statement_pipe_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.get_statement_pipe ...'
  end
  # verify the required parameter 'statement_pipe_id' is set
  if statement_pipe_id.nil?
    fail ArgumentError, "Missing the required parameter 'statement_pipe_id' when calling XapiApi.get_statement_pipe"
  end
  # resource path
  local_var_path = '/xapi/statementPipes/{statementPipeId}'.sub('{' + 'statementPipeId' + '}', statement_pipe_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 => 'XapiStatementPipeSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XapiApi#get_statement_pipe\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_statement_pipes(opts = {}) ⇒ XapiStatementPipeListSchema

Get a list of xAPI Statement Pipes Returns a list of all xAPI statement pipes.

Parameters:

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

    the optional parameters

Returns:



301
302
303
304
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 301

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

#get_statement_pipes_with_http_info(opts = {}) ⇒ Array<(XapiStatementPipeListSchema, Fixnum, Hash)>

Get a list of xAPI Statement Pipes Returns a list of all xAPI statement pipes.

Parameters:

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

    the optional parameters

Returns:



310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 310

def get_statement_pipes_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.get_statement_pipes ...'
  end
  # resource path
  local_var_path = '/xapi/statementPipes'

  # 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 => 'XapiStatementPipeListSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XapiApi#get_statement_pipes\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_xapi_credential(xapi_credential_id, opts = {}) ⇒ XapiCredentialSchema

Get detailed information about the xAPI Credentials Returns detailed information about the xAPI credentials. This includes the id (username), secret (password), permissions, and whether or not the credentials are enabled.

Parameters:

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

    the optional parameters

Returns:



351
352
353
354
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 351

def get_xapi_credential(xapi_credential_id, opts = {})
  data, _status_code, _headers = get_xapi_credential_with_http_info(xapi_credential_id, opts)
  data
end

#get_xapi_credential_with_http_info(xapi_credential_id, opts = {}) ⇒ Array<(XapiCredentialSchema, Fixnum, Hash)>

Get detailed information about the xAPI Credentials Returns detailed information about the xAPI credentials. This includes the id (username), secret (password), permissions, and whether or not the credentials are enabled.

Parameters:

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

    the optional parameters

Returns:

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

    XapiCredentialSchema data, response status code and response headers



361
362
363
364
365
366
367
368
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
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 361

def get_xapi_credential_with_http_info(xapi_credential_id, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.get_xapi_credential ...'
  end
  # verify the required parameter 'xapi_credential_id' is set
  if xapi_credential_id.nil?
    fail ArgumentError, "Missing the required parameter 'xapi_credential_id' when calling XapiApi.get_xapi_credential"
  end
  # resource path
  local_var_path = '/xapi/credentials/{xapiCredentialId}'.sub('{' + 'xapiCredentialId' + '}', xapi_credential_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 => 'XapiCredentialSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XapiApi#get_xapi_credential\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_xapi_credentials(opts = {}) ⇒ XapiCredentialsListSchema

Get a list of xAPI Credentials Returns a list of xAPI credentials. 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.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :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)

  • :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 credential_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:



413
414
415
416
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 413

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

#get_xapi_credentials_with_http_info(opts = {}) ⇒ Array<(XapiCredentialsListSchema, Fixnum, Hash)>

Get a list of xAPI Credentials Returns a list of xAPI credentials. 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.

Parameters:

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

    the optional parameters

Options Hash (opts):

  • :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

  • :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<(XapiCredentialsListSchema, Fixnum, Hash)>)

    XapiCredentialsListSchema data, response status code and response headers



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
467
468
469
470
471
472
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 430

def get_xapi_credentials_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.get_xapi_credentials ...'
  end
  # resource path
  local_var_path = '/xapi/credentials'

  # query parameters
  query_params = {}
  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[:'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 => 'XapiCredentialsListSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XapiApi#get_xapi_credentials\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#set_statement_pipe(statement_pipe_id, xapi_statement_pipe, opts = {}) ⇒ StringResultSchema

Create or update an xAPI Statement Pipe Creates or updates information about the xAPI statement pipe. - If the xAPI statement pipe is instead being updated, the pipe will start over and forward any statements it finds, even if it had already forwarded those statements. If the pipe being edited is currently being processed, then this request will fail with a status code of 409. >Note: >This method is asynchronous. A returned success status indicates a background process has been started, but there will still be a delay before the creation of the xAPI statement pipe takes place.

Parameters:

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

    the optional parameters

Returns:



480
481
482
483
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 480

def set_statement_pipe(statement_pipe_id, xapi_statement_pipe, opts = {})
  data, _status_code, _headers = set_statement_pipe_with_http_info(statement_pipe_id, xapi_statement_pipe, opts)
  data
end

#set_statement_pipe_with_http_info(statement_pipe_id, xapi_statement_pipe, opts = {}) ⇒ Array<(StringResultSchema, Fixnum, Hash)>

Create or update an xAPI Statement Pipe Creates or updates information about the xAPI statement pipe. - If the xAPI statement pipe is instead being updated, the pipe will start over and forward any statements it finds, even if it had already forwarded those statements. If the pipe being edited is currently being processed, then this request will fail with a status code of 409. &gt;Note: &gt;This method is asynchronous. A returned success status indicates a background process has been started, but there will still be a delay before the creation of the xAPI statement pipe takes place.

Parameters:

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

    the optional parameters

Returns:

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

    StringResultSchema data, response status code and response headers



491
492
493
494
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
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 491

def set_statement_pipe_with_http_info(statement_pipe_id, xapi_statement_pipe, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.set_statement_pipe ...'
  end
  # verify the required parameter 'statement_pipe_id' is set
  if statement_pipe_id.nil?
    fail ArgumentError, "Missing the required parameter 'statement_pipe_id' when calling XapiApi.set_statement_pipe"
  end
  # verify the required parameter 'xapi_statement_pipe' is set
  if xapi_statement_pipe.nil?
    fail ArgumentError, "Missing the required parameter 'xapi_statement_pipe' when calling XapiApi.set_statement_pipe"
  end
  # resource path
  local_var_path = '/xapi/statementPipes/{statementPipeId}'.sub('{' + 'statementPipeId' + '}', statement_pipe_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(xapi_statement_pipe)
  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,
    :return_type => 'StringResultSchema')
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: XapiApi#set_statement_pipe\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#set_xapi_credential(xapi_credential_id, xapi_credential, opts = {}) ⇒ nil

Create or update xAPI Credentials Creates or updates information about the xAPI credentials.

Parameters:

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

    the optional parameters

Returns:

  • (nil)


541
542
543
544
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 541

def set_xapi_credential(xapi_credential_id, xapi_credential, opts = {})
  set_xapi_credential_with_http_info(xapi_credential_id, xapi_credential, opts)
  nil
end

#set_xapi_credential_with_http_info(xapi_credential_id, xapi_credential, opts = {}) ⇒ Array<(nil, Fixnum, Hash)>

Create or update xAPI Credentials Creates or updates information about the xAPI credentials.

Parameters:

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

    the optional parameters

Returns:

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

    nil, response status code and response headers



552
553
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
# File 'lib/rustici_software_cloud_v2/api/xapi_api.rb', line 552

def set_xapi_credential_with_http_info(xapi_credential_id, xapi_credential, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: XapiApi.set_xapi_credential ...'
  end
  # verify the required parameter 'xapi_credential_id' is set
  if xapi_credential_id.nil?
    fail ArgumentError, "Missing the required parameter 'xapi_credential_id' when calling XapiApi.set_xapi_credential"
  end
  # verify the required parameter 'xapi_credential' is set
  if xapi_credential.nil?
    fail ArgumentError, "Missing the required parameter 'xapi_credential' when calling XapiApi.set_xapi_credential"
  end
  # resource path
  local_var_path = '/xapi/credentials/{xapiCredentialId}'.sub('{' + 'xapiCredentialId' + '}', xapi_credential_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(xapi_credential)
  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: XapiApi#set_xapi_credential\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end