Skip to main content
Glama

barcode-scanner-mcp

MCP server for scanning and generating barcodes and QR codes.

Use Cases

Decode a barcode from a photo: "What does this barcode say?" → reads the image, detects the barcode format, and returns the decoded text.

Generate a QR code: "Create a QR code for https://example.com" → generates a PNG QR code image with configurable error correction.

Create shipping labels: "Generate a Code 128 barcode for tracking number 1Z999AA10123456784" → produces a barcode image in the specified format.

Verify printed barcodes: "Scan this product barcode and look up the item" → decodes the barcode and returns the text for further lookup.

Related MCP server: mcp-scan-qr

Setup

Follow the instructions on install-mcp, which generates the right config for your MCP client (Claude Code, Claude Desktop, Cursor, Cline, VS Code, and more).

Tools

Tool

Description

decode_image

Decode a barcode or QR code from an image file or base64 data

generate_qr

Generate a QR code PNG from text or a URL

generate_barcode

Generate a barcode PNG in 25+ formats (Code 128, EAN-13, UPC-A, etc.)

Contributing

Pull requests are welcomed on GitHub! To get started:

  1. Install Git and Node.js

  2. Clone the repository

  3. Install dependencies with npm install

  4. Run npm run test to run tests

  5. Build with npm run build

Releases

Versions follow the semantic versioning spec.

To release:

  1. Use npm version <major | minor | patch> to bump the version

  2. Run git push --follow-tags to push with tags

  3. Wait for GitHub Actions to publish to the NPM registry.

Available Tools

3 tools
decode_imageDecode barcode/QR codeA
Read-only

Decode barcodes and QR codes from a base64-encoded image. Returns all codes found. Supports QR, EAN-13, EAN-8, UPC-A, UPC-E, Code 128, Code 39, Code 93, ITF, Codabar, and PDF 417. Handles noisy real-world photos by trying multiple preprocessing approaches.

ParametersJSON Schema
NameRequiredDescriptionDefault
imageYesBase64-encoded image data (PNG, JPEG, etc.)
format_hintNoExpected barcode format. If omitted, all formats are tried.

Output Schema

ParametersJSON Schema
NameRequiredDescription
codesYesAll barcodes/QR codes found in the image

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already include readOnlyHint=true, and the description adds useful context: it returns all codes found and handles noisy photos via multiple preprocessing approaches. This goes beyond the annotation by disclosing output behavior and robustness, though it does not detail error handling.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences, front-loaded with the primary action, and every sentence adds value. The format list is compact and directly useful, with no fluff or repetition.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The description fully covers what the tool does, what inputs it expects, what outputs to expect (all codes found), and what formats are supported. With an output schema present and readOnlyHint annotation, no further context is needed for correct selection and invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the parameters are already well-documented. The description mentions the list of supported formats, which overlaps with the format_hint enum, adding little beyond the schema. Baseline 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb ('Decode'), the resource ('barcodes and QR codes from a base64-encoded image'), and distinguishes it from siblings (generate_qr, generate_barcode) by focusing on decoding rather than generation. It lists supported formats, making the scope explicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage (decode an image to extract codes) but does not explicitly state when to use this tool versus alternatives or mention any exclusions. The contrast with generation siblings is implicit, but no direct guidance is provided.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

generate_barcodeGenerate barcodeA
Read-only

Generate a barcode image in various formats. Returns a PNG image. Supported formats: code128, code39, code93, ean13, ean8, upca, upce, itf14, interleaved2of5, isbn, issn, ismn, datamatrix, pdf417, azteccode, gs1-128, pharmacode, codabar, msi, plessey, postnet, onecode, royalmail, code11, code49.

ParametersJSON Schema
NameRequiredDescriptionDefault
textYesData to encode in the barcode
scaleNoScaling factor (default: 3)
formatYesBarcode format to generate
heightNoBar height in mm (default: 10, ignored for 2D formats)
include_textNoShow human-readable text below barcode (default: true)

