Skip to main content
Glama
digikala-mcp

digikala-mcp

by sepehr071

Filter options

dk_filters
Read-onlyIdempotent

Lists category or search filters (attributes, brands, colors, sellers, Toman price range), returning IDs for product/search tools; query attribute_id to get all values for attributes with many options.

Instructions

List the filters of a category or a search: attributes, colors, sellers, price range (Toman), brands.

Maps are {title: id}; an attribute with over 15 values has only value_count (call again with attribute_id). Pass the ids to dk_category_products or dk_search.

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": "dk_filters"
  }
}

Input Schema

NameRequiredDescriptionDefault
queryNoInstead of a category.
brand_codeNoWith category_code, e.g. 'samsung'.
attribute_idNoList all values of this one attribute.
category_codeNoe.g. 'mobile-phone'.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed17 schema fields changedv0.6.0
    • removedInput schema / properties / attribute_id / anyOf
      Removed value: -[
      -  {
      -    "minimum": 1,
      -    "type": "integer"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • changedInput schema / properties / attribute_id / description
      Previous value: -"Return only this attribute with all its values, e.g. 2251 (phone storage)."New value: +"List all values of this one attribute."
    • addedInput schema / properties / attribute_id / minimum
      Added value: +1
    • addedInput schema / properties / attribute_id / type
      Added value: +[
      +  "integer",
      +  "null"
      +]
    • removedInput schema / properties / brand_code / anyOf
      Removed value: -[
      -  {
      -    "pattern": "^[a-z0-9][a-z0-9_.'’-]{1,80}$",
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • changedInput schema / properties / brand_code / description
      Previous value: -"With category_code: only this brand, e.g. 'samsung'."New value: +"With category_code, e.g. 'samsung'."
    • addedInput schema / properties / brand_code / pattern
      Added value: +"^[a-z0-9][a-z0-9_.'’-]{1,80}$"
    • addedInput schema / properties / brand_code / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedInput schema / properties / category_code / anyOf
      Removed value: -[
      -  {
      -    "pattern": "^[a-z0-9][a-z0-9_.'’-]{1,80}$",
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • changedInput schema / properties / category_code / description
      Previous value: -"Category code from dk_suggest or dk_categories, e.g. 'mobile-phone'."New value: +"e.g. 'mobile-phone'."
    • addedInput schema / properties / category_code / pattern
      Added value: +"^[a-z0-9][a-z0-9_.'’-]{1,80}$"
    • addedInput schema / properties / category_code / type
      Added value: +[
      +  "string",
      +  "null"
      +]
    • removedInput schema / properties / query / anyOf
      Removed value: -[
      -  {
      -    "maxLength": 100,
      -    "minLength": 2,
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • changedInput schema / properties / query / description
      Previous value: -"Search words instead of a category, e.g. 'هدفون بی سیم'."New value: +"Instead of a category."
    • addedInput schema / properties / query / maxLength
      Added value: +100
    • addedInput schema / properties / query / minLength
      Added value: +2
    • addedInput schema / properties / query / type
      Added value: +[
      +  "string",
      +  "null"
      +]
  2. Changed6 schema fields changedv0.4.0
    • removedInput schema / properties / attribute_id / title
      Removed value: -"Attribute Id"
    • removedInput schema / properties / brand_code / title
      Removed value: -"Brand Code"
    • removedInput schema / properties / category_code / title
      Removed value: -"Category Code"
    • removedInput schema / properties / query / title
      Removed value: -"Query"
    • removedInput schema / title
      Removed value: -"dk_filtersArguments"
    • changedOutput schema / (root)
      Previous value: -{
      -  "additionalProperties": true,
      -  "title": "dk_filtersDictOutput",
      -  "type": "object"
      -}New value: +null
  3. Addedv0.2.1

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive, openWorld), so the description's value-add is the response shape disclosure: results are {title: id} maps, and attributes with more than 15 values return only a value_count, requiring a re-call. That truncation behavior is a genuinely important trait an agent could not infer from structured fields. No auth or rate-limit context is given, which keeps it below a 5.

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?

Three short sentences with no filler, front-loaded with the purpose and followed by the two operands an agent needs (return shape, follow-up call). Every clause carries actionable information.

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?

With no output schema, the description carries the burden of describing returns, and it does so adequately via the {title: id} map convention and the value_count truncation case. It leaves minor ambiguity about the exact shape of the price-range entry and what brand_code alone yields, but nothing that would cause a mis-call.

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 description coverage is 100%, so a baseline 3 is the floor. The description still adds meaning: it clarifies that category_code and query are alternative entry points, that price ranges are denominated in Toman, and that returned ids are meant to be piped into other tools. It does not explain the brand_code + category_code pairing 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 ('List the filters of a category or a search') and enumerates exactly what comes back: attributes, colors, sellers, price range (Toman), brands. Combined with the closing instruction to pass the ids to dk_category_products or dk_search, an agent can distinguish this discovery tool from the sibling search/product tools without opening any schema.

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 routing guidance: use it on a category or a search, then feed the returned ids into dk_category_products or dk_search. It also explains the follow-up call when an attribute is truncated ('call again with attribute_id'). It stops short of explicit when-not-to-use guidance or stating that category_code and query are mutually exclusive, which is only implied by the schema's 'Instead of a category' note.

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