editRoom method

Future editRoom({
  1. String? roomId,
  2. String? description,
  3. String? secret,
  4. String? newSecret,
  5. String? pin,
  6. bool? isPrivate,
  7. bool? permanent,
})

editRoom
this can be used to create a new text room .
Notice that, in general, all users can create rooms. If you want to limit this functionality, you can configure an admin admin_key in the plugin settings. When configured, only "create" requests that include the correct admin_key value in an "admin_key" property will succeed, and will be rejected otherwise. Notice that you can optionally extend this functionality to RTP forwarding as well, in order to only allow trusted clients to use that feature.

roomId : unique numeric ID, optional, chosen by plugin if missing.
permanent : true|false, whether the room should be saved in the config file, default=false.
description : pretty name of the room, optional.
secret : existing password required to edit/destroy the room, optional.
newSecret : new password required to edit/destroy the room, optional.
pin : password required to join the room, optional.
isPrivate : true|false, whether the room should appear in a list request.

Implementation

Future<dynamic> editRoom(
    {String? roomId,
    String? description,
    String? secret,
    String? newSecret,
    String? pin,
    bool? isPrivate,
    bool? permanent}) async {
  var payload = {
    "textroom": "create",
    "room": roomId,
    "secret": secret,
    "permanent": permanent,
    "new_description": description,
    "new_secret": newSecret,
    "new_pin": pin,
    "new_is_private": isPrivate,
  };
  _handleRoomIdTypeDifference(payload);
  _context._logger.fine('editRoom invoked with roomId:$roomId');
  JanusEvent response = JanusEvent.fromJson(await this.send(data: payload));
  JanusError.throwErrorFromEvent(response);
  return response;
}