Skip to content
This repository was archived by the owner on Jun 5, 2025. It is now read-only.

Commit cd892f3

Browse files
authored
Don't include provider routes in OpenAPI schema (#639)
For all providers, this ensures that their routes are not included in FastAPI's auto-generated OpenAPI schema. Signed-off-by: Juan Antonio Osorio <[email protected]>
1 parent b68186c commit cd892f3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/codegate/providers/registry.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ def add_provider(self, name: str, provider: BaseProvider):
1616
to the FastAPI app.
1717
"""
1818
self.providers[name] = provider
19-
self.app.include_router(provider.get_routes())
19+
self.app.include_router(provider.get_routes(), include_in_schema=False)
2020

2121
def get_provider(self, name: str) -> Optional[BaseProvider]:
2222
"""

0 commit comments

Comments
 (0)