Skip to main content
Glama

Create promotion

create_promotion

Create promotion codes with fixed or percentage discounts, set validity dates, usage limits, and restrict to specific products, price lists, or billing cycles.

Instructions

Create a promotion code. type: 1 = fixed amount (needs currency_id), 2 = percentage. Applies to all products unless restricted via "extra" (products, pricelists, billing_cycles).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYesThe coupon code clients enter
nameYes
typeYes1 = fixed amount, 2 = percentage
extraNoAdditional raw fields (products, pricelists, …)
amountYesDiscount amount (percent when type=2)
to_dateYesEnd date YYYY-MM-DD
brand_idYesBrand UUID
max_usesNo0 = unlimited (default)
from_dateYesStart date YYYY-MM-DD
currency_idNoRequired for fixed-amount promotions
for_new_clientsNoDefault true
recurring_cyclesNo-1 unlimited, 0 first invoice only (default), N cycles
max_uses_per_clientNo0 = unlimited (default)
for_existing_clientsNoDefault true
Behavior3/5

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

Annotations are neutral (readOnlyHint=false, destructiveHint=false). The description adds useful context about the discount scope ('Applies to all products unless restricted via extra') and the type/currency relationship, but it does not disclose potential side effects or validation behavior.

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, no redundant words. Front-loads the action and provides key parameter semantics efficiently.

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

Completeness4/5

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

For a 14-parameter tool, the description highlights the two most complex attributes (type and extra) while relying on the schema for defaults and constraints. It could mention return values, but the lack of an output schema makes this a minor gap.

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 high (93%), so the baseline is 3. The description adds meaning beyond the schema by explaining that type=1 requires currency_id and that 'extra' can restrict products, pricelists, and billing_cycles, which the schema merely labels as 'Additional raw 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?

The description opens with the verb 'Create' and the object 'a promotion code', making the tool's function immediately clear. It distinguishes itself from siblings like update_promotion and disable_promotion by focusing on creation.

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

Usage Guidelines3/5

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

The description does not explicitly state when to use this tool versus alternatives. It implies via 'Create' but does not name or exclude alternatives like update_promotion or disable_promotion.

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

Install Server

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/spidyhost-crm/upmind-mcp-server'

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