Chat / JavaScript
Chat JavaScript v4
Chat JavaScript
Chat
JavaScript
Home
/
Chat
/
JavaScript
/
Message
This is the new Docs for Chat SDK v4 for JavaScript. To see the previous Docs, click here.

Retrieve a scheduled message

You can retrieve a specific scheduled message by passing ScheduledMessageRetrievalParams as an argument to the MessageModule.getScheduledMessage() method.

const params: ScheduledMessageRetrievalParams = {
  channelUrl: channel.url,
  scheduledMessageId: scheduledMessage.scheduledInfo.scheduledMessageId,
};
const scheduledMessage: BaseMessage = await sb.message.getScheduledMessage(params);

ScheduledMessageRetrievalParams

Parameter nameTypeDescription

channelUrl

string

Specifies the URL of the channel.

scheduledMessageId

long

Specifies the ID of the scheduled message.