ChatIdWithChannelDirectMessageThreadId

Numeric Telegram chat identifier carrying a default channel direct-message thread.

Constructors

Link copied to clipboard
constructor(chatIdWithThreadId: Pair<RawChatId, DirectMessageThreadId>)
constructor(chatId: RawChatId, threadId: DirectMessageThreadId)

Creates an identifier from separate chatId and threadId values.

Properties

Link copied to clipboard

Business connection carried as default request context, when available.

Link copied to clipboard

Returns the embedded business connection, or null when no business connection is available.

Link copied to clipboard
open override val chatId: RawChatId

Numeric Telegram chat identifier.

Link copied to clipboard

Raw chat identifier and direct-message-thread identifier pair.

Link copied to clipboard
Link copied to clipboard

Direct-message thread carried as default request context, when available.

Link copied to clipboard

Returns the embedded channel direct-message thread, or null when no direct-message thread is available.

Link copied to clipboard

Existing ephemeral message targeted by an operation, when available.

Link copied to clipboard

Returns the embedded ephemeral-message identifier, or null when no identifier is available.

Link copied to clipboard
open val receiverUser: UserId?

User receiving an ephemeral message, when available.

Link copied to clipboard

Returns the embedded ephemeral-message receiver, or null when no receiver is available.

Link copied to clipboard

Message thread carried as default request context, when available.

Link copied to clipboard

Returns the embedded message thread, or null when no message thread is available.

Link copied to clipboard

https://core.telegram.org/bots/api#formatting-options

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
inline fun <T> ChatIdentifier.ifBusinessChatId(block: (BusinessChatId) -> T): T?
Link copied to clipboard
inline fun <T> ChatIdentifier.ifChatId(block: (ChatId) -> T): T?
Link copied to clipboard
Link copied to clipboard
inline fun <T> ChatIdentifier.ifEphemeralChatId(block: (EphemeralChatId) -> T): T?
Link copied to clipboard
Link copied to clipboard
inline fun <T> ChatIdentifier.ifUsername(block: (Username) -> T): T?
Link copied to clipboard

Replaces embedded request context with the supplied businessConnectionId.

Link copied to clipboard

Drops all embedded request context and returns a plain ChatId.

Link copied to clipboard

Replaces embedded request context with the supplied channel direct-message threadId.

Link copied to clipboard

Replaces embedded request context with the supplied message threadId.

Link copied to clipboard
fun IdChatIdentifier.toEphemeralChatId(receiverUser: UserId, ephemeralMessageId: EphemeralMessageId? = null): EphemeralChatId

Replaces embedded request context with ephemeral delivery context for receiverUser.

Link copied to clipboard
Link copied to clipboard