Toolpal

@toolpal/qr-code

public

v2.0published 1 download this weekMIT

Generates a scannable QR code image (PNG or SVG) offline for any text: a URL, a Wi-Fi login (WIFI:T:WPA;S:<network>;P:<password>;;), a vCard, a phone number (tel:...), an email (mailto:...) or plain text. Returns the image file. No API key needed.

manifest.json2.7 KBRaw
{
  "manifestVersion": 1,
  "name": "@toolpal/qr-code",
  "version": "1.0",
  "description": "Generates a scannable QR code image (PNG or SVG) offline for any text: a URL, a Wi-Fi login (WIFI:T:WPA;S:<network>;P:<password>;;), a vCard, a phone number (tel:...), an email (mailto:...) or plain text. Returns the image file. No API key needed.",
  "license": "MIT",
  "keywords": [
    "qr",
    "qrcode",
    "barcode",
    "png",
    "svg",
    "image",
    "generator"
  ],
  "entry": "dist/tool.mjs",
  "sdk": "0.1.0",
  "engines": {
    "node": ">=22.15.0"
  },
  "inputSchema": {
    "type": "object",
    "required": [
      "text"
    ],
    "properties": {
      "text": {
        "type": "string",
        "minLength": 1,
        "maxLength": 2953,
        "description": "What the QR code should contain"
      },
      "errorCorrection": {
        "anyOf": [
          {
            "type": "string",
            "const": "L"
          },
          {
            "type": "string",
            "const": "M"
          },
          {
            "type": "string",
            "const": "Q"
          },
          {
            "type": "string",
            "const": "H"
          }
        ],
        "description": "How much damage the code survives: L 7%, M 15% (default), Q 25%, H 30%. Higher means a denser code."
      },
      "format": {
        "anyOf": [
          {
            "type": "string",
            "const": "png"
          },
          {
            "type": "string",
            "const": "svg"
          }
        ],
        "description": "Image format, png by default"
      },
      "scale": {
        "type": "integer",
        "minimum": 1,
        "maximum": 20,
        "description": "PNG pixels per QR module, 10 by default"
      }
    }
  },
  "outputSchema": {
    "type": "object",
    "required": [
      "image",
      "version",
      "modules",
      "errorCorrection",
      "bytes"
    ],
    "properties": {
      "image": {
        "type": "string",
        "description": "Generated QR code image (.png or .svg)",
        "x-toolpal-file": true
      },
      "version": {
        "type": "integer",
        "description": "QR version, 1 (21x21) to 40 (177x177)"
      },
      "modules": {
        "type": "integer",
        "description": "Width of the code in modules, without the quiet zone"
      },
      "errorCorrection": {
        "type": "string"
      },
      "bytes": {
        "type": "integer",
        "description": "Bytes of UTF-8 data encoded"
      }
    }
  },
  "permissions": {
    "net": false,
    "env": [],
    "tmp": true
  },
  "limits": {
    "timeoutMs": 15000,
    "memoryMb": 128
  },
  "build": {
    "toolpal": "0.1.0",
    "esbuild": "0.28.2",
    "options": "sha256-tMpkndD8HsDUvZadrPbEAMGGIGK7nvmTGxMMlUxy9Fo="
  }
}