Skip to content

Commit

Permalink
fix(backend): exclude EventSource status endpoint from OpenAPI
Browse files Browse the repository at this point in the history
Signed-off-by: Jordan Shatford <jordanshatford@live.com>
  • Loading branch information
jordanshatford committed Aug 19, 2023
1 parent 3d47055 commit efe44a4
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 41 deletions.
40 changes: 0 additions & 40 deletions backend/openapi.json
Original file line number Diff line number Diff line change
Expand Up @@ -143,46 +143,6 @@
}
}
},
"/downloads/status": {
"get": {
"tags": [
"downloads"
],
"summary": "Get Downloads Status",
"operationId": "get_downloads_status",
"parameters": [
{
"name": "sessionId",
"in": "query",
"required": true,
"schema": {
"type": "string",
"title": "Sessionid"
}
}
],
"responses": {
"200": {
"description": "Successful Response",
"content": {
"application/json": {
"schema": {}
}
}
},
"422": {
"description": "Validation Error",
"content": {
"application/json": {
"schema": {
"$ref": "#/components/schemas/HTTPValidationError"
}
}
}
}
}
}
},
"/downloads/{video_id}": {
"get": {
"tags": [
Expand Down
2 changes: 1 addition & 1 deletion backend/routers/downloads.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ async def status_stream(request: Request, session_id: str):
session_manager.remove(session_id)


@router.get('/downloads/status', tags=['downloads'])
@router.get('/downloads/status', tags=['downloads'], include_in_schema=False)
async def get_downloads_status(request: Request, sessionId: str):
event_source = status_stream(request, session_id=sessionId)
return EventSourceResponse(event_source)
Expand Down

0 comments on commit efe44a4

Please sign in to comment.