toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final json = <String, dynamic>{};
    json[r'id'] = this.id;
    json[r'userId'] = this.userId;
    json[r'notificationType'] = this.notificationType;
  if (this.sentToRecipients != null) {
    json[r'sentToRecipients'] = this.sentToRecipients;
  } else {
    json[r'sentToRecipients'] = null;
  }
    json[r'sender'] = this.sender;
  if (this.bounceMta != null) {
    json[r'bounceMta'] = this.bounceMta;
  } else {
    json[r'bounceMta'] = null;
  }
  if (this.bounceType != null) {
    json[r'bounceType'] = this.bounceType;
  } else {
    json[r'bounceType'] = null;
  }
  if (this.bounceRecipients != null) {
    json[r'bounceRecipients'] = this.bounceRecipients;
  } else {
    json[r'bounceRecipients'] = null;
  }
  if (this.bounceSubType != null) {
    json[r'bounceSubType'] = this.bounceSubType;
  } else {
    json[r'bounceSubType'] = null;
  }
  if (this.sentEmailId != null) {
    json[r'sentEmailId'] = this.sentEmailId;
  } else {
    json[r'sentEmailId'] = null;
  }
  if (this.subject != null) {
    json[r'subject'] = this.subject;
  } else {
    json[r'subject'] = null;
  }
    json[r'createdAt'] = this.createdAt.toUtc().toIso8601String();
  return json;
}