Skip to content

Response Schema, Fastapi Streaming Responses for Documentation #11552

Discussion options

You must be logged in to vote

Hi!

If you are talking about clarifications for people who read docs, then you can add the description for 200 response:

@app.get("/test", responses={200: {"description": "Successfull response will return a stream of JSON objects"}, 500: {"model": ErrorModel}})

And if you are talking about specifying response type for client code generators, it requires more investigation..
Have you read discussions below?
OAI/OpenAPI-Specification#1576
OAI/OpenAPI-Specification#3730
OAI/OpenAPI-Specification#3769

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@anantgupta129
Comment options

@YuriiMotov
Comment options

@anantgupta129
Comment options

@YuriiMotov
Comment options

Answer selected by anantgupta129
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Question or problem
3 participants