Skip to main content
Glama

Find a delivery district

search_districts
Read-onlyIdempotent

Ranked delivery-district candidates for an address typed as free text. Each has an id (the district id a checkout routes on), a name, and the governorate it sits in. A free-text district is rejected when the order is booked; the candidate id goes in the checkout address's area.

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": {
      "store": "<store>",
      "query": "<query>"
    },
    "name": "search_districts"
  }
}

Input Schema

NameRequiredDescriptionDefault
queryYesWhat the shopper called the place — a district or area name, Arabic or English.
storeYesThe store, from find_stores or search_all_stores (its `store` field).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile is covered. The description adds meaningful context beyond that: results are ranked, each carries a routable `id`, and the raw free-text value will fail downstream — which explains the tool's role in the booking flow.

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 tight sentences, front-loaded with what is returned before the workflow rationale. No filler; the parenthetical about `id` is dense but informative rather than redundant.

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 no output schema, the description takes on the burden of describing return fields — `id`, name, governorate — and does so. It also closes the loop on how the returned `id` is consumed in the checkout address, which is the key thing an agent needs to act correctly.

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 both `query` and `store` are already documented in the schema. The description adds no guidance on how free text is matched (transliteration, fuzzy matching) or how the `store` scopes results, so it stays at the baseline for high-coverage schemas.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource: ranked delivery-district candidates for a free-text address, plus the shape of each candidate (`id`, name, governorate). It does not explicitly contrast itself with the sibling `resolve_district`, so the boundary between 'search' and 'resolve' is left to inference.

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 a clear reason to call it: a free-text district is rejected at booking, so the shopper's typed place must be turned into a candidate `id`. It does not say when to prefer `resolve_district` or how this relates to `check_delivery_area`, so no explicit exclusions are present.

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.