conduyt-mcp 4.45.0 → 4.47.0

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.
@@ -128,6 +128,54 @@ export function registerMessagingTools(server, client) {
128
128
  const result = await client.get(`/api/v1/reports/speed-to-lead?${params}`);
129
129
  return formatResult(result);
130
130
  });
131
+ server.tool("conduyt_attribution_report", "Attribution: where the window's new contacts came from and what they turned into: the contacts created in the window grouped by their first or latest touch (UTM source, medium, campaign, content, term, the channel, the landing page or the referrer), each group followed to appointments booked, deals won and revenue so far. Touches are captured on forms, booking pages, inbound webhooks, imports and contact creation through the API (pass an `attribution` object with utm_source, utm_medium, utm_campaign, utm_content, utm_term, referrer, landingUrl, pageTitle, clickIds). Spans clamp to 366 days; the definition comes back as `definition`.", {
132
+ from: z.string().optional().describe("ISO start (omit both for the last 366 days)"),
133
+ to: z.string().optional().describe("ISO end"),
134
+ touch: z.enum(["first", "last"]).optional().describe("Group by the first (default) or the latest touch"),
135
+ group: z.enum(["source", "utm_source", "medium", "campaign", "content", "term", "channel", "landing", "referrer"]).optional().describe("The touch field to group by (default source = the UTM source when the touch carried one, else the recorded source; utm_source = strictly the UTM)"),
136
+ }, async ({ from, to, touch, group }) => {
137
+ const params = new URLSearchParams();
138
+ if (from)
139
+ params.set("from", from);
140
+ if (to)
141
+ params.set("to", to);
142
+ if (touch)
143
+ params.set("touch", touch);
144
+ if (group)
145
+ params.set("group", group);
146
+ const result = await client.get(`/api/v1/reports/attribution?${params}`);
147
+ return formatResult(result);
148
+ });
149
+ server.tool("conduyt_agent_performance_report", "Agent performance: every active rep's numbers for the window next to their targets and next to each other: calls, conversations, appointments booked, deals won, revenue, activities, talk minutes, each with the target prorated to the window (daily once per day, weekly per 7 days, monthly per 30.4375 days) and the attainment; a score per rep and a team row. userIds (up to 10) is the compare set. Spans clamp to 366 days; the definition comes back as `definition`.", {
150
+ from: z.string().optional().describe("ISO start (omit both for the last 366 days)"),
151
+ to: z.string().optional().describe("ISO end"),
152
+ userIds: z.array(z.string().uuid()).max(10).optional().describe("The reps to compare; omit for every active member"),
153
+ }, async ({ from, to, userIds }) => {
154
+ const params = new URLSearchParams();
155
+ if (from)
156
+ params.set("from", from);
157
+ if (to)
158
+ params.set("to", to);
159
+ if (userIds && userIds.length > 0)
160
+ params.set("userIds", userIds.join(","));
161
+ const result = await client.get(`/api/v1/reports/agent-performance?${params}`);
162
+ return formatResult(result);
163
+ });
164
+ server.tool("conduyt_list_targets", "The account's per-user targets (userId, metric, period, value). Admins and owners read everyone's; anyone else reads their own. Metrics: calls, conversations, appointments, deals_won, revenue, activities, talk_minutes; periods: daily, weekly, monthly.", { userId: z.string().uuid().optional().describe("One user's targets") }, async ({ userId }) => {
165
+ const params = new URLSearchParams();
166
+ if (userId)
167
+ params.set("userId", userId);
168
+ const result = await client.get(`/api/v1/reports/targets?${params}`);
169
+ return formatResult(result);
170
+ });
171
+ server.tool("conduyt_set_targets", "Set per-user targets in one call (admins and owners): one row per user, metric and period is replaced; value 0 removes it; every user must be an active member. Up to 200 targets.", {
172
+ targets: z.array(z.object({
173
+ userId: z.string().uuid(),
174
+ metric: z.enum(["calls", "conversations", "appointments", "deals_won", "revenue", "activities", "talk_minutes"]),
175
+ period: z.enum(["daily", "weekly", "monthly"]),
176
+ value: z.number().min(0).describe("The target for the period; 0 removes it"),
177
+ })).min(1).max(200),
178
+ }, async ({ targets }) => formatResult(await client.put("/api/v1/reports/targets", { targets })));
131
179
  server.tool("conduyt_call_performance_report", "Unified call report: every call in the window, whatever carried it (the in-app dialer over Twilio, click-to-call Twilio, Project Blue), with the dialer analytics' definitions: calls, inbound and outbound, answered (network completed with talk time), connected and conversations (from the saved disposition), talk time and average talk, voicemails, missed inbound, appointments set and sales closed; overall and by user, transport, direction, disposition, day and hour of the account's timezone. Spans clamp to 366 days; the definition comes back as `definition`.", {
132
180
  from: z.string().optional().describe("ISO start (omit both for the last 366 days)"),
133
181
  to: z.string().optional().describe("ISO end"),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "conduyt-mcp",
3
- "version": "4.45.0",
3
+ "version": "4.47.0",
4
4
  "description": "MCP server for Conduyt CRM — expose CRM operations as AI-accessible tools",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -1,9 +1,9 @@
1
1
  {
2
- "generatedAt": "2026-09-11T10:42:14.525Z",
3
- "toolCount": 246,
4
- "totalEndpoints": 951,
2
+ "generatedAt": "2026-09-11T11:52:51.576Z",
3
+ "toolCount": 250,
4
+ "totalEndpoints": 955,
5
5
  "counts": {
6
- "covered": 228,
6
+ "covered": 232,
7
7
  "excluded": 283,
8
8
  "planned": 440,
9
9
  "uncategorized": 0
@@ -3211,12 +3211,24 @@
3211
3211
  "status": "planned",
3212
3212
  "reason": "additional report surfaces beyond ai/insights"
3213
3213
  },
3214
+ "GET /api/v1/reports/agent-performance": {
3215
+ "status": "covered",
3216
+ "tools": [
3217
+ "conduyt_agent_performance_report"
3218
+ ]
3219
+ },
3214
3220
  "GET /api/v1/reports/appointments": {
3215
3221
  "status": "covered",
3216
3222
  "tools": [
3217
3223
  "conduyt_appointment_report"
3218
3224
  ]
3219
3225
  },
3226
+ "GET /api/v1/reports/attribution": {
3227
+ "status": "covered",
3228
+ "tools": [
3229
+ "conduyt_attribution_report"
3230
+ ]
3231
+ },
3220
3232
  "GET /api/v1/reports/call-performance": {
3221
3233
  "status": "covered",
3222
3234
  "tools": [
@@ -3379,6 +3391,18 @@
3379
3391
  "conduyt_send_report_schedule_now"
3380
3392
  ]
3381
3393
  },
3394
+ "GET /api/v1/reports/targets": {
3395
+ "status": "covered",
3396
+ "tools": [
3397
+ "conduyt_list_targets"
3398
+ ]
3399
+ },
3400
+ "PUT /api/v1/reports/targets": {
3401
+ "status": "covered",
3402
+ "tools": [
3403
+ "conduyt_set_targets"
3404
+ ]
3405
+ },
3382
3406
  "GET /api/v1/reports/team": {
3383
3407
  "status": "planned",
3384
3408
  "reason": "additional report surfaces beyond ai/insights"