@arcadia-finance/mcp-server 0.7.1 → 0.7.3

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
@@ -20,10 +20,13 @@ The hosted server needs no install and no API key:
20
20
  https://mcp.arcadia.finance/mcp
21
21
  ```
22
22
 
23
+ [![Add to Claude](https://img.shields.io/badge/Claude-Add_Connector-D97757?logo=claude&logoColor=white)](https://claude.ai/customize/connectors?modal=add-custom-connector&connectorName=Arcadia%20Finance&connectorUrl=https%3A%2F%2Fmcp.arcadia.finance%2Fmcp)
23
24
  [![Install in VS Code](https://img.shields.io/badge/VS_Code-Install_Server-0078d4?logo=visualstudiocode)](https://insiders.vscode.dev/redirect/mcp/install?name=arcadia-finance&config=%7B%22type%22%3A%22http%22%2C%22url%22%3A%22https%3A%2F%2Fmcp.arcadia.finance%2Fmcp%22%7D)
24
25
  [![Install in Cursor](https://img.shields.io/badge/Cursor-Install_Server-black?logo=cursor)](https://cursor.com/en/install-mcp?name=arcadia-finance&config=eyJ1cmwiOiJodHRwczovL21jcC5hcmNhZGlhLmZpbmFuY2UvbWNwIn0%3D)
25
26
 
26
- Most clients accept this config:
27
+ The Claude button opens **Customize > Connectors > Add custom connector** with the name and URL filled in. Claude Free allows one custom connector. On Team and Enterprise, an owner adds it under **Organization settings > Connectors**.
28
+
29
+ Most clients accept this config. Cursor reads it from `.cursor/mcp.json` or `~/.cursor/mcp.json`. VS Code uses `.vscode/mcp.json` with `"servers"` in place of `"mcpServers"` and `"type": "http"` on the server.
27
30
 
28
31
  ```json
