Skip to main content
Glama

Create a draft program

create_program

Creates a draft the owner publishes in the app: a stamp-card program as a DRAFT. Customers can’t see or use it until the owner reviews and publishes it in the Loyal Digicard app (review_url). The Free plan includes 3 programs (drafts count). Without branch_ids it runs at every active branch.

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": {
      "name": "<name>",
      "reward": "<reward>",
      "stamps_to_reward": "<stamps_to_reward>"
    },
    "name": "create_program"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesProgram name, for example “Buy 5 coffees, get 1 free”
termsNoShort terms shown on the card
rewardYesThe reward, for example “Free coffee”
branch_idsNoFrom list_branches; default: all active branches
cashier_choosesNoThe cashier picks 1…max stamps per visit, starting at default
stamps_per_visitNoFixed stamps per visit (default 1). Leave out when the cashier chooses.
stamps_to_rewardYesStamps needed for the reward (1–10; 1 = reward on the first visit)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare it is a non-read-only, non-destructive, non-idempotent, closed-world write, so the safety profile is covered. The description adds genuinely useful behavior beyond that: the record is invisible to customers until published, publishing happens out-of-band in the app via review_url, and drafts consume the 3-program Free plan quota. It omits what happens when the quota is exceeded or what identifier is returned.

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?

Three compact sentences that front-load the action and the draft constraint. There is mild redundancy, with 'draft' repeated in the opening clause and the DRAFT state emphasized twice, making the first sentence slightly convoluted.

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 7-parameter write with a nested object and no output schema, the description covers the critical unknowns: draft status, who publishes, the review_url round trip, quota limits, and branch scoping. Remaining gaps are quota-exceeded behavior and the returned handle, which are modest relative to what is stated.

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 100%, so the schema already documents all seven parameters, including the cashier_chooses/stamps_per_visit split and min/max bounds. The description only restates the branch_ids default ('runs at every active branch'), adding no new meaning beyond what the schema specifies; baseline 3 applies.

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 ('Creates ... a stamp-card program') plus the resulting lifecycle state (DRAFT), which separates it from update_program and archive_program without needing to open a schema. The publishing path is named ('the owner publishes in the app ... review_url').

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?

Gives clear preconditions and context: the object is created as a draft, customers cannot see it until the owner publishes, and the Free plan caps programs at 3 including drafts. It does not explicitly route the agent to update_program for editing an existing program, so alternative selection is implied rather than stated.

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.

Resources