applications.py — fastapi Source File
Architecture documentation for applications.py, a python file in the fastapi codebase. 42 imports, 1 dependents.
Entity Profile
Dependency Diagram
graph LR 6c1867f2_34c4_b2ed_5639_41766e6fd7ce["applications.py"] 07d79a2e_d4e9_0bbb_be90_936274444c8c["collections.abc"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 07d79a2e_d4e9_0bbb_be90_936274444c8c 712b7268_fde0_3ca8_dc06_7aa9a47c77d9["enum"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 712b7268_fde0_3ca8_dc06_7aa9a47c77d9 0dda2280_3359_8460_301c_e98c77e78185["typing"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 0dda2280_3359_8460_301c_e98c77e78185 5efacb44_5373_ceb9_9579_6e6603820488["annotated_doc"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 5efacb44_5373_ceb9_9579_6e6603820488 534f6e44_61b8_3c38_8b89_6934a6df9802["__init__.py"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 534f6e44_61b8_3c38_8b89_6934a6df9802 de395a51_26f8_3424_1af0_2f5bef39c893["routing.py"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> de395a51_26f8_3424_1af0_2f5bef39c893 dc4a1804_f7b4_848b_3280_30523680d7b9["datastructures.py"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> dc4a1804_f7b4_848b_3280_30523680d7b9 28261a63_2ba9_f1ff_1d1b_475348a45a65["Default"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 28261a63_2ba9_f1ff_1d1b_475348a45a65 c509eb0b_23fb_fa54_c7e7_d4bec7d2f3a9["DefaultPlaceholder"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> c509eb0b_23fb_fa54_c7e7_d4bec7d2f3a9 2d259205_f589_7dee_455a_60e1c67ed35e["exception_handlers.py"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 2d259205_f589_7dee_455a_60e1c67ed35e b7aaa327_256c_826b_6da4_7f2714292af0["http_exception_handler"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> b7aaa327_256c_826b_6da4_7f2714292af0 2d028bc8_34b4_6303_1406_f7c12b4394e6["request_validation_exception_handler"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 2d028bc8_34b4_6303_1406_f7c12b4394e6 1d7ecc02_0319_a836_bffe_6f17ba1fc0ac["websocket_request_validation_exception_handler"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 1d7ecc02_0319_a836_bffe_6f17ba1fc0ac 01c652c5_d85c_f45e_848e_412c94ea4172["exceptions.py"] 6c1867f2_34c4_b2ed_5639_41766e6fd7ce --> 01c652c5_d85c_f45e_848e_412c94ea4172 style 6c1867f2_34c4_b2ed_5639_41766e6fd7ce fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
from collections.abc import Awaitable, Coroutine, Sequence
from enum import Enum
from typing import (
Annotated,
Any,
Callable,
Optional,
TypeVar,
Union,
)
from annotated_doc import Doc
from fastapi import routing
from fastapi.datastructures import Default, DefaultPlaceholder
from fastapi.exception_handlers import (
http_exception_handler,
request_validation_exception_handler,
websocket_request_validation_exception_handler,
)
from fastapi.exceptions import RequestValidationError, WebSocketRequestValidationError
from fastapi.logger import logger
from fastapi.middleware.asyncexitstack import AsyncExitStackMiddleware
from fastapi.openapi.docs import (
get_redoc_html,
get_swagger_ui_html,
get_swagger_ui_oauth2_redirect_html,
)
from fastapi.openapi.utils import get_openapi
from fastapi.params import Depends
from fastapi.types import DecoratedCallable, IncEx
from fastapi.utils import generate_unique_id
from starlette.applications import Starlette
from starlette.datastructures import State
from starlette.exceptions import HTTPException
from starlette.middleware import Middleware
from starlette.middleware.base import BaseHTTPMiddleware
from starlette.middleware.errors import ServerErrorMiddleware
from starlette.middleware.exceptions import ExceptionMiddleware
from starlette.requests import Request
from starlette.responses import HTMLResponse, JSONResponse, Response
from starlette.routing import BaseRoute
from starlette.types import ASGIApp, ExceptionHandler, Lifespan, Receive, Scope, Send
from typing_extensions import deprecated
AppType = TypeVar("AppType", bound="FastAPI")
class FastAPI(Starlette):
"""
`FastAPI` app class, the main entrypoint to use FastAPI.
Read more in the
[FastAPI docs for First Steps](https://fastapi.tiangolo.com/tutorial/first-steps/).
## Example
```python
from fastapi import FastAPI
app = FastAPI()
// ... (4613 more lines)
Domain
Subdomains
Classes
Dependencies
- AsyncExitStackMiddleware
- Default
- DefaultPlaceholder
- Depends
- RequestValidationError
- WebSocketRequestValidationError
- __init__.py
- annotated_doc
- asyncexitstack.py
- collections.abc
- datastructures.py
- docs.py
- enum
- exception_handlers.py
- exceptions.py
- generate_unique_id
- get_openapi
- get_redoc_html
- get_swagger_ui_html
- get_swagger_ui_oauth2_redirect_html
- http_exception_handler
- logger.py
- params.py
- request_validation_exception_handler
- routing.py
- starlette.applications
- starlette.datastructures
- starlette.exceptions
- starlette.middleware
- starlette.middleware.base
- starlette.middleware.errors
- starlette.middleware.exceptions
- starlette.requests
- starlette.responses
- starlette.routing
- starlette.types
- types.py
- typing
- typing_extensions
- utils.py
- utils.py
- websocket_request_validation_exception_handler
Imported By
Source
Frequently Asked Questions
What does applications.py do?
applications.py is a source file in the fastapi codebase, written in python. It belongs to the FastAPI domain, Applications subdomain.
What does applications.py depend on?
applications.py imports 42 module(s): AsyncExitStackMiddleware, Default, DefaultPlaceholder, Depends, RequestValidationError, WebSocketRequestValidationError, __init__.py, annotated_doc, and 34 more.
What files import applications.py?
applications.py is imported by 1 file(s): __init__.py.
Where is applications.py in the architecture?
applications.py is located at fastapi/applications.py (domain: FastAPI, subdomain: Applications, directory: fastapi).
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free