Class: EjabberdHttpClient::MucApi

Inherits:
Object
  • Object
show all
Defined in:
lib/ejabberd_http_client/api/muc_api.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ MucApi

Returns a new instance of MucApi.



19
20
21
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 19

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

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



17
18
19
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 17

def api_client
  @api_client
end

Instance Method Details

#create_rooms_file(create_rooms_file_request, opts = {}) ⇒ nil

Create the rooms indicated in file.

Parameters:

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

    the optional parameters

Returns:

  • (nil)


26
27
28
29
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 26

def create_rooms_file(create_rooms_file_request, opts = {})
  create_rooms_file_with_http_info(create_rooms_file_request, opts)
  nil
end

#create_rooms_file_with_http_info(create_rooms_file_request, opts = {}) ⇒ Array<(nil, Integer, Hash)>

Create the rooms indicated in file.

Parameters:

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

    the optional parameters

Returns:

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

    nil, response status code and response headers



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

def create_rooms_file_with_http_info(create_rooms_file_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.create_rooms_file ...'
  end
  # verify the required parameter 'create_rooms_file_request' is set
  if @api_client.config.client_side_validation && create_rooms_file_request.nil?
    fail ArgumentError, "Missing the required parameter 'create_rooms_file_request' when calling MucApi.create_rooms_file"
  end
  # resource path
  local_var_path = '/api/create_rooms_file'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type]

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.create_rooms_file",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#get_user_rooms(get_user_rooms_request, opts = {}) ⇒ Array<String>

Get the list of rooms where this user is occupant.

Parameters:

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

    the optional parameters

Returns:

  • (Array<String>)


90
91
92
93
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 90

def get_user_rooms(get_user_rooms_request, opts = {})
  data, _status_code, _headers = get_user_rooms_with_http_info(get_user_rooms_request, opts)
  data
end

#get_user_rooms_with_http_info(get_user_rooms_request, opts = {}) ⇒ Array<(Array<String>, Integer, Hash)>

Get the list of rooms where this user is occupant.

Parameters:

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

    the optional parameters

Returns:

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

    Array<String> data, response status code and response headers



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
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 99

def get_user_rooms_with_http_info(get_user_rooms_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.get_user_rooms ...'
  end
  # verify the required parameter 'get_user_rooms_request' is set
  if @api_client.config.client_side_validation && get_user_rooms_request.nil?
    fail ArgumentError, "Missing the required parameter 'get_user_rooms_request' when calling MucApi.get_user_rooms"
  end
  # resource path
  local_var_path = '/api/get_user_rooms'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type] || 'Array<String>'

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.get_user_rooms",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#get_user_subscriptions(get_user_rooms_request, opts = {}) ⇒ Array<GetUserSubscriptions200ResponseInner>

Get the list of rooms where this user is subscribed.

Parameters:

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

    the optional parameters

Returns:



156
157
158
159
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 156

def get_user_subscriptions(get_user_rooms_request, opts = {})
  data, _status_code, _headers = get_user_subscriptions_with_http_info(get_user_rooms_request, opts)
  data
end

#get_user_subscriptions_with_http_info(get_user_rooms_request, opts = {}) ⇒ Array<(Array<GetUserSubscriptions200ResponseInner>, Integer, Hash)>

Get the list of rooms where this user is subscribed.

Parameters:

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

    the optional parameters

Returns:



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

def get_user_subscriptions_with_http_info(get_user_rooms_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.get_user_subscriptions ...'
  end
  # verify the required parameter 'get_user_rooms_request' is set
  if @api_client.config.client_side_validation && get_user_rooms_request.nil?
    fail ArgumentError, "Missing the required parameter 'get_user_rooms_request' when calling MucApi.get_user_subscriptions"
  end
  # resource path
  local_var_path = '/api/get_user_subscriptions'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type] || 'Array<GetUserSubscriptions200ResponseInner>'

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.get_user_subscriptions",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#list_muc_online_rooms(list_muc_online_rooms_request, opts = {}) ⇒ Array<String>

List existing rooms (‘global’ to get all vhosts).

Parameters:

Returns:

  • (Array<String>)


222
223
224
225
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 222