29
32
  {
@@ -52,13 +55,6 @@ claude mcp add --transport http arcadia-finance https://mcp.arcadia.finance/mcp
52
55
 
53
56
  </details>
54
57
 
55
- <details>
56
- <summary>Claude Desktop and claude.ai</summary>
57
-
58
- Go to **Customize > Connectors > + Add > Add custom connector**, then enter `Arcadia Finance` and `https://mcp.arcadia.finance/mcp`. The Free plan allows one custom connector. On Team and Enterprise plans, an owner adds it under **Organization settings > Connectors**.
59
-
60
- </details>
61
-
62
58
  <details>
63
59
  <summary>ChatGPT</summary>
64
60
 
@@ -84,31 +80,6 @@ gemini mcp add --transport http arcadia-finance https://mcp.arcadia.finance/mcp
84
80
 
85
81
  </details>
86
82
 
87
- <details>
88
- <summary>Cursor</summary>
89
-
90
- Use the button above, or add the config above to `.cursor/mcp.json` (project) or `~/.cursor/mcp.json` (global).
91
-
92
- </details>
93
-
94
- <details>
95
- <summary>VS Code (GitHub Copilot)</summary>
96
-
97
- Use the button above, or add this to `.vscode/mcp.json`:
98
-
99
- ```json
100
- {
101
- "servers": {
102
- "arcadia-finance": {
103
- "type": "http",
104
- "url": "https://mcp.arcadia.finance/mcp"
105
- }
106
- }
107
- }
108
- ```
109
-
110
- </details>
111
-
112
83
  ### Run it locally
113
84
 
114
85
  To run the server as a local process instead (Node.js 22 or newer):
@@ -184,14 +155,6 @@ Write tools return unsigned transactions. Your wallet signs them, see [Transacti
184
155
  | `write_account_automations` | Configure automations from an intents array (full desired state). Returns the unsigned setAssetManagers tx. |
185
156
  | `write_account_automations_delta` | Enable/disable individual automations, leaving the rest untouched. |
186
157
 
187
- ### Dev Tools
188
-
189
- Registered only when the `PK` env var is set.
190
-
191
- | Tool | Description |
192
- | ---------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
193
- | `dev_send` | Sign and broadcast an unsigned transaction using a local private key (`PK` env var). Not for production: use a dedicated wallet MCP server instead. |
194
-
195
158
  ## Transaction Signing
196
159
 
197
160
  All write tools return **unsigned transactions** as `{ to, data, value, chainId }`. This server does not sign or broadcast them; your agent or application does.
@@ -224,20 +187,9 @@ const client = createWalletClient({ account, chain: base, transport: http() });
224
187
  const hash = await client.sendTransaction(tx);
225
188
  ```
226
189
 
227
- **Built-in `dev_send` tool (development only):**
228
- The server includes a dev-only signing tool that reads a private key from the `PK` environment variable. Set `PK` via a `.env` file or your MCP client config:
229
-
230
- ```bash
231
- # .env in the server directory (gitignored, never commit it)
232
- PK=0xYourPrivateKeyHex
233
- RPC_URL_BASE=https://base-mainnet.g.alchemy.com/v2/your-key
234
- ```
235
-
236
- The server loads `.env` on startup. Values in the MCP client `env` block take precedence.
237
-
238
190
  ## Configuration
239
191
 
240
- All environment variables are optional.
192
+ All environment variables are optional. Set them in a `.env` file in the server directory (gitignored, never commit it) or in your MCP client `env` block, which takes precedence.
241
193
 
242
194
  | Variable | Required | Default | Transport | Description |
243
195
  | ------------------- | -------- | ----------------------------- | --------- | -------------------------------------------------------------- |
@@ -245,7 +197,6 @@ All environment variables are optional.
245
197
  | `RPC_URL_UNICHAIN` | No | Public RPC | Both | RPC URL for Unichain (130). |
246
198
  | `RPC_URL_OPTIMISM` | No | Public RPC | Both | RPC URL for Optimism (10). |
247
199
  | `RPC_URL_ROBINHOOD` | No | Public RPC | Both | RPC URL for Robinhood (4663). |
248
- | `PK` | No | none | Both | Private key (hex) for dev-only `dev_send` tool. |
249
200
  | `TRANSPORT` | No | `stdio` | n/a | Transport mode: `stdio` or `http`. |
250
201
  | `PORT` | No | `3000` | HTTP | Listen port for HTTP transport. |
251
202
  | `ALLOWED_ORIGINS` | No | `https://mcp.arcadia.finance` | HTTP | Comma-separated allowed Origin headers (CORS / DNS rebinding). |
@@ -306,7 +257,7 @@ To point a client at your build, use `"command": "node"` with `"args": ["/absolu
306
257
 
307
258
  ## Privacy
308
259
 
309
- When `POSTHOG_KEY` is set on an HTTP deployment, the server records one analytics event per tool call in PostHog (EU ingestion host by default): the tool name, its arguments (which can include public wallet and account addresses), whether the call failed, the duration, and the client name and version. Events carry no person profile. Running the server locally over stdio sends no analytics, and neither does an HTTP deployment without `POSTHOG_KEY`. Tool calls never carry private keys. The development-only `dev_send` tool signs with a `PK` set in the server's own environment; the hosted server has none. Questions: legal@arcadia.finance.
260
+ When `POSTHOG_KEY` is set on an HTTP deployment, the server records one analytics event per tool call in PostHog (EU ingestion host by default): the tool name, its arguments (which can include public wallet and account addresses), whether the call failed, the duration, and the client name and version. Events carry no person profile. Running the server locally over stdio sends no analytics, and neither does an HTTP deployment without `POSTHOG_KEY`. The server never handles private keys. Questions: legal@arcadia.finance.
310
261
 
311
262
  ## License
312
263
 
@@ -27,7 +27,7 @@ const robinhood = defineChain({
27
27
  multicall3: { address: "0xcA11bde05977b3631167028862bE2a173976CA11" },
28
28
  },
29
29
  });
30
- export const viemChains = {
30
+ const viemChains = {
31
31
  8453: base,
32
32
  10: optimism,
33
33
  130: unichain,
@@ -16,7 +16,6 @@ import { registerApproveTool } from "./write/wallet/approve.js";
16
16
  import { registerPoolDepositTool } from "./write/pool/deposit.js";
17
17
  import { registerPoolRedeemTool } from "./write/pool/redeem.js";
18
18
  import { registerAutomationsTools } from "./write/asset-managers/automations.js";
19
- import { registerSendTool } from "./dev/send.js";
20
19
  import { registerAddLiquidityTool } from "./write/account/add-liquidity.js";
21
20
  import { registerRemoveLiquidityTool } from "./write/account/remove-liquidity.js";
22
21
  import { registerSwapTool } from "./write/account/swap.js";
@@ -57,6 +56,4 @@ export function registerAllTools(server, api, chains) {
57
56
  registerPoolRedeemTool(server, chains);
58
57
  // Write tools: asset managers (intent-based, compiled by the backend)
59
58
  registerAutomationsTools(server, api);
60
- // Dev tools
61
- registerSendTool(server, chains);
62
59
  }
@@ -87,14 +87,6 @@ export const WalletAllowanceOutput = z.object({
87
87
  is_max_approval: z.boolean(),
88
88
  })),
89
89
  });
90
- export const DevSendOutput = z.object({
91
- signer: z.string(),
92
- txHash: z.string(),
93
- status: z.string(),
94
- blockNumber: z.number(),
95
- gasLimit: z.number(),
96
- gasUsed: z.number(),
97
- });
98
90
  export const AccountInfoOutput = z
99
91
  .object({
100
92
  account_version: z.number().nullable(),
package/llms-full.txt CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  ## Overview
6
6
 
7
- Arcadia lets users deploy concentrated liquidity positions with automated rebalancing, compounding, yield optimization, and leverage, or provide single-sided liquidity to lending pools to earn borrower interest. This MCP server exposes the full protocol as 37 tools, plus `dev_send` when `PK` is set:
7
+ Arcadia lets users deploy concentrated liquidity positions with automated rebalancing, compounding, yield optimization, and leverage, or provide single-sided liquidity to lending pools to earn borrower interest. This MCP server exposes the full protocol as 37 tools:
8
8
 
9
9
  - **Account management**: health factor, collateral, debt, positions, PnL, history
10
10
  - **Wallet**: ERC20 balances, allowances, owned accounts, points
@@ -427,18 +427,6 @@ Parameters:
427
427
  - `disable` (string[], default: []): Asset-manager addresses to switch off, as returned by read_asset_manager_current
428
428
  - position context params and `chain_id`: same as write_account_automations
429
429
 
430
- ## Dev Tools (only when PK is set)
431
-
432
- ### dev_send
433
-
434
- Sign and broadcast an unsigned transaction using a local private key (PK env var). Dev only.
435
-
436
- Parameters:
437
- - `to` (string, required): Target contract address
438
- - `data` (string, required): Encoded calldata (hex)
439
- - `value` (string, default: "0"): Value in wei
440
- - `chain_id` (number, default: 8453): Chain ID: 8453 (Base), 130 (Unichain), 10 (Optimism), or 4663 (Robinhood)
441
-
442
430
  ## Links
443
431
 
444
432
  - Website: https://arcadia.finance
package/llms.txt CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  ## Overview
6
6
 
7
- Arcadia lets users deploy concentrated liquidity positions with automated rebalancing, compounding, yield optimization, and leverage, or provide single-sided liquidity to lending pools to earn borrower interest. This MCP server exposes the full protocol as 37 tools, plus `dev_send` when `PK` is set:
7
+ Arcadia lets users deploy concentrated liquidity positions with automated rebalancing, compounding, yield optimization, and leverage, or provide single-sided liquidity to lending pools to earn borrower interest. This MCP server exposes the full protocol as 37 tools:
8
8
 
9
9
  - **Account management**: health factor, collateral, debt, positions, PnL, history
10
10
  - **Wallet**: ERC20 balances, allowances, owned accounts, points
@@ -24,7 +24,7 @@ npx -y @arcadia-finance/mcp-server
24
24
 
25
25
  Or connect to the remote server: `https://mcp.arcadia.finance/mcp`
26
26
 
27
- ## Tools (37, plus dev_send when PK is set)
27
+ ## Tools (37 total)
28
28
 
29
29
  ### Read (19)
30
30
 
@@ -69,10 +69,6 @@ Or connect to the remote server: `https://mcp.arcadia.finance/mcp`
69
69
  - write_account_automations: configure automations from an intents array (complete desired state), returns the unsigned setAssetManagers tx
70
70
  - write_account_automations_delta: switch individual automations on or off, leaving the rest untouched
71
71
 
72
- ### Dev (only when PK is set)
73
-
74
- - dev_send: sign and broadcast using local private key (dev only)
75
-
76
72
  ## Links
77
73
 
78
74
  - Website: https://arcadia.finance
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@arcadia-finance/mcp-server",
3
3
  "mcpName": "io.github.arcadia-finance/mcp-server",
4
- "version": "0.7.1",
4
+ "version": "0.7.3",
5
5
  "description": "MCP server for Arcadia Finance. Deploy concentrated liquidity on Uniswap/Aero, Aerodrome and Velodrome with automated rebalancing, compounding, yield optimization, and leverage, or single-sided liquidity into lending pools. Live on Base, Optimism, Unichain and Robinhood.",
6
6
  "type": "module",
7
7
  "license": "AGPL-3.0",
package/server.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "name": "io.github.arcadia-finance/mcp-server",
4
4
  "title": "Arcadia Finance",
5
5
  "description": "Concentrated liquidity on Uniswap/Aero (rebalance, compound, leverage) or single-sided lending.",
6
- "version": "0.7.1",
6
+ "version": "0.7.3",
7
7
  "websiteUrl": "https://arcadia.finance",
8
8
  "icons": [
9
9
  {
@@ -20,7 +20,7 @@
20
20
  {
21
21
  "registryType": "npm",
22
22
  "identifier": "@arcadia-finance/mcp-server",
23
- "version": "0.7.1",
23
+ "version": "0.7.3",
24
24
  "transport": {
25
25
  "type": "stdio"
26
26
  },
@@ -49,12 +49,6 @@
49
49
  "isRequired": false,
50
50
  "isSecret": true
51
51
  },
52
- {
53
- "name": "PK",
54
- "description": "Private key for dev-only signing (not for production).",
55
- "isRequired": false,
56
- "isSecret": true
57
- },
58
52
  {
59
53
  "name": "TRANSPORT",
60
54
  "description": "Transport mode: stdio (default) or http.",
@@ -31,7 +31,7 @@ How you sign depends on your setup:
31
31
  - **MPC wallet** (Fireblocks, Dfns, Turnkey): pass the unsigned tx to your provider's signing API
32
32
  - **Smart account** (Safe, Biconomy): wrap the tx as a UserOperation or Safe transaction
33
33
  - **Embedded wallet** (Privy, Dynamic): use the provider's `sendTransaction` method
34
- - **Direct private key** (development only): use the built-in `dev_send` tool, which the server lists only when `PK` is set in a `.env` file or the MCP client config, or viem/ethers `sendTransaction` with a local signer
34
+ - **Direct private key** (development only): viem/ethers `sendTransaction` with a local signer
35
35
 
36
36
  Example with viem:
37
37
 
@@ -104,12 +104,6 @@ These tools batch multiple operations into ONE atomic transaction. Always prefer
104
104
  | `write_account_aero_upgrade` | Upgrade an account to Aero (MetadexCL V1): its Slipstream positions move to Aero CL and its old AERO becomes the new AERO, in one flashAction. Returns the plan (items, reasons, pool options) and the transaction. Check first with `read_account_aero_upgrade`; wallet VELO on Optimism goes through `write_wallet_upgrade_velo`. See strategies.md, "Upgrade to Aero". |
105
105
  | `write_account_automations_delta` | Change one automation without restating the rest: `enable` takes intents, `disable` takes asset-manager addresses from `read_asset_manager_current`. Prefer `write_account_automations` when setting the full desired state. See automation.md. |
106
106
 
107
- ### Dev Tools (only available when `PK` env var is set)
108
-
109
- | Tool | When to use |
110
- | ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
111
- | `dev_send` | Sign and broadcast an unsigned transaction using a local private key. Pass the `{ to, data, value, chainId }` from any `write_*` tool. **Not for production**: use a dedicated wallet MCP server (Fireblocks, Safe, Turnkey, etc.) instead. |
112
-
113
107
  ## Shared Addresses
114
108
 
115
109
  | Contract | Address |
@@ -1,92 +0,0 @@
1
- import { z } from "zod";
2
- import { createWalletClient, createPublicClient, http } from "viem";
3
- import { privateKeyToAccount } from "viem/accounts";
4
- import { viemChains } from "../../clients/chain.js";
5
- import { CHAIN_ID_DESCRIPTION } from "../../config/chains.js";
6
- import { DevSendOutput } from "../output-schemas.js";
7
- import { validateAddress, validateHexCalldata, parseWeiDecimalString, } from "../../utils/validation.js";
8
- export function registerSendTool(server, chains) {
9
- const pk = process.env.PK;
10
- if (!pk)
11
- return;
12
- server.registerTool("dev_send", {
13
- annotations: {
14
- title: "Sign and Send Transaction",
15
- readOnlyHint: false,
16
- destructiveHint: true,
17
- idempotentHint: false,
18
- openWorldHint: true,
19
- },
20
- description: "DEV ONLY: Sign and broadcast an unsigned transaction using a local private key (PK env var). For production, use a dedicated wallet MCP server (Fireblocks, Safe, Turnkey, etc.) instead of this tool. Takes the transaction object returned by any write_* tool and submits it onchain.",
21
- outputSchema: DevSendOutput,
22
- inputSchema: z.object({
23
- to: z.string().describe("Target contract address"),
24
- data: z.string().describe("Encoded calldata (hex)"),
25
- value: z.string().default("0").describe("Value in wei (default '0')"),
26
- chain_id: z.number().default(8453).describe(CHAIN_ID_DESCRIPTION),
27
- }),
28
- }, async (params) => {
29
- try {
30
- const validTo = validateAddress(params.to, "to");
31
- const calldata = validateHexCalldata(params.data, "data");
32
- const valueWei = parseWeiDecimalString(params.value, "value");
33
- const chain = viemChains[params.chain_id];
34
- const chainConfig = chains[params.chain_id];
35
- if (!chainConfig) {
36
- return {
37
- content: [
38
- { type: "text", text: `Error: Unsupported chain ID ${params.chain_id}` },
39
- ],
40
- isError: true,
41
- };
42
- }
43
- const transport = http(chainConfig.rpcUrl);
44
- const account = privateKeyToAccount(pk);
45
- const wallet = createWalletClient({ account, chain, transport });
46
- const client = createPublicClient({ chain, transport });
47
- const gasEstimate = await client.estimateGas({
48
- account: account.address,
49
- to: validTo,
50
- data: calldata,
51
- value: valueWei,
52
- });
53
- const gasLimit = (gasEstimate * 120n) / 100n;
54
- const hash = await wallet.sendTransaction({
55
- to: validTo,
56
- data: calldata,
57
- value: valueWei,
58
- gas: gasLimit,
59
- chain,
60
- });
61
- const receipt = await client.waitForTransactionReceipt({ hash, timeout: 60_000 });
62
- const result = {
63
- signer: account.address,
64
- txHash: receipt.transactionHash,
65
- status: receipt.status,
66
- blockNumber: Number(receipt.blockNumber),
67
- gasLimit: Number(gasLimit),
68
- gasUsed: Number(receipt.gasUsed),
69
- };
70
- return {
71
- content: [
72
- {
73
- type: "text",
74
- text: JSON.stringify(result, null, 2),
75
- },
76
- ],
77
- structuredContent: result,
78
- };
79
- }
80
- catch (err) {
81
- return {
82
- content: [
83
- {
84
- type: "text",
85
- text: `Error: ${err instanceof Error ? err.message : String(err)}`,
86
- },
87
- ],
88
- isError: true,
89
- };
90
- }
91
- });
92
- }