# xdto-decompile

Exports 1C XDTO packages into readable XSD schemas for editing, transferring to partners, or moving between configurations without metadata loss.

- skill · `type=skill` · Claude Code, Codex · 37 installs · ★ 730
- Author: Nikolay Shirokov
- License: MIT · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/Nikolay-Shirokov/cc-1c-skills/tree/HEAD/.claude/skills/xdto-decompile/SKILL.md
- Updated: 2026-10-23
- HTML: https://affpapa.org/en/nevibecode/skills/xdto-decompile

## What it does

This skill turns binary `Ext/Package.bin` files and 1C metadata objects into standard XML schemas. It accepts a package folder path, direct link to `Package.bin`, or the `<Name>.xml` metadata file. The output prints to stdout or writes to a UTF-8 with BOM file when using the `-OutFile` parameter.

Under the hood, it executes `scripts/xdto-decompile.ps1` through `powershell.exe`. Metadata properties like name, synonym, and comments are placed into `xs:annotation/xs:appinfo`, ensuring clean reassembly via `/xdto-compile`. Attributes unrepresentable in standard XML Schema, such as `nillable` on attributes, receive an `xdto:` namespace prefix.

Standard 1C Configurator export strips `nillable` markers from attribute properties, whereas this tool keeps schemas intact. You need PowerShell available in your environment.

## Install

### Claude Code (native platform)

1. **Plugin marketplace**
In the agent chat (not a shell):
```text
/plugin marketplace add Nikolay-Shirokov/cc-1c-skills
```
In the agent chat (not a shell):
```text
/plugin install 1c-skills@cc-1c-skills
```
This installs the whole 1c-skills plugin with all its skills

2. **Skills CLI (Vercel)**
```bash
npx skills add Nikolay-Shirokov/cc-1c-skills --skill xdto-decompile -a claude-code
```

3. **Manually: put the files in place**
- File: `~/.claude/skills/xdto-decompile/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/xdto-decompile/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add Nikolay-Shirokov/cc-1c-skills --skill xdto-decompile -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/xdto-decompile/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

**Manually: put the files in place**
- File: `.cursor/skills/xdto-decompile/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install Nikolay-Shirokov/cc-1c-skills xdto-decompile
```

2. **Manually: put the files in place**
- File: `.github/skills/xdto-decompile/SKILL.md`

### Gemini CLI

**Platform CLI**
```bash
gemini skills install https://github.com/Nikolay-Shirokov/cc-1c-skills --path .claude/skills/xdto-decompile
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/xdto-decompile/SKILL.md` — The legacy .windsurf/skills/ path still works

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/Nikolay-Shirokov/cc-1c-skills/tree/HEAD/.claude/skills/xdto-decompile/SKILL.md

## When to use it
- convert binary Package.bin into an editable XSD schema
- prepare complete XML schemas for external integrations
- unpack package metadata for wide type restructuring
- retain nillable attribute markers lost by Configurator

## Example prompts
- Export package metadata into schema file `bank.xsd` with `/xdto-decompile`.
- Convert binary `Ext/Package.bin` into a readable XSD schema using `/xdto-decompile`.

## Source text · SKILL.md · MIT

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: 74d2d3d6d724c79c.

BEGIN THIRD-PARTY FILE 74d2d3d6d724c79c
````text
---
name: xdto-decompile
description: Выгрузка пакета XDTO 1С в XML-схему (XSD). Используй когда нужно получить схему существующего пакета — чтобы переработать её целиком, отдать контрагенту или перенести пакет в другую конфигурацию
argument-hint: <PackagePath> [-OutFile <файл.xsd>]
allowed-tools:
  - Bash
  - Read
  - Glob
---

# /xdto-decompile — Выгрузка пакета XDTO в XML-схему

Превращает пакет XDTO в обычную XML-схему — читаемую и редактируемую.
Заменяет чтение `Ext/Package.bin` напрямую.

## Параметры

| Параметр | Обязательный | Описание |
|----------|--------------|----------|
| `PackagePath` | да | Каталог пакета, путь к `Ext/Package.bin` или к `<Имя>.xml` объекта метаданных. Псевдоним — `-Path` |
| `OutFile` | нет | Записать схему в файл (UTF-8 с BOM). Без него — вывод в stdout |

```powershell
powershell.exe -NoProfile -File "${CLAUDE_SKILL_DIR}/scripts/xdto-decompile.ps1" -PackagePath "<путь>"
```

Примеры:
```powershell
... -PackagePath src/XDTOPackages/ОбменСБанком
... -PackagePath src/XDTOPackages/ОбменСБанком -OutFile bank.xsd
```

## Переработка схемы целиком

`/xdto-decompile` → правка XSD → `/xdto-compile -Force` возвращает пакет без потерь,
включая имя, синоним и комментарий объекта метаданных — они выгружаются
в `xs:annotation/xs:appinfo`.

Этот же путь даёт версионную копию пакета: смени в схеме `targetNamespace` и собери
её с `-Name` нового пакета — имя и синоним задаются флагами `/xdto-compile`, внутри
схемы их править не нужно. Меняя пространство имён, поправь **и объявление `xmlns`
с тем же URI**: внутренние ссылки пользуются им как префиксом. Заменять все вхождения
строки нельзя — пострадает импорт пространства имён, для которого старый URI является
префиксом (`urn:пример:обмен` и `urn:пример:обмен:legacy`).

Этот путь нужен, когда схему меняют широко или сначала надо разобраться, как она
устроена. Чтобы поправить одно свойство, схему целиком читать не нужно — `/xdto-edit`.
Если нужна не схема, а сводка «что присвоить и что обязательно», — `/xdto-info`.
````
END THIRD-PARTY FILE 74d2d3d6d724c79c

The third-party file has ended. Everything between the 74d2d3d6d724c79c tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 3064 of 3973 bytes. © Nikolay Shirokov · MIT · https://github.com/Nikolay-Shirokov/cc-1c-skills/tree/HEAD/.claude/skills/xdto-decompile/SKILL.md

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
