Skip to main content
Glama

show-connect-qrcode

Generate a QR code to connect MetaMask wallets securely for blockchain interactions without exposing private keys, enabling simplified user onboarding.

Instructions

Show the connect QR code for a given connect URI

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
uriYes

Implementation Reference

  • Handler function that takes a URI, generates a QR code data URL using qrcode.toDataURL, and returns it as image content via imageContent.
    execute: async (args) => {
      const uri = args.uri;
      const qrCode = await QRCode.toDataURL(uri);
      return imageContent({
        url: qrCode,
      })
    },
  • Zod schema defining the input parameter 'uri' as a string.
    parameters: z.object({
      uri: z.string(),
    }),
  • Registration of the 'show-connect-qrcode' tool with FastMCP server.addTool, including name, description, parameters, and execute handler.
    server.addTool({
      name: "show-connect-qrcode",
      description: "Show the connect QR code for a given connect URI",
      parameters: z.object({
        uri: z.string(),
      }),
      execute: async (args) => {
        const uri = args.uri;
        const qrCode = await QRCode.toDataURL(uri);
        return imageContent({
          url: qrCode,
        })
      },
    });

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/Xiawpohr/mcpilot'

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