@aifinpay/mcp 1.3.0 → 1.4.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/README.md CHANGED
@@ -62,8 +62,8 @@ keypair and **prints it to stderr** at startup:
62
62
 
63
63
  ```
64
64
  [warn] no AIFINPAY_AGENT_SECRET set — generated EPHEMERAL agent.
65
- address: 9HucVaL5yinJ4MfBKCFnz5QJBGwK33bfSQKw15pSe3Ch
66
- secret: 2vfeWAYfkpTNGSgDpBonzmjkckrTKa5GTnhhztY141YcSKYrqCvtojVukQAQiJbbRLgdcfEdyqHbRMsUft6Pb7nD
65
+ address: 9xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
66
+ secret: 4xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
67
67
  >> Save this secret to AIFINPAY_AGENT_SECRET to keep the agent across restarts.
68
68
  ```
69
69
 
@@ -22,6 +22,10 @@ export declare function agentAddressTool(): {
22
22
  type: string;
23
23
  description: string;
24
24
  };
25
+ casper: {
26
+ type: string;
27
+ description: string;
28
+ };
25
29
  note: {
26
30
  type: string;
27
31
  };
@@ -37,6 +41,7 @@ export declare function runAgentAddress(ctx: ToolContext, _args: Record<string,
37
41
  structuredContent: {
38
42
  solana: string;
39
43
  evm: string;
44
+ casper: string;
40
45
  note: string;
41
46
  };
42
47
  }>;
