@avallon-labs/mcp 18.0.0 → 19.1.0-staging.444

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 CHANGED
@@ -54,5 +54,5 @@ function setupFetch() {
54
54
 
55
55
  // src/index.ts
56
56
  setupFetch();
57
- await import("./server-D6OQWFIX.js");
57
+ await import("./server-HS55UPC6.js");
58
58
  //# sourceMappingURL=index.js.map
@@ -1309,6 +1309,40 @@ var listWorkerWebhooks = async (workerId, options) => {
1309
1309
  headers: res.headers
1310
1310
  };
1311
1311
  };
1312
+ var getCreateChatAgentUrl = () => {
1313
+ return `/v1/chat-agents`;
1314
+ };
1315
+ var createChatAgent = async (createChatAgentBody, options) => {
1316
+ const res = await fetch(getCreateChatAgentUrl(), {
1317
+ ...options,
1318
+ method: "POST",
1319
+ headers: { "Content-Type": "application/json", ...options?.headers },
1320
+ body: JSON.stringify(createChatAgentBody)
1321
+ });
1322
+ const body = [204, 205, 304].includes(res.status) ? null : await res.text();
1323
+ const data = body ? JSON.parse(body) : {};
1324
+ return {
1325
+ data,
1326
+ status: res.status,
1327
+ headers: res.headers
1328
+ };
1329
+ };
1330
+ var getGetChatAgentUrl = (chatAgentId) => {
1331
+ return `/v1/chat-agents/${chatAgentId}`;
1332
+ };
1333
+ var getChatAgent = async (chatAgentId, options) => {
1334
+ const res = await fetch(getGetChatAgentUrl(chatAgentId), {
1335
+ ...options,
1336
+ method: "GET"
1337
+ });
1338
+ const body = [204, 205, 304].includes(res.status) ? null : await res.text();
1339
+ const data = body ? JSON.parse(body) : {};
1340
+ return {
1341
+ data,
1342
+ status: res.status,
1343
+ headers: res.headers
1344
+ };
1345
+ };
1312
1346
  var getGetExtractUrl = (id) => {
1313
1347
  return `/v1/extracts/${id}`;
1314
1348
  };
@@ -2450,6 +2484,28 @@ var listWorkerWebhooksHandler = async (args) => {
2450
2484
  ]
2451
2485
  };
2452
2486
  };
