Skip to main content
Glama
craveup

CraveUp MCP Server

Official
by craveup

Create an order-level discount

create_order_discount

Create order-level promo codes idempotently to prevent duplicates, with dry-run preview and validation. Confirm the stored configuration afterward using list_discounts.

Instructions

Idempotently create an order-level promo code at one authorized location. If the code already exists, returns it without creating a duplicate. Percentage amounts must be at most 100. Use list_discounts afterward to verify the stored configuration.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYes
modeNoPreview by default. Apply requires the exact returned planDigest.dry-run
amountYes
isFixedYes
disabledNo
maxUsageNo
startDateYes
startTimeNo12:00 AM
expireDateYes
expireTimeNo11:59 PM
locationIdNoOmit to use CRAVEUP_LOCATION_ID
planDigestNoExact digest returned by a dry-run of the same arguments.
descriptionNo
oncePerOrderNo
oncePerCustomerNo
minItemsQuantityNo
confirmationTokenNoRequired exact phrase for destructive, paid, or release operations.
minPurchaseAmountNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
dataNo
modeYes
statusYes
changesYes
summaryYes
operationYes
planDigestYes
environmentYes
nextActionsYes
schemaVersionYes
Install Server

TDQS

B3.3/5.0
Behavior1/5

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

Description claims 'Idempotently create... If the code already exists, returns it without creating a duplicate,' but the idempotentHint annotation is false. This is a direct annotation contradiction, so the score must be 1 regardless of the useful dedup and percentage-cap details.

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?

Three short sentences, front-loaded with the action. Each sentence contributes a distinct fact: idempotent create behavior, amount constraint, and verification workflow. No filler or repetition.

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?

For a complex 18-parameter tool with a dry-run/apply mechanism, the description omits the critical mode workflow and confirmation-token requirement. It mentions verification, but an agent cannot safely perform a real apply operation from the description alone.

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

Parameters2/5

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

With only 22% schema coverage, the description needed to compensate for the 18 parameters, but it only adds the amount cap and 'one authorized location.' It fails to explain the dry-run/apply flow, planDigest, confirmationToken, code format, dates, or other required fields.

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: 'Idempotently create an order-level promo code at one authorized location.' This clearly distinguishes it from siblings that create locations, list discounts, or update products.

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?

Provides clear context: use for creating an order-level promo code at one authorized location, and verify with list_discounts afterward. It doesn't explicitly enumerate when-not-to-use alternatives, but the scope is unambiguous.

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

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/craveup/craveup-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server