Skip to content
VS Code

trade router mcp for VS Code

io.github.traderouter/trade-router-mcp

Non-custodial Solana swap & limit order engine for AI agents.

client:VS Code transport:stdio runtime:npm

Install trade router mcp in VS Code

.vscode/mcp.json

{
  "inputs": [
    {
      "type": "promptString",
      "id": "traderouter-private-key",
      "description": "TRADEROUTER_PRIVATE_KEY",
      "password": true
    },
    {
      "type": "promptString",
      "id": "solana-rpc-url",
      "description": "SOLANA_RPC_URL",
      "password": true
    },
    {
      "type": "promptString",
      "id": "traderouter-server-pubkey",
      "description": "TRADEROUTER_SERVER_PUBKEY",
      "password": true
    },
    {
      "type": "promptString",
      "id": "traderouter-server-pubkey-next",
      "description": "TRADEROUTER_SERVER_PUBKEY_NEXT",
      "password": true
    },
    {
      "type": "promptString",
      "id": "traderouter-require-server-signature",
      "description": "TRADEROUTER_REQUIRE_SERVER_SIGNATURE",
      "password": true
    },
    {
      "type": "promptString",
      "id": "traderouter-require-order-created-signature",
      "description": "TRADEROUTER_REQUIRE_ORDER_CREATED_SIGNATURE",
      "password": true
    },
    {
      "type": "promptString",
      "id": "traderouter-dry-run",
      "description": "TRADEROUTER_DRY_RUN",
      "password": true
    }
  ],
  "servers": {
    "trade-router-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@traderouter/trade-router-mcp"
      ],
      "env": {
        "TRADEROUTER_PRIVATE_KEY": "${input:traderouter-private-key}",
        "SOLANA_RPC_URL": "${input:solana-rpc-url}",
        "TRADEROUTER_SERVER_PUBKEY": "${input:traderouter-server-pubkey}",
        "TRADEROUTER_SERVER_PUBKEY_NEXT": "${input:traderouter-server-pubkey-next}",
        "TRADEROUTER_REQUIRE_SERVER_SIGNATURE": "${input:traderouter-require-server-signature}",
        "TRADEROUTER_REQUIRE_ORDER_CREATED_SIGNATURE": "${input:traderouter-require-order-created-signature}",
        "TRADEROUTER_DRY_RUN": "${input:traderouter-dry-run}"
      }
    }
  }
}

VS Code prompts for each input the first time the server starts, so no secret is written to the file. VS Code docs

trade router mcp in other clients