pythonasyncioapiasyncfastapiframeworkjsonjson-schemaopenapiopenapi3pydanticpython-typespython3redocreststarletteswaggerswagger-uiuvicornweb
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
991 B
991 B
Middleware
There are several middlewares available provided by Starlette directly.
Read more about them in the FastAPI docs for Middleware.
::: fastapi.middleware.cors.CORSMiddleware
It can be imported from fastapi
:
from fastapi.middleware.cors import CORSMiddleware
::: fastapi.middleware.gzip.GZipMiddleware
It can be imported from fastapi
:
from fastapi.middleware.gzip import GZipMiddleware
::: fastapi.middleware.httpsredirect.HTTPSRedirectMiddleware
It can be imported from fastapi
:
from fastapi.middleware.httpsredirect import HTTPSRedirectMiddleware
::: fastapi.middleware.trustedhost.TrustedHostMiddleware
It can be imported from fastapi
:
from fastapi.middleware.trustedhost import TrustedHostMiddleware
::: fastapi.middleware.wsgi.WSGIMiddleware
It can be imported from fastapi
:
from fastapi.middleware.wsgi import WSGIMiddleware