getSavedMessages

Get messages saved from a specific chat.

Parameters

chatId: ID

The identifier of a chat.

offsetId?: number

The identifier of a message. If specified, the messages will be fetched from that message.

offsetDate?: number

A point in time. If specified, the messages will be fetched from that date.

addOffset?: number

Additional offset.

limit?: number

The maximum number of results to return. Must be in the range of 1-100. Defaults to 100.

Result

Syntax

// Required parameters only.
await client.getSavedMessages(chatId);

// Required parameters + optional parameters.
// Any of the optional parameters can be omitted.
await client.getSavedMessages(chatId, {
    offsetId,
    offsetDate,
    addOffset,
    limit,
});