messages.SendEncrypted
- class pyrogram.raw.functions.messages.SendEncrypted
Sends a text message to a secret chat.
- Details:
Layer:
223ID:
44FA7A15
- Parameters:
peer (
InputEncryptedChat) – Secret chat IDrandom_id (
int64-bit) – Unique client message ID, necessary to avoid message resendingdata (
bytes) – TL-serialization of DecryptedMessage type, encrypted with a key that was created during chat initializationsilent (
bool, optional) – Send encrypted message without a notification
- Returns:
TL Schema
messages.sendEncrypted#44fa7a15
flags:#
silent:flags.0?true
peer:InputEncryptedChat
random_id:long
data:bytes
= messages.SentEncryptedMessage
Parameter Tree
SendEncrypted
├── silent →
true (optional)├── peer →
InputEncryptedChat│ └──
InputEncryptedChat│ ├── chat_id →
int│ └── access_hash →
long├── random_id →
long└── data →
bytesExample
await app.invoke(
SendEncrypted(
silent=None,
peer=InputEncryptedChat(
chat_id=0,
access_hash=0
),
random_id=app.rnd_id(),
data=b"data",
)
)