Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Swagger UI Config #2523

@mjhea0

Description

@mjhea0

Hello, I wrote the https://testdriven.io/courses/tdd-fastapi/ course and I get asked a lot about how to customize Swagger UI. I see questions like this on Reddit a lot too: https://www.reddit.com/r/FastAPI/comments/kdrk2r/how_do_i_disable_try_it_out_in_swagger_docs/

Anyway, I wonder if it's worth adding the ability to customize Swagger UI even more? https://github.com/swagger-api/swagger-ui/blob/master/docs/usage/configuration.md

These look like relevant issues and PRs:

  1. Enable showCommonExtensions for Swagger UI #372
  2. Enable showCommonExtensions and showExtensions in SwaggerUI #1466
  3. Enable support for multiple request body "examples" in openapi / swagger ui docs #822

Here's how Flask-RESTX handles it: https://flask-restx.readthedocs.io/en/latest/swagger.html#configuring-try-it-out

Happy to help work on this if someone can provide a bit of direction. Cheers!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions