toJson method
Implementation
Map<String, dynamic> toJson() {
final ret = <String, dynamic>{
'message': message,
'scheduled_at': scheduledAt,
'custom_type': customType,
'data': data,
'mention_type': mentionType.toString().split('.').last,
'mentionedUserIds': mentionedUserIds,
'sorted_metaarray': metaArrays,
'name': appleCriticalAlertOptions?.name,
'volume': appleCriticalAlertOptions?.volume,
'push_option': pushNotificationDeliveryOption.toString().split('.').last,
'target_langs': translationTargetLanguages,
};
ret.removeWhere((key, value) => value == null);
return ret;
}