api-docs

Regenerate OpenAPI specifications from JSDoc annotations and schema changes.

Updated Sep 21, 2025
One-click install
npx skills add https://github.com/hmjn023/solid-imager --skill api-docs-hmjn023
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: api-docs
Source: https://github.com/hmjn023/solid-imager/tree/main/.opencode/skills/api-docs
Command: npx skills add https://github.com/hmjn023/solid-imager --skill api-docs-hmjn023

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Keeping API documentation up to date as endpoints and data schemas evolve, so teams can rely on accurate specs.

Core Features & Use Cases

  • Regenerate the OpenAPI spec automatically when code comments or schemas change.
  • Validate that apps/server/public/openapi.json reflects current routers and schemas.
  • Use for CI/CD checks to ensure docs stay in sync before deployments.

Quick Start

Update JSDoc comments and run the generation command to refresh OpenAPI docs.

Frequently Asked Questions about api-docs

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

FAQPage Schema
How do I keep OpenAPI specifications in sync with code changes automatically?

To keep OpenAPI specifications in sync with code, this skill automates regenerating the openapi.json file whenever API endpoints or data schemas change using bun gen:spec. It relies on JSDoc annotations to ensure documentation reflects current routers and schemas accurately.

How do I validate that my OpenAPI spec reflects current routers and schemas before deployment?

You can validate that your OpenAPI spec reflects current routers by running the generation workflow in CI/CD checks. The skill uses the bun --filter @solid-imager/server gen:spec command to rebuild apps/server/public/openapi.json, ensuring docs stay synchronized before deployments.

Can I use JSDoc annotations to generate OpenAPI documentation with Bun?

Yes, you can use JSDoc annotations to generate OpenAPI documentation with Bun. The skill processes JSDoc comments from routers under apps/server/src/infrastructure/api/routers and shared schemas under packages/core to rebuild the OpenAPI specification.

What is the best way to automate API documentation generation for shared schemas?

The best way to automate API documentation generation for shared schemas is using a dedicated generation command. This skill applies the bun gen:spec workflow to rebuild the OpenAPI spec, ensuring that schema updates under packages/core are reflected in apps/server/public/openapi.json.

Do I need to manually update openapi.json when API endpoints change?

No, you do not need to manually update openapi.json when API endpoints change. The skill automates regenerating the OpenAPI specification by running bun gen:spec, which rebuilds the documentation based on updated JSDoc comments and data schemas.