Skip to content

[Feature]: Add OpenAPI Schema Export and Interactive Swagger Documentation #153

Description

@adepat06

Problem Statement

While exploring Eagle and reviewing the repository, I could not find any interactive API documentation or a clearly exposed OpenAPI/Swagger interface for the backend services.

At the moment, contributors often need to look through route definitions and source files to understand available endpoints, request parameters, and response formats. This can make onboarding and development slower, especially for contributors working on integrations, testing, frontend features, or backend services.

Providing interactive API documentation would make it easier to discover and test endpoints, improve the developer experience, and help new contributors understand the system more quickly.

Proposed Solution

A possible solution would be to expose interactive API documentation using FastAPI's built-in OpenAPI support.

This could include:

  • Enabling Swagger UI (/docs) for exploring available endpoints.
  • Providing an OpenAPI schema (openapi.json) that can be used for integrations and API testing.
  • Adding summaries, descriptions, and response models to important routes where needed.
  • Optionally enabling ReDoc (/redoc) for a cleaner documentation view.

With this in place, contributors and developers would be able to view available endpoints, understand request/response formats, and test APIs directly from the browser without having to inspect the source code for every route.

Affected Component

Backend API (FastAPI — apps/backend/)

Estimated Difficulty

🟡 Intermediate — Requires understanding of one service

Alternatives Considered

Currently, contributors can inspect route definitions directly in the source code or rely on existing documentation to understand how the APIs work.

Another option would be to maintain separate API documentation manually, but this can easily become outdated as endpoints evolve over time.

Using FastAPI's built-in OpenAPI support would provide automatically generated documentation that stays synchronized with the actual API implementation.

Additional Context

While exploring the repository, I searched for references to Swagger/OpenAPI support (e.g., swagger, openapi, docs_url, and redoc) but could not find an existing implementation or related issue.

FastAPI already provides built-in support for OpenAPI schema generation and interactive documentation, which could make this enhancement relatively straightforward while significantly improving the developer experience.

Reference:
https://fastapi.tiangolo.com/features/

Contribution

  • I would like to implement this feature and submit a PR.

Checklist

  • I have searched existing issues and this is not a duplicate.
  • I have read the CONTRIBUTING.md guidelines.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions