ClawKit Logo
ClawKitReliability Toolkit
Back to Registry
Official Verified developer tools Safety 4/5

code-to-prd

Reverse-engineer any codebase into a complete Product Requirements Document (PRD). Analyzes routes, components, state management, API integrations, and user interactions to produce business-readable documentation detailed enough for engineers or AI agents to fully reconstruct every page and endpoint. Works with frontend frameworks (React, Vue, Angular, Svelte, Next.js, Nuxt), backend frameworks (NestJS, Django, Express, FastAPI), and fullstack applications. Trigger when users mention: generate PRD, reverse-engineer requirements, code to documentation, extract product specs from code, document page logic, analyze page fields and interactions, create a functional inventory, write requirements from an existing codebase, document API endpoints, or analyze backend routes.

skill-install — Terminal

Install via CLI (Recommended)

clawhub install openclaw/skills/skills/alirezarezvani/code-to-prd
Or

What This Skill Does

The Code-to-PRD skill acts as a bridge between technical implementation and product strategy. It reverse-engineers existing codebases—ranging from complex React frontends to robust Django backends—into a comprehensive, human-readable Product Requirements Document (PRD). Instead of requiring manual documentation, this skill autonomously traverses your repository to catalog routes, state management logic, UI components, and API integrations. It synthesizes this data into a structured format that provides both business stakeholders with a high-level overview of features and engineers with the technical precision required to reconstruct the application from scratch. By analyzing models, constants, and endpoints, it captures the 'source of truth' directly from the code.

Installation

To add this skill to your OpenClaw environment, execute the following command in your terminal:

clawhub install openclaw/skills/skills/alirezarezvani/code-to-prd

Ensure your current directory is within your OpenClaw project context to maintain proper environment configuration. Once installed, the skill becomes immediately available via the /code-to-prd slash command.

Use Cases

  • Legacy System Migration: When taking over an undocumented codebase, use this skill to quickly understand system requirements and functional behavior before refactoring.
  • Onboarding & Knowledge Transfer: Provide new team members with a generated PRD to accelerate their understanding of the architecture, data models, and business logic.
  • Audit & Compliance: Automatically generate documentation of existing API endpoints and data handling processes for internal review or security audits.
  • Project Documentation: Keep your project documentation synced with current code without writing a single line of manual text.

Example Prompts

  1. "/code-to-prd ./src --generate-summary: Analyze our React frontend and create a user-friendly PRD focusing on the checkout flow and user interactions."
  2. "/code-to-prd ./backend: Reverse-engineer our FastAPI backend to document all RESTful endpoints, data schemas, and authentication models."
  3. "/code-to-prd . : Create a comprehensive fullstack PRD for this Next.js project, documenting both the UI components and the backend API logic."

Tips & Limitations

  • Pre-processing: Ensure your project is clean and dependencies are installed. The tool works best when it can resolve imports and type definitions clearly.
  • Accuracy: While the tool is highly accurate for standard framework patterns, custom or highly non-standard architectural patterns may require manual review of the generated output.
  • File Scope: When analyzing massive monorepos, target specific directories to improve processing speed and document relevance.
  • Context: The tool is designed for code analysis; it cannot interpret business intent not explicitly represented in the code (e.g., future feature plans).

Metadata

Stars4473
Views1
Updated2026-05-01
View Author Profile
AI Skill Finder

Not sure this is the right skill?

Describe what you want to build — we'll match you to the best skill from 16,000+ options.

Find the right skill
Add to Configuration

Paste this into your clawhub.json to enable this plugin.

{
  "plugins": {
    "official-alirezarezvani-code-to-prd": {
      "enabled": true,
      "auto_update": true
    }
  }
}

Tags(AI)

#documentation#reverse-engineering#product-management#code-analysis#developer-productivity
Safety Score: 4/5

Flags: file-read, code-execution

Related Skills

intl-expansion

International market expansion strategy. Market selection, entry modes, localization, regulatory compliance, and go-to-market by region. Use when expanding to new countries, evaluating international markets, planning localization, or building regional teams.

alirezarezvani 4473

marketing-strategy-pmm

Product marketing skill for positioning, GTM strategy, competitive intelligence, and product launches. Use when the user asks about product positioning, go-to-market planning, competitive analysis, target audience definition, ICP definition, market research, launch plans, or sales enablement. Covers April Dunford positioning, ICP definition, competitive battlecards, launch playbooks, and international market entry. Produces deliverables including positioning statements, battlecard documents, launch plans, and go-to-market strategies.

alirezarezvani 4473

paid-ads

When the user wants help with paid advertising campaigns on Google Ads, Meta (Facebook/Instagram), LinkedIn, Twitter/X, or other ad platforms. Also use when the user mentions 'PPC,' 'paid media,' 'ad copy,' 'ad creative,' 'ROAS,' 'CPA,' 'ad campaign,' 'retargeting,' or 'audience targeting.' This skill covers campaign strategy, ad creation, audience targeting, and optimization.

alirezarezvani 4473

qms-audit-expert

ISO 13485 internal audit expertise for medical device QMS. Covers audit planning, execution, nonconformity classification, and CAPA verification. Use for internal audit planning, audit execution, finding classification, external audit preparation, or audit program management.

alirezarezvani 4473

code-reviewer

Code review automation for TypeScript, JavaScript, Python, Go, Swift, Kotlin. Analyzes PRs for complexity and risk, checks code quality for SOLID violations and code smells, generates review reports. Use when reviewing pull requests, analyzing code quality, identifying issues, generating review checklists.

alirezarezvani 4473