Browse Source

Fix docstring of `servers` parameter

pull/14405/head
Yurii Motov 8 months ago
parent
commit
972c0c507d
  1. 6
      fastapi/applications.py

6
fastapi/applications.py

@ -301,7 +301,11 @@ class FastAPI(Starlette):
browser tabs open). Or if you want to leave fixed the possible URLs. browser tabs open). Or if you want to leave fixed the possible URLs.
If the servers `list` is not provided, or is an empty `list`, the If the servers `list` is not provided, or is an empty `list`, the
default value would be a `dict` with a `url` value of `/`. `servers` property in the generated OpenAPI will be:
* a `dict` with a `url` value of application's mounting point
(`root_path`) if it's different from `/`.
* otherwise, `servers` property will be omitted from the OpenAPI schema.
Each item in the `list` is a `dict` containing: Each item in the `list` is a `dict` containing:

Loading…
Cancel
Save