Skip to main content
Glama

Metafield Key Check

metafield_key_check
Read-onlyIdempotent

Validate a metafield namespace and key before you define it. FREE.

Shopify metafield namespaces and keys are lowercase alphanumerics and underscores; a capital letter or a dash is rejected at definition time, usually after the rest of the import has already run. Typical input {"namespace": "custom", "key": "Care-Instructions"} returns {"ok": false, "problems": ["key: dashes and capitals are not allowed"], "suggested_key": "care_instructions"}.

Use when designing metafields. Not for the CSV column that carries them: that is product_csv_check. Errors: on invalid, missing, or malformed input this tool never raises a protocol error; it returns {"error": ""}. Every call is read-only and idempotent, so after correcting the input it is always safe to retry.

Input Schema

NameRequiredDescriptionDefault
keyYesThe metafield key, e.g. "care_instructions".
namespaceYesThe metafield namespace, e.g. "custom".
value_typeNoThe intended metafield type, echoed back for your record, e.g. "single_line_text_field". Not validated against Shopify's type list, which changes.single_line_text_field

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.9/5.0
Behavior5/5

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

The description goes far beyond the structural annotations by explaining the internal rules (lowercase alphanumerics and underscores only) and the error handling mechanism. It clarifies that the tool 'never raises a protocol error,' which is critical behavioral information.

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 tool is comprehensive and therefore longer, but its structure is highly effective. Each sentence and paragraph serves a distinct, necessary function (core purpose, validation rules, usage boundaries, error handling), ensuring no information is wasted.

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 definition is maximally complete for a utility tool. It covers functionality, scope, constraints (character set), safety (read-only), idempotency, failure mode (dict return vs protocol error), and precise differentiation from sibling tools.

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

Parameters4/5

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

While the schema covers 100% of the parameters, the description adds crucial context, specifically for 'value_type' by explaining that it is 'echoed back for your record' and is 'Not validated against Shopify's type list, which changes.' This provides necessary operational context.

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 purpose is stated immediately: 'Validate a metafield namespace and key before you define it.' It clearly distinguishes itself from the sibling tool, explicitly stating its use case versus 'product_csv_check' during input validation phase design.

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

Usage Guidelines5/5

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

The definition provides crystal clear usage boundaries. It specifies, 'Use when designing metafields,' and explicitly dictates 'Not for the CSV column that carries them: that is product_csv_check,' effectively routing the agent to the correct tool based on context.

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.