sendSecretMessage
Send a message to a secret chat. USER-ONLY
Parameters
id: number
The identifier of the secret chat.
text: string
The message’s text.
The entities of the message’s text.
isSilent?: boolean
Whether the message should be sent silently.
replyToMessageId?: string
The identifier of a message to reply to.
ttl?: number
The message’s time-to-live.
viaBot?: string
The name of the bot that was used to send the message.
Result
void
Syntax
// Required parameters only.
await client.sendSecretMessage(id, text);
// Required parameters + optional parameters.
// Any of the optional parameters can be omitted.
await client.sendSecretMessage(id, text, {
entities,
isSilent,
replyToMessageId,
ttl,
viaBot,
});