Skip to main content
Glama

Loyaltie

Read cart

get_cart
Read-onlyIdempotent

A cart create_cart returned, by id, with current prices, quantities and availability, totals for the items only (shipping, any discount and any Loyaltie+ membership in the cart are added at checkout), and the same continue_url cart. When you give the person continue_url, ask them to check the total before paying: the cart may already include an optional paid Loyaltie+ membership, which they can turn off before they pay. An item no longer available or sold out fails the call with its path; a quantity above the stock now on hand is lowered, with a warning. An unknown or expired id fails with not_found.

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": {
      "cart": "<cart>"
    },
    "name": "get_cart"
  }
}

Input Schema

NameRequiredDescriptionDefault
srcNoSend "skill" when you were set up by the Loyaltie Skill; returned links then carry src=skill. Default "api"; any other value counts as "api".
cartYesThe cart to read: id, with optional context.
metaNoOptional UCP request metadata. meta["ucp-agent"].profile is your UCP agent profile URL; it is recorded, never required.
agent_idNoYour agent id. Every loyaltie.com link returned then carries agent=<agent_id>, so Loyaltie knows which agent helped.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

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

The annotations already establish read-only, idempotent, closed-world behavior, while the description adds meaningful details about item-only totals, checkout add-ons, membership opt-out, availability failures, quantity warnings, and not_found. The only ambiguity is whether the over-stock quantity is lowered only in the returned response or persisted, which should be explicit against readOnlyHint=true.

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?

The definition is front-loaded with purpose and then proceeds through important caveats and failure modes. It is dense, with a long first sentence, but almost every clause carries operational information; slight tightening would help.

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?

With annotations, a fully described input schema, and an output schema, the description supplies the missing operational context: totals scope, membership warning, stock warnings, and failure modes. It is complete enough for an agent to call and interpret this read operation.

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 coverage is 100%, so the schema already carries the parameter meaning for cart.id, src, context, and agent_id. The description only reinforces that cart.id comes from create_cart and does not add usage semantics for the other parameters beyond the schema.

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 a specific retrieval resource: the cart that create_cart returned, fetched by id. It also names the core returned data—current prices, quantities, availability, item-only totals, and continue_url—so an agent can distinguish it from create_cart and product/catalog siblings.

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?

The post-create_cart retrieval context is clear, and it gives an actionable checkout instruction about passing continue_url and asking the user to check totals before paying. It does not explicitly state when not to use it or name alternative cart tools, so it stops short of top usage guidance.

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