@dudamel/mcp-peers 2026.1104.1 → 2026.1106.2
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/index.js +14 -7
- package/dist/stdio-server.js +14 -7
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -37,6 +37,10 @@ var DudamelApiError = class extends Error {
|
|
|
37
37
|
if (apiError?.context?.["inputsSchema"] !== void 0) {
|
|
38
38
|
lines.push(`Expected inputs schema: ${JSON.stringify(apiError.context["inputsSchema"])}`);
|
|
39
39
|
}
|
|
40
|
+
const rest = Object.entries(apiError?.context ?? {}).filter(([key]) => key !== "inputsSchema");
|
|
41
|
+
if (rest.length > 0) {
|
|
42
|
+
lines.push(`Context: ${JSON.stringify(Object.fromEntries(rest))}`);
|
|
43
|
+
}
|
|
40
44
|
super(lines.join("\n"));
|
|
41
45
|
this.status = status;
|
|
42
46
|
this.statusText = statusText;
|
|
@@ -145,9 +149,12 @@ function errorResult(error) {
|
|
|
145
149
|
};
|
|
146
150
|
}
|
|
147
151
|
|
|
148
|
-
//
|
|
152
|
+
// ../common/dist/owner-tools.js
|
|
149
153
|
import { z } from "zod";
|
|
150
154
|
|
|
155
|
+
// src/tools/peers.ts
|
|
156
|
+
import { z as z2 } from "zod";
|
|
157
|
+
|
|
151
158
|
// src/poll.ts
|
|
152
159
|
var GET_TASK_MAX_WAIT_SECONDS = 120;
|
|
153
160
|
var INITIAL_POLL_INTERVAL_MS = 2e3;
|
|
@@ -193,12 +200,12 @@ function registerPeerTools(server, client, config) {
|
|
|
193
200
|
{
|
|
194
201
|
description: "Send a message to another dudamel agent. Returns a task: in async mode (the default) it comes back `submitted` immediately \u2014 tell the user you delegated and end your turn; the answer arrives later as an `a2a-task-completed` system message (or poll it with get-task if you have no conversation). `sync` blocks and returns the task `completed` with the answer \u2014 only for short questions. Every response carries a `contextId`: pass it back on the next send-message to CONTINUE that conversation with the peer (it keeps its full history); omit it to start fresh.",
|
|
195
202
|
inputSchema: {
|
|
196
|
-
agentName:
|
|
197
|
-
message:
|
|
203
|
+
agentName: z2.string().min(1).describe("Peer agent to message \u2014 a `name` from list-agents"),
|
|
204
|
+
message: z2.string().min(1).describe(
|
|
198
205
|
"The message. Be specific and self-contained: the peer does not see your conversation"
|
|
199
206
|
),
|
|
200
|
-
contextId:
|
|
201
|
-
mode:
|
|
207
|
+
contextId: z2.string().optional().describe("contextId from a previous exchange \u2014 continues that same thread"),
|
|
208
|
+
mode: z2.enum(["async", "sync"]).optional().describe("async (default): fire and get notified. sync: wait for the answer inline")
|
|
202
209
|
},
|
|
203
210
|
annotations: { readOnlyHint: false, destructiveHint: false }
|
|
204
211
|
},
|
|
@@ -227,8 +234,8 @@ function registerPeerTools(server, client, config) {
|
|
|
227
234
|
{
|
|
228
235
|
description: `Status and result of a send-message task by its \`taskId\`. Statuses: submitted (the peer has not answered yet), completed (\`result\` holds the answer), failed (\`errorSummary\` says why). Use it when you sent async and no completion message can reach you (e.g. you run outside a dudamel conversation). Pass \`waitSeconds\` (max ${GET_TASK_MAX_WAIT_SECONDS}) to have the tool poll internally and return as soon as the task goes terminal \u2014 if it is still submitted at the deadline, call again later instead of looping yourself.`,
|
|
229
236
|
inputSchema: {
|
|
230
|
-
taskId:
|
|
231
|
-
waitSeconds:
|
|
237
|
+
taskId: z2.string().min(1).describe("The `taskId` a send-message response returned"),
|
|
238
|
+
waitSeconds: z2.number().int().min(0).max(GET_TASK_MAX_WAIT_SECONDS).optional().describe("Keep polling internally up to this many seconds (default 0: one look)")
|
|
232
239
|
},
|
|
233
240
|
annotations: { readOnlyHint: true }
|
|
234
241
|
},
|
package/dist/stdio-server.js
CHANGED
|
@@ -39,6 +39,10 @@ var DudamelApiError = class extends Error {
|
|
|
39
39
|
if (apiError?.context?.["inputsSchema"] !== void 0) {
|
|
40
40
|
lines.push(`Expected inputs schema: ${JSON.stringify(apiError.context["inputsSchema"])}`);
|
|
41
41
|
}
|
|
42
|
+
const rest = Object.entries(apiError?.context ?? {}).filter(([key]) => key !== "inputsSchema");
|
|
43
|
+
if (rest.length > 0) {
|
|
44
|
+
lines.push(`Context: ${JSON.stringify(Object.fromEntries(rest))}`);
|
|
45
|
+
}
|
|
42
46
|
super(lines.join("\n"));
|
|
43
47
|
this.status = status;
|
|
44
48
|
this.statusText = statusText;
|
|
@@ -159,11 +163,14 @@ function errorResult(error) {
|
|
|
159
163
|
};
|
|
160
164
|
}
|
|
161
165
|
|
|
166
|
+
// ../common/dist/owner-tools.js
|
|
167
|
+
import { z } from "zod";
|
|
168
|
+
|
|
162
169
|
// src/server.ts
|
|
163
170
|
import { McpServer as McpServer2 } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
164
171
|
|
|
165
172
|
// src/tools/peers.ts
|
|
166
|
-
import { z } from "zod";
|
|
173
|
+
import { z as z2 } from "zod";
|
|
167
174
|
|
|
168
175
|
// src/poll.ts
|
|
169
176
|
var GET_TASK_MAX_WAIT_SECONDS = 120;
|
|
@@ -210,12 +217,12 @@ function registerPeerTools(server2, client, config) {
|
|
|
210
217
|
{
|
|
211
218
|
description: "Send a message to another dudamel agent. Returns a task: in async mode (the default) it comes back `submitted` immediately \u2014 tell the user you delegated and end your turn; the answer arrives later as an `a2a-task-completed` system message (or poll it with get-task if you have no conversation). `sync` blocks and returns the task `completed` with the answer \u2014 only for short questions. Every response carries a `contextId`: pass it back on the next send-message to CONTINUE that conversation with the peer (it keeps its full history); omit it to start fresh.",
|
|
212
219
|
inputSchema: {
|
|
213
|
-
agentName:
|
|
214
|
-
message:
|
|
220
|
+
agentName: z2.string().min(1).describe("Peer agent to message \u2014 a `name` from list-agents"),
|
|
221
|
+
message: z2.string().min(1).describe(
|
|
215
222
|
"The message. Be specific and self-contained: the peer does not see your conversation"
|
|
216
223
|
),
|
|
217
|
-
contextId:
|
|
218
|
-
mode:
|
|
224
|
+
contextId: z2.string().optional().describe("contextId from a previous exchange \u2014 continues that same thread"),
|
|
225
|
+
mode: z2.enum(["async", "sync"]).optional().describe("async (default): fire and get notified. sync: wait for the answer inline")
|
|
219
226
|
},
|
|
220
227
|
annotations: { readOnlyHint: false, destructiveHint: false }
|
|
221
228
|
},
|
|
@@ -244,8 +251,8 @@ function registerPeerTools(server2, client, config) {
|
|
|
244
251
|
{
|
|
245
252
|
description: `Status and result of a send-message task by its \`taskId\`. Statuses: submitted (the peer has not answered yet), completed (\`result\` holds the answer), failed (\`errorSummary\` says why). Use it when you sent async and no completion message can reach you (e.g. you run outside a dudamel conversation). Pass \`waitSeconds\` (max ${GET_TASK_MAX_WAIT_SECONDS}) to have the tool poll internally and return as soon as the task goes terminal \u2014 if it is still submitted at the deadline, call again later instead of looping yourself.`,
|
|
246
253
|
inputSchema: {
|
|
247
|
-
taskId:
|
|
248
|
-
waitSeconds:
|
|
254
|
+
taskId: z2.string().min(1).describe("The `taskId` a send-message response returned"),
|
|
255
|
+
waitSeconds: z2.number().int().min(0).max(GET_TASK_MAX_WAIT_SECONDS).optional().describe("Keep polling internally up to this many seconds (default 0: one look)")
|
|
249
256
|
},
|
|
250
257
|
annotations: { readOnlyHint: true }
|
|
251
258
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dudamel/mcp-peers",
|
|
3
|
-
"version": "2026.
|
|
3
|
+
"version": "2026.1106.2",
|
|
4
4
|
"description": "Dudamel Peers MCP — stdio client for messaging the dudamel agents of an org (A2A-shaped tasks) over its REST API.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"type": "module",
|