def list_muc_online_rooms(list_muc_online_rooms_request, opts = {})
  data, _status_code, _headers = list_muc_online_rooms_with_http_info(list_muc_online_rooms_request, opts)
  data
end

#list_muc_online_rooms_by_regex(list_muc_online_rooms_by_regex_request, opts = {}) ⇒ Array<ListMucOnlineRoomsByRegex200ResponseInner>

List existing rooms (‘global’ to get all vhosts) by regex.

Parameters:

Returns:



288
289
290
291
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 288

def list_muc_online_rooms_by_regex(list_muc_online_rooms_by_regex_request, opts = {})
  data, _status_code, _headers = list_muc_online_rooms_by_regex_with_http_info(list_muc_online_rooms_by_regex_request, opts)
  data
end

#list_muc_online_rooms_by_regex_with_http_info(list_muc_online_rooms_by_regex_request, opts = {}) ⇒ Array<(Array<ListMucOnlineRoomsByRegex200ResponseInner>, Integer, Hash)>

List existing rooms (&#39;global&#39; to get all vhosts) by regex.

Parameters:

Returns:



297
298
299
300
301
302
303
304
305
306
307
308
309
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
345
346
347
348
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 297

def list_muc_online_rooms_by_regex_with_http_info(list_muc_online_rooms_by_regex_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.list_muc_online_rooms_by_regex ...'
  end
  # verify the required parameter 'list_muc_online_rooms_by_regex_request' is set
  if @api_client.config.client_side_validation && list_muc_online_rooms_by_regex_request.nil?
    fail ArgumentError, "Missing the required parameter 'list_muc_online_rooms_by_regex_request' when calling MucApi.list_muc_online_rooms_by_regex"
  end
  # resource path
  local_var_path = '/api/muc_online_rooms_by_regex'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type] || 'Array<ListMucOnlineRoomsByRegex200ResponseInner>'

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.list_muc_online_rooms_by_regex",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#list_muc_online_rooms_with_http_info(list_muc_online_rooms_request, opts = {}) ⇒ Array<(Array<String>, Integer, Hash)>

List existing rooms (&#39;global&#39; to get all vhosts).

Parameters:

Returns:

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

    Array<String> data, response status code and response headers



231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 231

def list_muc_online_rooms_with_http_info(list_muc_online_rooms_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.list_muc_online_rooms ...'
  end
  # verify the required parameter 'list_muc_online_rooms_request' is set
  if @api_client.config.client_side_validation && list_muc_online_rooms_request.nil?
    fail ArgumentError, "Missing the required parameter 'list_muc_online_rooms_request' when calling MucApi.list_muc_online_rooms"
  end
  # resource path
  local_var_path = '/api/muc_online_rooms'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type] || 'Array<String>'

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.list_muc_online_rooms",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#register_muc_nick(register_muc_nick_request, opts = {}) ⇒ nil

Register a nick to a User JID in a MUC service.

Parameters:

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

    the optional parameters

Returns:

  • (nil)


354
355
356
357
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 354

def register_muc_nick(register_muc_nick_request, opts = {})
  register_muc_nick_with_http_info(register_muc_nick_request, opts)
  nil
end

#register_muc_nick_with_http_info(register_muc_nick_request, opts = {}) ⇒ Array<(nil, Integer, Hash)>

Register a nick to a User JID in a MUC service.

Parameters:

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

    the optional parameters

Returns:

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

    nil, response status code and response headers



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
400
401
402
403
404
405
406
407
408
409
410
411
412
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 363

def register_muc_nick_with_http_info(register_muc_nick_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.register_muc_nick ...'
  end
  # verify the required parameter 'register_muc_nick_request' is set
  if @api_client.config.client_side_validation && register_muc_nick_request.nil?
    fail ArgumentError, "Missing the required parameter 'register_muc_nick_request' when calling MucApi.register_muc_nick"
  end
  # resource path
  local_var_path = '/api/muc_register_nick'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type]

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.register_muc_nick",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#rooms_empty_destroy(opts = {}) ⇒ Array<String>

Destroy the rooms that have no messages in archive.

Parameters:

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

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<String>)


418
419
420
421
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 418

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

#rooms_empty_destroy_with_http_info(opts = {}) ⇒ Array<(Array<String>, Integer, Hash)>

Destroy the rooms that have no messages in archive.

Parameters:

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

    the optional parameters

Options Hash (opts):

Returns:

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

    Array<String> data, response status code and response headers



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
467
468
469
470
471
472
473
474
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 427

def rooms_empty_destroy_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.rooms_empty_destroy ...'
  end
  # resource path
  local_var_path = '/api/rooms_empty_destroy'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type] || 'Array<String>'

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.rooms_empty_destroy",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#rooms_empty_list(opts = {}) ⇒ Array<String>