@@ -1 +1 @@
1
- {"version":3,"file":"agent-address.d.ts","sourceRoot":"","sources":["../../src/tools/agent-address.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD,wBAAgB,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyB/B;AAED,wBAAsB,eAAe,CACnC,GAAG,EAAE,WAAW,EAChB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;;;;;GAgB/B"}
1
+ {"version":3,"file":"agent-address.d.ts","sourceRoot":"","sources":["../../src/tools/agent-address.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD,wBAAgB,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAwC/B;AAED,wBAAsB,eAAe,CACnC,GAAG,EAAE,WAAW,EAChB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;;;;;;;;;;;GAuB/B"}
@@ -1,11 +1,14 @@
1
1
  export function agentAddressTool() {
2
2
  return {
3
3
  name: "agent_address",
4
- description: "Return the agent's on-chain identity on both Solana and Polygon. " +
5
- "Fund EITHER address to enable payments via payable_fetch / agent_call. " +
6
- "Polygon (EVM) address — for io.net, Exa, Venice and other bridges " +
7
- "advertising Polygon settlement. Solana (base58) address — for the " +
8
- "leaderboard / Seat PDA and Solana-native bridges. One agent, two chains.",
4
+ description: "Return the agent's on-chain identity. " +
5
+ "Fund the Polygon or Solana address to enable payments via " +
6
+ "payable_fetch / agent_call. Polygon (EVM) — for io.net, Exa, Venice " +
7
+ "and other bridges advertising Polygon settlement. Solana (base58) — " +
8
+ "for the leaderboard / Seat PDA and Solana-native bridges. Casper — " +
9
+ "identity only for now: the address is derived from the same seed and " +
10
+ "can be funded, but this SDK cannot yet sign Casper deploys, so it is " +
11
+ "not a settlement rail here. One seed, three addresses.",
9
12
  inputSchema: {
10
13
  type: "object",
11
14
  properties: {},
@@ -17,8 +20,19 @@ export function agentAddressTool() {
17
20
  properties: {
18
21
  solana: { type: "string", description: "Solana base58 address" },
19
22
  evm: { type: "string", description: "Polygon/EVM address" },
23
+ // Declared because the handler returns it. A field present in the
24
+ // payload but absent from the schema is how a client silently drops
25
+ // it — the address would be derived, returned, and never shown.
26
+ casper: {
27
+ type: "string",
28
+ description: "Casper account hash. Identity only: derived from the same seed " +
29
+ "and fundable, but this SDK cannot sign Casper deploys yet.",
30
+ },
20
31
  note: { type: "string" },
21
32
  },
33
+ // `casper` is deliberately not required: an agent built from a raw EVM
34
+ // key has no seed to derive it from, and claiming it always exists
35
+ // would make that case look like a bug rather than a limitation.
22
36
  required: ["solana", "evm"],
23
37
  },
24
38
  };
@@ -27,9 +41,16 @@ export async function runAgentAddress(ctx, _args) {
27
41
  const payload = {
28
42
  solana: ctx.agent.solanaAddress,
29
43
  evm: ctx.agent.evmAddress,
44
+ // Casper was absent here while the project counted it among its live
45
+ // networks, so an agent could not be told its own address on a chain we
46
+ // advertise. Same seed as the other two; the account hash is what a Casper
47
+ // explorer expects.
48
+ casper: ctx.agent.casperAddress,
30
49
  note: "Polygon (EVM) is the default settlement chain for live bridges " +
31
50
  "(io.net, Exa, Venice). Solana is supported via Seat PDA payments. " +
32
- "Same seed derives both — funding either enables the corresponding chain.",
51
+ "Casper has a deployed settlement contract and the SDK derives the " +
52
+ "address, but does not yet sign Casper deploys. " +
53
+ "One seed derives all three — funding any enables that chain.",
33
54
  };
34
55
  return {
35
56
  content: [
@@ -1 +1 @@
1
- {"version":3,"file":"agent-address.js","sourceRoot":"","sources":["../../src/tools/agent-address.ts"],"names":[],"mappings":"AAEA,MAAM,UAAU,gBAAgB;IAC9B,OAAO;QACL,IAAI,EAAE,eAAe;QACrB,WAAW,EACT,mEAAmE;YACnE,yEAAyE;YACzE,oEAAoE;YACpE,oEAAoE;YACpE,0EAA0E;QAC5E,WAAW,EAAE;YACX,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE,EAAE;SACf;QACD,qFAAqF;QACrF,WAAW,EAAE,EAAE,YAAY,EAAE,IAAI,EAAE,aAAa,EAAE,KAAK,EAAE,eAAe,EAAE,KAAK,EAAE;QACjF,YAAY,EAAE;YACZ,IAAI,EAAE,QAAQ;YACd,UAAU,EAAE;gBACV,MAAM,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,uBAAuB,EAAE;gBAChE,GAAG,EAAK,EAAE,IAAI,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K,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,qBAAqB,EAAE;gBAC9D,kEAAkE;gBAClE,oEAAoE;gBACpE,gEAAgE;gBAChE,MAAM,EAAE;oBACN,IAAI,EAAE,QAAQ;oBACd,WAAW,EACT,iEAAiE;wBACjE,4DAA4D;iBAC/D;gBACD,IAAI,EAAI,EAAE,IAAI,EAAE,QAAQ,EAAE;aAC3B;YACD,uEAAuE;YACvE,mEAAmE;YACnE,iEAAiE;YACjE,QAAQ,EAAE,CAAC,QAAQ,EAAE,KAAK,CAAC;SAC5B;KACF,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,eAAe,CACnC,GAAgB,EAChB,KAA8B;IAE9B,MAAM,OAAO,GAAG;QACd,MAAM,EAAE,GAAG,CAAC,KAAK,CAAC,aAAa;QAC/B,GAAG,EAAK,GAAG,CAAC,KAAK,CAAC,UAAU;QAC5B,qEAAqE;QACrE,wEAAwE;QACxE,2EAA2E;QAC3E,oBAAoB;QACpB,MAAM,EAAE,GAAG,CAAC,KAAK,CAAC,aAAa;QAC/B,IAAI,EACF,iEAAiE;YACjE,oEAAoE;YACpE,oEAAoE;YACpE,iDAAiD;YACjD,8DAA8D;KACjE,CAAC;IACF,OAAO;QACL,OAAO,EAAE;YACP,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,OAAO,EAAE,IAAI,EAAE,CAAC,CAAC,EAAE;SACzD;QACD,iBAAiB,EAAE,OAAO;KAC3B,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@aifinpay/mcp",
3
- "version": "1.3.0",
4
- "description": "Pay-per-call MCP server for autonomous AI agents — installs in Claude Desktop / Cursor / Continue with one config block; on-chain settlement on Polygon and Solana via x402.",
3
+ "version": "1.4.0",
4
+ "description": "Pay-per-call MCP server for autonomous AI agents \u2014 installs in Claude Desktop / Cursor / Continue with one config block; on-chain settlement on Polygon and Solana via x402.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
@@ -57,7 +57,7 @@
57
57
  },
58
58
  "bugs": "https://github.com/AiFinPay/sdk/issues",
59
59
  "dependencies": {
60
- "@aifinpay/agent": "^1.0.0",
60
+ "@aifinpay/agent": "^1.5.0",
61
61
  "@modelcontextprotocol/sdk": "^1.0.0"
62
62
  },
63
63
  "devDependencies": {