toJson method
Converts this object to TDLib JSON.
Implementation
@override
Map<String, dynamic> toJson() => {
'@type': CONSTRUCTOR,
'id': id,
'sender_id': senderId.toJson(),
'chat_id': chatId,
'sending_state': sendingState?.toJson(),
'scheduling_state': schedulingState?.toJson(),
'is_outgoing': isOutgoing,
'is_pinned': isPinned,
'can_be_edited': canBeEdited,
'can_be_forwarded': canBeForwarded,
'can_be_replied_in_another_chat': canBeRepliedInAnotherChat,
'can_be_saved': canBeSaved,
'can_be_deleted_only_for_self': canBeDeletedOnlyForSelf,
'can_be_deleted_for_all_users': canBeDeletedForAllUsers,
'can_get_added_reactions': canGetAddedReactions,
'can_get_statistics': canGetStatistics,
'can_get_message_thread': canGetMessageThread,
'can_get_read_date': canGetReadDate,
'can_get_viewers': canGetViewers,
'can_get_media_timestamp_links': canGetMediaTimestampLinks,
'can_report_reactions': canReportReactions,
'has_timestamped_media': hasTimestampedMedia,
'is_channel_post': isChannelPost,
'is_topic_message': isTopicMessage,
'contains_unread_mention': containsUnreadMention,
'date': date,
'edit_date': editDate,
'forward_info': forwardInfo?.toJson(),
'import_info': importInfo?.toJson(),
'interaction_info': interactionInfo?.toJson(),
'unread_reactions': [for (final e in unreadReactions) e.toJson()],
'reply_to': replyTo?.toJson(),
'message_thread_id': messageThreadId,
'saved_messages_topic_id': savedMessagesTopicId,
'self_destruct_type': selfDestructType?.toJson(),
'self_destruct_in': selfDestructIn,
'auto_delete_in': autoDeleteIn,
'via_bot_user_id': viaBotUserId,
'sender_boost_count': senderBoostCount,
'author_signature': authorSignature,
'media_album_id': mediaAlbumId.toString(),
'restriction_reason': restrictionReason,
'content': content.toJson(),
'reply_markup': replyMarkup?.toJson(),
};