Skip to main content
Glama
shopify-mcp-complete

shopify-mcp-complete

by hishamalhadi

update-discount

Modify an existing Shopify discount code's title, code, value, dates, or usage limit.

Instructions

Update an existing discount code's title, code, value, dates, or usage limit.

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": {
      "discountId": "<discountId>"
    },
    "name": "update-discount"
  }
}

Input Schema

NameRequiredDescriptionDefault
codeNo
titleNo
valueNo
endsAtNo
startsAtNo
valueTypeNo
discountIdYesDiscount ID to update
usageLimitNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.9/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden and does not meet it. It never says whether omitted fields are preserved or cleared, whether dates must be ISO strings and ordered (startsAt before endsAt), whether changing the code affects existing redemptions, or what permissions are required. For a mutation tool with zero annotation coverage this is a significant gap.

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?

A single front-loaded sentence with no filler, and the field list is easy to scan. It is efficiently written, though its brevity is achieved partly by dropping information the agent actually needs.

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

Completeness2/5

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

The tool has 8 parameters, a 13% documented schema, no annotations, and no output schema. Given that complexity, the one-sentence description leaves critical semantics undefined: merge-vs-replace behavior, date formats, the valueType/value relationship, and the success/return behavior.

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 only 13% (just discountId), so the description must compensate; it does map 'dates' to startsAt/endsAt and names value and usage limit, which helps. However it omits valueType ('FIXED_AMOUNT' vs 'PERCENTAGE') entirely and gives no format constraints for the date strings or interaction rules between value and valueType.

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

Purpose4/5

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

The description gives a specific verb ('Update') and resource ('an existing discount code') and enumerates the mutable fields (title, code, value, dates, usage limit). 'Existing' cleanly separates it from the sibling create-discount, though no sibling is named explicitly.

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

Usage Guidelines2/5

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

There is no guidance on when to choose this over create-discount or delete-discount, no prerequisite statement beyond the implicit need for an existing discount, and no explanation of whether this is a partial or full replacement update. The only usable cue is the word 'existing'.

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