Skip to main content
Glama

validate_gtin

Read-only

USE THIS to verify a product barcode — GTIN/EAN/UPC — before trusting it, instead of guessing the check digit. Handles EAN-8, UPC-A (12), EAN-13 and GTIN-14, verifies the GS1 mod-10 check digit, and returns the barcode type plus the GS1 prefix's issuing country (e.g. 50 = UK, 690-699 = China, 978 = Bookland/ISBN). Validates structure only — it does NOT confirm the barcode maps to a real, registered product.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
gtinYesThe barcode digits (EAN-8/UPC-A/EAN-13/GTIN-14); spaces and hyphens are ignored.

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observed

TDQS

A4.8/5.0
Behavior5/5

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

Annotations already provide readOnlyHint=true, and the description adds behavioral details: it validates structure only, does not confirm real products, and returns barcode type and country. No contradictions.

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?

Two sentences, front-loaded with usage intent, concise and without wasted words. Every sentence provides essential 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?

Despite no output schema, the description explains what is returned and the limitation of not checking real products. Parameter is thoroughly covered. The tool is well-documented for its complexity.

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

Parameters5/5

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

The input schema has 100% coverage for the single parameter. The description adds value by explaining that spaces and hyphens are ignored, listing supported barcode types (EAN-8, UPC-A, etc.), and describing return values (barcode type, country).

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 verifies product barcodes (GTIN/EAN/UPC) by validating the check digit, using a specific verb 'verify' and specifying the resource. It distinguishes itself among sibling validate_* tools by focusing on barcodes.

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

Usage Guidelines4/5

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

Explicitly says 'USE THIS to verify a product barcode instead of guessing the check digit,' providing a clear when-to-use. It also notes the tool only validates structure, not product registration, but does not explicitly list when not to use or alternative tools.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.