Skip to main content
Glama

@theyahia/chestnyznak-mcp

MCP server for the «Честный ЗНАК» / ЦРПТ API — product marking verification. 5 tools. Public checks without authorization, information from True API with a token.

npm License: MIT

Part of the Russian API MCP series (50 servers) by @theYahia.

Installation

Claude Desktop

{
  "mcpServers": {
    "chestnyznak": {
      "command": "npx",
      "args": ["-y", "@theyahia/chestnyznak-mcp"]
    }
  }
}

Claude Desktop (with authorization)

{
  "mcpServers": {
    "chestnyznak": {
      "command": "npx",
      "args": ["-y", "@theyahia/chestnyznak-mcp"],
      "env": {
        "CHESTNYZNAK_TOKEN": "ваш-токен"
      }
    }
  }
}

Claude Code

claude mcp add chestnyznak -- npx -y @theyahia/chestnyznak-mcp

# С авторизацией
CHESTNYZNAK_TOKEN=ваш-токен claude mcp add chestnyznak -- npx -y @theyahia/chestnyznak-mcp

Streamable HTTP

npx @theyahia/chestnyznak-mcp --http --port=3000
# Endpoint: POST http://127.0.0.1:3000/mcp
# Health:   GET  http://127.0.0.1:3000/health

By default, the HTTP server listens only on 127.0.0.1 and checks the Host header (protection against DNS-rebinding). To expose it externally — --host=0.0.0.0 (at your own risk, there is no authentication on /mcp).

Related MCP server: Kettu Marketplace Intelligence

Environment variables

Variable

Required

Description

CHESTNYZNAK_TOKEN

No

True API token for the search_products, get_cis_info tools. See «Authorization».

CHESTNYZNAK_BASE_URL

No

