conduyt-mcp 4.35.0 → 4.36.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.
- package/dist/tools/reports.js +35 -0
- package/package.json +1 -1
- package/scripts/coverage-matrix.json +53 -9
package/dist/tools/reports.js
CHANGED
|
@@ -102,4 +102,39 @@ export function registerReportTools(server, client) {
|
|
|
102
102
|
const result = await client.postText(`/api/v1/reports/custom/${encodeURIComponent(id)}/export?format=${format ?? "csv"}`, {});
|
|
103
103
|
return formatResult(result);
|
|
104
104
|
});
|
|
105
|
+
// ── Reporting P2 (2026-09-10): scheduled delivery of saved reports ────────────────────────────────────────────────
|
|
106
|
+
/** the API takes recipients as objects; the tool takes plain addresses (the contract audit reads the body literally, so the shape lives here) */
|
|
107
|
+
const toRecipients = (emails) => emails.map((email) => ({ email }));
|
|
108
|
+
const scheduleFields = {
|
|
109
|
+
name: z.string().min(1).max(120).optional().describe("A label for the schedule (defaults to the report name)"),
|
|
110
|
+
cadence: z.enum(["daily", "weekly", "monthly"]),
|
|
111
|
+
hourLocal: z.number().int().min(0).max(23).optional().describe("Hour in the workspace timezone (default 7)"),
|
|
112
|
+
minuteLocal: z.number().int().min(0).max(59).optional(),
|
|
113
|
+
weekday: z.number().int().min(0).max(6).optional().describe("weekly: 0 = Sunday … 6 = Saturday"),
|
|
114
|
+
monthday: z.number().int().min(1).max(28).optional().describe("monthly: 1-28"),
|
|
115
|
+
timezone: z.string().optional().describe("IANA zone; defaults to the workspace timezone"),
|
|
116
|
+
formats: z.array(z.enum(["csv", "xlsx", "pdf"])).min(1).describe("The files to build and send"),
|
|
117
|
+
recipients: z.array(z.string().email()).min(1).max(20).describe("Email addresses inside or outside the workspace"),
|
|
118
|
+
rangeMode: z.enum(["as_saved", "rolling"]).optional().describe("rolling = only records created in the period since the last run"),
|
|
119
|
+
enabled: z.boolean().optional(),
|
|
120
|
+
};
|
|
121
|
+
server.tool("conduyt_list_report_schedules", "The scheduled deliveries on a saved report (daily / weekly / monthly emails of the report as CSV, XLSX or PDF): cadence, time, formats, recipients, next and last run.", { id: z.string().uuid().describe("Saved report id") }, async ({ id }) => formatResult(await client.get(`/api/v1/reports/custom/${encodeURIComponent(id)}/subscriptions`)));
|
|
122
|
+
server.tool("conduyt_create_report_schedule", "Schedule a saved report to be emailed on a cadence. The delivery runs with the visibility of whoever creates it. Needs reports export.", { id: z.string().uuid().describe("Saved report id"), ...scheduleFields }, async ({ id, recipients, ...rest }) => formatResult(await client.post(`/api/v1/reports/custom/${encodeURIComponent(id)}/subscriptions`, { ...rest, recipients: toRecipients(recipients) })));
|
|
123
|
+
server.tool("conduyt_update_report_schedule", "Change a schedule (only the fields you pass), including pausing (enabled: false) or resuming it.", {
|
|
124
|
+
sid: z.string().uuid().describe("Schedule id (from conduyt_list_report_schedules)"),
|
|
125
|
+
name: scheduleFields.name,
|
|
126
|
+
cadence: scheduleFields.cadence.optional(),
|
|
127
|
+
hourLocal: scheduleFields.hourLocal,
|
|
128
|
+
minuteLocal: scheduleFields.minuteLocal,
|
|
129
|
+
weekday: scheduleFields.weekday,
|
|
130
|
+
monthday: scheduleFields.monthday,
|
|
131
|
+
timezone: scheduleFields.timezone,
|
|
132
|
+
formats: scheduleFields.formats.optional(),
|
|
133
|
+
recipients: scheduleFields.recipients.optional(),
|
|
134
|
+
rangeMode: scheduleFields.rangeMode,
|
|
135
|
+
enabled: scheduleFields.enabled,
|
|
136
|
+
}, async ({ sid, recipients, ...rest }) => formatResult(await client.patch(`/api/v1/reports/subscriptions/${encodeURIComponent(sid)}`, { ...rest, ...(recipients ? { recipients: toRecipients(recipients) } : {}) })));
|
|
137
|
+
server.tool("conduyt_delete_report_schedule", "Remove a schedule. Past deliveries stay downloadable until they expire (14 days).", { sid: z.string().uuid() }, async ({ sid }) => formatResult(await client.del(`/api/v1/reports/subscriptions/${encodeURIComponent(sid)}`)));
|
|
138
|
+
server.tool("conduyt_send_report_schedule_now", "Build and email a schedule right now (one manual delivery; the schedule itself is untouched). Rate-limited to 3 per 10 minutes per schedule.", { sid: z.string().uuid() }, async ({ sid }) => formatResult(await client.post(`/api/v1/reports/subscriptions/${encodeURIComponent(sid)}/run`, {})));
|
|
139
|
+
server.tool("conduyt_report_schedule_deliveries", "The delivery history of a schedule (newest first): status, rows, whether it was emailed, and download URLs for the files.", { sid: z.string().uuid() }, async ({ sid }) => formatResult(await client.get(`/api/v1/reports/subscriptions/${encodeURIComponent(sid)}/deliveries`)));
|
|
105
140
|
}
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
|
-
"generatedAt": "2026-09-
|
|
3
|
-
"toolCount":
|
|
4
|
-
"totalEndpoints":
|
|
2
|
+
"generatedAt": "2026-09-10T18:42:14.384Z",
|
|
3
|
+
"toolCount": 231,
|
|
4
|
+
"totalEndpoints": 939,
|
|
5
5
|
"counts": {
|
|
6
|
-
"covered":
|
|
6
|
+
"covered": 213,
|
|
7
7
|
"excluded": 283,
|
|
8
|
-
"planned":
|
|
8
|
+
"planned": 443,
|
|
9
9
|
"uncategorized": 0
|
|
10
10
|
},
|
|
11
11
|
"matrix": {
|
|
@@ -1537,6 +1537,10 @@
|
|
|
1537
1537
|
"status": "excluded",
|
|
1538
1538
|
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
1539
1539
|
},
|
|
1540
|
+
"GET /api/v1/cron/deliver-report-subscriptions": {
|
|
1541
|
+
"status": "excluded",
|
|
1542
|
+
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
1543
|
+
},
|
|
1540
1544
|
"GET /api/v1/cron/file-storage-cleanup": {
|
|
1541
1545
|
"status": "excluded",
|
|
1542
1546
|
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
@@ -1789,10 +1793,6 @@
|
|
|
1789
1793
|
"status": "excluded",
|
|
1790
1794
|
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
1791
1795
|
},
|
|
1792
|
-
"POST /api/v1/cron/retry-webhooks": {
|
|
1793
|
-
"status": "excluded",
|
|
1794
|
-
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
1795
|
-
},
|
|
1796
1796
|
"GET /api/v1/cron/scheduled-account-exports": {
|
|
1797
1797
|
"status": "excluded",
|
|
1798
1798
|
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
@@ -3203,6 +3203,18 @@
|
|
|
3203
3203
|
"status": "planned",
|
|
3204
3204
|
"reason": "additional report surfaces beyond ai/insights"
|
|
3205
3205
|
},
|
|
3206
|
+
"GET /api/v1/reports/custom/:id/subscriptions": {
|
|
3207
|
+
"status": "covered",
|
|
3208
|
+
"tools": [
|
|
3209
|
+
"conduyt_list_report_schedules"
|
|
3210
|
+
]
|
|
3211
|
+
},
|
|
3212
|
+
"POST /api/v1/reports/custom/:id/subscriptions": {
|
|
3213
|
+
"status": "covered",
|
|
3214
|
+
"tools": [
|
|
3215
|
+
"conduyt_create_report_schedule"
|
|
3216
|
+
]
|
|
3217
|
+
},
|
|
3206
3218
|
"GET /api/v1/reports/custom/fields": {
|
|
3207
3219
|
"status": "covered",
|
|
3208
3220
|
"tools": [
|
|
@@ -3215,6 +3227,10 @@
|
|
|
3215
3227
|
"conduyt_preview_report"
|
|
3216
3228
|
]
|
|
3217
3229
|
},
|
|
3230
|
+
"GET /api/v1/reports/deliveries/:did/files/:index": {
|
|
3231
|
+
"status": "planned",
|
|
3232
|
+
"reason": "additional report surfaces beyond ai/insights"
|
|
3233
|
+
},
|
|
3218
3234
|
"GET /api/v1/reports/dialer/agent-hourly": {
|
|
3219
3235
|
"status": "planned",
|
|
3220
3236
|
"reason": "additional report surfaces beyond ai/insights"
|
|
@@ -3257,6 +3273,34 @@
|
|
|
3257
3273
|
"status": "planned",
|
|
3258
3274
|
"reason": "additional report surfaces beyond ai/insights"
|
|
3259
3275
|
},
|
|
3276
|
+
"GET /api/v1/reports/subscriptions/:sid": {
|
|
3277
|
+
"status": "planned",
|
|
3278
|
+
"reason": "additional report surfaces beyond ai/insights"
|
|
3279
|
+
},
|
|
3280
|
+
"PATCH /api/v1/reports/subscriptions/:sid": {
|
|
3281
|
+
"status": "covered",
|
|
3282
|
+
"tools": [
|
|
3283
|
+
"conduyt_update_report_schedule"
|
|
3284
|
+
]
|
|
3285
|
+
},
|
|
3286
|
+
"DELETE /api/v1/reports/subscriptions/:sid": {
|
|
3287
|
+
"status": "covered",
|
|
3288
|
+
"tools": [
|
|
3289
|
+
"conduyt_delete_report_schedule"
|
|
3290
|
+
]
|
|
3291
|
+
},
|
|
3292
|
+
"GET /api/v1/reports/subscriptions/:sid/deliveries": {
|
|
3293
|
+
"status": "covered",
|
|
3294
|
+
"tools": [
|
|
3295
|
+
"conduyt_report_schedule_deliveries"
|
|
3296
|
+
]
|
|
3297
|
+
},
|
|
3298
|
+
"POST /api/v1/reports/subscriptions/:sid/run": {
|
|
3299
|
+
"status": "covered",
|
|
3300
|
+
"tools": [
|
|
3301
|
+
"conduyt_send_report_schedule_now"
|
|
3302
|
+
]
|
|
3303
|
+
},
|
|
3260
3304
|
"GET /api/v1/reports/team": {
|
|
3261
3305
|
"status": "planned",
|
|
3262
3306
|
"reason": "additional report surfaces beyond ai/insights"
|