2487
+ var createChatAgentHandler = async (args) => {
2488
+ const res = await createChatAgent(args.bodyParams);
2489
+ return {
2490
+ content: [
2491
+ {
2492
+ type: "text",
2493
+ text: JSON.stringify(res)
2494
+ }
2495
+ ]
2496
+ };
2497
+ };
2498
+ var getChatAgentHandler = async (args) => {
2499
+ const res = await getChatAgent(args.pathParams.chatAgentId);
2500
+ return {
2501
+ content: [
2502
+ {
2503
+ type: "text",
2504
+ text: JSON.stringify(res)
2505
+ }
2506
+ ]
2507
+ };
2508
+ };
2453
2509
  var getExtractHandler = async (args) => {
2454
2510
  const res = await getExtract(args.pathParams.id);
2455
2511
  return {
@@ -2834,7 +2890,7 @@ var CreateVoiceAgentBody = zod.object({
2834
2890
  call_processor_type: zod.enum(["extractor", "worker"]).optional().describe("Type of processor: extractor or worker")
2835
2891
  });
2836
2892
  var GetVoiceAgentParams = zod.object({
2837
- voiceAgentId: zod.string().min(1).describe("Voice Agent ID")
2893
+ voiceAgentId: zod.string().uuid().describe("Voice Agent ID")
2838
2894
  });
2839
2895
  var GetVoiceAgentResponse = zod.object({
2840
2896
  agent: zod.object({
@@ -2894,7 +2950,7 @@ var UpdateVoiceAgentParams = zod.object({
2894
2950
  });
2895
2951
  var UpdateVoiceAgentBody = zod.object({
2896
2952
  name: zod.string().min(1).optional(),
2897
- call_processor_id: zod.union([zod.string(), zod.null()]).optional(),
2953
+ call_processor_id: zod.union([zod.string().uuid(), zod.null()]).optional(),
2898
2954
  call_processor_type: zod.enum(["extractor", "worker"]).optional()
2899
2955
  });
2900
2956
  var UpdateVoiceAgentResponse = zod.object({
@@ -3069,13 +3125,13 @@ var DeleteToolsFromVoiceAgentResponse = zod.object({
3069
3125
  })
3070
3126
  });
3071
3127
  var GetVoiceAgentPromptParams = zod.object({
3072
- voiceAgentId: zod.string().min(1)
3128
+ voiceAgentId: zod.string().uuid()
3073
3129
  });
3074
3130
  var GetVoiceAgentPromptResponse = zod.object({
3075
3131
  placeholders: zod.array(zod.string()).describe("Available placeholder variables")
3076
3132
  });
3077
3133
  var UpdateVoiceAgentModelsParams = zod.object({
3078
- voiceAgentId: zod.string().min(1)
3134
+ voiceAgentId: zod.string().uuid()
3079
3135
  });
3080
3136
  var UpdateVoiceAgentModelsBody = zod.object({
3081
3137
  llm_model: zod.enum([
@@ -3312,7 +3368,7 @@ var ListJobsResponseItem = zod.object({
3312
3368
  });
3313
3369
  var ListJobsResponse = zod.array(ListJobsResponseItem);
3314
3370
  var CancelJobParams = zod.object({
3315
- jobId: zod.string().min(1)
3371
+ jobId: zod.string().uuid()
3316
3372
  });
3317
3373
  var CancelJobResponse = zod.object({
3318
3374
  id: zod.string(),
@@ -4377,6 +4433,23 @@ var ListWorkerWebhooksResponseItem = zod.object({
4377
4433
  var ListWorkerWebhooksResponse = zod.array(
4378
4434
  ListWorkerWebhooksResponseItem
4379
4435
  );
4436
+ var CreateChatAgentBody = zod.object({
4437
+ name: zod.string().min(1),
4438
+ prompt: zod.string().min(1)
4439
+ });
4440
+ var CreateChatAgentResponse = zod.object({
4441
+ chat_agent_id: zod.string(),
4442
+ created_at: zod.string().datetime({})
4443
+ });
4444
+ var GetChatAgentParams = zod.object({
4445
+ chatAgentId: zod.string().uuid()
4446
+ });
4447
+ var GetChatAgentResponse = zod.object({
4448
+ id: zod.string(),
4449
+ name: zod.string(),
4450
+ created_at: zod.string().datetime({}),
4451
+ updated_at: zod.string().datetime({})
4452
+ });
4380
4453
  var GetExtractParams = zod.object({
4381
4454
  id: zod.string().uuid()
4382
4455
  });
@@ -4482,7 +4555,8 @@ var GetProfileResponse = zod.object({
4482
4555
  "claims:write",
4483
4556
  "feedback:write",
4484
4557
  "outbound-jobs:write",
4485
- "workers:write"
4558
+ "workers:write",
4559
+ "chat-agents:write"
4486
4560
  ])
4487
4561
  ),
4488
4562
  tenants: zod.object({
@@ -4571,7 +4645,7 @@ var ExecuteCodeResponse = zod.object({
4571
4645
  )
4572
4646
  });
4573
4647
  var GetToolParams = zod.object({
4574
- id: zod.string().min(1)
4648
+ id: zod.string().uuid()
4575
4649
  });
4576
4650
  var GetToolResponse = zod.object({
4577
4651
  tool: zod.object({
@@ -5420,6 +5494,22 @@ server.tool(
5420
5494
  },
5421
5495
  listWorkerWebhooksHandler
5422
5496
  );
5497
+ server.tool(
5498
+ "createChatAgent",
5499
+ "Create chat agent",
5500
+ {
5501
+ bodyParams: CreateChatAgentBody
5502
+ },
5503
+ createChatAgentHandler
5504
+ );
5505
+ server.tool(
5506
+ "getChatAgent",
5507
+ "Get chat agent",
5508
+ {
5509
+ pathParams: GetChatAgentParams
5510
+ },
5511
+ getChatAgentHandler
5512
+ );
5423
5513
  server.tool(
5424
5514
  "getExtract",
5425
5515
  "Get extract",
@@ -5601,4 +5691,4 @@ var transport = new StdioServerTransport();
5601
5691
  server.connect(transport).then(() => {
5602
5692
  console.error("MCP server running on stdio");
5603
5693
  }).catch(console.error);
5604
- //# sourceMappingURL=server-D6OQWFIX.js.map
5694
+ //# sourceMappingURL=server-HS55UPC6.js.map