conduyt-mcp 4.105.15 → 4.105.17
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/README.md +2 -1
- package/dist/tool-annotations.js +4 -0
- package/dist/tools/calls.d.ts +21 -0
- package/dist/tools/calls.js +39 -0
- package/dist/tools/invoices.js +24 -2
- package/package.json +1 -1
- package/scripts/coverage-matrix.json +30 -6
package/README.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
MCP server for [Conduyt CRM](https://conduyt.app) — expose your CRM as AI-accessible tools. Covers the core CRM surface (contacts, deals, pipelines, custom fields, automations, messaging, and more); use `conduyt_api_catalog` to discover the full set of 600+ REST endpoints.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## 412 Tools
|
|
6
6
|
|
|
7
7
|
### Discovery
|
|
8
8
|
| Tool | Description |
|
|
@@ -403,6 +403,7 @@ Team Chat 2.0 publishes thin events (ids and kinds, never message content) on th
|
|
|
403
403
|
| `conduyt_ai_deal_insights` | AI risk/momentum analysis and next actions for a single deal |
|
|
404
404
|
| `conduyt_ai_conversation_intelligence` | AI summary/sentiment/objections for a transcribed call |
|
|
405
405
|
| `conduyt_ai_call_disposition` | AI-suggested disposition for a call from its transcript |
|
|
406
|
+
| `conduyt_save_call_disposition` | Save a call's outcome; a Callback as a follow-up task (default) or a real calendar appointment that blocks the slot (`callbackMode`, `callbackDurationMinutes`) |
|
|
406
407
|
| `conduyt_ai_daily_brief` | AI daily brief — today's priorities for a user |
|
|
407
408
|
| `conduyt_ai_next_actions` | AI-ranked next actions for a user |
|
|
408
409
|
| `conduyt_ai_feed` | Chronological stream of AI-surfaced events and insights |
|
package/dist/tool-annotations.js
CHANGED
|
@@ -111,6 +111,7 @@ export const TOOL_ANNOTATIONS = {
|
|
|
111
111
|
conduyt_link_call: update("Link Call"),
|
|
112
112
|
conduyt_get_call: ro("Get Call"),
|
|
113
113
|
conduyt_get_post_call_insight: ro("Get Post Call Insight"),
|
|
114
|
+
conduyt_save_call_disposition: row("Save Call Disposition", false, false, false), // (#1262) PATCH; non-destructive but NOT idempotent: a same-mode repeat books nothing new yet still appends a call.updated audit record (Codex parity26-r1 P2)
|
|
114
115
|
conduyt_sync_local_presence: row("Sync Local Presence", false, false, false), // every call writes lastSyncedAt (local-presence-sync.ts:225)
|
|
115
116
|
conduyt_get_dialer_settings: ro("Get Dialer Settings"),
|
|
116
117
|
conduyt_update_dialer_settings: update("Update Dialer Settings"),
|
|
@@ -151,6 +152,9 @@ export const TOOL_ANNOTATIONS = {
|
|
|
151
152
|
conduyt_void_invoice: destroy("Void Invoice"), // terminal: a voided invoice cannot be edited, sent or paid; a repeat is refused
|
|
152
153
|
conduyt_delete_invoice: destroy("Delete Invoice"),
|
|
153
154
|
conduyt_duplicate_invoice: create("Duplicate Invoice"),
|
|
155
|
+
conduyt_get_invoice_reminders: ro("Get Invoice Reminders"),
|
|
156
|
+
conduyt_set_invoice_reminders_paused: create("Set Invoice Reminders Paused"), // not idempotent by the parity26 ruling: the same value again changes nothing but still appends an audit record (invoices/[id]/reminders/route.ts)
|
|
157
|
+
conduyt_get_invoice_billing_summary: ro("Get Invoice Billing Summary"),
|
|
154
158
|
conduyt_list_tax_rates: ro("List Tax Rates"),
|
|
155
159
|
conduyt_create_tax_rate: create("Create Tax Rate"),
|
|
156
160
|
conduyt_update_tax_rate: update("Update Tax Rate"),
|
package/dist/tools/calls.d.ts
CHANGED
|
@@ -1,7 +1,27 @@
|
|
|
1
1
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
2
|
+
import { z } from "zod";
|
|
2
3
|
import { ConduytClient } from "../client.js";
|
|
3
4
|
/** Where a call's audio is fetched (no tool carries the bytes: a binary stream does not belong in a tool result). */
|
|
4
5
|
export declare const RECORDING_DOWNLOAD_NOTE = "AUDIO is not returned by any tool: GET {API base}/api/v1/dialer/call/{id}/media?type=recording (or type=voicemail) streams it, with the header `Authorization: Bearer <the same API key>`; add `&download=1` (or `download=true`) for a `Content-Disposition: attachment` file named `<Contact or number>_<date>_<time>_<callId8>.mp3` (the same authorisation and the same stream; a call with no media is a 404). The conduyt CLI does this: `conduyt dialer recording download <callId> [--voicemail] [-o file]`.";
|
|
6
|
+
export declare const CALL_DISPOSITION_DESCRIPTION: string;
|
|
7
|
+
export declare const CALL_DISPOSITION_SCHEMA: {
|
|
8
|
+
id: z.ZodString;
|
|
9
|
+
disposition: z.ZodOptional<z.ZodString>;
|
|
10
|
+
notes: z.ZodOptional<z.ZodString>;
|
|
11
|
+
callbackAt: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
|
|
12
|
+
callbackMode: z.ZodOptional<z.ZodEnum<["task", "appointment"]>>;
|
|
13
|
+
callbackDurationMinutes: z.ZodOptional<z.ZodNumber>;
|
|
14
|
+
};
|
|
15
|
+
type CallDispositionArgs = {
|
|
16
|
+
id: string;
|
|
17
|
+
disposition?: string;
|
|
18
|
+
notes?: string;
|
|
19
|
+
callbackAt?: string;
|
|
20
|
+
callbackMode?: string;
|
|
21
|
+
callbackDurationMinutes?: number;
|
|
22
|
+
};
|
|
23
|
+
/** Mirrors the API's invalid_callback_fields 400s so a bad combination never leaves the machine. */
|
|
24
|
+
export declare function checkCallDisposition(a: CallDispositionArgs): void;
|
|
5
25
|
/**
|
|
6
26
|
* Dialer/call-history tools. Live call control (initiate, mute, hold,
|
|
7
27
|
* transfer, hangup, vm-drop, record) is deliberately NOT exposed here —
|
|
@@ -11,3 +31,4 @@ export declare const RECORDING_DOWNLOAD_NOTE = "AUDIO is not returned by any too
|
|
|
11
31
|
* exactly like a rep's "Search a contact" + Attach.
|
|
12
32
|
*/
|
|
13
33
|
export declare function registerCallTools(server: McpServer, client: ConduytClient): void;
|
|
34
|
+
export {};
|
package/dist/tools/calls.js
CHANGED
|
@@ -2,6 +2,34 @@ import { z } from "zod";
|
|
|
2
2
|
import { formatResult } from "../client.js";
|
|
3
3
|
/** Where a call's audio is fetched (no tool carries the bytes: a binary stream does not belong in a tool result). */
|
|
4
4
|
export const RECORDING_DOWNLOAD_NOTE = "AUDIO is not returned by any tool: GET {API base}/api/v1/dialer/call/{id}/media?type=recording (or type=voicemail) streams it, with the header `Authorization: Bearer <the same API key>`; add `&download=1` (or `download=true`) for a `Content-Disposition: attachment` file named `<Contact or number>_<date>_<time>_<callId8>.mp3` (the same authorisation and the same stream; a call with no media is a 404). The conduyt CLI does this: `conduyt dialer recording download <callId> [--voicemail] [-o file]`.";
|
|
5
|
+
/** (#1262) PATCH /dialer/call/{id}: the saved outcome of a call, and how a Callback is set up. */
|
|
6
|
+
const CALLBACK_MIN = 15;
|
|
7
|
+
const CALLBACK_MAX = 240;
|
|
8
|
+
export const CALL_DISPOSITION_DESCRIPTION = "Save a call's outcome (PATCH /api/v1/dialer/call/{id}; dialer scope; a rep saves only their own calls, an admin any). `disposition` is a built-in value (interested, not-interested, callback-requested, appointment-set, ...) or one of the account's custom outcomes. " +
|
|
9
|
+
"CALLBACK (disposition callback-requested, `callbackAt` = the callback time): `callbackMode` \"task\" (the default) creates a follow-up task due then and blocks nothing; \"appointment\" books a real calendar appointment for the call's agent at `callbackAt`, written back to their connected calendar and blocking that slot for booking. `callbackDurationMinutes` (a whole number from 15 to 240, default 30) only with the appointment mode. " +
|
|
10
|
+
"Saving the same callback again with the same mode returns the stored task or appointment and books nothing new; the other mode is refused 409 callback_mode_mismatch (the stored mode comes back as storedMode). " +
|
|
11
|
+
"Refusals, forwarded with their code and never retried: 400 invalid_callback_fields (a mode or duration on another disposition, a duration without the appointment mode or outside 15 to 240, an appointment without callbackAt); 400 callback_requires_contact (an appointment needs a contact on the call: match one, or use the task mode); 409 callback_conflict (the agent already has something on the calendar at that time: pick another time).";
|
|
12
|
+
export const CALL_DISPOSITION_SCHEMA = {
|
|
13
|
+
id: z.string().uuid().describe("Call UUID"),
|
|
14
|
+
disposition: z.string().trim().min(1).optional().describe("The outcome: a built-in value or a custom outcome of the account"),
|
|
15
|
+
notes: z.string().optional().describe("The rep's notes on the call"),
|
|
16
|
+
callbackAt: z.string().refine((v) => !Number.isNaN(new Date(v).getTime()), "callbackAt must be a date and time").optional().describe("The callback time (ISO 8601), with disposition callback-requested; required for callbackMode appointment"),
|
|
17
|
+
callbackMode: z.enum(["task", "appointment"]).optional().describe("task (default) = a follow-up task due at callbackAt, blocks nothing; appointment = a real calendar appointment for the call's agent that blocks the slot. Only with disposition callback-requested"),
|
|
18
|
+
callbackDurationMinutes: z.number().int().min(CALLBACK_MIN).max(CALLBACK_MAX).optional().describe("Appointment length in minutes, a whole number from 15 to 240 (default 30). Only with callbackMode appointment"),
|
|
19
|
+
};
|
|
20
|
+
/** Mirrors the API's invalid_callback_fields 400s so a bad combination never leaves the machine. */
|
|
21
|
+
export function checkCallDisposition(a) {
|
|
22
|
+
const callback = a.callbackMode !== undefined || a.callbackDurationMinutes !== undefined;
|
|
23
|
+
if (callback && !(a.disposition !== undefined && a.disposition.trim().toLowerCase().replace(/[\s_]+/g, "-") === "callback-requested")) {
|
|
24
|
+
throw new Error("callbackMode and callbackDurationMinutes apply only with disposition callback-requested.");
|
|
25
|
+
}
|
|
26
|
+
if (a.callbackDurationMinutes !== undefined && a.callbackMode !== "appointment")
|
|
27
|
+
throw new Error('callbackDurationMinutes applies only with callbackMode "appointment".');
|
|
28
|
+
if (a.callbackMode === "appointment" && a.callbackAt === undefined)
|
|
29
|
+
throw new Error('callbackMode "appointment" needs callbackAt (the callback time).');
|
|
30
|
+
if (a.disposition === undefined && a.notes === undefined && a.callbackAt === undefined)
|
|
31
|
+
throw new Error("Pass at least disposition or notes.");
|
|
32
|
+
}
|
|
5
33
|
const SEARCH_FILTERS = {
|
|
6
34
|
q: z.string().refine((v) => Array.from(v).length <= 200, "q is at most 200 characters").optional().describe("Search words (200 characters at most; a repeated q is a 400): matches the contact's name, a phone number, the agent's name and the call's transcript (NOT the call's notes); each row then carries `match`"),
|
|
7
35
|
recordedOnly: z.boolean().optional().describe("true = only calls that have a recording (sent as recorded_only=1)"),
|
|
@@ -133,6 +161,17 @@ export function registerCallTools(server, client) {
|
|
|
133
161
|
const result = await client.get(`/api/v1/dialer/call/${encodeURIComponent(id)}/post-call?include=${includeTranscript ? "transcript" : ""}`);
|
|
134
162
|
return formatResult(result);
|
|
135
163
|
});
|
|
164
|
+
server.tool("conduyt_save_call_disposition", CALL_DISPOSITION_DESCRIPTION, CALL_DISPOSITION_SCHEMA, async (args) => {
|
|
165
|
+
checkCallDisposition(args);
|
|
166
|
+
const result = await client.patch(`/api/v1/dialer/call/${encodeURIComponent(args.id)}`, {
|
|
167
|
+
disposition: args.disposition,
|
|
168
|
+
notes: args.notes,
|
|
169
|
+
callbackAt: args.callbackAt,
|
|
170
|
+
callbackMode: args.callbackMode,
|
|
171
|
+
callbackDurationMinutes: args.callbackDurationMinutes,
|
|
172
|
+
});
|
|
173
|
+
return formatResult(result);
|
|
174
|
+
});
|
|
136
175
|
server.tool("conduyt_sync_local_presence", "Sync the dialer's Local Presence number pool from the account's Twilio subaccount. IMPORTANT — sync only adopts numbers that meet ALL of: (1) the Twilio FriendlyName contains a standalone 'LP' (or 'LocalPres'), e.g. 'LP Miami 305'; (2) the number is voice-capable; (3) it is a US +1 E.164 number. The first 50 matches in sorted order become the pool; anything already in the pool that no longer matches is REMOVED. So buying a number is not enough — name it with the LP convention in Twilio first, then run this. Returns pool/added/removed/matched. Requires settings:edit.", {}, async () => {
|
|
137
176
|
const result = await client.post("/api/v1/dialer/local-presence/sync", {});
|
|
138
177
|
return formatResult(result);
|
package/dist/tools/invoices.js
CHANGED
|
@@ -15,19 +15,22 @@ const lineItem = z.object({
|
|
|
15
15
|
taxPercent: z.number().optional().describe("A one-off tax percent (with taxName)"),
|
|
16
16
|
});
|
|
17
17
|
export function registerInvoiceTools(server, client) {
|
|
18
|
-
server.tool("conduyt_list_invoices", "List invoices with filtering by status, contact, or date range.", {
|
|
18
|
+
server.tool("conduyt_list_invoices", "List invoices with filtering by status, contact, deal, or date range. deal_id (one UUID) is the deal card's View all: 400 invalid_request if it is repeated or not a UUID, 403 for a key without the deals scope, 404 when the deal does not exist or the caller cannot see it.", {
|
|
19
19
|
status: z.string().optional().describe("Filter by status (e.g. 'draft', 'sent', 'paid', 'overdue', 'voided')"),
|
|
20
20
|
contact_id: z.string().optional().describe("Filter by contact UUID"),
|
|
21
|
+
deal_id: z.string().uuid().optional().describe("Filter by deal UUID (one value; an invalid or empty value is refused before any request)"),
|
|
21
22
|
date_from: z.string().optional().describe("Start of date range (ISO 8601)"),
|
|
22
23
|
date_to: z.string().optional().describe("End of date range (ISO 8601)"),
|
|
23
24
|
page: z.number().optional().describe("Page number (default 1)"),
|
|
24
25
|
per_page: z.number().optional().describe("Results per page"),
|
|
25
|
-
}, async ({ status, contact_id, date_from, date_to, page, per_page }) => {
|
|
26
|
+
}, async ({ status, contact_id, deal_id, date_from, date_to, page, per_page }) => {
|
|
26
27
|
const params = new URLSearchParams();
|
|
27
28
|
if (status)
|
|
28
29
|
params.set("status", status);
|
|
29
30
|
if (contact_id)
|
|
30
31
|
params.set("contact_id", contact_id);
|
|
32
|
+
if (deal_id !== undefined)
|
|
33
|
+
params.set("deal_id", deal_id);
|
|
31
34
|
if (date_from)
|
|
32
35
|
params.set("date_from", date_from);
|
|
33
36
|
if (date_to)
|
|
@@ -131,4 +134,23 @@ export function registerInvoiceTools(server, client) {
|
|
|
131
134
|
const result = await client.post(`/api/v1/invoices/${id}/duplicate`, {});
|
|
132
135
|
return formatResult(result);
|
|
133
136
|
});
|
|
137
|
+
server.tool("conduyt_get_invoice_reminders", "What the account's Invoice reminders automation does for THIS invoice (the invoice page's Reminders card): { state, automation, applies, steps }. state is on, paused (this invoice's switch is off), inactive (a reminders automation exists but none is active) or none (no reminders automation). automation is { id, name, isActive } or null; applies is true only while the invoice is out for payment (sent, viewed, partly paid, overdue); each step is { nodeId, label, at, sent } with the date it is due and what went out when. 404 when the invoice does not exist or the caller cannot see it.", { id: z.string().uuid().describe("Invoice UUID") }, async ({ id }) => {
|
|
138
|
+
const result = await client.get(`/api/v1/invoices/${encodeURIComponent(id)}/reminders`);
|
|
139
|
+
return formatResult(result);
|
|
140
|
+
});
|
|
141
|
+
server.tool("conduyt_set_invoice_reminders_paused", "The invoice's Reminders switch: paused true makes the Invoice reminders automation skip this invoice's reminders (its waits still run), paused false resumes the next one. Nothing is scheduled by this call: the reminders are the automation. Returns the same view as conduyt_get_invoice_reminders. Setting the value it already has changes nothing (an audit record is still appended). 400 invalid_request (paused must be true or false; an unknown key is refused), 404 when the invoice does not exist or the caller may not edit it.", { id: z.string().uuid().describe("Invoice UUID"), paused: z.boolean().describe("true = skip this invoice's reminders; false = resume") }, async ({ id, paused }) => {
|
|
142
|
+
const result = await client.patch(`/api/v1/invoices/${encodeURIComponent(id)}/reminders`, { paused });
|
|
143
|
+
return formatResult(result);
|
|
144
|
+
});
|
|
145
|
+
server.tool("conduyt_get_invoice_billing_summary", "The billing state the Invoices card shows on a deal or a contact page: { totals, latest, count }. totals is per currency { currency, invoiced, paid, outstanding, overdue, count }; latest is the newest invoices (id, invoiceNumber, status, total, amountPaid, balance, currency, dates, contactId, dealId). Pass exactly one of dealId or contactId (refused before any request otherwise; the API answers 400 invalid_request). 403 for a key without the deals scope on a dealId; 404 when the deal or contact does not exist or the caller cannot see it.", { dealId: z.string().uuid().optional().describe("Deal UUID"), contactId: z.string().uuid().optional().describe("Contact UUID") }, async ({ dealId, contactId }) => {
|
|
146
|
+
if ((dealId === undefined) === (contactId === undefined))
|
|
147
|
+
throw new Error("Pass exactly one of dealId or contactId.");
|
|
148
|
+
const params = new URLSearchParams();
|
|
149
|
+
if (dealId !== undefined)
|
|
150
|
+
params.set("deal_id", dealId);
|
|
151
|
+
else if (contactId !== undefined)
|
|
152
|
+
params.set("contact_id", contactId);
|
|
153
|
+
const result = await client.get(`/api/v1/invoices/summary?${params}`);
|
|
154
|
+
return formatResult(result);
|
|
155
|
+
});
|
|
134
156
|
}
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
|
-
"generatedAt": "2026-11-
|
|
3
|
-
"toolCount":
|
|
4
|
-
"totalEndpoints":
|
|
2
|
+
"generatedAt": "2026-11-11T01:18:38.260Z",
|
|
3
|
+
"toolCount": 415,
|
|
4
|
+
"totalEndpoints": 1193,
|
|
5
5
|
"counts": {
|
|
6
|
-
"covered":
|
|
6
|
+
"covered": 367,
|
|
7
7
|
"excluded": 368,
|
|
8
8
|
"planned": 458,
|
|
9
9
|
"uncategorized": 0
|
|
@@ -235,6 +235,18 @@
|
|
|
235
235
|
"status": "planned",
|
|
236
236
|
"reason": "invoicing"
|
|
237
237
|
},
|
|
238
|
+
"GET /api/v1/invoices/:id/reminders": {
|
|
239
|
+
"status": "covered",
|
|
240
|
+
"tools": [
|
|
241
|
+
"conduyt_get_invoice_reminders"
|
|
242
|
+
]
|
|
243
|
+
},
|
|
244
|
+
"PATCH /api/v1/invoices/:id/reminders": {
|
|
245
|
+
"status": "covered",
|
|
246
|
+
"tools": [
|
|
247
|
+
"conduyt_set_invoice_reminders_paused"
|
|
248
|
+
]
|
|
249
|
+
},
|
|
238
250
|
"POST /api/v1/invoices/:id/send": {
|
|
239
251
|
"status": "covered",
|
|
240
252
|
"tools": [
|
|
@@ -257,6 +269,12 @@
|
|
|
257
269
|
"status": "planned",
|
|
258
270
|
"reason": "invoicing"
|
|
259
271
|
},
|
|
272
|
+
"GET /api/v1/invoices/summary": {
|
|
273
|
+
"status": "covered",
|
|
274
|
+
"tools": [
|
|
275
|
+
"conduyt_get_invoice_billing_summary"
|
|
276
|
+
]
|
|
277
|
+
},
|
|
260
278
|
"POST /api/public/subscribe": {
|
|
261
279
|
"status": "excluded",
|
|
262
280
|
"reason": "public unauthenticated surfaces (forms, booking, unsubscribe) — no key semantics"
|
|
@@ -2124,6 +2142,10 @@
|
|
|
2124
2142
|
"status": "excluded",
|
|
2125
2143
|
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
2126
2144
|
},
|
|
2145
|
+
"GET /api/v1/cron/process-calendar-provider-ops": {
|
|
2146
|
+
"status": "excluded",
|
|
2147
|
+
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
2148
|
+
},
|
|
2127
2149
|
"GET /api/v1/cron/process-calendly-sync": {
|
|
2128
2150
|
"status": "excluded",
|
|
2129
2151
|
"reason": "CRON_SECRET-gated infrastructure jobs; never key-callable"
|
|
@@ -2696,8 +2718,10 @@
|
|
|
2696
2718
|
"reason": "realtime browser dialer (WebRTC tokens, live call control) — needs a live audio session"
|
|
2697
2719
|
},
|
|
2698
2720
|
"PATCH /api/v1/dialer/call/:id": {
|
|
2699
|
-
"status": "
|
|
2700
|
-
"
|
|
2721
|
+
"status": "covered",
|
|
2722
|
+
"tools": [
|
|
2723
|
+
"conduyt_save_call_disposition"
|
|
2724
|
+
]
|
|
2701
2725
|
},
|
|
2702
2726
|
"POST /api/v1/dialer/call/:id/ai-disposition": {
|
|
2703
2727
|
"status": "covered",
|