| name | api-doc-auditor |
|---|---|
| description | Use when REST or Kafka contracts change and you need OpenAPI and AsyncAPI to stay aligned with source annotations and runtime docs. |
Use when endpoints, DTOs, error contracts, event payloads, or topics change and you need to keep generated API documentation accurate.
- source annotations and config under
application/src/main/java/... README.mdonly when access URLs or user-facing documentation behavior changes
- changes to
@RestControllerendpoints, request or response DTOs, orProblemDetailresponses - changes to Kafka publishers or listeners, topics, payloads, or retry behavior
- checking whether Swagger or Springwolf output still matches the code
- identifying missing or stale OpenAPI or AsyncAPI annotations
- Changed controller, listener, publisher, DTO, or config files
- Expected HTTP contract or event contract
- Any new status codes, fields, channels, or payload semantics
- Audit REST sources first: controller mappings, DTO fields, validation annotations, error handlers, and
OpenApiConfig. - Audit async sources next:
@AsyncPublisher,@AsyncListener,@AsyncOperation, topic names, and payload records or DTOs. - Prefer fixing the source-of-truth code and annotations instead of editing generated specs.
- Keep access paths accurate:
/swagger-ui.html,/v3/api-docs,/springwolf/asyncapi-ui.html, and/springwolf/docs. - Update durable docs only when the public interface or documented access pattern truly changed.
- Mismatch list between code and generated docs
- Source changes needed to restore alignment
- Any README or durable-documentation follow-up that is actually justified
- Do not hand-edit generated OpenAPI or AsyncAPI output.
- Keep DTO naming, JSON property mappings, and payload shapes aligned with runtime serialization.
- Make public contract changes explicit; do not rely on defaults when annotations would clarify behavior.
- Prefer source fixes over documentation-only patches.
- Use the running application and generated docs only as verification; the source code remains authoritative.