Skip to main content
Glama

Last Price

create_commerce_policy

Create a commerce pricing policy: the rules the pipeline uses to draft price proposals, with an optional floor and ceiling and an approval mode. Starts active. Needs a Last Price credential with commerce configure scope, and a claimed workspace. Needs a claimed workspace: a sandbox key from self-registration is refused (403) until a person claims the workspace.

Input Schema

NameRequiredDescriptionDefault
nameYesA name for the policy.
rulesYesThe rules, tried in order; the first that produces a price wins. Each rule has an id, a kind and the fields its kind needs: a percent to undercut by, an amount to beat the lowest price by, a percent off the list price, a competitor to match, a fixed price, or a routing choice. The Pricing Policies section of the documentation lists them.
scopeNoWhich items the policy covers: skus, brands and marketplaces lists. Empty covers every item.
is_activeNoWhether the pipeline applies the policy.
descriptionNoWhat the policy is for.
floor_priceNoNo proposal goes below this price.
approval_modeNomanual queues every proposal for a decision, auto approves small changes, shadow records proposals without acting on them.
ceiling_priceNoNo proposal goes above this price.
auto_approve_max_delta_pctNoWith approval_mode auto: proposals that move the price by at most this percent skip the queue. Required for auto.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior5/5

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

Annotations only say write, non-destructive, non-idempotent; the description adds materially more: the policy starts active (so it affects live pricing immediately), which credential scope is required, and that unclaimed workspaces get a 403. Those are exactly the operational facts an agent needs before committing a mutation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The front-loaded definition is efficient and useful, but the closing authority/workspace requirement is stated twice in slightly different words ('Needs a claimed workspace... Needs a claimed workspace: a sandbox key...'), which is redundant and could have been one sentence.

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 9-parameter, nested-object mutation with no output schema, the description covers purpose, default active state, and access prerequisites. It does not say what is returned on success (the created policy) or that creates are non-idempotent, but the annotation already flags non-idempotency.

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 description coverage is 100%, so the baseline is 3, but the description adds the semantic link between floor_price/ceiling_price and the pipeline ('optional floor and ceiling') and names approval mode as a behavioral choice rather than a field. Rule ordering semantics are in the schema, not repeated here.

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?

States a precise verb (create) and a precisely named resource (commerce pricing policy), then explains what the resource is: the rules the pipeline uses to draft price proposals. It is clearly distinct from create_routing_policy and update_commerce_policy by wording alone, though it never names a sibling to route away from.

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 concrete preconditions for invocation: a Last Price credential with commerce configure scope and a claimed workspace, plus the fact that a self-registration sandbox key is refused with 403. It does not say when to prefer update_commerce_policy or list_commerce_policies instead, so no explicit exclusions or alternatives are offered.

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