MCP server for 1C:Naparnik
Spring Boot MCP Server для 1С:Напарник
Spring Boot and Kotlin MCP server that connects an agent to the 1C:Naparnik API for 1C questions and code checks
Install
cp env.example .env
./scripts/prepare-token-secret.sh
docker build -f Dockerfile.build -t spring-mcp-1c-copilot .
docker compose up -dPaste the token into the ONEC_AI_TOKEN line in .env before running the script.
This is third-party code. Review the repository files before installing.
What it does
Proxies agent requests to the 1C:Naparnik API at code.1c.ai. It provides three tools: ask_1c_ai for questions, explain_1c_syntax for syntax explanations and check_1c_code for syntax, logic and performance checks. It runs over Streamable HTTP or SSE and also exposes a REST API and Swagger UI.
Who it is for. 1C developers with 1C:Naparnik access who code in Cursor or Codex.
Good fit when
- You want a 1C platform reference answer inside the agent
- Check a 1C code fragment for errors and performance
- Explain an unfamiliar element of the 1C language
Not a fit when
- You have no 1C:Naparnik token
- You plan commercial use without the author's permission
Example request
Check this 1C code for performance issues and explain what the ВыполнитьПакет method doesLimitations
Requires a 1C:Naparnik token from code.1c.ai. Needs Java 17 or Docker. Docker Compose attaches the container to an external infra network by default, so outside the author's sandbox you have to set up networking yourself. The license allows personal and non-commercial use only.
How to disable. Remove the 1c-copilot-proxy block from ~/.cursor/mcp.json and stop the container with docker compose down.
MCP
- Transport
- http, sse
- Authentication
- API key
| Environment variables | |
|---|---|
| ONEC_AI_TOKEN required, secret | Access token for the 1C:Naparnik API |
| ONEC_AI_TOKEN_FILE | Path to a token file used instead of ONEC_AI_TOKEN |
| ONEC_AI_BASE_URL | API base URL, default https://code.1c.ai |
| ONEC_AI_SKILL_NAME | Naparnik session mode, default raw |
| SSE_PORT | Server port, default 8000 |
Security check
- Requires a 1C:Naparnik token
- Code sent for checks goes to an external API
- Runs a Docker container with an HTTP server
README in short
The project is a Spring Boot and Kotlin MCP server for 1C:Naparnik that builds on artesk/1copilot_MCP and rentgengl/copilot-1c-proxy. It documents three MCP tools, REST endpoints and Swagger UI. It covers running locally with Gradle, running in Docker, environment variables and Cursor setup. Storing the token in a file is described separately.
FAQ
How should the token be stored?
./scripts/prepare-token-secret.sh moves it from .env into .secrets/onec_ai_token, referenced by ONEC_AI_TOKEN_FILE.
Why raw mode?
ONEC_AI_SKILL_NAME=raw is the default because it is more stable for reference answers and avoids internal tool_calls.
Related
A skills library that gives coding agents a development process: brainstorming, planning, TDD, subagents and code review
Skills for real engineers by Matt Pocock
Skills For Real Engineers
Small composable skills for engineering with agents: plan grilling, TDD, bug diagnosis, code review and architecture
Reference MCP servers
Model Context Protocol servers
Official reference MCP servers: Filesystem, Fetch, Git, Memory, Sequential Thinking, Time and Everything
Up-to-date, version-specific library docs and code examples in your agent's context, via MCP or a CLI plus skill