Skip to content

feat: add utoipa OpenAPI spec and Swagger UI at /docs (Closes #30) - #61

Open
ZacLou wants to merge 2 commits into
StellarRoute:mainfrom
ZacLou:feat/issue-30-openapi-swagger
Open

feat: add utoipa OpenAPI spec and Swagger UI at /docs (Closes #30)#61
ZacLou wants to merge 2 commits into
StellarRoute:mainfrom
ZacLou:feat/issue-30-openapi-swagger

Conversation

@ZacLou

@ZacLou ZacLou commented Aug 27, 2026

Copy link
Copy Markdown

Closes #30

Changes

Adds OpenAPI 3.0 specification and Swagger UI to the WaveFlow API:

  • Cargo.toml: Added utoipa v5 (with axum_extras) and utoipa-swagger-ui v9 dependencies
  • mod.rs:
    • Added #[derive(OpenApi)] struct ApiDoc documenting all public endpoints and schemas
    • Merged SwaggerUi at /docs serving interactive API docs
    • OpenAPI JSON available at /api-docs/openapi.json

Documented endpoints

  • GET /health — Health check
  • GET /ready — Readiness check
  • GET /api/v1/programs — List programs
  • GET /api/v1/programs/:id — Get program details
  • GET /api/v1/programs/:id/payouts — List program payouts
  • GET /api/v1/programs/:id/contributors — List program contributors

Documented schemas

  • ProgramRecord, ContributorRecord, PayoutRecord, ProgramStatus

Access Swagger UI at http://localhost:<port>/docs after startup.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[api] Add utoipa OpenAPI spec and Swagger UI at /docs

1 participant