
Description
golang-swagger is an agent skill for adding OpenAPI and Swagger documentation to a Go API using the swaggo/swag tool. It tells the agent how to write the annotation comments that swag reads, such as @Summary, @Param, @Success, @Router and @Security, so that each handler describes its inputs, responses and authentication. The skill then covers running swag init to generate the documentation files, and wiring a Swagger UI endpoint into the server so the docs can be opened in a browser. It works in two modes. Build mode is for adding Swagger to a new or existing Go project: set up the toolchain, annotate the handlers, generate the docs and expose the UI. Audit mode reviews existing annotations for completeness, correctness and security coverage, so missing or wrong responses can be found before they break an integration. The skill treats the documentation as a contract that API consumers rely on. It is part of the samber cc-skills-golang collection and is added to a compatible agent with the skills command. Go is required, and the swag command is installed with go install.…
Highlights
- Writes swaggo annotation comments for handlers
- Generates docs with swag init
- Wires a Swagger UI endpoint into the server
- Audit mode checks existing annotations
Ratings & Reviews
No ratings yet
Be the first to rate golang-swagger.
People also visit
golang-swagger FAQ
What does golang-swagger do?
It guides an agent through adding Swagger or OpenAPI documentation to a Go API that uses swaggo/swag, from annotations to generated docs and a UI endpoint.
Which annotations does it cover?
Annotation comments such as @Summary, @Param, @Success, @Router and @Security, which describe each handler's inputs, responses and authentication.
What are the two modes?
Build mode adds Swagger to a project. Audit mode reviews existing annotations for completeness, correctness and security coverage.
What do I need first?
A Go project and the swag command, which is installed with go install github.com/swaggo/swag/cmd/swag@latest.
How do I install the skill?
Run: npx skills add https://github.com/samber/cc-skills-golang --skill golang-swagger
What security audits has it passed?
Gen Agent Trust Hub, Socket and Snyk all passed.
What are the best golang-swagger alternatives?
Popular alternatives to golang-swagger include golang-graphql, agent-docs-api-openapi and golang-documentation. See all golang-swagger alternatives







