Skip to main content
Glama

Create Demand Curve

create_demand_curve

Create a demand curve from 12 monthly weights (January-first). The server normalizes the points to mean 1.0 before persisting, so attaching the curve can never change an item's annual forecast volume by itself. curveType: Seasonal (repeats every year, calendar-anchored) or Lifecycle (plays once from each item's launch/anchor date — launch ramps, promos, end-of-life). Creating only adds a reusable shape; nothing is forecast-affecting until the curve is applied with apply_demand_curve_to_items.

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>",
      "curveType": "<curveType>",
      "points": "<points>"
    },
    "name": "create_demand_curve"
  }
}

Input Schema

NameRequiredDescriptionDefault
nameYesCurve name, e.g. "Summer peak".
pointsYesExactly 12 non-negative monthly weights, January first. Relative values — the server normalizes them to average 1.0.
previewNoStep 1 of the required two-step write: set true to validate and receive a structured preview plus a single-use previewReceipt. Nothing is created until the commit call.
curveTypeYesSeasonal (repeats annually) or Lifecycle (one-shot from an anchor date).
descriptionNoOptional description of when to use this curve.
idempotencyKeyNoCaller-generated idempotency key; required with previewReceipt to commit.
previewReceiptNoStep 2 of the required two-step write: the receipt returned by the preview call. Supply together with a fresh idempotencyKey to commit; calls without it are refused.

Output Schema

NameRequiredDescriptionDefault
okNo
curveNo
previewNo
expiresAtNo
actionItemIdNo
confirmationNo
correlationIdNo
approvalResultNo
idempotencyKeyNo
previewReceiptNo
idempotentReplayNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.7/5.0
Behavior5/5

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

Annotations declare a non-read-only, non-destructive write but say nothing about workflow or side effects. The description adds two substantive traits: server-side normalization to mean 1.0 (so annual forecast volume is unchanged) and a mandatory two-step preview/commit requiring a previewReceipt with a fresh idempotencyKey, with un-receipted commits refused.

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?

Front-loads the verb, the 12-weight input contract, and the normalization guarantee before the curveType taxonomy and the pointer to the apply tool. Dense but every sentence carries information an agent needs; no filler.

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?

For a 7-parameter write tool with 3 required fields and an output schema, the description covers the input contract, the safety property of normalization, the curve-type distinction, and the two-step commit protocol. Nothing needed to invoke it correctly is missing.

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 baseline is 3; the description still adds value by explaining why points are relative (normalization to mean 1.0) and by unpacking curveType semantics — Seasonal repeats annually and is calendar-anchored, Lifecycle plays once from each item's launch/anchor date. It does not elaborate on preview/idempotencyKey interaction beyond what the schema already states.

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 plus a concrete input shape: "Create a demand curve from 12 monthly weights (January-first)." It also draws an explicit boundary against the sibling that applies curves, so an agent can distinguish creation from activation without reading either schema.

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 when-to-use context (create a reusable shape now; apply later via apply_demand_curve_to_items) and explains the Seasonal vs Lifecycle choice. It does not address when to author weights by hand versus deriving them from history, so one relevant alternative is left implicit.

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