Skip to main content
Glama

offerhopper.ai — AI Supermarket & Drugstore Shopping Assistant for Germany

Plan optimal grocery and drug store shopping trip

plan_optimal_shopping_route
Read-onlyIdempotent

Plans the optimal shopping trip for a given list and starting location in Germany. Answers 'where should I go to buy this list, and is the trip worth it?' — not 'what's on offer near me'. Matches each item on the list to the best current offer across German supermarkets and drug stores (REWE, Aldi, Lidl, Penny, Netto, Norma, Edeka, DM, Rossmann, Mueller, Globus), then computes the cheapest realistic route by weighing product prices against travel distance and shopping time. Returns the chosen store(s), the per-item picks with live prices, the trip's savings and a worth-it Supports car, bicycle, and pedestrian travel modes. The route is computed from the starting point, so 'location' MUST include the German 5-digit postcode (PLZ) of where the user starts (or be 'lat,lng'). A city name alone ('München', 'Berlin') spans many postcodes and does not say which part of the city: if the user only names a city, ask which part, as a postcode, before calling — never guess one. Write city and street names in German ('München', 'Köln'), never English ('Munich', 'Cologne'). For corridor trips (A-to-B), supply 'end_location' to route stores along the way. Pricing note: 'price' is the standard shelf price available to all shoppers (do NOT say discounts require an app). 'app_credit' is optional wallet cashback (e.g. REWE Bonus: plus €0.50 into wallet). 'app_price' is an app-exclusive checkout price (e.g. Lidl Plus).

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": {
      "items": "<items>",
      "location": "<location>"
    },
    "name": "plan_optimal_shopping_route"
  }
}

Input Schema

NameRequiredDescriptionDefault
itemsYesThe shopping list in natural language (e.g. '3x milk, eggs, bread')
km_costNoTravel cost penalty per kilometer (forced to 0.0 for bicycle/pedestrian)
locationYesWhere the user starts, with its German 5-digit postcode (PLZ): '80331', '80331 München' or 'Leopoldstraße 50, 80802 München' — or 'lat,lng'. A city name alone ('München') does not say which part of the city: ask the user for the postcode of where they start; never guess one or use the city centre. Names in German ('München', 'Köln'), never English ('Munich', 'Cologne').
hour_costNoTime cost penalty in EUR per hour (defaults to 12.0)
max_storesNoMaximum number of candidate stores to evaluate for the route (default: 100)
travel_modeNoTravel mode to usecar
end_locationNoOptional destination if not a round trip — same rule: include its 5-digit postcode (or 'lat,lng'), never just a city name
max_radius_kmNoMaximum search radius in kilometers (defaults: car=15km, bicycle=5km, pedestrian=2km)
shopping_time_per_storeNoBase shopping minutes spent per store (defaults to 10)

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • changedInput schema / properties / end_location / description
      Previous value: -"Optional destination location if not a round trip"New value: +"Optional destination if not a round trip — same rule: include its 5-digit postcode (or 'lat,lng'), never just a city name"
    • changedInput schema / properties / location / description
      Previous value: -"Starting location (ZIP code, city, or address in Germany)"New value: +"Where the user starts, with its German 5-digit postcode (PLZ): '80331', '80331 München' or 'Leopoldstraße 50, 80802 München' — or 'lat,lng'. A city name alone ('München') does not say which part of the city: ask the user for the postcode of where they start; never guess one or use the city centre. Names in German ('München', 'Köln'), never English ('Munich', 'Cologne')."
  2. Changed5 schema fields changed
    • changedInput schema / properties / max_stores / description
      Previous value: -"Maximum number of store stops to allow in the route (default: 100)"New value: +"Maximum number of candidate stores to evaluate for the route (default: 100)"
    • addedOutput schema / additionalProperties
      Added value: +true
    • removedOutput schema / properties
      Removed value: -{
      -  "result": {
      -    "type": "string"
      -  }
      -}
    • removedOutput schema / required
      Removed value: -[
      -  "result"
      -]
    • removedOutput schema / x-fastmcp-wrap-result
      Removed value: -true
  3. First observed

TDQS

A4.3/5.0
Behavior5/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive, openWorld), and the description adds real domain behavior on top: the cost model that weighs prices against travel distance and shopping time, the three supported travel modes, and the default radius behavior. The pricing taxonomy ('price' as shelf price for all shoppers, 'app_credit' as wallet cashback, 'app_price' as app-exclusive) plus the explicit 'do NOT say discounts require an app' correction are exactly the kind of behavioral disclosure annotations cannot carry.

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?

Purpose and scope are front-loaded well, but the text is dense and repetitive — the postcode rule is restated in the description and again in two schema fields, and the German-naming rule appears twice. One sentence is broken ('the trip's savings and a worth-it'), which costs clarity in a section that would otherwise be informative.

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 nine-parameter planning tool with an output schema, this covers everything an agent needs: input preconditions (postcode, lat,lng), travel modes and radius defaults, corridor routing via end_location, and the pricing semantics that govern how results should be reported. Return values are properly left to the output schema.

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 nine parameters including the PLZ requirement, cost defaults, and travel_mode enum. The description reinforces the location/postcode rule and explains the underlying cost rationale, but adds little parameter-level meaning the schema does not already state; 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?

The first sentence gives a specific verb and resource ('Plans the optimal shopping trip for a given list and starting location in Germany') and the second explicitly fences off a nearby-but-different question ('what's on offer near me'). It also enumerates the covered retailers and the optimization inputs (price vs. distance vs. shopping time), so an agent knows exactly what this tool answers.

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?

Strong conditional guidance: ask for a postcode when the user names only a city and never guess one, use end_location for A-to-B corridor trips, and write place names in German. What is missing is routing to alternatives — the sibling swap_route_item (for changing a pick after planning) is never mentioned, so the agent gets no selection guidance for follow-up edits.

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