class NotificationRequest { String? priority; List? registrationIds; Data? data; Notification? notification; NotificationRequest( {this.priority, this.registrationIds, this.data, this.notification}); NotificationRequest.fromJson(Map json) { priority = json['priority']; registrationIds = json['registration_ids'].cast(); data = json['data'] != null ? new Data.fromJson(json['data']) : null; notification = json['notification'] != null ? new Notification.fromJson(json['notification']) : null; } Map toJson() { final Map data = new Map(); data['priority'] = this.priority; data['registration_ids'] = this.registrationIds; if (this.data != null) { data['data'] = this.data!.toJson(); } if (this.notification != null) { data['notification'] = this.notification!.toJson(); } return data; } } class Data { String? accessid; Data({this.accessid}); Data.fromJson(Map json) { accessid = json['accessid']; } Map toJson() { final Map data = new Map(); data['accessid'] = this.accessid; return data; } } class Notification { String? title; String? body; String? sound; Notification({this.title, this.body, this.sound}); Notification.fromJson(Map json) { title = json['title']; body = json['body']; sound = json['sound']; } Map toJson() { final Map data = new Map(); data['title'] = this.title; data['body'] = this.body; data['sound'] = this.sound; return data; } }