using System;
namespace TL
{
#pragma warning disable IDE1006, CS1574
/// Object describes the contents of an encrypted message. See
public abstract partial class DecryptedMessageBase : IObject
{
/// Flags, see TL conditional fields (added in layer 45)
public virtual uint FFlags => default;
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public virtual long RandomId => default;
/// Message lifetime. Has higher priority than .
Parameter added in Layer 17.
public virtual int Ttl => default;
/// Message text
public virtual string Message => default;
/// Media content
public virtual DecryptedMessageMedia Media => default;
/// Message entities for styled text (parameter added in layer 45)
public virtual MessageEntity[] Entities => default;
/// Specifies the ID of the inline bot that generated the message (parameter added in layer 45)
public virtual string ViaBotName => default;
/// Random message ID of the message this message replies to (parameter added in layer 45)
public virtual long ReplyToRandom => default;
/// Random group ID, assigned by the author of message.
Multiple encrypted messages with a photo attached and with the same group ID indicate an album or grouped media (parameter added in layer 45)
public virtual long Grouped => default;
public virtual byte[] RandomBytes => default;
public virtual DecryptedMessageAction Action => default;
}
/// Object describes media contents of an encrypted message. See
/// a value means decryptedMessageMediaEmpty
public abstract partial class DecryptedMessageMedia : IObject
{
public virtual string MimeType => default;
internal virtual (long size, byte[] key, byte[] iv) SizeKeyIV { get => default; set => throw new WTelegram.WTException("Incompatible DecryptedMessageMedia"); }
}
/// Object describes the action to which a service message is linked. See
public abstract partial class DecryptedMessageAction : IObject { }
/// Indicates the location of a photo, will be deprecated soon See
public abstract partial class FileLocationBase : IObject
{
public virtual long VolumeId => default;
public virtual int LocalId => default;
public virtual long Secret => default;
}
namespace Layer8
{
/// Contents of an encrypted message. See
[TLDef(0x1F814F1F)]
public sealed partial class DecryptedMessage : DecryptedMessageBase
{
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public long random_id;
public byte[] random_bytes;
/// Message text
public string message;
/// Media content
public DecryptedMessageMedia media;
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public override long RandomId => random_id;
/// Message text
public override string Message => message;
/// Media content
public override DecryptedMessageMedia Media => media;
public override byte[] RandomBytes => random_bytes;
}
/// Contents of an encrypted service message. See
[TLDef(0xAA48327D)]
public sealed partial class DecryptedMessageService : DecryptedMessageBase
{
/// Random message ID, assigned by the message author.
Must be equal to the ID passed to the sending method.
public long random_id;
public byte[] random_bytes;
/// Action relevant to the service message
public DecryptedMessageAction action;
/// Random message ID, assigned by the message author.
Must be equal to the ID passed to the sending method.
public override long RandomId => random_id;
public override byte[] RandomBytes => random_bytes;
/// Action relevant to the service message
public override DecryptedMessageAction Action => action;
}
/// Photo attached to an encrypted message. See
[TLDef(0x32798A8C)]
public sealed partial class DecryptedMessageMediaPhoto : DecryptedMessageMedia
{
/// Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90)
public byte[] thumb;
/// Thumbnail width
public int thumb_w;
/// Thumbnail height
public int thumb_h;
/// Photo width
public int w;
/// Photo height
public int h;
/// Size of the photo in bytes
public int size;
/// Key to decrypt an attached file with a full version
public byte[] key;
/// Initialization vector
public byte[] iv;
public override string MimeType => "image/jpeg";
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// Video attached to an encrypted message. See
[TLDef(0x4CEE6EF3)]
public sealed partial class DecryptedMessageMediaVideo : DecryptedMessageMedia
{
/// Content of thumbnail file (JPEG file, quality 55, set in a square 90x90)
public byte[] thumb;
/// Thumbnail width
public int thumb_w;
/// Thumbnail height
public int thumb_h;
/// Duration of video in seconds
public int duration;
/// Image width
public int w;
/// Image height
public int h;
/// File size
public int size;
/// Key to decrypt the attached video file
public byte[] key;
/// Initialization vector
public byte[] iv;
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// GeoPoint attached to an encrypted message. See
[TLDef(0x35480A59)]
public sealed partial class DecryptedMessageMediaGeoPoint : DecryptedMessageMedia
{
/// Latitude of point
public double lat;
/// Longitude of point
public double lon;
}
/// Contact attached to an encrypted message. See
[TLDef(0x588A0A97)]
public sealed partial class DecryptedMessageMediaContact : DecryptedMessageMedia
{
/// Phone number
public string phone_number;
/// Contact's first name
public string first_name;
/// Contact's last name
public string last_name;
/// Telegram User ID of signed-up contact
public int user_id;
}
/// Document attached to a message in a secret chat. See
[TLDef(0xB095434B)]
public sealed partial class DecryptedMessageMediaDocument : DecryptedMessageMedia
{
/// Thumbnail-file contents (JPEG-file, quality 55, set in a 90x90 square)
public byte[] thumb;
/// Thumbnail width
public int thumb_w;
/// Thumbnail height
public int thumb_h;
public string file_name;
/// File MIME-type
public string mime_type;
/// Document size ( on layer <143, on layer >=143)
public int size;
/// Key to decrypt the attached document file
public byte[] key;
/// Initialization
public byte[] iv;
/// File MIME-type
public override string MimeType => mime_type;
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// Audio file attached to a secret chat message. See
[TLDef(0x6080758F)]
public sealed partial class DecryptedMessageMediaAudio : DecryptedMessageMedia
{
/// Audio duration in seconds
public int duration;
/// File size
public int size;
/// Key to decrypt the attached media file
public byte[] key;
/// Initialization vector
public byte[] iv;
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// Setting of a message lifetime after reading. See
[TLDef(0xA1733AEC)]
public sealed partial class DecryptedMessageActionSetMessageTTL : DecryptedMessageAction
{
/// Lifetime in seconds
public int ttl_seconds;
}
/// Messages marked as read. See
[TLDef(0x0C4F40BE)]
public sealed partial class DecryptedMessageActionReadMessages : DecryptedMessageAction
{
/// List of message IDs
public long[] random_ids;
}
/// Deleted messages. See
[TLDef(0x65614304)]
public sealed partial class DecryptedMessageActionDeleteMessages : DecryptedMessageAction
{
/// List of deleted message IDs
public long[] random_ids;
}
/// A screenshot was taken. See
[TLDef(0x8AC1F475)]
public sealed partial class DecryptedMessageActionScreenshotMessages : DecryptedMessageAction
{
/// List of affected message ids (that appeared on the screenshot)
public long[] random_ids;
}
/// The entire message history has been deleted. See
[TLDef(0x6719E45C)]
public sealed partial class DecryptedMessageActionFlushHistory : DecryptedMessageAction { }
}
namespace Layer23
{
/// Image description. See
[TLDef(0x77BFB61B)]
public sealed partial class PhotoSize : PhotoSizeBase
{
/// Thumbnail type »
public string type;
public FileLocationBase location;
/// Image width
public int w;
/// Image height
public int h;
/// File size
public int size;
/// Thumbnail type »
public override string Type => type;
}
/// Description of an image and its content. See
[TLDef(0xE9A734FA)]
public sealed partial class PhotoCachedSize : PhotoSizeBase
{
/// Thumbnail type
public string type;
public FileLocationBase location;
/// Image width
public int w;
/// Image height
public int h;
/// Binary data, file content
public byte[] bytes;
/// Thumbnail type
public override string Type => type;
}
/// User is uploading a video. See
[TLDef(0x92042FF7)]
public sealed partial class SendMessageUploadVideoAction : SendMessageAction { }
/// User is uploading a voice message. See
[TLDef(0xE6AC8A6F)]
public sealed partial class SendMessageUploadAudioAction : SendMessageAction { }
/// User is uploading a photo. See
[TLDef(0x990A3C1A)]
public sealed partial class SendMessageUploadPhotoAction : SendMessageAction { }
/// User is uploading a file. See
[TLDef(0x8FAEE98E)]
public sealed partial class SendMessageUploadDocumentAction : SendMessageAction { }
/// Defines a sticker See
[TLDef(0xFB0A5727)]
public sealed partial class DocumentAttributeSticker : DocumentAttribute { }
/// Defines a video See
[TLDef(0x5910CCCB)]
public sealed partial class DocumentAttributeVideo : DocumentAttribute
{
/// Duration in seconds
public int duration;
/// Video width
public int w;
/// Video height
public int h;
}
/// Represents an audio file See
[TLDef(0x051448E5)]
public sealed partial class DocumentAttributeAudio : DocumentAttribute
{
/// Duration in seconds
public int duration;
}
/// Contents of an encrypted message. See
[TLDef(0x204D3878)]
public sealed partial class DecryptedMessage : DecryptedMessageBase
{
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public long random_id;
/// Message lifetime. Has higher priority than .
Parameter added in Layer 17.
public int ttl;
/// Message text
public string message;
/// Media content
public DecryptedMessageMedia media;
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public override long RandomId => random_id;
/// Message lifetime. Has higher priority than .
Parameter added in Layer 17.
public override int Ttl => ttl;
/// Message text
public override string Message => message;
/// Media content
public override DecryptedMessageMedia Media => media;
}
/// Contents of an encrypted service message. See
[TLDef(0x73164160)]
public sealed partial class DecryptedMessageService : DecryptedMessageBase
{
/// Random message ID, assigned by the message author.
Must be equal to the ID passed to the sending method.
public long random_id;
/// Action relevant to the service message
public DecryptedMessageAction action;
/// Random message ID, assigned by the message author.
Must be equal to the ID passed to the sending method.
public override long RandomId => random_id;
/// Action relevant to the service message
public override DecryptedMessageAction Action => action;
}
/// Video attached to an encrypted message. See
[TLDef(0x524A415D)]
public sealed partial class DecryptedMessageMediaVideo : DecryptedMessageMedia
{
/// Content of thumbnail file (JPEG file, quality 55, set in a square 90x90)
public byte[] thumb;
/// Thumbnail width
public int thumb_w;
/// Thumbnail height
public int thumb_h;
/// Duration of video in seconds
public int duration;
/// MIME-type of the video file
Parameter added in Layer 17.
public string mime_type;
/// Image width
public int w;
/// Image height
public int h;
/// File size
public int size;
/// Key to decrypt the attached video file
public byte[] key;
/// Initialization vector
public byte[] iv;
/// MIME-type of the video file
Parameter added in Layer 17.
public override string MimeType => mime_type;
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// Audio file attached to a secret chat message. See
[TLDef(0x57E0A9CB)]
public sealed partial class DecryptedMessageMediaAudio : DecryptedMessageMedia
{
/// Audio duration in seconds
public int duration;
/// MIME-type of the audio file
Parameter added in Layer 13.
public string mime_type;
/// File size
public int size;
/// Key to decrypt the attached media file
public byte[] key;
/// Initialization vector
public byte[] iv;
/// MIME-type of the audio file
Parameter added in Layer 13.
public override string MimeType => mime_type;
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// Non-e2e documented forwarded from non-secret chat See
[TLDef(0xFA95B0DD)]
public sealed partial class DecryptedMessageMediaExternalDocument : DecryptedMessageMedia
{
/// Document ID
public long id;
/// access hash
public long access_hash;
/// Date
public DateTime date;
/// Mime type
public string mime_type;
/// Size
public int size;
/// Thumbnail
public PhotoSizeBase thumb;
/// DC ID
public int dc_id;
/// Attributes for media types
public DocumentAttribute[] attributes;
/// Mime type
public override string MimeType => mime_type;
}
/// Request for the other party in a Secret Chat to automatically resend a contiguous range of previously sent messages, as explained in Sequence number is Secret Chats. See
[TLDef(0x511110B0)]
public sealed partial class DecryptedMessageActionResend : DecryptedMessageAction
{
/// out_seq_no of the first message to be resent, with correct parity
public int start_seq_no;
/// out_seq_no of the last message to be resent, with same parity.
public int end_seq_no;
}
/// A notification stating the API layer that is used by the client. You should use your current layer and take notice of the layer used on the other side of a conversation when sending messages. See
[TLDef(0xF3048883)]
public sealed partial class DecryptedMessageActionNotifyLayer : DecryptedMessageAction
{
/// Layer number, must be 17 or higher (this constructor was introduced in Layer 17.
public int layer;
}
/// User is preparing a message: typing, recording, uploading, etc. See
[TLDef(0xCCB27641)]
public sealed partial class DecryptedMessageActionTyping : DecryptedMessageAction
{
/// Type of action
public SendMessageAction action;
}
/// Request rekeying, see rekeying process See
[TLDef(0xF3C9611B)]
public sealed partial class DecryptedMessageActionRequestKey : DecryptedMessageAction
{
/// Exchange ID
public long exchange_id;
/// g_a, see rekeying process
public byte[] g_a;
}
/// Accept new key See
[TLDef(0x6FE1735B)]
public sealed partial class DecryptedMessageActionAcceptKey : DecryptedMessageAction
{
/// Exchange ID
public long exchange_id;
/// B parameter, see rekeying process
public byte[] g_b;
/// Key fingerprint, see rekeying process
public long key_fingerprint;
}
/// Abort rekeying See
[TLDef(0xDD05EC6B)]
public sealed partial class DecryptedMessageActionAbortKey : DecryptedMessageAction
{
/// Exchange ID
public long exchange_id;
}
/// Commit new key, see rekeying process See
[TLDef(0xEC2E0B9B)]
public sealed partial class DecryptedMessageActionCommitKey : DecryptedMessageAction
{
/// Exchange ID, see rekeying process
public long exchange_id;
/// Key fingerprint, see rekeying process
public long key_fingerprint;
}
/// NOOP action See
[TLDef(0xA82FDD63)]
public sealed partial class DecryptedMessageActionNoop : DecryptedMessageAction { }
/// Sets the layer number for the contents of an encrypted message. See
[TLDef(0x1BE31789)]
public sealed partial class DecryptedMessageLayer : IObject
{
/// Set of random bytes to prevent content recognition in short encrypted messages.
Clients are required to check that there are at least 15 random bytes included in each message. Messages with less than 15 random bytes must be ignored.
Parameter moved here from in Layer 17.
public byte[] random_bytes;
/// Layer number. Mimimal value - 17 (the layer in which the constructor was added).
public int layer;
/// 2x the number of messages in the sender's inbox (including deleted and service messages), incremented by 1 if current user was not the chat creator
Parameter added in Layer 17.
public int in_seq_no;
/// 2x the number of messages in the recipient's inbox (including deleted and service messages), incremented by 1 if current user was the chat creator
Parameter added in Layer 17.
public int out_seq_no;
/// The content of message itself
public DecryptedMessageBase message;
}
/// File is currently unavailable. See
[TLDef(0x7C596B46)]
public sealed partial class FileLocationUnavailable : FileLocationBase
{
public long volume_id;
public int local_id;
public long secret;
public override long VolumeId => volume_id;
public override int LocalId => local_id;
public override long Secret => secret;
}
/// File location. See
[TLDef(0x53D69076)]
public sealed partial class FileLocation : FileLocationBase
{
public int dc_id;
public long volume_id;
public int local_id;
public long secret;
public override long VolumeId => volume_id;
public override int LocalId => local_id;
public override long Secret => secret;
}
}
namespace Layer45
{
/// Represents an audio file See
[TLDef(0xDED218E0)]
public sealed partial class DocumentAttributeAudio : DocumentAttribute
{
/// Duration in seconds
public int duration;
/// Name of song
public string title;
/// Performer
public string performer;
}
}
namespace Layer46
{
/// Defines a sticker See
[TLDef(0x3A556302)]
public sealed partial class DocumentAttributeSticker : DocumentAttribute
{
/// Alternative emoji representation of sticker
public string alt;
/// Associated stickerset
public InputStickerSet stickerset;
}
/// Message entity representing a user mention: for creating a mention use . See
[TLDef(0x352DCA58, inheritBefore = true)]
public sealed partial class MessageEntityMentionName : MessageEntity
{
/// Identifier of the user that was mentioned
public int user_id;
}
/// Contents of an encrypted message. See
[TLDef(0x36B091DE)]
public sealed partial class DecryptedMessage : DecryptedMessageBase
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
public Flags flags;
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public long random_id;
/// Message lifetime. Has higher priority than .
Parameter added in Layer 17.
public int ttl;
/// Message text
public string message;
/// Media content
[IfFlag(9)] public DecryptedMessageMedia media;
/// Message entities for styled text (parameter added in layer 45)
[IfFlag(7)] public MessageEntity[] entities;
/// Specifies the ID of the inline bot that generated the message (parameter added in layer 45)
[IfFlag(11)] public string via_bot_name;
/// Random message ID of the message this message replies to (parameter added in layer 45)
[IfFlag(3)] public long reply_to_random_id;
[Flags] public enum Flags : uint
{
/// Field has a value
has_reply_to_random_id = 0x8,
/// Field has a value
has_entities = 0x80,
/// Field has a value
has_media = 0x200,
/// Field has a value
has_via_bot_name = 0x800,
}
/// Flags, see TL conditional fields (added in layer 45)
public override uint FFlags => (uint)flags;
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public override long RandomId => random_id;
/// Message lifetime. Has higher priority than .
Parameter added in Layer 17.
public override int Ttl => ttl;
/// Message text
public override string Message => message;
/// Media content
public override DecryptedMessageMedia Media => media;
/// Message entities for styled text (parameter added in layer 45)
public override MessageEntity[] Entities => entities;
/// Specifies the ID of the inline bot that generated the message (parameter added in layer 45)
public override string ViaBotName => via_bot_name;
/// Random message ID of the message this message replies to (parameter added in layer 45)
public override long ReplyToRandom => reply_to_random_id;
}
/// Photo attached to an encrypted message. See
[TLDef(0xF1FA8D78)]
public sealed partial class DecryptedMessageMediaPhoto : DecryptedMessageMedia
{
/// Content of thumbnail file (JPEGfile, quality 55, set in a square 90x90)
public byte[] thumb;
/// Thumbnail width
public int thumb_w;
/// Thumbnail height
public int thumb_h;
/// Photo width
public int w;
/// Photo height
public int h;
/// Size of the photo in bytes
public int size;
/// Key to decrypt an attached file with a full version
public byte[] key;
/// Initialization vector
public byte[] iv;
/// Caption
public string caption;
public override string MimeType => "image/jpeg";
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// Video attached to an encrypted message. See
[TLDef(0x970C8C0E)]
public sealed partial class DecryptedMessageMediaVideo : DecryptedMessageMedia
{
/// Content of thumbnail file (JPEG file, quality 55, set in a square 90x90)
public byte[] thumb;
/// Thumbnail width
public int thumb_w;
/// Thumbnail height
public int thumb_h;
/// Duration of video in seconds
public int duration;
/// MIME-type of the video file
Parameter added in Layer 17.
public string mime_type;
/// Image width
public int w;
/// Image height
public int h;
/// File size
public int size;
/// Key to decrypt the attached video file
public byte[] key;
/// Initialization vector
public byte[] iv;
/// Caption
public string caption;
/// MIME-type of the video file
Parameter added in Layer 17.
public override string MimeType => mime_type;
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// Document attached to a message in a secret chat. See
[TLDef(0x7AFE8AE2)]
public sealed partial class DecryptedMessageMediaDocument : DecryptedMessageMedia
{
/// Thumbnail-file contents (JPEG-file, quality 55, set in a 90x90 square)
public byte[] thumb;
/// Thumbnail width
public int thumb_w;
/// Thumbnail height
public int thumb_h;
/// File MIME-type
public string mime_type;
/// Document size ( on layer <143, on layer >=143)
public int size;
/// Key to decrypt the attached document file
public byte[] key;
/// Initialization
public byte[] iv;
/// Document attributes for media types
public DocumentAttribute[] attributes;
/// Caption
public string caption;
/// File MIME-type
public override string MimeType => mime_type;
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = (checked((int)value.size), value.key, value.iv); }
}
/// Venue See
[TLDef(0x8A0DF56F)]
public sealed partial class DecryptedMessageMediaVenue : DecryptedMessageMedia
{
/// Latitude of venue
public double lat;
/// Longitude of venue
public double lon;
/// Venue name
public string title;
/// Address
public string address;
/// Venue provider: currently only "foursquare" and "gplaces" (Google Places) need to be supported
public string provider;
/// Venue ID in the provider's database
public string venue_id;
}
/// Webpage preview See
[TLDef(0xE50511D8)]
public sealed partial class DecryptedMessageMediaWebPage : DecryptedMessageMedia
{
/// URL of webpage
public string url;
}
}
namespace Layer66
{
/// User is uploading a round video See
[TLDef(0xBB718624)]
public sealed partial class SendMessageUploadRoundAction : SendMessageAction { }
/// Defines a video See
[TLDef(0x0EF02CE6)]
public sealed partial class DocumentAttributeVideo : DocumentAttribute
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
public Flags flags;
/// Duration in seconds
public int duration;
/// Video width
public int w;
/// Video height
public int h;
[Flags] public enum Flags : uint
{
/// Whether this is a round video
round_message = 0x1,
}
}
}
namespace Layer73
{
/// Contents of an encrypted message. See
[TLDef(0x91CC4674)]
public sealed partial class DecryptedMessage : DecryptedMessageBase
{
/// Extra bits of information, use flags.HasFlag(...) to test for those
public Flags flags;
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public long random_id;
/// Message lifetime. Has higher priority than .
Parameter added in Layer 17.
public int ttl;
/// Message text
public string message;
/// Media content
[IfFlag(9)] public DecryptedMessageMedia media;
/// Message entities for styled text (parameter added in layer 45)
[IfFlag(7)] public MessageEntity[] entities;
/// Specifies the ID of the inline bot that generated the message (parameter added in layer 45)
[IfFlag(11)] public string via_bot_name;
/// Random message ID of the message this message replies to (parameter added in layer 45)
[IfFlag(3)] public long reply_to_random_id;
/// Random group ID, assigned by the author of message.
Multiple encrypted messages with a photo attached and with the same group ID indicate an album or grouped media (parameter added in layer 45)
[IfFlag(17)] public long grouped_id;
[Flags] public enum Flags : uint
{
/// Field has a value
has_reply_to_random_id = 0x8,
/// Whether this is a silent message (no notification triggered)
silent = 0x20,
/// Field has a value
has_entities = 0x80,
/// Field has a value
has_media = 0x200,
/// Field has a value
has_via_bot_name = 0x800,
/// Field has a value
has_grouped_id = 0x20000,
}
/// Flags, see TL conditional fields (added in layer 45)
public override uint FFlags => (uint)flags;
/// Random message ID, assigned by the author of message.
Must be equal to the ID passed to sending method.
public override long RandomId => random_id;
/// Message lifetime. Has higher priority than .
Parameter added in Layer 17.
public override int Ttl => ttl;
/// Message text
public override string Message => message;
/// Media content
public override DecryptedMessageMedia Media => media;
/// Message entities for styled text (parameter added in layer 45)
public override MessageEntity[] Entities => entities;
/// Specifies the ID of the inline bot that generated the message (parameter added in layer 45)
public override string ViaBotName => via_bot_name;
/// Random message ID of the message this message replies to (parameter added in layer 45)
public override long ReplyToRandom => reply_to_random_id;
/// Random group ID, assigned by the author of message.
Multiple encrypted messages with a photo attached and with the same group ID indicate an album or grouped media (parameter added in layer 45)
public override long Grouped => grouped_id;
}
}
namespace Layer101
{
/// Message entity representing a block quote. See
[TLDef(0x020DF5D0)]
public sealed partial class MessageEntityBlockquote : MessageEntity { }
}
namespace Layer143
{
/// Document attached to a message in a secret chat. See
[TLDef(0x6ABD9782)]
public sealed partial class DecryptedMessageMediaDocument : DecryptedMessageMedia
{
/// Thumbnail-file contents (JPEG-file, quality 55, set in a 90x90 square)
public byte[] thumb;
/// Thumbnail width
public int thumb_w;
/// Thumbnail height
public int thumb_h;
/// File MIME-type
public string mime_type;
/// Document size ( on layer <143, on layer >=143)
public long size;
/// Key to decrypt the attached document file
public byte[] key;
/// Initialization
public byte[] iv;
/// Document attributes for media types
public DocumentAttribute[] attributes;
/// Caption
public string caption;
/// File MIME-type
public override string MimeType => mime_type;
internal override (long size, byte[] key, byte[] iv) SizeKeyIV { get => (size, key, iv); set => (size, key, iv) = value; }
}
}
namespace Layer144
{ }
}