Skip to main content
Glama
ozon-customer-mcp

ozon-customer-mcp

by Raleose

ozon-customer-mcp

MCP-сервер для маркетплейса Ozon (сторона покупателя): поиск, карточки товаров, отзывы, Q&A, сравнение продавцов, каталоги и город доставки через Model Context Protocol.

Репозиторий: ozon-customer-mcp. Имя MCP-сервера и Docker-образа совпадает.

Работает в Cursor, Claude Desktop, VS Code и других MCP-клиентах.

Зачем

У Ozon нет публичного consumer API. Сайт защищён антиботом — обычный headless Chromium в Docker часто получает капчу.

Этот сервер держит сессию anti-detect браузера Camoufox, один раз проходит JS-челлендж и дальше читает внутренний composer-api как JSON. HTML не парсится.

Related MCP server: Kettu Marketplace Intelligence

Инструменты

Tool

Назначение

ozon_search

Поиск (+ foodOnly, pages, seller min*, withDelivery)

ozon_product_details

Карточка (+ nutrition{}, imageDataUri, delivery)

ozon_products_batch

Пакет 1–40 карточек (БЖУ / Data URI)

ozon_product_reviews

Отзывы (sort helpful/date/product, aboutProduct)

ozon_product_questions

Вопросы и ответы на карточке

ozon_product_offers

Тот же товар у других продавцов (+ даты доставки, location)

ozon_product_variants

Варианты (память, цвет, …)

ozon_product_specs

Полные характеристики (+ nutrition{})

ozon_compare_products

Сравнение 2–8 товаров (матрица + extracted)

ozon_seller_info

Профиль продавца

ozon_seller_catalog

Каталог магазина

ozon_category_browse

Товары в категории (+ filters, dedupe)

ozon_list_categories

Живое дерево категорий (title + slug, без хардкода)

ozon_brand_catalog

Витрина бренда (+ filters)

ozon_related_products

«Покупают вместе» / похожие

ozon_search_filters

Доступные фильтры поиска

ozon_get_location

Текущий город доставки сессии

ozon_search_cities

Живой поиск городов (Ozon Maps suggest)

ozon_set_city

Сменить город доставки (через выбор ПВЗ)

Доставка и город

По умолчанию анонимная сессия — Москва. Даты в ozon_product_offers относятся к location.city.

Типичный сценарий:

ozon_get_location
ozon_search_cities({ query: "Каз" })   → показать варианты пользователю
ozon_set_city({ city: "Казань" })      → ~20–40 с
ozon_product_offers({ product: sku })  → даты для выбранного региона

ozon_search_cities ходит в живой API Ozon (не хардкод). Список городов всегда актуальный.

Идентификаторы

  • Товар: SKU, URL https://www.ozon.ru/product/... или slug

  • Продавец / категория / бренд: slug, numeric id или полный URL

  • Категория: только реальный slug из ozon_list_categories / ozon_search_filters или ozon.ru — Ozon смотрит на numeric id, угаданный префикс может открыть чужую категорию

ozon_list_categories()                    → топ-отделы
ozon_list_categories({ parent: "…" })     → дети
ozon_list_categories({ query: "…" })      → категории по поисковому запросу
ozon_category_browse({ category: slug })  → товары

Быстрый старт

git clone https://github.com/Raleose/ozon-customer-mcp.git
cd ozon-customer-mcp
docker build -t ozon-customer-mcp:latest .

MCP-конфиг (Docker)

Скопируйте docs/mcp.example.json в конфиг клиента (например ~/.cursor/mcp.json) или используйте .cursor/mcp.json в проекте:

{
  "mcpServers": {
    "ozon-customer": {
      "command": "docker",
      "args": [
        "run", "-i", "--rm", "--init", "--stop-timeout=10", "--shm-size=1g",
        "--label", "ozon-customer-mcp=1",
        "ozon-customer-mcp:latest"
      ]
    }
  }
}

После сборки перезагрузите MCP-сервер в клиенте. Должно быть 17 tools.

Подробнее: docs/install.md.

Архитектура

MCP-клиент
    ↓ stdio
  src/index.js              — MCP tools
  src/ozon.js               — пути composer-api
  src/parse.js              — парсеры widgetStates
  src/browser.js            — мост Node ↔ Python
    ↓
  python/browser_service.py — Camoufox + location
  python/locations.py       — парсинг suggest / location
    ↓
  www.ozon.ru composer-api

Локальная разработка

npm install
pip install -r python/requirements.txt
python -m camoufox fetch

node src/index.js                 # MCP по stdio
python test/locations.test.py     # unit-тесты location/suggest
node scripts/smoke-test.js        # live smoke (нужен Camoufox)
node scripts/smoke-location.js    # live: search_cities + set_city

Переменные окружения

Переменная

По умолчанию

Описание

OZON_HEADLESS

true

