Skip to main content
Glama
jigarkkarangiya

magento-sql-mcp-server

Get Catalog Rule Price

get_catalog_rule_price
Read-onlyIdempotent

Retrieve indexed catalog rule price for a given SKU, website ID, and customer group for today. Reads from catalogrule_product_price index only; no live calculation.

Instructions

Returns indexed catalog rule price for a SKU on a website and customer group for today. Does NOT calculate rules live — reads catalogrule_product_price index only.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
skuYesProduct SKU. Use find_product_by_sku instead of guessing EAV table joins.
profileNoOverride the MAGENTO_SQL_PROFILE env var for this call only. Use list_connection_profiles to see available names.
website_idNoWebsite ID for catalog rule price scope (default 1).
magentoRootNoAbsolute path to the Magento root (must contain app/etc/env.php). Defaults to MAGENTO_ROOT env var or auto-discovery.
customer_group_idNoCustomer group ID for catalog rule price (default 0 = NOT LOGGED IN).

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
noteNo
rowsYes
sampledNo
rowCountYes
truncatedNo
Behavior5/5

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

Annotations already declare readOnlyHint, idempotentHint, openWorldHint, and destructiveHint=false. The description adds crucial context beyond these: it reads only the catalogrule_product_price index, meaning results are not live and may be stale, and it is scoped to today's prices. This behavioral trait is essential for correct interpretation and is not covered by the annotations. No contradiction exists.

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

Conciseness5/5

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

Two sentences, zero filler. The key functional constraint (reads index, not live) is front-loaded and the temporal scope ('for today') is included. Every word earns its place.

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?

Given the low complexity, 5 parameters with only 1 required and defaults for others, and the presence of an output schema, the description covers the essential behavior and caveats. An agent knows exactly what to expect: a read-only, indexed, today-scoped price lookup. The lack of details about missing-rule handling is acceptable because the output schema likely covers the return shape, and the index-based note implies the behavior.

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?

With 100% schema description coverage, each parameter already has a detailed explanation (sku, profile, website_id, magentoRoot, customer_group_id). The description does not add additional semantic detail; it simply reiterates the role of sku, website, and customer group in the broader context. It adds no new information beyond the schema, so baseline 3 is appropriate.

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 states a specific verb ('Returns indexed catalog rule price') and scopes it precisely to a SKU, website, customer group, and today. It also explicitly distinguishes what it does not do ('Does NOT calculate rules live'), making the tool's function unambiguous and clearly differentiated from potential alternatives.

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 description provides clear guidance on when to use this tool: it reads the catalogrule_product_price index and is not a live calculator. This implies that the index may be stale and that live rule evaluation is out of scope, which helps an agent decide to use this instead of a hypothetical recalculation tool. However, it does not name an explicit alternative or describe the exact conditions under which this tool should be preferred over other index-based reads.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jigarkkarangiya/magento-sql-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server