Agent skill · Data & Analytics

doc-ctr

Create Data Contracts (CTR) - Optional Layer 9 artifact using dual-file format (.md + .yaml) for API/data contracts

majiayu000github.com/majiayu000GitHub ↗
claude-codeMIT
Install
npx skills add majiayu000/claude-skill-registry --skill doc-ctr --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 2
SKILL.md size: 24 KB
Bundled scripts: none
Path: skills/api/doc-ctr/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 534
Language: HTML

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

Review
written from the skill's own SKILL.md · Aug 5, 2026

What it does

Guides the user to create a Data Contract (CTR) as an optional Layer 9 artifact, using two files per contract: a Markdown (.md) document and a YAML (.yaml) file. It specifies required document control fields, the dual-file requirement, and describes the content each file must contain (Markdown with contract overview, usage, traceability; YAML with OpenAPI 3.0 or JSON Schema definitions, validation rules, and example payloads). It also defines how to format element IDs, traceability tags, and how CTRs relate to upstream/downstream artifacts.

How it works

  • Requires dual-file format for each contract: a Markdown file documenting the contract and a companion YAML file containing the formal contract definition (OpenAPI 3.0 or JSON Schema).
  • Enforces a set of 9 required Document Control Fields in the Markdown: CTR ID, Title, Status, Version, Created, Author, Owner, Last Updated, SPEC-Ready Score.
  • Specifies sections to be included in the Markdown: Document Control, Contract Overview, Business Context, Contract Definition, Usage Examples, Validation Rules, Error Handling, Traceability.
  • Defines element ID formatting with the pattern CTR.{DOC_NUM}.{ELEM_TYPE}.{SEQ} for various element types (Interface, Data Model, Contract Clause).
  • Mandates usage of upstream/downstream artifact references and cumulative tagging across layers 1-8 when creating a CTR, including specific tag codes (e.g., BRD.01.01.03, PRD.01.07.02, etc.).
  • Provides OpenAPI 3.0 and JSON Schema example formats to include in the YAML file, with field types, examples, and error handling structures.
  • Includes guidance on SPEC-Ready scoring and directory organization, and outlines creation steps and required checks.

When to use it

Use doc-ctr when you have completed BRD through REQ (Layers 1-7), need to define API contracts or data schemas, multiple teams/services require shared contracts, and the contract complexity justifies a formal Layer 9 artifact. This layer is optional.

What it can touch

  • Upstream artifacts: BRD, PRD, EARS, BDD, ADR, SYS, REQ, IMPL
  • Downstream artifacts: SPEC, TASKS, IPLAN, Code
  • Tools: claude-code
  • File formats: Markdown (.md) and YAML (.yaml) for dual-file CTR artifacts

Caveats

  • Concentrates on strict upstream/downstream traceability rules and mandatory dual-file format; deviations are not described here.
  • Contains detailed formatting rules for element IDs and cumulative tagging that must be followed exactly.
From the SKILL.md

# doc-ctr ## Purpose Create **Data Contracts (CTR)** - Optional Layer 9 artifact in the SDD workflow that defines API contracts, data schemas, and interface specifications using dual-file format (markdown + YAML). **Layer**: 9 (Optional) **Upstream**: BRD (Layer 1), PRD (Layer 2), EARS (Layer 3), BDD (Layer 4), ADR (Layer 5), SYS (Layer 6), REQ (Layer 7), IMPL (Layer 8) **Downstream Artifacts**: SPEC (Layer 10), TASKS (Layer 11), IPLAN (Layer 12), Code (Layer 13) ## Prerequisites ### Upstream Artifact Verification (CRITICAL) **Before creating this document, you MUST:** 1. **List existing upstream artifacts**: ```bash ls docs/BRD/ docs/PRD/ docs/EARS/ docs/BDD/ docs/ADR/ docs/SYS/ docs/REQ/ docs/IMPL/ 2>/dev/null ``` 2. **Reference only existing documents** in traceability tags 3. **Use `null`** only when upstream artifact type genuinely doesn't exist 4. **NEVER use placeholders** like `BRD-XXX` or `TBD` 5. **Do NOT create missing upstream artifacts** - skip functionality instead Before creating CTR, read: 1. **Shared Standards**: `.claude/skills/doc-flow/SHARED_CONTENT.md` 2. **Upstream REQ**: Read atomic requirements (especially Section 3: Interface Specifications, Section 4: Data

What's inside
Steps it walks through
  1. Purpose
  2. Prerequisites
  3. Upstream Artifact Verification (CRITICAL)
  4. Reserved ID Exemption (CTR-00)
  5. When to Use This Skill
  6. CTR-Specific Guidance
  7. 1. Mandatory Dual-File Format
  8. 2. Document Control Fields (9 Required)
  9. 3. Required Sections (Markdown File)
  10. 4. Element ID Format (MANDATORY)
  11. 5. YAML Contract Format
  12. 6. Usage Examples Section
  13. 7. Contract Versioning
  14. 8. SPEC-Ready Scoring System
Ships with 1 file
  • metadata.json
Commands it runs
ls docs/BRD/ docs/PRD/ docs/EARS/ docs/BDD/ docs/ADR/ docs/SYS/ docs/REQ/ docs/IMPL/ 2>/dev/null
More from claude-skill-registry
All skills →
About this skill
What does the doc-ctr skill do?

Create Data Contracts (CTR) - Optional Layer 9 artifact using dual-file format (.md + .yaml) for API/data contracts

How do I install it?

Run `npx skills add majiayu000/claude-skill-registry --skill doc-ctr --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From majiayu000/claude-skill-registry, a repository with 534 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going