role-compile

Generates 1C:Enterprise role metadata and rights XML files from a JSON DSL definition.

1|2|Updated Jul 19, 2026
One-click install
npx skills add https://github.com/IngvarConsulting/unica-marketplace --skill role-compile-ingvarconsulting
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: role-compile
Source: https://github.com/IngvarConsulting/unica-marketplace/tree/main/plugins/unica/skills/role-compile
Command: npx skills add https://github.com/IngvarConsulting/unica-marketplace --skill role-compile-ingvarconsulting

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Manually authoring 1C:Enterprise role files (Roles/Name.xml and Ext/Rights.xml) is verbose and error-prone, requiring correct UUIDs, right names, and RLS template escaping. This Skill converts a compact JSON description of permissions into valid role XML registered in Configuration.xml. ## Core Features & Use Cases - JSON DSL to role XML: Accepts a JSON role definition and generates the role metadata file plus the rights file, registering the role in Configuration.xml automatically. - Presets and synonyms: Supports @view and @edit right presets per object type, plus Russian synonyms for object types and rights (e.g. Справочник → Catalog, Чтение → Read). - RLS templates: Defines row-level security templates with automatic & escaping and per-object restriction references. - Use Case: Define a role granting read access to the Номенклатура catalog and view access to sales documents restricted by organization, then compile it into ready-to-use role XML via the unica.role.compile MCP tool. ## Quick Start Ask the assistant to create a 1C role from your JSON rights definition by running the role-compile skill with the JSON file path and your configuration output directory.

Frequently Asked Questions about role-compile

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a 1C role from a JSON description?▼

Write a JSON file with name, synonym, and an objects array listing permissions, then call the unica.role.compile MCP tool with JsonPath pointing to that file and OutputDir set to your configuration dump root. It generates the role XML and rights XML and registers the role in Configuration.xml.

What right presets are available for 1C role generation?▼

Two presets exist: @view grants read-only access (Read, View, plus InputByString for catalogs and documents), and @edit grants full CRUD with interactive rights and posting for documents. Services like WebService have no presets and require explicit rights such as Use.

Can I use Russian object type and right names in the role DSL?▼

Yes, Russian synonyms are translated automatically, so Справочник maps to Catalog and Чтение maps to Read. Mixing languages in one line is allowed, for example "Справочник.Контрагенты: Чтение, View".

How do I add RLS restrictions to a generated 1C role?▼

Define templates in the templates array with a name and condition, then reference them in an object's rls field using the #TemplateName("params") syntax. The & character in conditions is escaped automatically in the generated XML.

Which 1C metadata types cannot have rights in a role?▼

Enums, CommonModules, DefinedTypes, CommonPictures, CommonTemplates, Languages, FunctionalOptions, EventSubscriptions, ScheduledJobs, and StyleItems cannot carry rights in roles. Attempting to include them is invalid because they are resources or configuration elements, not right-bearing objects.

How do I verify a generated 1C role is correct?▼

Call unica.role.validate with the RightsPath to check XML correctness, rights, and RLS, and unica.role.info to get a structural summary of the role. Both are exposed through the unica MCP tool.