Divar MCPのロゴ

Divar MCP

コミュニティ
mmdju

MCP server for Divar — search, compare and analyze classified ads. Read-only, no API key.

公開者mmdju
リポジトリdivar-mcp
言語JavaScript
フォーク
8
スター
84
利用可能なツール
0
通信方式stdio, streamable-http
カテゴリ
リンク
  • ツールをAIワークフローに接続

    Divar MCPは、対応するAIクライアントやAIエージェントから利用できるMCP機能を提供します。

  • 0個の利用可能なツール

    呼び出し可能なアクションを以下で確認できます。サーバーから提供されている場合は、名前や説明も表示されます。

  • コピーして使える設定

    セットアップ用の設定例を使って、お好みのMCPクライアントにこのサーバーを設定できます。

  • オープンソースの注目度

    リンク先のリポジトリには84件のスターと8件のフォークがあります。

Divar MCP - Classifieds intelligence for AI agents

Divar MCP banner

A public MCP server that gives AI agents real Divar knowledge: search Iran's largest classifieds, prices in Toman, categories and neighbourhoods, car mileage and phone specs, rental deposit + rent, ad details, side-by-side comparisons and a live price verdict. Read-only, no key needed. No login, no phone numbers - ever.

Live endpoint: https://divar-mcp.mmdju2.workers.dev/mcp (Streamable HTTP, stateless)

نسخه فارسی · Examples · Tool reference · Changelog

Connect in 30 seconds

Any MCP client, one URL. Cline / Cursor / Claude Desktop (mcp.json style):

json
{
  "mcpServers": {
    "divar": { "url": "https://divar-mcp.mmdju2.workers.dev/mcp" }
  }
}

Then just talk: "pride under 300 million", "two-bedroom to rent in Tehran", "is this 207 a good deal?", "cheapest iPhone 13 in Mashhad".

Agents running in a browser work too - the endpoint answers CORS preflights (OPTIONS /mcp).

7 tools

ToolWhat it answers
divar_suggestVague wording to real search terms, category slugs, city and district ids - all 237 categories and 1177 cities
search_ads"Show me X", price checks - filters, sorting, paging; one call can scan and merge up to 5 pages
ad_detailsEverything about one ad: price, specs, amenities, condition scores, photos, map, expiry, chat flag, seller type
get_ads_batchShortlist cards for up to 10 tokens - feeds compare_ads, and each card says who is selling and until when
compare_ads"Which of these?" - only the specs that actually differ, plus the middle of the set and where each ad sits
find_best_value"Best X under Y Toman" - picks ranked by what the budget reaches, judged against the uncapped market (market_scale)
market_price"Is this price normal?" - the median of a live sample, with its size and what it kept out of the maths

Every tool is read-only (readOnlyHint: true) and needs no credentials. MCP prompts (compare-ads, best-under-budget) and resources (divar://cities, divar://categories, divar://category-filters/{slug}) ride along - reference data without spending a tool call.

Notes for agent builders:

  • All prices are in Toman (1 Toman = 10 Rial), and a negotiable ad returns price_toman: null - never 0. Ads sell in hours, so link the ad URL and let the user confirm.
  • Not every number in a price field is a price. A seller who will not publish one types a fake (۱,۰۰۰ تومان, repeated digits) - those ads stay in every list, labelled price_is_placeholder with a price_note, and never set a median. The evidence rides along as price_reading, so the caller judges the number instead of trusting it.
  • A rent ad has two numbers. price_toman is the monthly rent, deposit_toman (ودیعه) rides beside it, each with its own flag. A room in a shared home (همخونه / هماتاقی / اجاره اتاق) carries shared_housing - a room's price is not a flat's rent.
  • Start vague queries with divar_suggest: a district needs an id, a name alone will not filter it.
  • Anything with a budget or the word "best" goes to find_best_value - plain search only walks the pages you ask for.
  • Negotiable ads are not hidden. find_best_value ranks priced ads first by default; include_negotiable: true adds the توافقی picks last, with price_toman: null and an "ask the seller" line.
  • market_price is not an appraisal. It says how many ads it compared and keeps placeholder prices out of the maths.
  • Results are capped (default 10, max 30) and page goes up to max 50 - the caps protect agent context. Persian queries are folded (yeh/kaf, Persian digits, ZWNJ) with one automatic retry when a spelling variant comes back empty.
  • examples/sample-calls.md has eight copy-paste flows, and docs/tools.md has every parameter, which filters each category honours, and what is deliberately absent.

How it works

How a question becomes an answer. No user data is stored anywhere in this path.

What this means:

  • Stateless. Every request stands alone - no sessions, no accounts, nothing to log in to.
  • Read-only. All 7 tools carry readOnlyHint. Nothing here can post, change or delete anything.
  • No user data. Nothing about you is stored. What the server does keep: a short-lived response cache (10 minutes for searches and ads, 24 hours for the city/category lists).
  • Rate-limit aware. Search requests go out 800 ms apart, ad details 2 s apart with backoff, and Divar's model lists are cached for a day - load on your side never leaves this server as a burst.
  • Undocumented upstream. Divar's public API can change without notice, which is exactly why the verify script exists.

Trust, verified

Don't take my word for it - check the live server yourself:

bash
node scripts/verify-live.mjs   # needs Node.js 18+, nothing to install

It lists all 7 tools over Streamable HTTP, runs a search + details read + a market_price pricing + a privacy sweep + error paths, asserts the honest-data contract (Toman prices, negotiable = null, actionable errors), and compares the version the live service reports against the newest release in this repo - so a deployment that lags these docs cannot stay quiet. The same script runs hourly in CI (Live verify). See docs/architecture.md for the full path, and examples/python.py for a copy-paste client.

Privacy

Phone numbers need the seller's own login, and this server never logs in and never returns them - no phone, mobile or contact_number field appears in search results or ad details. Ads are linked, not contacted: the user talks to the seller themselves.

Data source

Divar's public web listings (undocumented, may change without notice). This project is not affiliated with or endorsed by Divar.

Status

Free public service on Cloudflare Workers. Fair use: 20 requests per minute per IP on /mcp (HTTP 429 with retry-after) - counted at the edge and in the server code, details in SECURITY.md.

License

Showcase repository (docs only, no source published) - see LICENSE. Security notes in SECURITY.md. Persian version in README_FA.md.

インストール

TypingMind
{
  "mcpServers": {
    "divar-mcp": {
      "command": "node",
      "args": [
        "scripts/verify-live.mjs"
      ]
    }
  }
}

Divar MCPのMCPを複数のAIモデルで活用

TypingMindはワークスペース単位でMCPツールに接続します。そのため、一度Divar MCPに接続すれば、モデルごとに個別に設定することなく、TypingMind内のさまざまなAIモデルで利用できます。 お使いのデバイス上でMCPをローカル実行することも、リモートMCPサーバーのURLに接続することもできます。

方法1:ローカルコネクタを使用

MCPサーバーが、お使いのコンピューター上のローカルファイル、アプリ、非公開リソースにアクセスする必要がある場合は、この方法を使います。

1

MCP設定を開く

TypingMindで「設定」、「詳細設定」、「MCP」の順に進み、「コネクタを設定」を選択してください。

  1. ブラウザでTypingMindを開いてください。
  2. 設定アイコンをクリックしてください。
  3. 「詳細設定」に移動してください。
  4. 「MCP」セクションを開いてください。
  5. 「コネクタを設定」をクリックし、「このデバイス」を選択してください。
「このデバイス」が選択されたTypingMindのMCPコネクタ設定画面
2

コネクタのコマンドを実行

「このデバイス」を選択し、TypingMindからコマンドをコピーしてターミナルで実行してください。MCPの使用中は、プロセスを実行したままにしてください。

  1. TypingMindに表示されるセットアップコマンドをコピーしてください。
  2. macOSではターミナルを、WindowsではWindows Terminalを開いてください。
  3. コマンドを貼り付けて実行してください。
  4. ターミナルで続行の確認を求められた場合は、パッケージのインストールを承認してください。
  5. MCPツールの使用中は、ターミナルウィンドウを開いたまま、プロセスの実行を継続してください。
3

Divar MCPをサーバーとして追加

コネクタのステータスが「準備完了」になったら、「サーバーを編集」をクリックし、MCPサーバーの設定を貼り付けてください。

  1. コネクタのステータスが「準備完了」になるまでお待ちください。
  2. 「サーバーを編集」をクリックしてください。
  3. Divar MCPのMCPサーバー設定を貼り付けてください。
  4. サーバー一覧を保存してください。
  5. コネクタが引き続き使用可能か確認するには、更新してください。
稼働中のサーバーと「サーバーを編集」ボタンが表示されたTypingMindのMCP設定画面
{
  "mcpServers": {
    "divar-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

複数のモデルで同じ接続を使用

サーバー一覧を保存し、「プラグイン」を開いてDivar MCPのMCPツールを有効にしてください。その後、TypingMindで対応するAIモデルを選択し、チャットでツールを使うか、AIエージェントに割り当ててください。

  1. TypingMindの「プラグイン」ページを開いてください。
  2. Divar MCPのMCPツールを有効にしてください。
  3. チャットを開始し、使用するAIモデルを選択してください。
  4. MCPツールをチャットで使うか、AIエージェントに割り当ててください。
  5. MCPに再接続することなく、必要に応じて別のAIモデルに切り替えられます。
選択したAIモデルと有効なMCPツールを使用したTypingMindのチャット
Divar MCPを使ってこのタスクを手伝ってもらえますか?
Divar MCP
はい、読みました。
Divar MCPで調べた結果をお伝えします。

方法2:MCPサーバーのURLを追加

Divar MCPがすでにリモートでホストされている場合や、チームの複数のユーザーで1つのコネクタを共有したい場合は、この方法を使います。

1

MCPコネクタを開く

TypingMindで「プラグイン」に移動し、「MCPコネクタ」を開いて「URLを追加」を選択してください。

  1. ブラウザでTypingMindを開いてください。
  2. 「プラグイン」に移動してください。
  3. 「MCPコネクタ」を開いてください。
  4. 「URLを追加」をクリックします。
TypingMindの「カスタムMCPサーバーURLを追加」フォーム
2

サーバーURLを貼り付け

「サーバーURL」欄にhttps://divar-mcp.mmdju2.workers.dev/mcpを入力してください。サーバーで必要とされる場合は、接続名、説明、アイコン、カスタムHTTPヘッダー、OAuthクライアント設定を追加してください。

  1. 「サーバーURL」欄にhttps://divar-mcp.mmdju2.workers.dev/mcpを貼り付けてください。
  2. Divar MCPの接続名を入力してください。
  3. 接続を識別しやすくするには、説明とアイコンを追加してください。
  4. サーバーで認証が必要な場合は、カスタムHTTPヘッダーまたはOAuthクライアントの詳細情報を追加してください。
3

接続を作成

「接続を作成」をクリックし、プラグイン一覧に戻って、新しいMCP接続が有効になっていることを確認してください。

  1. 「接続を作成」をクリックします。
  2. MCPコネクタの一覧に戻ってください。
  3. Divar MCPの接続が「有効」と表示されていることを確認してください。
  4. 接続がすぐに表示されない場合は、プラグイン一覧を更新してください。
4

再接続せずにモデルを切り替え

お好みのモデルでチャットを開始し、「プラグイン」でDivar MCPのツールを有効にしてください。必要に応じて別のモデルに切り替えられます。MCP接続は、TypingMindのワークスペースで引き続き利用できます。

  1. TypingMindで新しいチャットを開始してください。
  2. 使用するAIモデルを選択してください。
  3. 「プラグイン」でDivar MCPのツールを有効にしてください。
  4. 必要に応じて、ツールを使うようモデルに依頼してください。
  5. 別のAIモデルに切り替えて、同じMCP接続を再利用してください。
選択したAIモデルと有効なMCPツールを使用したTypingMindのチャット
Divar MCPを使ってこのタスクを手伝ってもらえますか?
Divar MCP
はい、読みました。
Divar MCPで調べた結果をお伝えします。

よくある質問

Divar MCP MCPサーバーは何に使いますか?

Divar MCPは、対応するAIクライアントを外部ツールやコンテキストに接続するためのMCPサーバーです。TypingMindでは、このMCPサーバーを一度追加するだけで、AIワークスペース内でそのツールを利用できるようになります。

TypingMindでDivar MCP MCPを複数のAIモデルと併用できますか?

はい。TypingMindはワークスペース単位でMCPツールに接続するため、モデルごとにMCPサーバーを設定する必要はありません。Claude、ChatGPT、Geminiや、TypingMindで設定したその他のAIモデルでDivar MCPを利用できます。

TypingMindでDivar MCP MCPを使うメリットは何ですか?

TypingMindは、複数のAIモデル、プロンプト、プラグイン、AIエージェント、APIキー、MCPツールを1つのワークスペースにまとめられる、LLMチャット向けの優れたフロントエンドです。Divar MCPを接続すると、TypingMindでチャットのワークフローを整理しながら、お好みのモデルでそのMCPツールを利用できます。

Divar MCP MCPをTypingMindに接続するにはどうすればよいですか?

Divar MCPは、ローカルMCPコネクタを使うか、リモートMCPサーバーのURLを追加することでTypingMindに接続できます。サーバーがデバイス上のファイル、アプリ、プライベートリソースにアクセスする必要がある場合はローカルコネクタを、MCPサーバーがリモートでホストされている場合はサーバーURLを使用してください。

TypingMindでDivar MCP MCPのどのようなツールを利用できますか?

Divar MCPはMCP機能を提供しています。TypingMindのプラグインページで有効にすると、チャットで使用したり、AIエージェントに割り当てたりできます。

Divar MCP MCPを使うには、APIキーをTypingMindと共有する必要がありますか?

いいえ。TypingMindはローカルファーストの設計で、モデルプロバイダー、APIキー、プロンプト、MCP設定をご自身で管理できます。Divar MCPで認証が必要な場合は、接続の作成時に、そのMCPサーバーに必要なヘッダー、OAuth設定、またはローカル設定を追加してください。

関連するMCPサーバー

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