Skip to content

Commit 420c941

Browse files
committed
build: serve openapi.json under /api endpoint
1 parent 606cc60 commit 420c941

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

main.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
OPENAI_THREAD_ID = os.getenv("OPENAI_THREAD_ID")
1515
OPENAI_ASSISTANT_ID = os.getenv("OPENAI_ASSISTANT_ID")
1616

17-
app = FastAPI(docs_url="/api/docs/", redoc_url="/api/redoc/")
17+
app = FastAPI(
18+
docs_url="/api/docs/", redoc_url="/api/redoc/", openapi_url="/api/openapi.json"
19+
)
1820

1921
app.add_middleware(
2022
CORSMiddleware,

0 commit comments

Comments
 (0)