toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final _json = <String, dynamic>{};
  if (ackId != null) {
    _json[r'ack_id'] = ackId;
  }
  if (platform != null) {
    _json[r'platform'] = platform;
  }
  if (serverId != null) {
    _json[r'server_id'] = serverId;
  }
  if (deviceId != null) {
    _json[r'device_id'] = deviceId;
  }
  if (postId != null) {
    _json[r'post_id'] = postId;
  }
  if (category != null) {
    _json[r'category'] = category;
  }
  if (sound != null) {
    _json[r'sound'] = sound;
  }
  if (message != null) {
    _json[r'message'] = message;
  }
  if (badge != null) {
    _json[r'badge'] = badge;
  }
  if (contAva != null) {
    _json[r'cont_ava'] = contAva;
  }
  if (teamId != null) {
    _json[r'team_id'] = teamId;
  }
  if (channelId != null) {
    _json[r'channel_id'] = channelId;
  }
  if (rootId != null) {
    _json[r'root_id'] = rootId;
  }
  if (channelName != null) {
    _json[r'channel_name'] = channelName;
  }
  if (type != null) {
    _json[r'type'] = type;
  }
  if (senderId != null) {
    _json[r'sender_id'] = senderId;
  }
  if (senderName != null) {
    _json[r'sender_name'] = senderName;
  }
  if (overrideUsername != null) {
    _json[r'override_username'] = overrideUsername;
  }
  if (overrideIconUrl != null) {
    _json[r'override_icon_url'] = overrideIconUrl;
  }
  if (fromWebhook != null) {
    _json[r'from_webhook'] = fromWebhook;
  }
  if (version != null) {
    _json[r'version'] = version;
  }
  if (isIdLoaded != null) {
    _json[r'is_id_loaded'] = isIdLoaded;
  }
  return _json;
}