Digikala

io.github.sepehr071v0.1.0更新於 Oct 3, 2026

Unofficial read-only Digikala: search products, compare sellers, price history, reviews, deals.

概覽

AI 產生的概覽

唯讀的 MCP 伺服器,用來搜尋 Digikala 商品、比較賣家報價、查看價格歷史、評價與優惠。

功能
在使用者本機執行,呼叫 Digikala 的公開網頁端點,可用波斯語或英語搜尋商品,並依價格、品牌與庫存篩選。工具涵蓋找出真正最便宜的符合商品、列出某商品所有賣家的報價、約 30 天的每日價格歷史、評價、問答、規格比較、分期方案、優惠、暢銷排行、Fresh 超市、Digikala Plus 會員方案、黃金與金幣價格,以及地址查詢。所有工具皆為唯讀,並回傳精簡的 JSON。
適用情境
適合讓助理在 Digikala 上做購物研究:找出最便宜的現貨報價、比較賣家與型號、判斷目前價格是否划算,或查看當前優惠。它著重於購物研究,而不是實際下單購買。
執行需求
需要本機 Python 執行環境與 uv 或 uvx(也可 pip install digikala-mcp);不需要帳號或 API 金鑰。需要能連線至 Digikala 的公開 API。若請求被封鎖,可選擇設定 DIGIKALA_MCP_PROXY 為 HTTP 代理網址;系統代理設定會被忽略。
安裝前請注意
設計上為唯讀:不登入,也不會呼叫購物車、下單、付款或張貼評價/提問的端點,因此無法購買。它會從你的機器向 Digikala 公開端點送出請求;選用的 DIGIKALA_MCP_PROXY 值可能包含代理憑證。此伺服器為非官方專案,所依賴的端點可能隨時變動,請維持合理的請求頻率。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Digikala,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

🛍️ digikala-mcp

Let your AI agent shop around on Digikala.
Search Iran's largest online store, compare every seller's offer, check a product's price history,
read reviews and Q&A, and catch today's Incredible Offers, all from Claude, Cursor or Copilot.

[PyPI] [Python] [CI] [MCP Registry] [License: MIT]

[Install in Cursor] [Install in VS Code]

Quick start · What it can do · Tools · FAQ · فارسی


Why

Digikala lists the same phone many times: different colors, memory sizes, bundles and a dozen sellers per listing, with prices that move every day. Sorting by "cheapest" puts phone cases first. Finding the real cheapest offer, and whether today's price is a good one means a lot of clicking. An agent with digikala-mcp does it in three calls:

You: Cheapest Samsung Galaxy A07 on Digikala, and is now a good time to buy?

Agent: calls dk_find_cheapest(query="samsung a07") → dk_product(product_id=20109389) → dk_price_history(product_id=20109389)

PriceModelSeller
42,503,600Galaxy A07 64 GB / 4 GBDigikala (same-day delivery in Tehran)
44,518,000Galaxy A07 64 GB / 4 GB + 25 W chargerSepahan Hamrah Yaghout
46,811,800Galaxy A07 128 GB / 4 GBDigikala

The 64 GB model is cheapest at 42,503,600, sold by Digikala itself; the next seller asks 42,918,000. But it's not a great moment: the black one sold for 34,499,000 yesterday and 33,200,000 at its lowest this month, and the 30-day low was 28,373,600. Today's best offer is about 23% above yesterday's, so waiting may pay off.

Real tool output from 2026-10-03; prices change all the time. Prices are in Toman.

What it can do

  • 🔎 Search the whole catalogue in Persian or English, with price range, brand and in-stock filters
  • 💸 Find the real cheapest match, with accessories filtered out, and every seller's offer for a product
  • 📈 Judge a price with about 30 days of daily price history and the 30-day low
  • 🗂️ Browse categories, brands, sellers and best sellers, sorted by price, sales, views, newest or buyers' pick
  • ⭐ Check quality with reviews, pros/cons, buyer Q&A and seller reputation
  • ⚡ Catch deals: Incredible Offers and supermarket (Digikala Fresh) discounts
  • 🧾 Extras: spec comparison, installment plans, Digikala Plus shipping plans, live gold and coin prices
  • 🔒 Read-only by design: no login, no cart, no orders, no payment

Quick start

You need uv. No API key or account.

Claude Code
bash
claude mcp add digikala -- uvx digikala-mcp
Claude Desktop

Settings → Developer → Edit Config, then add:

json
{  "mcpServers": {    "digikala": { "command": "uvx", "args": ["digikala-mcp"] }  }}
Cursor

Click Install in Cursor above, or add the Claude Desktop block to ~/.cursor/mcp.json.

VS Code (Copilot agent mode)

Click Install in VS Code above, or add to .vscode/mcp.json:

json
{  "servers": {    "digikala": { "type": "stdio", "command": "uvx", "args": ["digikala-mcp"] }  }}
Anything else

It's a standard stdio MCP server: run uvx digikala-mcp, or pip install digikala-mcp and run digikala-mcp.

Then just ask:

  • "Cheapest AirPods-style earbuds under 3 million Toman with at least 4 stars?"
  • "Compare the Galaxy A07 64 GB and 128 GB. Is the bigger one worth the difference?"
  • "Is this seller reliable? CGDG9"
  • ارزان‌ترین شیر کم‌چرب در سوپرمارکت دیجی‌کالا چند است؟

How it works

text
  AI agent  (Claude, Cursor, Copilot, ...)      │      │  MCP over stdio      ▼  digikala-mcp  (runs on your machine)      │      │  HTTPS      └──────▶  api.digikala.com   products, sellers, deals, Fresh supermarket

digikala-mcp runs locally and calls the same public endpoints the digikala.com web app uses. There's no hosted server in between, no API key, and nothing about you is sent anywhere else.