Headless Camoufox

OZON_GEOIP

false

Геолокация браузера по IP (не прокси)

OZON_CHALLENGE_WAIT_MS

15000

Ожидание антибота

OZON_EXIT_IDLE_MS

600000

Exit после простоя (Docker --rm убирает контейнер)

OZON_PYTHON

python3

Интерпретатор для browser service

HTTP_PROXY / HTTPS_PROXY

—

HTTP(S)-прокси при необходимости

Docker-контейнеры

Контейнер живёт, пока открыта MCP-сессия. После отключения клиента или idle-таймаута процесс завершается, --rm удаляет контейнер.

Зависшие:

.\scripts\cleanup-containers.ps1

Troubleshooting

Симптом

Что сделать

Antibot / Captcha

Другой IP или RU-прокси

HTTP 403

Сессия перезапустится сама

Контейнеры не удаляются

Пересоберите образ, проверьте --stop-timeout=10

Мало tools в клиенте

Reload MCP / пересоберите ozon-customer-mcp:latest

Город не тот

ozon_search_cities → ozon_set_city

Пустой search

Смотри hint / suggestedCategory или ozon_search_filters

Лицензия

MIT — см. LICENSE.

Available Tools

19 tools
ozon_brand_catalogBrowse Ozon brand storeA
Read-onlyIdempotent

Official brand storefront on Ozon. Accepts brand name, slug-id ("name-123"), or /brand/... URL. Plain names are resolved via Ozon search. Returns brand products (ads filtered out). Supports filters{}.

Inputs: brand (required), rich, sort, limit, +4 more.

ozon_category_browseBrowse Ozon categoryA
Read-onlyIdempotent

Products inside a category without text search. Use for browsing a department with priceMax/filters. Returns products, breadcrumbs, top brands. IMPORTANT: Ozon matches the numeric id only — a guessed stem+id can open a different category. Always copy slug from ozon_list_categories (or ozon_search_filters / real ozon.ru link). Mismatch of text prefix vs real category → error. Supports filters{} like ozon_search.

Inputs: category (required), page, rich, sort, +15 more.

ozon_compare_productsCompare Ozon products side-by-sideA
Read-onlyIdempotent

Compare 2–8 products. Default compact=true: matrix + slim product rows (no per-SKU characteristics dump / missingKeys). compact:false keeps full characteristics + missingKeysByProduct. extracted{} from characteristics/title only.

Inputs: products (required), rich, compact.

ozon_get_locationGet Ozon delivery locationA
Read-onlyIdempotent

Current delivery city/region for this browser session. Anonymous sessions default to Москва. Use before quoting delivery dates. Returns { city, region, pickupAddress }.

Inputs: no named parameters.

ozon_list_categoriesList Ozon categoriesA
Read-onlyIdempotent

Live category directory from Ozon (not a hardcoded map). Returns title + slug + url. No args → top departments. parent=slug|id|title → children. query=text → category facet for that search. Copy slug into ozon_category_browse / ozon_search.category — never invent stems.

Inputs: rich, limit, query, parent, +1 more.

ozon_product_detailsGet Ozon product detailsA
Read-onlyIdempotent

Product card. Default compact=true: price, seller, location, delivery, characteristics, nutrition{} (proteinG/carbsG/fatG/kcal/per — auto-loads features for food-like cards). imageDataUri:true → small Data URI thumbnail for canvases. compact:false / rich:true keeps images[] URLs + full description. For ALL specs: ozon_product_specs.

Inputs: sku, rich, compact, product, +3 more.

ozon_product_offersCompare Ozon seller offersA
Read-onlyIdempotent

Lists sellers for the product cluster. includeCurrent=true (default) prepends THIS card's seller with isCurrentListing=true and delivery from the product page (not only /otherOffers). Each row: price, rating, delivery text, advantages[] (all badges, not only first), productUrl, sellerUrl. Delivery dates follow location.city / pickupAddress — call ozon_search_cities then ozon_set_city (optionally with address for a specific PVZ area) first. Requires product sku.

Inputs: sku, rich, sort, limit, +3 more.

ozon_product_questionsGet Ozon product Q&AA
Read-onlyIdempotent

Questions and answers on the product page (not reviews). Use for compatibility, package contents, warranty, regional versions, setup tips — things buyers ask before purchase. Returns question text, author, date, and answers (seller or buyers). Requires product sku or URL.

Inputs: sku, limit, product.

ozon_product_reviewsGet Ozon product reviewsA
Read-onlyIdempotent

Buyer reviews for a product SKU. Default variantOnly=true matches Ozon UI «Этот вариант» (only reviews left on this exact color/config SKU — may be empty while the card shows pooled totals). Pass variantOnly=false for all sibling variants on the same card. sort=helpful|date|product|default. hasPhotos=true keeps photo reviews. Each review: aboutProduct, likelySellerGeneric, matchedSku, isOtherVariant, variant[] labels, reviewsScope (product|otherVariant|seller|crossListing|unclear). If count=0 with variantOnly, retry variantOnly=false and label quotes as other-variant.

