@caypo/canton-mcp 0.1.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/index.js ADDED
@@ -0,0 +1,643 @@
1
+ #!/usr/bin/env node
2
+
3
+ // src/index.ts
4
+ import { Server } from "@modelcontextprotocol/sdk/server/index.js";
5
+ import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
6
+ import { CantonAgent } from "@caypo/canton-sdk";
7
+
8
+ // src/tools/index.ts
9
+ import {
10
+ CallToolRequestSchema,
11
+ ListToolsRequestSchema
12
+ } from "@modelcontextprotocol/sdk/types.js";
13
+
14
+ // src/tools/balance.ts
15
+ function balanceTools(agent) {
16
+ return [
17
+ {
18
+ name: "caypo_balance",
19
+ description: "Get USDCx checking account balance and holding count",
20
+ inputSchema: { type: "object", properties: {}, required: [] },
21
+ handler: async () => {
22
+ const bal = await agent.checking.balance();
23
+ return {
24
+ content: [
25
+ {
26
+ type: "text",
27
+ text: JSON.stringify({
28
+ available: bal.available,
29
+ holdingCount: bal.holdingCount,
30
+ currency: "USDCx",
31
+ network: agent.wallet.network
32
+ }, null, 2)
33
+ }
34
+ ]
35
+ };
36
+ }
37
+ },
38
+ {
39
+ name: "caypo_address",
40
+ description: "Get Canton party ID (address) and network info",
41
+ inputSchema: { type: "object", properties: {}, required: [] },
42
+ handler: async () => ({
43
+ content: [
44
+ {
45
+ type: "text",
46
+ text: JSON.stringify({
47
+ partyId: agent.wallet.address,
48
+ network: agent.wallet.network,
49
+ format: "<DisplayName>::<hex-fingerprint>"
50
+ }, null, 2)
51
+ }
52
+ ]
53
+ })
54
+ },
55
+ {
56
+ name: "caypo_history",
57
+ description: "Get recent transaction history",
58
+ inputSchema: {
59
+ type: "object",
60
+ properties: { limit: { type: "number", description: "Max transactions to return", default: 20 } }
61
+ },
62
+ handler: async (args) => {
63
+ const history = await agent.checking.history({ limit: args.limit });
64
+ return {
65
+ content: [{ type: "text", text: JSON.stringify(history, null, 2) }]
66
+ };
67
+ }
68
+ },
69
+ {
70
+ name: "caypo_positions",
71
+ description: "View DeFi positions (Coming in Phase 3)",
72
+ inputSchema: { type: "object", properties: {}, required: [] },
73
+ handler: async () => ({
74
+ content: [{ type: "text", text: "DeFi positions are not yet available. Coming in Phase 3 when Canton DeFi protocols launch." }]
75
+ })
76
+ },
77
+ {
78
+ name: "caypo_rates",
79
+ description: "Get exchange rates and APYs (Coming in Phase 3)",
80
+ inputSchema: { type: "object", properties: {}, required: [] },
81
+ handler: async () => ({
82
+ content: [{ type: "text", text: "Exchange rates and APYs are not yet available. Coming in Phase 3." }]
83
+ })
84
+ }
85
+ ];
86
+ }
87
+
88
+ // src/tools/checking.ts
89
+ function checkingTools(agent) {
90
+ return [
91
+ {
92
+ name: "caypo_send",
93
+ description: "Send USDCx to a recipient via TransferFactory_Transfer. Checks safeguards before sending.",
94
+ inputSchema: {
95
+ type: "object",
96
+ properties: {
97
+ recipient: { type: "string", description: "Recipient Canton party ID" },
98
+ amount: { type: "string", description: "Amount of USDCx to send (string, e.g. '1.50')" },
99
+ memo: { type: "string", description: "Optional memo" }
100
+ },
101
+ required: ["recipient", "amount"]
102
+ },
103
+ handler: async (args) => {
104
+ const { recipient, amount, memo } = args;
105
+ const result = await agent.checking.send(recipient, amount, { memo });
106
+ return {
107
+ content: [
108
+ {
109
+ type: "text",
110
+ text: JSON.stringify({
111
+ status: "success",
112
+ amount,
113
+ recipient,
114
+ updateId: result.updateId,
115
+ completionOffset: result.completionOffset,
116
+ commandId: result.commandId
117
+ }, null, 2)
118
+ }
119
+ ]
120
+ };
121
+ }
122
+ },
123
+ {
124
+ name: "caypo_receive",
125
+ description: "Show party ID and deposit instructions for receiving USDCx",
126
+ inputSchema: { type: "object", properties: {}, required: [] },
127
+ handler: async () => ({
128
+ content: [
129
+ {
130
+ type: "text",
131
+ text: JSON.stringify({
132
+ partyId: agent.wallet.address,
133
+ network: agent.wallet.network,
134
+ instructions: "Send USDCx to this party ID. The sender needs a TransferPreapproval or must use a 2-step TransferInstruction."
135
+ }, null, 2)
136
+ }
137
+ ]
138
+ })
139
+ },
140
+ {
141
+ name: "caypo_contacts",
142
+ description: "Manage contact list \u2014 list, add, or remove contacts",
143
+ inputSchema: {
144
+ type: "object",
145
+ properties: {
146
+ action: { type: "string", enum: ["list", "add", "remove"], default: "list" },
147
+ name: { type: "string", description: "Contact name" },
148
+ partyId: { type: "string", description: "Contact party ID" }
149
+ }
150
+ },
151
+ handler: async () => ({
152
+ content: [{ type: "text", text: "Contact management coming soon. Use party IDs directly for now." }]
153
+ })
154
+ }
155
+ ];
156
+ }
157
+
158
+ // src/tools/mpp.ts
159
+ function mppTools(agent) {
160
+ return [
161
+ {
162
+ name: "caypo_pay",
163
+ description: "Pay for an API call via MPP (HTTP 402 auto-handling). Fetches URL, handles payment if 402, returns response.",
164
+ inputSchema: {
165
+ type: "object",
166
+ properties: {
167
+ url: { type: "string", description: "URL to fetch" },
168
+ method: { type: "string", description: "HTTP method", default: "GET" },
169
+ body: { type: "string", description: "Request body (JSON string)" },
170
+ maxPrice: { type: "string", description: "Maximum price willing to pay in USDCx" }
171
+ },
172
+ required: ["url"]
173
+ },
174
+ handler: async (args) => {
175
+ const { url, method, body, maxPrice } = args;
176
+ const result = await agent.mpp.pay(url, {
177
+ method,
178
+ body,
179
+ maxPrice,
180
+ headers: body ? { "Content-Type": "application/json" } : void 0
181
+ });
182
+ const responseBody = await result.response.text();
183
+ return {
184
+ content: [
185
+ {
186
+ type: "text",
187
+ text: JSON.stringify({
188
+ status: result.response.status,
189
+ paid: result.paid,
190
+ receipt: result.receipt,
191
+ body: responseBody.slice(0, 2e3)
192
+ }, null, 2)
193
+ }
194
+ ]
195
+ };
196
+ }
197
+ },
198
+ {
199
+ name: "caypo_pay_status",
200
+ description: "Check payment status by Canton update ID",
201
+ inputSchema: {
202
+ type: "object",
203
+ properties: {
204
+ updateId: { type: "string", description: "Canton transaction update ID" }
205
+ },
206
+ required: ["updateId"]
207
+ },
208
+ handler: async () => ({
209
+ content: [{ type: "text", text: "Payment status lookup requires gateway integration. Use the updateId with the Canton Ledger API directly." }]
210
+ })
211
+ },
212
+ {
213
+ name: "caypo_services",
214
+ description: "List available MPP gateway services and pricing",
215
+ inputSchema: { type: "object", properties: {}, required: [] },
216
+ handler: async () => ({
217
+ content: [
218
+ {
219
+ type: "text",
220
+ text: JSON.stringify({
221
+ gateway: "mpp.cayvox.io",
222
+ services: [
223
+ { name: "OpenAI", path: "/openai", price: "$0.001-$0.05" },
224
+ { name: "Anthropic", path: "/anthropic", price: "$0.01" },
225
+ { name: "fal.ai", path: "/fal", price: "$0.01-$0.10" },
226
+ { name: "Firecrawl", path: "/firecrawl", price: "$0.005-$0.02" },
227
+ { name: "Google Gemini", path: "/gemini", price: "$0.005-$0.02" },
228
+ { name: "Groq", path: "/groq", price: "$0.001-$0.005" },
229
+ { name: "Perplexity", path: "/perplexity", price: "$0.01" },
230
+ { name: "Brave Search", path: "/brave", price: "$0.001-$0.005" },
231
+ { name: "DeepSeek", path: "/deepseek", price: "$0.005" },
232
+ { name: "Resend", path: "/resend", price: "$0.005" },
233
+ { name: "Together AI", path: "/together", price: "$0.001-$0.02" },
234
+ { name: "ElevenLabs", path: "/elevenlabs", price: "$0.02-$0.05" },
235
+ { name: "OpenWeather", path: "/openweather", price: "$0.001" },
236
+ { name: "Google Maps", path: "/googlemaps", price: "$0.005" },
237
+ { name: "Judge0", path: "/judge0", price: "$0.002" },
238
+ { name: "Reloadly", path: "/reloadly", price: "$0.01+" },
239
+ { name: "Lob", path: "/lob", price: "$0.01-$0.50" }
240
+ ]
241
+ }, null, 2)
242
+ }
243
+ ]
244
+ })
245
+ }
246
+ ];
247
+ }
248
+
249
+ // src/tools/safeguards.ts
250
+ function safeguardTools(agent) {
251
+ return [
252
+ {
253
+ name: "caypo_safeguards",
254
+ description: "View current safeguard settings: tx limit, daily limit, lock status, daily spending",
255
+ inputSchema: { type: "object", properties: {}, required: [] },
256
+ handler: async () => {
257
+ const s = agent.safeguards.settings();
258
+ return {
259
+ content: [{ type: "text", text: JSON.stringify(s, null, 2) }]
260
+ };
261
+ }
262
+ },
263
+ {
264
+ name: "caypo_set_limit",
265
+ description: "Set per-transaction or daily spending limit",
266
+ inputSchema: {
267
+ type: "object",
268
+ properties: {
269
+ type: { type: "string", enum: ["tx", "daily"], description: "Limit type" },
270
+ amount: { type: "string", description: "Limit amount in USDCx" }
271
+ },
272
+ required: ["type", "amount"]
273
+ },
274
+ handler: async (args) => {
275
+ const { type, amount } = args;
276
+ if (type === "tx") {
277
+ agent.safeguards.setTxLimit(amount);
278
+ } else {
279
+ agent.safeguards.setDailyLimit(amount);
280
+ }
281
+ return {
282
+ content: [{ type: "text", text: `${type === "tx" ? "Per-transaction" : "Daily"} limit set to ${amount} USDCx` }]
283
+ };
284
+ }
285
+ },
286
+ {
287
+ name: "caypo_lock",
288
+ description: "Lock or unlock the wallet. When locked, all transactions are rejected.",
289
+ inputSchema: {
290
+ type: "object",
291
+ properties: {
292
+ action: { type: "string", enum: ["lock", "unlock"], description: "Action to perform" },
293
+ pin: { type: "string", description: "PIN for lock/unlock" }
294
+ },
295
+ required: ["action"]
296
+ },
297
+ handler: async (args) => {
298
+ const { action, pin } = args;
299
+ if (action === "lock") {
300
+ agent.safeguards.lock(pin);
301
+ return { content: [{ type: "text", text: "Wallet locked. All transactions will be rejected until unlocked." }] };
302
+ } else {
303
+ agent.safeguards.unlock(pin ?? "");
304
+ return { content: [{ type: "text", text: "Wallet unlocked." }] };
305
+ }
306
+ }
307
+ }
308
+ ];
309
+ }
310
+
311
+ // src/tools/traffic.ts
312
+ function trafficTools(agent) {
313
+ return [
314
+ {
315
+ name: "caypo_traffic",
316
+ description: "Check validator traffic balance. Canton uses traffic budgets, not gas fees.",
317
+ inputSchema: { type: "object", properties: {}, required: [] },
318
+ handler: async () => {
319
+ const bal = await agent.traffic.trafficBalance();
320
+ return {
321
+ content: [
322
+ {
323
+ type: "text",
324
+ text: JSON.stringify({
325
+ ...bal,
326
+ note: "Canton uses traffic budgets per validator, not per-transaction gas fees."
327
+ }, null, 2)
328
+ }
329
+ ]
330
+ };
331
+ }
332
+ },
333
+ {
334
+ name: "caypo_purchase_traffic",
335
+ description: "Purchase additional traffic by burning Canton Coin (CC). Coming soon.",
336
+ inputSchema: {
337
+ type: "object",
338
+ properties: {
339
+ ccAmount: { type: "string", description: "Amount of CC to burn" }
340
+ },
341
+ required: ["ccAmount"]
342
+ },
343
+ handler: async () => ({
344
+ content: [{ type: "text", text: "Traffic purchase is not yet implemented. Requires validator admin API access." }]
345
+ })
346
+ }
347
+ ];
348
+ }
349
+
350
+ // src/tools/stubs.ts
351
+ function stub(name, description, phase) {
352
+ return {
353
+ name,
354
+ description: `${description} (Coming in ${phase})`,
355
+ inputSchema: { type: "object", properties: {} },
356
+ handler: async () => ({
357
+ content: [{ type: "text", text: `${description} is not yet available. Coming in ${phase} when Canton DeFi protocols launch.` }]
358
+ })
359
+ };
360
+ }
361
+ function stubTools() {
362
+ return [
363
+ // Savings (4)
364
+ stub("caypo_save", "Deposit USDCx into savings for yield", "Phase 3"),
365
+ stub("caypo_withdraw", "Withdraw from savings to checking", "Phase 3"),
366
+ stub("caypo_rebalance_savings", "Rebalance savings across protocols", "Phase 3"),
367
+ stub("caypo_earnings", "View savings earnings and APY", "Phase 3"),
368
+ // Credit (3)
369
+ stub("caypo_borrow", "Borrow USDCx against collateral", "Phase 3"),
370
+ stub("caypo_repay", "Repay borrowed amount", "Phase 3"),
371
+ stub("caypo_health", "Check credit health factor", "Phase 3"),
372
+ // Exchange (2)
373
+ stub("caypo_exchange", "Exchange tokens on Canton DEX", "Phase 3"),
374
+ stub("caypo_quote", "Get exchange rate quote", "Phase 3"),
375
+ // Investment (8)
376
+ stub("caypo_invest_buy", "Buy investment assets", "Phase 4"),
377
+ stub("caypo_invest_sell", "Sell investment assets", "Phase 4"),
378
+ stub("caypo_invest_earn", "Stake assets for yield", "Phase 4"),
379
+ stub("caypo_invest_unearn", "Unstake assets", "Phase 4"),
380
+ stub("caypo_invest_rebalance", "Rebalance investment portfolio", "Phase 4"),
381
+ stub("caypo_portfolio", "View investment portfolio", "Phase 4"),
382
+ stub("caypo_strategy_buy", "Execute investment strategy", "Phase 4"),
383
+ stub("caypo_auto_invest", "Configure auto-invest DCA", "Phase 4"),
384
+ // Rewards (2)
385
+ stub("caypo_claim_rewards", "Claim Canton Coin mining rewards", "Phase 3"),
386
+ stub("caypo_reward_history", "View reward claim history", "Phase 3")
387
+ ];
388
+ }
389
+
390
+ // src/tools/index.ts
391
+ function registerTools(server, agent) {
392
+ const allTools = [
393
+ ...balanceTools(agent),
394
+ ...checkingTools(agent),
395
+ ...mppTools(agent),
396
+ ...safeguardTools(agent),
397
+ ...trafficTools(agent),
398
+ ...stubTools()
399
+ ];
400
+ const toolMap = /* @__PURE__ */ new Map();
401
+ for (const tool of allTools) {
402
+ toolMap.set(tool.name, tool);
403
+ }
404
+ server.setRequestHandler(ListToolsRequestSchema, async () => ({
405
+ tools: allTools.map((t) => ({
406
+ name: t.name,
407
+ description: t.description,
408
+ inputSchema: t.inputSchema
409
+ }))
410
+ }));
411
+ server.setRequestHandler(CallToolRequestSchema, async (request) => {
412
+ const tool = toolMap.get(request.params.name);
413
+ if (!tool) {
414
+ return {
415
+ content: [{ type: "text", text: `Unknown tool: ${request.params.name}` }],
416
+ isError: true
417
+ };
418
+ }
419
+ try {
420
+ return await tool.handler(request.params.arguments ?? {});
421
+ } catch (err) {
422
+ return {
423
+ content: [{ type: "text", text: `Error: ${err.message}` }],
424
+ isError: true
425
+ };
426
+ }
427
+ });
428
+ }
429
+
430
+ // src/prompts/index.ts
431
+ import {
432
+ GetPromptRequestSchema,
433
+ ListPromptsRequestSchema
434
+ } from "@modelcontextprotocol/sdk/types.js";
435
+ function stubPrompt(name, description) {
436
+ return {
437
+ name,
438
+ description,
439
+ handler: () => ({
440
+ messages: [
441
+ {
442
+ role: "user",
443
+ content: {
444
+ type: "text",
445
+ text: `Please provide a ${description.toLowerCase()}. Note: This prompt template will be enhanced in a future version.`
446
+ }
447
+ }
448
+ ]
449
+ })
450
+ };
451
+ }
452
+ var prompts = [
453
+ // 5 fully implemented prompts
454
+ {
455
+ name: "morning_briefing",
456
+ description: "Daily financial briefing \u2014 balance, spending, traffic, alerts",
457
+ handler: () => ({
458
+ messages: [
459
+ {
460
+ role: "user",
461
+ content: {
462
+ type: "text",
463
+ text: `Good morning! Please give me my daily Canton agent briefing:
464
+
465
+ 1. **Balance**: Call caypo_balance to get my current USDCx balance and holding count.
466
+ 2. **Spending**: Call caypo_safeguards to check my daily spending vs limits.
467
+ 3. **Traffic**: Call caypo_traffic to check validator traffic status.
468
+ 4. **Recent activity**: Call caypo_history with limit=5 to show recent transactions.
469
+
470
+ Format as a concise morning briefing with key numbers highlighted.`
471
+ }
472
+ }
473
+ ]
474
+ })
475
+ },
476
+ {
477
+ name: "financial_report",
478
+ description: "Comprehensive financial report \u2014 all accounts, spending patterns, recommendations",
479
+ handler: () => ({
480
+ messages: [
481
+ {
482
+ role: "user",
483
+ content: {
484
+ type: "text",
485
+ text: `Generate a comprehensive financial report for my Canton agent:
486
+
487
+ 1. Call caypo_balance for current balance
488
+ 2. Call caypo_safeguards for spending limits and daily usage
489
+ 3. Call caypo_history with limit=20 for recent transactions
490
+ 4. Call caypo_traffic for traffic status
491
+
492
+ Analyze the data and provide:
493
+ - Total balance and holding efficiency (suggest merging if >5 UTXOs)
494
+ - Daily spending rate vs limits
495
+ - Traffic consumption trend
496
+ - Recommendations for limit adjustments`
497
+ }
498
+ }
499
+ ]
500
+ })
501
+ },
502
+ {
503
+ name: "spending_analysis",
504
+ description: "Analyze recent spending patterns and suggest optimizations",
505
+ handler: () => ({
506
+ messages: [
507
+ {
508
+ role: "user",
509
+ content: {
510
+ type: "text",
511
+ text: `Analyze my spending patterns:
512
+
513
+ 1. Call caypo_history with limit=50
514
+ 2. Call caypo_safeguards for current limits
515
+ 3. Call caypo_balance for current balance
516
+
517
+ Then:
518
+ - Categorize spending (API calls, transfers, etc.)
519
+ - Identify the most expensive API services
520
+ - Suggest whether my safeguard limits are appropriate
521
+ - Flag any unusual transaction patterns`
522
+ }
523
+ }
524
+ ]
525
+ })
526
+ },
527
+ {
528
+ name: "security_audit",
529
+ description: "Security audit \u2014 check safeguards, wallet status, traffic health",
530
+ handler: () => ({
531
+ messages: [
532
+ {
533
+ role: "user",
534
+ content: {
535
+ type: "text",
536
+ text: `Perform a security audit of my Canton agent:
537
+
538
+ 1. Call caypo_safeguards \u2014 are limits set appropriately?
539
+ 2. Call caypo_traffic \u2014 is traffic healthy?
540
+ 3. Call caypo_balance \u2014 any concerns about holding count?
541
+ 4. Call caypo_address \u2014 verify network
542
+
543
+ Check for:
544
+ - Are safeguard limits reasonable? (tx limit should be < 10% of balance)
545
+ - Is the wallet locked when it should be?
546
+ - Are there too many UTXOs? (>10 = recommend merge)
547
+ - Is traffic balance sufficient?
548
+ - Any signs of unusual activity?`
549
+ }
550
+ }
551
+ ]
552
+ })
553
+ },
554
+ {
555
+ name: "onboarding",
556
+ description: "New user onboarding \u2014 explain Canton agent features and guide setup",
557
+ handler: () => ({
558
+ messages: [
559
+ {
560
+ role: "user",
561
+ content: {
562
+ type: "text",
563
+ text: `Welcome a new user to CAYPO \u2014 their Canton Network agent bank account. Explain:
564
+
565
+ 1. **What CAYPO is**: A bank account for AI agents on Canton Network. Privacy-preserving, institutional-grade.
566
+ 2. **Key features**: USDCx checking account, MPP auto-payments for APIs, safeguards, traffic management.
567
+ 3. **How to get started**:
568
+ - Call caypo_address to show their party ID
569
+ - Call caypo_balance to check initial balance
570
+ - Call caypo_safeguards to review default limits
571
+ - Call caypo_services to see available paid APIs
572
+ 4. **Important concepts**:
573
+ - Canton uses party IDs, not addresses
574
+ - USDCx is USDC-backed via Circle xReserve
575
+ - Amounts are always strings (never floating point)
576
+ - Traffic replaces gas (validator-level, not per-tx)
577
+ 5. **Safety**: Safeguards protect against overspending. Always set appropriate limits.`
578
+ }
579
+ }
580
+ ]
581
+ })
582
+ },
583
+ // 15 stub prompts
584
+ stubPrompt("what_if", "What-if financial scenario analysis"),
585
+ stubPrompt("optimize_yield", "Yield optimization recommendations"),
586
+ stubPrompt("risk_assessment", "Risk assessment for current positions"),
587
+ stubPrompt("investment_thesis", "Investment thesis generation"),
588
+ stubPrompt("rebalance_plan", "Portfolio rebalance plan"),
589
+ stubPrompt("savings_strategy", "Savings strategy recommendations"),
590
+ stubPrompt("credit_health", "Credit health assessment"),
591
+ stubPrompt("traffic_report", "Detailed traffic consumption report"),
592
+ stubPrompt("market_overview", "Canton market overview"),
593
+ stubPrompt("portfolio_review", "Investment portfolio review"),
594
+ stubPrompt("defi_opportunities", "DeFi opportunities on Canton"),
595
+ stubPrompt("weekly_summary", "Weekly financial summary"),
596
+ stubPrompt("budget_plan", "Budget planning assistant"),
597
+ stubPrompt("tax_summary", "Transaction tax summary"),
598
+ stubPrompt("troubleshoot", "Troubleshoot Canton agent issues")
599
+ ];
600
+ function registerPrompts(server) {
601
+ const promptMap = /* @__PURE__ */ new Map();
602
+ for (const p of prompts) {
603
+ promptMap.set(p.name, p);
604
+ }
605
+ server.setRequestHandler(ListPromptsRequestSchema, async () => ({
606
+ prompts: prompts.map((p) => ({
607
+ name: p.name,
608
+ description: p.description,
609
+ arguments: p.arguments
610
+ }))
611
+ }));
612
+ server.setRequestHandler(GetPromptRequestSchema, async (request) => {
613
+ const prompt = promptMap.get(request.params.name);
614
+ if (!prompt) {
615
+ throw new Error(`Unknown prompt: ${request.params.name}`);
616
+ }
617
+ return prompt.handler(request.params.arguments ?? {});
618
+ });
619
+ }
620
+
621
+ // src/index.ts
622
+ var CANTON_MCP_VERSION = "0.1.0";
623
+ async function main() {
624
+ const agent = await CantonAgent.create({
625
+ token: process.env.CANTON_JWT ?? ""
626
+ });
627
+ const server = new Server(
628
+ { name: "caypo", version: CANTON_MCP_VERSION },
629
+ { capabilities: { tools: {}, prompts: {} } }
630
+ );
631
+ registerTools(server, agent);
632
+ registerPrompts(server);
633
+ const transport = new StdioServerTransport();
634
+ await server.connect(transport);
635
+ }
636
+ main().catch((err) => {
637
+ console.error("MCP server failed to start:", err);
638
+ process.exit(1);
639
+ });
640
+ export {
641
+ CANTON_MCP_VERSION
642
+ };
643
+ //# sourceMappingURL=index.js.map