Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for /messages #15

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Half-Shot
Copy link
Member

Checklist

  • Tests written for all new code
  • Linter has been satisfied
  • [N/A] Sign-off given on the changes (see CONTRIBUTING.md)

@AndrewFerr AndrewFerr changed the base branch from main to element-main June 29, 2023 14:01
@AndrewFerr AndrewFerr requested a review from a team as a code owner June 29, 2023 14:01
@tadzik
Copy link

tadzik commented Jun 29, 2023

Fixes turt2live#250?

@AndrewFerr
Copy link
Member

To make merging easier, rebase this on upstream's main (bb93184), which had a release since this PR was filed.

Comment on lines +1981 to +1988
/**
* Get relations for a given event.
* @param {string} roomId The room ID to for the given event.
* @param {string} eventId The event ID to list relations for.
* @param {string?} relationType The type of relations (e.g. `m.room.member`) to filter for. Optional.
* @param {string?} eventType The type of event to look for (e.g. `m.room.member`). Optional.
* @returns {Promise<{chunk: any[]}>} Resolves to an object containing the chunk of relations
*/
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comment is apparently copied from elsewhere

Suggested change
/**
* Get relations for a given event.
* @param {string} roomId The room ID to for the given event.
* @param {string} eventId The event ID to list relations for.
* @param {string?} relationType The type of relations (e.g. `m.room.member`) to filter for. Optional.
* @param {string?} eventType The type of event to look for (e.g. `m.room.member`). Optional.
* @returns {Promise<{chunk: any[]}>} Resolves to an object containing the chunk of relations
*/
/**
* Get list of message and state events for a room using /messages.
* @param {string} roomId The room ID to for the given event.
* @param {string} dir Thedirection to paginate in.
* @param {Partials<{filter: string, from: string, limit: number, to: string}>} opts Additional options to set for the request. Can be `filter`, `from`, `limit` and `to`.
* @returns {Promise<{chunk: GetRoomMessagesResponse}>} Resolves to an object containing the chunk of messages
*/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants