Skip to main content
Glama

defacto-mcp

Unofficial read-only MCP server for DeFacto (defacto.com.tr) — Türkiye's big fashion retailer (500+ stores in 100 countries, founded 2004): product search, full product detail, the category directory, one category's products, price statistics and the store locator.

mcp-name: io.github.mohammad-abbasi-sh/defacto-mcp

Tools

Tool

What it does

defacto_search_products

Search products by keyword (Turkish), e.g. elbise (dress), kot pantolon, mont. Page (24 products/page).

defacto_get_product

Full detail of one product (URL or path ending in -<id>): name, code, category, colour, season, list / discounted / campaign prices in TRY, sizes with per-size stock, colour variants, description, Ürün Bilgileri attributes, review count and fit percentages, images.

defacto_list_categories

The full category directory from the public sitemap: 240 categories grouped by department (Kadın, Erkek, Kız Çocuk, Erkek Çocuk, Kız Bebek, Erkek Bebek, Bebek, Ev, …).

defacto_category_products

Products of one category (e.g. /kadin-tesettur-elbise), with paging. Top-level landing slugs such as /kadin-elbise work too.

defacto_price_stats

Price statistics for a search (first 24 results): min / median / mean / max in TRY, campaign share, average discount, top categories.

defacto_list_stores

DeFacto stores from the store locator (300+ stores): name, city, address, phone, hours, coordinates. Optional city filter, e.g. İstanbul.

defacto_health

Reachability check (home page + one search).

Related MCP server: hepsiburada-mcp

Install

Requires Python 3.10+. The package is published on PyPI (pending publisher setup — see below); once live:

uvx defacto-mcp

Claude Desktop (claude_desktop_config.json):

{
  "mcpServers": {
    "defacto": {
      "command": "uvx",
      "args": ["defacto-mcp"]
    }
  }
}

No login, no API key. Read-only: the server only fetches public pages.

For AI agents

  • Search is Turkish: use Turkish keywords (elbise, not dress). Results carry exact_match — a nonsense query returns HTTP 200 with generic fallback products, so exact_match: false means the site found nothing; check the flag before treating results as matches.

  • Prices are live and move with campaigns; price_try is the effective price (campaign price when present), list_price_try the site's listed price and discount_pct is computed from them. Verify price and availability on defacto.com.tr before buying.

  • A product URL always ends in -<id> (e.g. ...-midi-elbise-3511234) — that is the identifier defacto_get_product needs.

  • Category slugs come from defacto_list_categories (e.g. kadin-tesettur-elbise).

  • Every response includes fetched_at (UTC) and source.

How it works

  • Search and category listings are parsed from the server-rendered pages (24 products per page, each card carrying a data-documents JSON blob with prices, campaign price, sizes and stock). One card per page is an empty "freeItem" promo card and is skipped.

  • Detail pages are parsed from the embedded JS object (list / discounted / campaign prices, per-size quantities, colour variants, pictures, description and the Ürün Bilgileri attributes) plus the review summary (count + fit percentages).

  • Categories come from the public sitemap (/sharedxml/tr-tr/category.xml, 240 URLs); the sitemap lists fine-grained categories — top-level landing pages such as /kadin-elbise are not in it but work as category pages.

  • Stores come from the /magazalar page's window.STORES JSON (cities + stores with addresses, phones, hours and coordinates).

  • Transport uses Chrome TLS impersonation (curl-cffi): plain requests are refused with HTTP 403. Requests are spaced ~0.8s apart and retried once with another fingerprint on 403/429.

Caveats

  • DeFacto runs frequent campaigns: a price seen in the morning can change the same day. The server always returns what the site returns at fetch time.

  • The average star rating and review texts load client-side and are not in the server HTML — detail returns the review count and fit percentages only.

  • The site's own Google Maps / Firebase keys embedded in recorded pages were never included in the test fixtures.

  • Category names in defacto_list_categories are derived from the slugs (the sitemap carries no display names).

License

PolyForm Noncommercial 1.0.0 — free for personal and non-commercial use; commercial use needs a separate license.

Built by Mohammad Abbasi — Almanibama · mabbasi.ir

Available Tools

7 tools
defacto_category_productsA

Products of one DeFacto category.

category: a category slug, site path or URL from defacto_list_categories, e.g. "/kadin-tesettur-elbise" or "kadin-tesettur-elbise". Top-level landing slugs such as "/kadin-elbise" also work even though they are not in the sitemap list. page: result page (24 products per page, default 1). limit: how many of the page to return (1-50, default 10).

Inputs: category (required), page, limit. Returns: result

defacto_get_productA

Full detail of one DeFacto product.

product: a full defacto.com.tr product URL or site path, e.g. "https://www.defacto.com.tr/100-pamuk-bisiklet-yaka-kolsuz-midi-elbise-3511234" (the trailing "-" is the product variant id — find one with defacto_search_products first). Returns name, product code, category breadcrumb, colour, season, list / discounted / campaign prices in TRY, sizes with per-size stock, colour variants, description, the Ürün Bilgileri attributes, review count and fit percentages, and image URLs.

Inputs: product (required). Returns: result

defacto_healthA

Check whether DeFacto is reachable right now.

Returns status ok (HTTP 200), blocked (HTTP 403/429 — bot wall or rate limit) or error, plus the HTTP status and the probed URL. Two polite requests (home page + one search); it fetches no product detail.

Inputs: no named parameters. Returns: result

defacto_list_categoriesA

DeFacto's full category directory, grouped by department.

Returns departments (Kadın, Erkek, Kız Çocuk, Erkek Çocuk, Kız Bebek, Erkek Bebek, Bebek, Ev, ...) with their categories, each with its Turkish name (derived from the slug), slug and URL. Use a category's slug or URL with defacto_category_products. No arguments.

Inputs: no named parameters. Returns: result

defacto_list_storesA

DeFacto stores in Turkey (and abroad) from the store locator.

city: optional Turkish city name to filter by, e.g. "İstanbul", "Ankara", "İzmir" (substring match, case-insensitive). limit: how many stores to return (1-50, default 20). Returns each store's name, city, address, phone, opening/closing hours, latitude and longitude, and its page URL — plus the full list of cities the locator covers.

Inputs: city, limit. Returns: result

defacto_price_statsA

Price statistics for a DeFacto search (first 24 results).

query: e.g. "elbise". Returns the search total, the number of products analysed, min / median / mean / max price in TRY, how many are on campaign and the average discount, and the most common categories. Use it to answer "how much does X cost at DeFacto?" without paging through listings.

Inputs: query (required). Returns: result

defacto_search_productsA

Search DeFacto products by keyword (Turkish).

query: e.g. "elbise" (dress), "kot pantolon", "mont". page: result page (24 products per page, default 1). limit: how many of the page to return (1-50, default 10). Returns each product's name, id, current and list price in TRY, computed discount %, campaign info, colour, category, sizes, stock and URL. A nonsense query returns HTTP 200 with generic fallback products — exact_match is false then; check the flag before treating results as matches.

Inputs: query (required), page, limit. Returns: result

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4/5.0

    Scored across 7 tools

    Disambiguation4/5

    Most tools are cleanly separated by input axis: search takes a keyword, category_products takes a slug/URL, get_product takes a single URL, list_stores takes a city, and health probes reachability. The only mild overlap is that search_products, category_products and price_stats all return product listings, but the descriptions make clear that price_stats is an aggregate summary and the other two differ by input type.

    Naming Consistency4/5

    All tools share a uniform `defacto_` prefix and snake_case, and most follow verb_noun (get_product, search_products, list_categories, list_stores). The two noun-only names (category_products, price_stats) break the verb pattern slightly but are still predictable and readable.

    Tool Count5/5

    Seven tools is well within the sweet spot for a read-only product catalog server. Each tool covers a distinct capability (detail, keyword search, category browse, category directory, price aggregation, store locator, health) and none feels redundant filler.

    Completeness4/5

    The surface covers the core discovery-to-detail lifecycle for products plus stores and a diagnostic health check, which is solid for a read-only scraping server. Minor gaps remain: search and category listings expose no sort/filter parameters, and there is no tool for reviews, related products, or per-store product availability.

    Maintenance

    ActivityMaintained
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      A
      quality
      B
      maintenance
      Provides read-only access to Migros Sanal Market's public catalogue, enabling product search, product details, category and promotion listings, and price statistics for Turkish supermarket items.
      5
      PolyForm Noncommercial 1.0.0
    • A
      license
      A
      quality
      B
      maintenance
      Enables read-only browsing of BİM's weekly Aktüel and İndirim deals, letting users search priced products, view per-week price statistics, and list product categories and Turkish provinces.
      7
      PolyForm Noncommercial 1.0.0