Skip to main content
Glama

apply-product-template-mappings

Write a set of field mappings across every channel category of one or more mapping templates — the bulk alternative to adding rows one category at a time in the mapping UI, for a seller whose listings are missing item specifics. Each mapping names a channel field and exactly one source (a product column, custom attribute, variation property, literal, lookup list or rule), and applies to every template in the request unless it names its own templateIds — so one call can cover several accounts that share most fields but bind a few to their own seller-scoped attributes. Additive and safe to re-run: a category that already maps that field keeps the row it has and is reported as skipped. Item specifics use scope categories and should carry their own categoryIds, since a field the category does not define publishes nothing; listing-level fields (title, description, price, conditionDescription) use scope common. ALWAYS run with dryRun=true first and show the caller the row counts before writing. Get attributeId values from get-product-custom-attributes and valid fieldName values from get-channel-category-fields — do not guess either.

ONLY the templates named in templateIds are written. A seller has one template per site AND per listing type, so "every eBay template" is usually a dozen or more ids, not the one the caller happened to be looking at — enumerate them with get-product-templates and pass them all. Nothing warns you otherwise: the sibling template keeps its old source and looks untouched in the UI, which reads as the change having silently failed. Needs product:write.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "templateIds": "<templateIds>",
      "mappings": "<mappings>"
    },
    "name": "apply-product-template-mappings"
  }
}

Input Schema

NameRequiredDescriptionDefault
dryRunNoReport the rows that would be written, per field, without writing anything. Use this first.
mappingsYesThe field mappings to apply
backgroundNoReturn immediately with a jobId and run the work in the background, then poll get-product-template-mapping-job. The payload is still validated before returning, so mistakes still come back as an error. Use it whenever onlyEligibleCategories covers many categories
categoryIdsNoRestrict to these channel category IDs. Defaults to every category each template covers; each template takes the IDs it has. An ID on none of the templates is rejected.
templateIdsYesMapping templates to write into. The same mapping set is applied to each one.
onlyEligibleCategoriesNoAsk the channel which categories actually define each field and write only those — most item specifics are not valid in every category, and a row where the aspect does not exist publishes nothing. Costs one channel call per uncached category, so pair it with dryRun first to warm the cache. Strongly recommended when applying item specifics to every category

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?

Annotations already declare it is not read-only, not destructive, and not open-world; the description adds meaningful behavioral context: writes are additive, re-running is safe, already-mapped fields are skipped and reported, only named templateIds are touched, and product:write is required. It also exposes the important failure mode where an unwritten sibling template may look silently untouched.

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?

Although long, it is appropriately sized for a complex bulk mutation and is front-loaded with the core purpose. Each paragraph carries operational value: source constraints, additive/skipped behavior, scope rules, dryRun workflow, template enumeration, and auth requirements.

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?

No output schema exists, but the description covers the important return/operational signals: dryRun reports row counts, background returns a jobId to poll via get-product-template-mapping-job, and skipped mappings are reported. Combined with the detailed input schema and annotations, an agent has enough information to call it correctly.

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?

Schema coverage is 100%, so the baseline is 3, but the description adds cross-parameter workflow meaning: scope categories vs common, categoryIds for item specifics, per-mapping templateIds for seller-scoped sources, and dryRun/background/onlyEligibleCategories behavior. It is not fully additive over the schema because many individual field meanings are already described there.

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?

States a specific verb and resource: writing field mappings across channel category templates, and explicitly frames it as the bulk alternative to UI row-entry. It is readily distinguishable from sibling tools such as delete-product-template-mapping, get-product-template-mappings, set-category-mappings, and validate-mapping-template.

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?

Gives clear when-to-use guidance for sellers missing item specifics, mandates dryRun=true first, explains how to obtain attributeId and fieldName values, and warns to enumerate all relevant templateIds with get-product-templates. It also explains when to use onlyEligibleCategories and background mode.

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.