RocketChat / RocketChat/Rocket.Chat

rocketchat api: users.info - not able to get correct unread messages counter of rooms

Open
#26,740 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
46.1k
Forks
13.9k
Avg merge
3d 3h
Merged PRs (30d)
130

Description

I'm trying to get a counter of unread messages per room for specific user. The route of users.info with the extra rooms field seems to give the wanted info but when showing channels (as part of the rooms array) the unread counter doesn't seem to show the correct number. Is there a way to make it work? or maybe is this a permission problem? I'm trying to get the info about the logged user rooms.

In addition, I tried to get the info i need from the channels.counters route but the info on private channels still doesn't seem to show the correct number.

rocket chat version used: 5.1.0

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the users.info request with the extra rooms field and the channels.counters request for the logged-in user on Rocket.Chat 5.1.0. Compare unread counters for regular and private rooms and investigate whether permissions affect the results. Done means the API returns correct per-room unread counts or clearly documents the limitation.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
api
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.