Skip to main content
Glama
casaley-mcp

casaley-mcp

by s00rk

search_products

Read-onlyIdempotent

Query grocery products by keyword or category filters in a chosen branch to retrieve prices, promotions, package contents, and unit pricing with paginated results.

Instructions

Busca productos por texto en una sucursal, o recorre una categoría del catálogo (texto vacío + los filters de un nodo de list_departments). Cada producto trae precio, precio normal, promociones (precio especial, % o combo 'N x $'), contenido neto y precio unitario. Paginado: la respuesta trae pagination.has_more y pagination.next_page; una consulta solo deja recorrer sus primeros 1000 resultados, así que para más hay que acotar con filtros.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "search_products"
  }
}

Input Schema

NameRequiredDescriptionDefault
pageNoPágina, desde 1.
sortNorelevance | price_asc | price_desc | namerelevance
brandNoNombre exacto de la marca.
limitNoResultados por página (1–100).
queryNoTexto a buscar, p. ej. 'queso panela'. Vacío para recorrer una categoría.
storeNoId numérico de la sucursal (ver `list_stores`). Vacío: la configurada.
departmentNoCódigo de 3 letras: SYL lácteos, FYV frutas y verduras, ABA abarrotes… (ver `list_departments`).
group_codeNoCódigo de grupo (de `list_departments`).
on_sale_onlyNoSolo productos en oferta.
category_codeNoCódigo de categoría (de `list_departments`).
subcategory_codeNoCódigo de subcategoría (de `list_departments`).

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, so the safety profile is covered; the description adds genuinely useful operational context beyond them. The 1000-results-per-query hard cap and the "narrow with filters to go deeper" workaround are exactly the kind of hidden behavior an agent needs, as is the note that product records carry regular price, promo price, percentage or 'N x $' combos, net content and unit price.

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 dense but front-loaded sentences: mode selection first, payload contents second, pagination limits third. A minor cost is that the enumeration of returned price fields partially duplicates what an output schema already provides.

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 an 11-parameter tool with an output schema, the description covers the parts structured data cannot: mode selection, the pagination ceiling, and where filter codes originate. Return-field detail is somewhat redundant given the output schema, and the interaction between store default and department codes is left to the schema, but nothing critical for correct invocation 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 the baseline would be 3, but the description adds cross-parameter meaning the schema cannot: that `query` should be empty when traversing a category and that the nested `filters` come from a `list_departments` node. It also clarifies the default store behavior implicitly through the branch framing, though it does not expand on sort, brand or on_sale_only beyond what the schema already says.

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 ("Busca productos") and explicitly defines the two operating modes: text search in a branch, or category traversal via empty text plus the filters of a `list_departments` node. This distinguishes it from sibling tools like list_departments (the code source) and get_product (which it does not duplicate, since this returns lists with pricing).

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 for both modes, including the non-obvious recipe (empty query + node filters) for browsing a category, and tells the agent to narrow with filters once the 1000-result ceiling is hit. It stops short of naming alternative tools for a single-product lookup or for offer-only browsing, so no explicit exclusions.

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