TDQS

A3.7/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnlyHint=true, covering safety. The description adds 'Returns a PNG image' as a behavioral detail not present in the schema or annotations. However, it discloses no format-specific constraints, error conditions, or side-effect details, so transparency is partial.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences, front-loaded with the core action and output type. The long list of formats is redundant with the schema enum but serves as a quick reference and contains no filler words. It is efficient though slightly verbose due to the exhaustive list.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the schema fully documents parameters and annotations cover the read-only safety, the description adequately explains the tool's function and output (PNG). It lacks details on error handling or format-specific limitations, but these are not critical with a well-defined schema. The description is sufficiently complete for selection and invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100% (all 5 parameters have descriptions). The description repeats the format enum from the schema but adds no new parameter semantics, so it provides no value beyond the structured schema. Baseline of 3 is appropriate.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Generate a barcode image in various formats' and specifies the output type ('Returns a PNG image'). The list of supported formats differentiates it from sibling tools like generate_qr (which is not listed) and decode_image (which performs the opposite action).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage by listing supported formats, but it does not explicitly state when to use this tool versus alternatives. No exclusions or alternative tool references are provided, leaving usage guidance implicit rather than explicit.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

generate_qrGenerate QR codeA
Read-only

Generate a QR code image from text or a URL. Returns a PNG image.

ParametersJSON Schema
NameRequiredDescriptionDefault
textYesText or URL to encode in the QR code
scaleNoScaling factor (default: 3)
error_correctionNoError correction level: L (7%), M (15%), Q (25%), H (30%)M

TDQS

A3.9/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations provide readOnlyHint=true, which indicates a non-destructive operation. The description adds the return format (PNG image) but no further behavioral details such as limits or side effects. No contradiction exists.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description consists of two concise sentences that front-load the primary action and output format. There is no unnecessary information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's simplicity, complete schema descriptions, and readOnlyHint annotation, the description adequately covers the tool's purpose and output. No output schema exists, but the description explicitly mentions the PNG return format, compensating for that gap.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

All three parameters (text, scale, error_correction) have descriptions in the schema, covering 100% of params. The tool description does not add additional meaning or examples beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool generates a QR code image from text or a URL, with a specific verb and resource. It distinguishes itself from siblings by naming QR code, unlike generate_barcode which likely handles barcodes.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies use for encoding text/URLs into QR codes but does not explicitly compare to alternatives like generate_barcode or decode_image. There is no clear 'when not to use' guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

  1. 3 tool updatesv1.2.0
    • First observeddecode_image
    • First observedgenerate_barcode
    • First observedgenerate_qr

TDQS

A4.2/5.0

Scored across 3 tools

Disambiguation5/5

Each tool has a clearly distinct purpose: decoding images, generating QR codes, and generating barcodes. There is no overlap or ambiguity between the tools.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern: decode_image, generate_qr, generate_barcode. The naming is uniform and predictable.

Tool Count5/5

With only 3 tools, the server is well-scoped and every tool serves a necessary core function in barcode/QR handling. The count is ideal for the domain.

Completeness5/5

The server provides both decoding and generation capabilities for barcodes and QR codes, covering the primary lifecycle of barcode operations. No obvious gaps exist within the stated purpose.

Maintenance

ActivityActive
ResponsivenessNo issues

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • F
    license
    Not graded
    quality
    D
    maintenance
    An advanced MCP server for generating styled QR codes with logos, batch processing, and specialized formats like WiFi or vCards. It also provides tools to decode existing QR code images and analyze their quality or content.
    -
  • A
    license
    Not graded
    quality
    D
    maintenance
    An MCP server that provides tools for scanning and extracting data from QR codes using single or multiple image URLs. It supports both individual and batch processing to retrieve encoded information from images hosted online.
    10
    MIT
  • A
    license
    Not graded
    quality
    C
    maintenance
    MCP server for looking up EAN/UPC barcodes to get localized product details like title, description, price, and images.
    8
    1
    MIT