List the rooms that have no messages in archive.

Parameters:

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

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<String>)


480
481
482
483
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 480

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

#rooms_empty_list_with_http_info(opts = {}) ⇒ Array<(Array<String>, Integer, Hash)>

List the rooms that have no messages in archive.

Parameters:

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

    the optional parameters

Options Hash (opts):

Returns:

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

    Array<String> data, response status code and response headers



489
490
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
534
535
536
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 489

def rooms_empty_list_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.rooms_empty_list ...'
  end
  # resource path
  local_var_path = '/api/rooms_empty_list'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type] || 'Array<String>'

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.rooms_empty_list",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#rooms_unused_destroy(opts = {}) ⇒ Array<String>

Destroy the rooms that are unused for many days in the service.

Parameters:

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

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<String>)


542
543
544
545
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 542

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

#rooms_unused_destroy_with_http_info(opts = {}) ⇒ Array<(Array<String>, Integer, Hash)>

Destroy the rooms that are unused for many days in the service.

Parameters:

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

    the optional parameters

Options Hash (opts):

Returns:

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

    Array<String> data, response status code and response headers



551
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
594
595
596
597
598
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 551

def rooms_unused_destroy_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.rooms_unused_destroy ...'
  end
  # resource path
  local_var_path = '/api/rooms_unused_destroy'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type] || 'Array<String>'

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.rooms_unused_destroy",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#rooms_unused_list(opts = {}) ⇒ Array<String>

List the rooms that are unused for many days in the service.

Parameters:

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

    the optional parameters

Options Hash (opts):

Returns:

  • (Array<String>)


604
605
606
607
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 604

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

#rooms_unused_list_with_http_info(opts = {}) ⇒ Array<(Array<String>, Integer, Hash)>

List the rooms that are unused for many days in the service.

Parameters:

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

    the optional parameters

Options Hash (opts):

Returns:

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

    Array<String> data, response status code and response headers



613
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
654
655
656
657
658
659
660
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 613

def rooms_unused_list_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.rooms_unused_list ...'
  end
  # resource path
  local_var_path = '/api/rooms_unused_list'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type] || 'Array<String>'

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.rooms_unused_list",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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

#unregister_muc_nick(unregister_muc_nick_request, opts = {}) ⇒ nil

Unregister the nick registered by that account in the MUC service.

Parameters:

Returns:

  • (nil)


666
667
668
669
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 666

def unregister_muc_nick(unregister_muc_nick_request, opts = {})
  unregister_muc_nick_with_http_info(unregister_muc_nick_request, opts)
  nil
end

#unregister_muc_nick_with_http_info(unregister_muc_nick_request, opts = {}) ⇒ Array<(nil, Integer, Hash)>

Unregister the nick registered by that account in the MUC service.

Parameters:

Returns:

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

    nil, response status code and response headers



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
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
# File 'lib/ejabberd_http_client/api/muc_api.rb', line 675

def unregister_muc_nick_with_http_info(unregister_muc_nick_request, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: MucApi.unregister_muc_nick ...'
  end
  # verify the required parameter 'unregister_muc_nick_request' is set
  if @api_client.config.client_side_validation && unregister_muc_nick_request.nil?
    fail ArgumentError, "Missing the required parameter 'unregister_muc_nick_request' when calling MucApi.unregister_muc_nick"
  end
  # resource path
  local_var_path = '/api/muc_unregister_nick'

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

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

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

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

  # return_type
  return_type = opts[:debug_return_type]

  # auth_names
  auth_names = opts[:debug_auth_names] || []

  new_options = opts.merge(
    :operation => :"MucApi.unregister_muc_nick",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

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