CallConfig constructor

const CallConfig({
  1. required String roomName,
  2. String? initialUserName,
  3. String? userId,
  4. required bool isOwner,
  5. required bool initialCameraEnabled,
  6. required bool initialMicrophoneEnabled,
  7. required RecordingMode recordingMode,
  8. @JsonKey(fromJson: _dateTimeFromInt) DateTime? roomExpiration,
  9. @JsonKey(fromJson: _durationFromInt) Duration? tokenExpiration,
  10. @JsonKey(fromJson: _dateTimeFromInt) DateTime? roomNotBefore,
  11. @JsonKey(fromJson: _dateTimeFromInt) DateTime? tokenNotBefore,
  12. required bool ejectAtRoomExpiration,
  13. required bool ejectAtTokenExpiration,
  14. required ParticipantPermissions permissionsOnJoin,
  15. @Default([]) List<StreamingEndpoint> defaultStreamingEndpoints,
  16. required bool terseLoggingEnabled,
})

Implementation

const factory CallConfig({
  /// The name of the room.
  required String roomName,

  /// An optional displayed username that clients will initially assigned when connecting to the room. Clients can
  /// change their username using [CallClient.setUsername].
  String? initialUserName,

  /// The current user's ID.
  String? userId,

  /// Whether the current user is the owner of this room.
  ///
  /// See [Meeting owner privileges](https://docs.daily.co/guides/configurations-and-settings/controlling-who-joins-a-meeting#meeting-owner-privileges).
  required bool isOwner,

  /// Whether participants' camera will initially be enabled by default when joining the room.
  required bool initialCameraEnabled,

  /// Whether participants' microphone will initially be enabled by default when joining the room.
  required bool initialMicrophoneEnabled,

  /// The recording mode set for the room.
  ///
  /// See [recording documentation](https://docs.daily.co/guides/products/live-streaming-recording/recording-calls-with-the-daily-api) for more information.
  required RecordingMode recordingMode,

  /// If set, users will be unable to join the room after this time.
  @JsonKey(fromJson: _dateTimeFromInt) DateTime? roomExpiration,

  /// If set, tokens to enter private rooms expire after this duration.
  ///
  /// See [Meeting tokens](https://docs.daily.co/guides/configurations-and-settings/controlling-who-joins-a-meeting#meeting-tokens).
  @JsonKey(fromJson: _durationFromInt) Duration? tokenExpiration,

  /// If set, the room cannot be entered before this time.
  @JsonKey(fromJson: _dateTimeFromInt) DateTime? roomNotBefore,

  /// If set, tokens to enter private rooms cannot be used before this time.
  ///
  /// See [Meeting tokens](https://docs.daily.co/guides/configurations-and-settings/controlling-who-joins-a-meeting#meeting-tokens).
  @JsonKey(fromJson: _dateTimeFromInt) DateTime? tokenNotBefore,

  /// Whether or not all users are ejected from the room when it expires.
  required bool ejectAtRoomExpiration,

  /// Whether or not a user that entered a private room using a token will be ejected when their token expires.
  ///
  /// See [Meeting tokens](https://docs.daily.co/guides/configurations-and-settings/controlling-who-joins-a-meeting#meeting-tokens).
  required bool ejectAtTokenExpiration,

  /// Initial default permissions for a non-meeting-owner participant joining a call.
  required ParticipantPermissions permissionsOnJoin,

  /// Default streaming endpoints for the room.
  ///
  /// See [StreamingSettings].
  @Default([]) List<StreamingEndpoint> defaultStreamingEndpoints,

  /// If true, logging is limited to reduce performance overhead.
  required bool terseLoggingEnabled,
}) = _CallConfig;