Skip to content

Conversation

@AlexanderMakarov
Copy link

Summary

Adds richer channel metadata to the channels list so MCP clients can show membership, unread state, and mention counts.

Changes

  • Channel struct (provider): New fields IsMember, HasUnreads, LastRead, MentionCount.
  • channels_list handler: Returns the new fields in the channel list response.
  • conversations handlers: Message/channel responses keep the same structure; new fields are populated where the data source provides them.
  • Provider: For browser/edge clients, unread data is filled from the edge ClientCounts API; for OAuth/bot tokens without edge, the new fields stay false/zero.

Rationale

Clients (e.g. Cursor, IDEs) can use this to:

  • Show which channels the user is in (IsMember).
  • Highlight channels with unread messages (HasUnreads, MentionCount).
  • Order or filter by last read time (LastRead).

Backward compatible: new fields are additive; existing clients can ignore them.

- Added new fields to the Channel struct: IsMember, HasUnreads, LastRead, and MentionCount.
- Updated the Message struct to maintain consistency with the new fields.
- Modified the ChannelsHandler and ConversationsHandler to populate the new fields from the data source.
- Implemented logic to fetch unread counts and last read information for channels.

These changes improve the handling of channel and message data, allowing for better tracking of user engagement and message status.
@AlexanderMakarov AlexanderMakarov deleted the feat/unread_and_ismember_props_for_channels branch February 10, 2026 11:36
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.

1 participant