@feedmob/user-activity-reporting 0.0.1 → 0.0.3

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/dist/index.js +14 -4
  2. package/package.json +4 -2
package/dist/index.js CHANGED
@@ -5,7 +5,7 @@ import { z } from 'zod';
5
5
  import dotenv from 'dotenv';
6
6
  import * as api from './api.js';
7
7
  dotenv.config();
8
- const server = new McpServer({ name: 'user-activity-reporting', version: '0.0.3' });
8
+ const server = new McpServer({ name: 'user-activity-reporting', version: '0.0.4' });
9
9
  const errMsg = (e) => e instanceof Error ? e.message : 'Unknown error';
10
10
  const errResp = (msg) => ({ content: [{ type: 'text', text: `Error: ${msg}` }], isError: true });
11
11
  const textResp = (text) => ({ content: [{ type: 'text', text }] });
@@ -35,13 +35,23 @@ server.tool('get_client_team_members', 'Query team members for a client. Returns
35
35
  return errResp(errMsg(e));
36
36
  }
37
37
  });
38
- server.tool('get_clients_by_pod', 'Query clients in a POD team.', {
39
- pod: z.string().describe('POD name (fuzzy match)'),
38
+ server.tool('get_clients_by_pod', 'Query clients in a POD team (AllyPod/KeyPod/Seapod). Returns full client info with all team members.', {
39
+ pod: z.string().describe('POD name (AllyPod/KeyPod/Seapod)'),
40
40
  month: z.string().optional().describe('Month in YYYY-MM format'),
41
41
  }, async (args) => {
42
42
  try {
43
43
  const d = await api.getClientsByPod(args.pod, args.month);
44
- return textResp(`# Clients in POD: ${d.pod}\n\nMonth: ${d.month} | Count: ${d.count}\n\n${d.client_names.map(c => `- ${c}`).join('\n')}`);
44
+ const clients = d.clients || [];
45
+ const total = d.total || clients.length;
46
+ if (total === 0 && d.note) {
47
+ return textResp(`# Clients in POD: ${d.pod}\n\nRequested month: ${d.requested_month}\n\n${d.note}`);
48
+ }
49
+ if (total === 0) {
50
+ return textResp(`# Clients in POD: ${d.pod}\n\nNo clients found for month: ${d.month || args.month || 'latest'}`);
51
+ }
52
+ const preview = clients.slice(0, 15);
53
+ const more = total > 15 ? `\n... and ${total - 15} more clients` : '';
54
+ return textResp(`# Clients in POD: ${d.pod}\n\nMonth: ${d.month} | Total: ${total}\n\n\`\`\`json\n${JSON.stringify(preview, null, 2)}\n\`\`\`${more}`);
45
55
  }
46
56
  catch (e) {
47
57
  return errResp(errMsg(e));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@feedmob/user-activity-reporting",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "description": "MCP server for querying client contacts, Slack messages, and HubSpot tickets",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -12,8 +12,10 @@
12
12
  ],
13
13
  "repository": {
14
14
  "type": "git",
15
- "url": "https://github.com/anthropics/fm-mcp-servers.git"
15
+ "url": "git+https://github.com/feed-mob/fm-mcp-servers.git",
16
+ "directory": "src/user-activity-reporting"
16
17
  },
18
+ "homepage": "https://github.com/feed-mob/fm-mcp-servers/tree/main/src/user-activity-reporting#readme",
17
19
  "keywords": [
18
20
  "mcp",
19
21
  "model-context-protocol",