Skip to main content
Glama

Record a placed grocery order

record_grocery_order

Log a placed grocery order, mark its week as ordered, and restock bought staples; optionally keep purchased items as 7-day leftovers instead of adding them to the pantry.

Instructions

Log the placed order and move the week to 'ordered'. Staples marked out that were bought are back in stock (listed under restocked). Purchased items don't join the pantry since they get cooked this week; set add_to_on_hand to keep them as leftovers for 7 days.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
itemsYes
storeNo
totalNo
week_idNo
order_refNo
add_to_on_handNoKeep the purchased items as 7-day leftovers

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
weekYes
orderYes
restockedNoStaples that were marked out and are back in stock

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv0.1.1
    • changedInput schema / properties / add_to_on_hand / default
      Previous value: -trueNew value: +false
    • addedInput schema / properties / add_to_on_hand / description
      Added value: +"Keep the purchased items as 7-day leftovers"
    • addedOutput schema / properties / restocked
      Added value: +{
      +  "anyOf": [
      +    {
      +      "items": {
      +        "$ref": "#/properties/week/properties/id"
      +      },
      +      "type": "array"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "description": "Staples that were marked out and are back in stock"
      +}
    • addedOutput schema / properties / week / properties / share_url
      Added value: +{
      +  "description": "Public page showing this week's winners",
      +  "type": [
      +    "string",
      +    "null"
      +  ]
      +}
  2. First observedv0.1.0

TDQS

A3.9/5.0
Behavior5/5

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

Annotations only declare write/non-destructive/closed-world. The description goes well beyond them by disclosing the exact state transitions: the week moves to 'ordered', out-of-stock staples that were bought are restocked (surfaced under 'restocked'), and purchased items do not join the pantry unless add_to_on_hand is set. This is precisely the side-effect context an agent needs for a mutating tool.

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 tightly packed sentences that lead with the primary action before detailing restock and pantry behavior. Dense but every clause carries information; no filler or restatement of the title.

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

Completeness3/5

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

The behavioral half is well covered and an output schema exists (so return values needn't be described), but the description leaves four parameters semantically unexplained against a 17% schema coverage. For a six-parameter write tool this is a meaningful gap, though the state-change narrative is strong.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is only 17%, so the description carries the burden — but it only explains add_to_on_hand (already documented in the schema) and touches items indirectly. store, total, week_id, and order_ref receive no meaning at all, leaving four of six parameters undocumented in both schema and prose.

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 names a specific verb and resource ('Log the placed order') and pins down the primary state change ('move the week to ordered'), which cleanly separates it from siblings like assemble_online_grocery_order (assembling an order) and get_current_week. An agent can tell what this does without opening the schema.

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?

Usage context is only implied: this is the tool to call once an order has been placed. There is no explicit when/when-not or named alternative (e.g. versus assemble_online_grocery_order). The one piece of real guidance — when to set add_to_on_hand — is given, which lifts it above a bare 2.

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