Tools

Product ids are the number in a digikala.com/product/dkp-<id>/ link. Every list returns compact product cards: id, title, brand, price, discount, stock, seller, rating and the product link.

🔎 Find products (10)
ToolWhat it does
dk_searchSearch by words with sort, price range, brand and in-stock filters
dk_find_cheapestCheapest in-stock real matches for a query, accessories dropped, one list
dk_suggestAutocomplete: better keywords, category codes and brand ids
dk_categoriesFind category codes and main-category ids
dk_category_productsBrowse a category with sort and filters, optionally one brand
dk_brand_productsBrowse a brand's products
dk_sellerA seller's rating, on-time shipping, cancellations, returns and products
dk_dealsIncredible Offers or supermarket deals, biggest discount first
dk_best_sellersCurrent best sellers, overall or per main category
dk_fresh_searchSearch or browse Digikala Fresh, the supermarket
📦 One product (7)
ToolWhat it does
dk_productPrice, stock, specs and every seller's offer (color, warranty, shipping), cheapest first
dk_price_historyAbout 30 days of daily prices per color, with low and high
dk_reviewsCustomer reviews with stars, pros/cons and verified-buyer flag
dk_questionsCustomer questions with their top answers
dk_similarSimilar products, e.g. cheaper alternatives
dk_compare2-4 products side by side: the specs that differ, plus the shared ones
dk_installmentsDigipay credit-line offers for a product (credit amount, monthly repayment, months)
🧾 Other (3)
ToolWhat it does
dk_plus_plansDigikala Plus membership plans (free shipments) and benefits
dk_gold_pricesLive 18k gold price per gram (daily and ~3-month change) and gold coin prices
dk_locationAddress → coordinates, or coordinates → address with Digikala city/province ids

All tools are annotated readOnlyHint: true and return compact structured JSON, so they don't flood the agent's context.

Good to know

  • Prices are in Toman. The Digikala API answers in Rial; every tool divides by 10 so numbers match the website. Gold and coin prices are already Toman.
  • Ratings are 0–5, like the site (the API's 0–100 divided by 20); null means not rated yet. Review stars are 1–5.
  • Persian and English queries both work (گوشی سامسونگ, airpods pro). Category and brand codes are English slugs (mobile-phone, samsung).
  • sort=cheapest on a text search shows accessories first; that's how Digikala ranks it. Use dk_find_cheapest for "cheapest X".
  • Search always returns something, even for nonsense words (Digikala's search is semantic). dk_find_cheapest keeps only titles that contain every query word.
  • Groceries come from the supermarket store: dk_product shows its price, which can differ from the main-store price in search results.
  • Shipping cost is only calculated at checkout (login). dk_product shows how each offer ships, and dk_plus_plans the free-shipping plans.

FAQ

Do I need an Iranian IP?

Usually not: in testing the API answered from a foreign (Turkish) exit. If every tool fails with "refused the request (HTTP 403)", set DIGIKALA_MCP_PROXY to an HTTP proxy with an Iranian exit. (A 403 from just one call usually means an unknown category or brand code.) Normal system proxy variables are ignored on purpose.

Can it buy something for me?

No, and that's deliberate. It has no login and never calls the cart, checkout, payment, or review/question posting endpoints; it only reads public data. The agent finds the best option; you tap buy on the site.

A product shows in_stock: false and no price

Digikala lists products that are out of stock, coming soon or discontinued. They have no current offer, so there's no price. Searches use in_stock_only: true by default.

Claude Desktop says uvx is not found

Use the full path to uvx (where uvx on Windows, which uvx on macOS/Linux) as command.

How do I debug what the agent sees?
bash
npx @modelcontextprotocol/inspector uvx digikala-mcp

Configuration

VariableDefaultMeaning
DIGIKALA_MCP_PROXYunsetHTTP proxy for every request, e.g. http://user:pass@host:port

فارسی

digikala-mcp به دستیار هوش مصنوعی شما (Claude، Cursor، Copilot و ...) اجازه می‌دهد در دیجی‌کالا جستجو کند، قیمت همه فروشندگان یک کالا را مقایسه کند، تاریخچه قیمت، نظرات و پرسش‌وپاسخ‌ها را بخواند و پیشنهادهای شگفت‌انگیز را پیدا کند.

  • فقط خواندنی است: وارد حساب نمی‌شود، سبد خرید نمی‌سازد و سفارش ثبت نمی‌کند.
  • همه قیمت‌ها به تومان است و امتیازها مثل سایت از ۵.
  • روی سیستم خود شما اجرا می‌شود و به هیچ سرور واسطی داده نمی‌فرستد.

نصب در Claude Code:

bash
claude mcp add digikala -- uvx digikala-mcp

بعد بپرسید: «ارزان‌ترین گوشی سامسونگ A07 کدام است و الان قیمتش خوب است؟»

Development

bash
git clone https://github.com/sepehr071/digikala-mcp && cd digikala-mcpuv syncuv run pytest            # offline, against recorded responsesuv run pytest -m live    # real APIuv run ruff check .

Tools live in src/digikala_mcp/catalog.py, product.py and services.py; each is a typed async function with a docstring that tells the agent when to use it. Issues and PRs are welcome, especially new tools and fixes for API changes.

Releases: bump the version in pyproject.toml and server.json, then push a v* tag. GitHub Actions tests, publishes to PyPI and the MCP Registry, and creates the GitHub Release.

Disclaimer

Unofficial and not affiliated with or endorsed by Digikala. It uses the public endpoints of the digikala.com web app, which can change without notice. Please keep request rates reasonable.

License

MIT

來源:README.md,提交 40b8d5b

工具

0
工具後設資料尚未被收錄。

版本歷史

1
  1. v0.1.0最新Oct 3, 2026