Skip to main content
Glama

wc_connect

Generate WalletConnect URI to pair external wallets like D'CENT, MetaMask, or Phantom with AI agents for multi-chain crypto operations.

Instructions

Start WalletConnect pairing. Returns a WC URI that the wallet owner can use to connect their external wallet (D'CENT, MetaMask, Phantom, etc). Share the URI with the user -- they can paste it into their wallet app.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
wallet_idNoTarget wallet ID. Required for multi-wallet sessions; auto-resolved when session has a single wallet.

Implementation Reference

  • The handler function that executes the wc_connect tool by calling the /v1/wallet/wc/pair endpoint via the apiClient.
    async (args) => {
      const body: Record<string, unknown> = {};
      if (args.wallet_id) body.walletId = args.wallet_id;
      const result = await apiClient.post('/v1/wallet/wc/pair', body);
      return toToolResult(result);
    },
  • The registration function for the wc_connect tool in the MCP server.
    export function registerWcConnect(
      server: McpServer,
      apiClient: ApiClient,
      walletContext?: WalletContext,
    ): void {
      server.tool(
        'wc_connect',
        withWalletPrefix(
          "Start WalletConnect pairing. Returns a WC URI that the wallet owner can use to connect their external wallet (D'CENT, MetaMask, Phantom, etc). Share the URI with the user -- they can paste it into their wallet app.",
          walletContext?.walletName,
        ),
        {
          wallet_id: z.string().optional().describe('Target wallet ID. Required for multi-wallet sessions; auto-resolved when session has a single wallet.'),
        },
        async (args) => {
          const body: Record<string, unknown> = {};
          if (args.wallet_id) body.walletId = args.wallet_id;
          const result = await apiClient.post('/v1/wallet/wc/pair', body);
          return toToolResult(result);
        },
      );
    }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/minhoyoo-iotrust/WAIaaS'

If you have feedback or need assistance with the MCP directory API, please join our Discord server