Inputs: sku, rich, sort, limit, +4 more.

ozon_products_batchBatch Ozon product detailsA
Read-onlyIdempotent

Fetch 1–40 product cards in one call (nutrition + optional imageDataUri). imageDataUri only for ≤24 SKUs (auto-disabled above). For huge canvases prefer Docker script over stuffing MCP context. Reload MCP after upgrades so Cursor sees new tool schemas.

Inputs: products (required), rich, compact, imageSize, +2 more.

ozon_product_specsGet full Ozon product specificationsA
Read-onlyIdempotent

Technical characteristics from the listing (fieldCount varies — many cards are sparse with <8 fields). Also returns nutrition{} when macros are in the table. When sparse/specsIncomplete=true, do not invent numbers; try another SKU or ozon_product_questions. More complete than ozon_product_details.characteristics when the seller filled the table.

Inputs: sku, product.

ozon_product_variantsGet Ozon product variantsA
Read-onlyIdempotent

Product configuration options: memory size, color, storage, etc. Each variant has its own sku and price. Use when user asks '512GB or 1TB?', 'what colors available?', or needs sku for a specific configuration. Returns aspects[] with variants[]: sku, label, price, oldPrice, available, url.

Inputs: sku, product.

ozon_search_citiesSearch Ozon delivery citiesA
Read-onlyIdempotent

Live city lookup via Ozon maps API (not a static list). Use when user asks about delivery to a city or you need options to choose from. Pass first letters or full name: "Каз", "Санкт", "Екатеринбург". Returns cities[]: label, city, region, lat, lng, uid. Show options to user, then ozon_set_city(city).

Inputs: query (required), limit.

ozon_search_filtersGet Ozon search filtersA
Read-onlyIdempotent

Available filters and sort options BEFORE / alongside searching. Default compact=true truncates long facet option lists (keeps brand/category/price fuller; category options include slug+url). Pass compact:false for complete options. For browsing the category tree use ozon_list_categories. Does not return products.

Inputs: rich, query, compact, category.

ozon_seller_catalogBrowse Ozon seller catalogA
Read-onlyIdempotent

Product listing from a seller's shop page. Use when user wants to see what else this shop sells. Returns same fields as ozon_search items plus seller info. Supports sort and price filters.

Inputs: seller (required), rich, sort, limit, +3 more.

ozon_seller_infoGet Ozon seller profileA
Read-onlyIdempotent

Shop profile for a seller. Use when user asks 'is this seller trustworthy?' or before buying from unknown shop. Returns: shop name, logo, subtitle, rating, orders + reviewCount (from badges like «20,6 K заказов»), badges with human labels, infoUrl, isExpress/isOfficial hints. Product-card seller.rating is often richer than this page.

Inputs: seller (required).

ozon_set_citySet Ozon delivery cityA

Change delivery city for the session (picks a pickup point via Ozon map). Call ozon_search_cities first to show the user valid options from Ozon. Pass address to bias PVZ toward a street/district (e.g. city=Зеленоград, address="Заводская 14к2"). Returns requestedCity and location { city, region, pickupAddress }. Affects delivery in ozon_product_details / ozon_product_offers. Takes ~20–40s.

Inputs: city (required), lat, lng, address.

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    A4.2/5.0

    Scored across 19 tools

    Disambiguation5/5

    Each tool maps to a distinct resource/action: search vs category browsing vs filters, product details vs specs vs variants vs offers vs reviews vs questions, and seller info vs seller catalog vs city lookup vs city setting. No two tools appear to do the same thing; close pairs like ozon_search and ozon_category_browse are clearly separated by text-search vs department-browsing.

    Naming Consistency3/5

    All tools share the consistent ozon_ prefix, which helps recognize them as a family. However, naming conventions are mixed: many are noun-first resources (ozon_product_details, ozon_seller_catalog) while several are verb-first actions (ozon_search_cities, ozon_set_city, ozon_compare_products), and ozon_search contains no noun at all. It is readable but not a uniform verb_noun pattern.

    Tool Count4/5

    19 tools is above the typical 3–15 sweet spot and feels slightly heavy, but the toolset covers a broad e-commerce domain with distinct workflows: search, category browsing, product details, variants, reviews, questions, offers, seller/brand catalogs, comparison, and delivery-city management. Each tool earns its place, so the count is reasonable rather than bloated.

    Completeness5/5

    The surface covers the full product-research lifecycle: category discovery, search/filtering, product details/specs/variants, social proof via reviews/questions/offers/seller info, comparison and related products, and delivery-location setup. There are no obvious dead ends or missing critical operations for a browsing-focused Ozon customer assistant.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers