GroupChannelScheduledFileMessageSendRequest constructor Null safety
- {required String channelUrl,
- required ScheduledFileMessageParams params}
Implementation
GroupChannelScheduledFileMessageSendRequest({
required String channelUrl,
required ScheduledFileMessageParams params,
}) : super() {
if (userId == null) {
throw InvalidParameterError;
}
url = 'group_channels/$channelUrl/scheduled_messages';
body = {
'user_id': userId,
'message_type': 'FILE',
};
body.addAll(params.toJson());
body.remove('file');
}