mcp-chat-connect 1.1.3 → 1.1.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.js +8 -3
  2. package/package.json +1 -1
package/index.js CHANGED
@@ -98,12 +98,17 @@ function connectWebSocket() {
98
98
 
99
99
  if (data.type === 'new_message') {
100
100
  const msg = data.message;
101
- // Don't echo back messages sent by this user's session
102
- if (msg.user_id === sessionState.userId) return;
101
+ // Don't echo back messages sent by this Claude session itself
102
+ // But DO receive messages from the same user's browser UI
103
+ if (msg.session_id === sessionState.sessionToken) return;
104
+
105
+ const senderLabel = msg.session_id
106
+ ? `${msg.user_name?.split(' ')[0]}'s Claude`
107
+ : msg.user_name || 'unknown';
103
108
 
104
109
  pushChannelMessage('mcp-chat', msg.content, {
105
110
  channel: sessionState.channelName,
106
- user: msg.user_name || 'unknown',
111
+ user: senderLabel,
107
112
  message_type: msg.message_type || 'info',
108
113
  timestamp: msg.created_at || new Date().toISOString(),
109
114
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mcp-chat-connect",
3
- "version": "1.1.3",
3
+ "version": "1.1.4",
4
4
  "description": "MCP server with channels support for connecting Claude Code sessions to MCP Chat -- real-time team messaging for AI-assisted development",
5
5
  "main": "index.js",
6
6
  "bin": {