Rocket.Chat Extended icon

Rocket.Chat Extended

Extended Rocket.Chat operations: channels, messages, threads, reactions, file upload, and more

Message → Get History

AI-generated

Summary

Fetch message history from a channel with optional date range and pagination controls.

Inputs

  • specifyRoomManually — Whether to manually provide the room ID instead of selecting from the list.
  • roomId (required) — Channel identifier; select from dropdown or enter ID manually.
  • inclusive — Include the earliest message when defining a history range.
  • latest — End date (ISO 8601) for the history range.
  • oldest — Start date (ISO 8601) for the history range.
  • returnAll — Whether to return all results regardless of limit.
  • limit — Maximum number of messages to return; ignored when returnAll is true.

Output shape

array of message objects representing channel history

Pagination via limit; optional inclusive, latest, oldest parameters; may be empty if no messages match.

Examples

Example 1: Fetch recent messages up to limit 20

roomId selected, limit=20, returnAll=false

Example 2: Retrieve full history between two dates

oldest=2023-01-01T00:00:00.000Z, latest=2023-12-31T23:59:59.000Z, returnAll=true

Example 3: Get unread history since a timestamp

oldest=2024-10-01T00:00:00.000Z, inclusive=true, limit=50

Links

Discussion