ActiveStreamRegistry
type ActiveStreamRegistry = object;Where a chat’s active stream id is kept while the stream runs.
Methods
clearActiveStreamIdIfMatches()
clearActiveStreamIdIfMatches(chatId, streamId): Promise<void>;Atomically clears the marker only if it still identifies this stream.
Parameters
chatId
string
streamId
string
getActiveStreamId()
getActiveStreamId(chatId): Promise<string | null>;Parameters
chatId
string
setActiveStreamId()
setActiveStreamId(
chatId,
streamId,
ttlSeconds
): Promise<void>;Parameters
chatId
string
streamId
string
ttlSeconds
number
Last updated on