Origin of the authorized API (default https://markirovka.crpt.ru). Only https hosts *.crpt.ru / *.crptech.ru are allowed.

CHESTNYZNAK_PUBLIC_BASE_URL

No

Base URL of the public API (default https://mobile.api.crpt.ru/mobile). Convenient for mocks in tests.

Tools (5)

Public (no authorization)

Tool

Arguments

Description

check_marking_code

code, codeType?

Authenticity check by marking code

get_product_info

code, codeType?

Detailed information: name, group, manufacturer, owner

check_batch

codes[], codeType?

Batch check of up to 50 codes (concurrency limited)

codeType — datamatrix (default), qr or ean13.

Authorized (CHESTNYZNAK_TOKEN)

Tool

Arguments

Description

search_products

query (GTIN)

Product information by GTIN from True API

get_cis_info

cis

Information about a CIS (identification code) from True API

Search by name/brand is the National Catalog (nk.crpt.ru), a separate API; it is not supported here. search_products works by GTIN.

Response format

check_marking_code:

{ "code": "0104600702028445", "found": true, "valid": true, "status": "INTRODUCED" }

get_product_info (the producer/owner/status fields are taken from the nested product group object, null if absent):

{
  "code": "0104600702028445",
  "found": true,
  "valid": true,
  "status": "INTRODUCED",
  "productName": "Молоко 3.2%",
  "category": "milk",
  "producerName": "АО \"Данон Россия\"",
  "ownerName": "ООО Магнит",
  "ownerInn": "2309085638"
}

status — string enum: EMITTED / APPLIED / INTRODUCED / RETIRED / WRITTEN_OFF / DISAGGREGATION and others.

Each tool additionally returns structuredContent (a typed object according to outputSchema), in addition to the textual JSON.

Examples

Проверь код маркировки 0104600702028445
Расскажи подробнее о товаре с кодом 010460070202844521
Проверь пачку кодов: 0104600702028445, 0104600702028446
Информация о товаре с GTIN 04600702028445
Информация о CIS 0104600702028445

Authorization (True API)

⚠️ Important: True API (ГИС МТ) has no static «eternal» token. The token is obtained using the «request-signature» scheme with an enhanced qualified electronic signature (UKEP) certificate (GOST):

  1. GET /api/v3/true-api/auth/key → { uuid, data }

  2. Sign data with a UKEP certificate (CAdES-BES, base64).

  3. POST /api/v3/true-api/auth/simpleSignIn { uuid, data: <подпись> } → token.

  4. Token lifetime — no more than ~10 hours, then re-authorization is required.

This server uses CHESTNYZNAK_TOKEN as a token already obtained in this way (it is sent as Authorization: Bearer). UKEP signing is performed outside the server (e.g., via КриптоПро) — there is no built-in GOST signing here. Registration is available to legal entities/individual entrepreneurs at markirovka.crpt.ru.

The endpoints/methods of the authorized part (paths, request body) were verified against the official documentation and open clients, but have not been tested against a live token due to the UKEP requirement. If ЦРПТ changes the contract — adjust via CHESTNYZNAK_BASE_URL.

Skills

Skill

Trigger

skill-check-product

«Check the product marking by code»

skill-search

«Find a product by GTIN»

Troubleshooting

Symptom

Cause / solution

CHESTNYZNAK_TOKEN не задан

The search_products/get_cis_info tools require a token (see «Authorization»).

таймаут запроса / все попытки исчерпаны

Network/API unavailability; the server makes up to 3 attempts with backoff. The public API may not respond from non-RF IPs.

HTTP 401 / HTTP 403

The token is invalid or has expired (~10h) — obtain a new one.

HTTP 429

Rate limit; the server retries automatically. For batch, reduce the batch size.

CHESTNYZNAK_BASE_URL отклонён

The override must be https with a *.crpt.ru/*.crptech.ru host.

API

  • Public (no authorization): GET https://mobile.api.crpt.ru/mobile/check?code=<код>&codeType=<тип> — undocumented endpoint of the mobile application.

  • Authorized (Bearer): https://markirovka.crpt.ru/api/v3/true-api/... — True API (ГИС МТ).

Development

npm ci
npm run typecheck   # tsc --noEmit (src + tests)
npm test            # vitest
npm run build       # tsc -> dist/
npm run dev         # tsx watch (stdio)
npm run dev:http    # tsx watch (HTTP)

License

MIT

Available Tools

5 tools
check_batchA

Пакетная проверка до 50 кодов маркировки за один запрос.

Inputs: codes (required), codeType. Returns: total, results

check_marking_codeA

Проверка подлинности товара по коду маркировки Честный ЗНАК.

Inputs: code (required), codeType. Returns: code, found, valid, status

get_cis_infoB

Информация о CIS (коде идентификации) из True API. Требует CHESTNYZNAK_TOKEN.

Inputs: cis (required). Returns: cis, gtin, status, producerInn, +2 more

get_product_infoA

Подробная информация о товаре по коду маркировки: название, группа, производитель, владелец.

Inputs: code (required), codeType. Returns: code, found, valid, status, +5 more

search_productsA

Информация о товаре по GTIN из True API. Требует CHESTNYZNAK_TOKEN. (Поиск по названию — Нацкаталог, вне API.)

Inputs: query (required). Returns: query, total, results

Tool Schema Changelog

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

Loading tool schema changelog…

    TDQS

    A3.6/5.0

    Scored across 5 tools

    Disambiguation2/5

    check_marking_code, check_batch, and get_cis_info have unclear boundaries: all appear to work with marking/CIS codes and return overlapping verification/information data. get_product_info also overlaps with get_cis_info for code-based product details; only search_products is clearly distinct via GTIN.

    Naming Consistency5/5

    All tool names follow a consistent snake_case verb_noun pattern: check/get/search + resource. The naming is predictable and easy to navigate.

    Tool Count5/5

    Five tools form a compact, well-scoped set for a marking-code verification and product information service. There is no bloat or obvious redundancy in count.

    Completeness4/5

    Core operations are covered: single-code verification, detailed product info, batch checks, GTIN lookup, and CIS info. Minor gaps exist, such as no batch-level product details or GTIN lookup without a token, but the main workflow is supported.

    Maintenance

    ActivityNo data
    ResponsivenessOutdated data

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      A
      quality
      D
      maintenance
      MCP server for Russia's Chestnyi Znak product labelling system, allowing AI assistants to query marking codes, documents, warehouse balances, and participant data via natural language.
      10
      44 npm
      4
      -
    • A
      license
      A
      quality
      D
      maintenance
      Enables querying authoritative product data from GS1 Brasil's Verified by GS1 API via GTIN, including brand, description, classifications, images, weights, dimensions, and licensee details, with support for national and international bases and batch enrichment.
      4
      MIT