Upgrading fastapi 0.128 to 0.129
Breaking0.128.8 → 0.129.2Breaking1Deprecated1Changed2Fixed1Other25
BreakingUpgrade verdict
1 breaking change.
In plain terms
- This version no longer works on Python 3.9; you need Python 3.10 or newer.
- The fastapi-slim package is discontinued. Install fastapi or fastapi[standard] instead.
Must act 2 items need code or config changes
Python requirement changed in 0.129.0: >=3.9 → >=3.10.
What you must change
Breaking1
Drops support for Python 3.9.
Deprecations to plan for
Deprecated1
Drops support for fastapi-slim; no more versions will be released, use "fastapi[standard]" or fastapi.
fastapi-slimfastapi[standard]fastapiAPI changes
Generated by DepDelta from published Python source. Not mixed with prose notes.
- changed:
constructor FastAPI(*, debug: Annotated[bool, Doc('\n Boolean indicating if debug tracebacks should be returned on server\n errors.\n\n Read more in the\n [Starlette docs for Applications](https://www.starlette.dev/applications/#instantiating-the-application).\n ')]=…, routes: Annotated[Optional[list[BaseRoute]], Doc("\n… → constructor FastAPI(*, debug: Annotated[bool, Doc('\n Boolean indicating if debug tracebacks should be returned on server\n errors.\n\n Read more in the\n [Starlette docs for Applications](https://www.starlette.dev/applications/#instantiating-the-application).\n ')]=…, routes: Annotated[list[BaseRoute] | None, Doc("\n… - changed:
method FastAPI.add_api_route(path: str, endpoint: Callable[..., Any], *, response_model: Any=…, status_code: Optional[int]=…, tags: Optional[list[Union[str, Enum]]]=…, dependencies: Optional[Sequence[Depends]]=…, summary: Optional[str]=…, description: Optional[str]=…, response_description: str=…, responses: Optional[dict[Union[int, str], dict[str, Any]]]=…, deprecated: Optional[bool]=…, methods:… → method FastAPI.add_api_route(path: str, endpoint: Callable[..., Any], *, response_model: Any=…, status_code: int | None=…, tags: list[str | Enum] | None=…, dependencies: Sequence[Depends] | None=…, summary: str | None=…, description: str | None=…, response_description: str=…, responses: dict[int | str, dict[str, Any]] | None=…, deprecated: bool | None=…, methods: list[str] | None=…, operation_id:… - changed:
method FastAPI.add_api_websocket_route(path: str, endpoint: Callable[..., Any], name: Optional[str]=…, *, dependencies: Optional[Sequence[Depends]]=…) -> None → method FastAPI.add_api_websocket_route(path: str, endpoint: Callable[..., Any], name: str | None=…, *, dependencies: Sequence[Depends] | None=…) -> None - changed:
method FastAPI.api_route(path: str, *, response_model: Any=…, status_code: Optional[int]=…, tags: Optional[list[Union[str, Enum]]]=…, dependencies: Optional[Sequence[Depends]]=…, summary: Optional[str]=…, description: Optional[str]=…, response_description: str=…, responses: Optional[dict[Union[int, str], dict[str, Any]]]=…, deprecated: Optional[bool]=…, methods: Optional[list[str]]=…, operation_i… → method FastAPI.api_route(path: str, *, response_model: Any=…, status_code: int | None=…, tags: list[str | Enum] | None=…, dependencies: Sequence[Depends] | None=…, summary: str | None=…, description: str | None=…, response_description: str=…, responses: dict[int | str, dict[str, Any]] | None=…, deprecated: bool | None=…, methods: list[str] | None=…, operation_id: str | None=…, response_model_incl… - changed:
method FastAPI.exception_handler(exc_class_or_status_code: Annotated[Union[int, type[Exception]], Doc('\n The Exception class this would handle, or a status code.\n ')]) -> Callable[[DecoratedCallable], DecoratedCallable] → method FastAPI.exception_handler(exc_class_or_status_code: Annotated[int | type[Exception], Doc('\n The Exception class this would handle, or a status code.\n ')]) -> Callable[[DecoratedCallable], DecoratedCallable] - changed:
method FastAPI.include_router(router: Annotated[routing.APIRouter, Doc('The `APIRouter` to include.')], *, prefix: Annotated[str, Doc('An optional path prefix for the router.')]=…, tags: Annotated[Optional[list[Union[str, Enum]]], Doc('\n A list of tags to be applied to all the *path operations* in this\n router.\n\n It will be added to the generated O… → method FastAPI.include_router(router: Annotated[routing.APIRouter, Doc('The `APIRouter` to include.')], *, prefix: Annotated[str, Doc('An optional path prefix for the router.')]=…, tags: Annotated[list[str | Enum] | None, Doc('\n A list of tags to be applied to all the *path operations* in this\n router.\n\n It will be added to the generated OpenAPI (e… - changed:
method FastAPI.websocket(path: Annotated[str, Doc('\n WebSocket path.\n ')], name: Annotated[Optional[str], Doc('\n A name for the WebSocket. Only used internally.\n ')]=…, *, dependencies: Annotated[Optional[Sequence[Depends]], Doc('\n A list of dependencies (using `Depends()`) to be used for this\n WebSock… → method FastAPI.websocket(path: Annotated[str, Doc('\n WebSocket path.\n ')], name: Annotated[str | None, Doc('\n A name for the WebSocket. Only used internally.\n ')]=…, *, dependencies: Annotated[Sequence[Depends] | None, Doc('\n A list of dependencies (using `Depends()`) to be used for this\n WebSocket.\n\… - changed:
method FastAPI.websocket_route(path: str, name: Union[str, None]=…) -> Callable[[DecoratedCallable], DecoratedCallable] → method FastAPI.websocket_route(path: str, name: str | None=…) -> Callable[[DecoratedCallable], DecoratedCallable]
- changed:
field UploadFile.content_type: Annotated[Optional[str], Doc('The content type of the request, from the headers.')] → field UploadFile.content_type: Annotated[str | None, Doc('The content type of the request, from the headers.')] - changed:
field UploadFile.filename: Annotated[Optional[str], Doc('The original file name.')] → field UploadFile.filename: Annotated[str | None, Doc('The original file name.')] - changed:
field UploadFile.size: Annotated[Optional[int], Doc('The size of the file in bytes.')] → field UploadFile.size: Annotated[int | None, Doc('The size of the file in bytes.')]
- removed:
property Dependant.computed_scope -> Union[str, None] - changed:
field Dependant.background_tasks_param_name: Optional[str] → field Dependant.background_tasks_param_name: str | None - changed:
field Dependant.call: Optional[Callable[..., Any]] → field Dependant.call: Callable[..., Any] | None - changed:
field Dependant.http_connection_param_name: Optional[str] → field Dependant.http_connection_param_name: str | None - changed:
field Dependant.name: Optional[str] → field Dependant.name: str | None - changed:
field Dependant.own_oauth_scopes: Optional[list[str]] → field Dependant.own_oauth_scopes: list[str] | None - changed:
field Dependant.parent_oauth_scopes: Optional[list[str]] → field Dependant.parent_oauth_scopes: list[str] | None - changed:
field Dependant.path: Optional[str] → field Dependant.path: str | None - changed:
field Dependant.request_param_name: Optional[str] → field Dependant.request_param_name: str | None - changed:
field Dependant.response_param_name: Optional[str] → field Dependant.response_param_name: str | None - changed:
field Dependant.scope: Union[Literal['function', 'request'], None] → field Dependant.scope: Literal['function', 'request'] | None - changed:
field Dependant.security_scopes_param_name: Optional[str] → field Dependant.security_scopes_param_name: str | None - changed:
field Dependant.websocket_param_name: Optional[str] → field Dependant.websocket_param_name: str | None - added:
property Dependant.computed_scope -> str | None
- changed:
async function request_body_to_args(body_fields: list[ModelField], received_body: Optional[Union[dict[str, Any], FormData]], embed_body_fields: bool) -> tuple[dict[str, Any], list[dict[str, Any]]] → async function request_body_to_args(body_fields: list[ModelField], received_body: dict[str, Any] | FormData | None, embed_body_fields: bool) -> tuple[dict[str, Any], list[dict[str, Any]]] - changed:
async function solve_dependencies(*, request: Union[Request, WebSocket], dependant: Dependant, body: Optional[Union[dict[str, Any], FormData]]=…, background_tasks: Optional[StarletteBackgroundTasks]=…, response: Optional[Response]=…, dependency_overrides_provider: Optional[Any]=…, dependency_cache: Optional[dict[DependencyCacheKey, Any]]=…, async_exit_stack: AsyncExitStack, embed_body_fields: boo… → async function solve_dependencies(*, request: Request | WebSocket, dependant: Dependant, body: dict[str, Any] | FormData | None=…, background_tasks: StarletteBackgroundTasks | None=…, response: Response | None=…, dependency_overrides_provider: Any | None=…, dependency_cache: dict[DependencyCacheKey, Any] | None=…, async_exit_stack: AsyncExitStack, embed_body_fields: bool) -> SolvedDependency - changed:
field ParamDetails.depends: Optional[params.Depends] → field ParamDetails.depends: params.Depends | None - changed:
field ParamDetails.field: Optional[ModelField] → field ParamDetails.field: ModelField | None - changed:
field SolvedDependency.background_tasks: Optional[StarletteBackgroundTasks] → field SolvedDependency.background_tasks: StarletteBackgroundTasks | None - changed:
function add_non_field_param_to_dependency(*, param_name: str, type_annotation: Any, dependant: Dependant) -> Optional[bool] → function add_non_field_param_to_dependency(*, param_name: str, type_annotation: Any, dependant: Dependant) -> bool | None - changed:
function get_body_field(*, flat_dependant: Dependant, name: str, embed_body_fields: bool) -> Optional[ModelField] → function get_body_field(*, flat_dependant: Dependant, name: str, embed_body_fields: bool) -> ModelField | None - changed:
function get_dependant(*, path: str, call: Callable[..., Any], name: Optional[str]=…, own_oauth_scopes: Optional[list[str]]=…, parent_oauth_scopes: Optional[list[str]]=…, use_cache: bool=…, scope: Union[Literal['function', 'request'], None]=…) -> Dependant → function get_dependant(*, path: str, call: Callable[..., Any], name: str | None=…, own_oauth_scopes: list[str] | None=…, parent_oauth_scopes: list[str] | None=…, use_cache: bool=…, scope: Literal['function', 'request'] | None=…) -> Dependant - changed:
function get_flat_dependant(dependant: Dependant, *, skip_repeats: bool=…, visited: Optional[list[DependencyCacheKey]]=…, parent_oauth_scopes: Optional[list[str]]=…) -> Dependant → function get_flat_dependant(dependant: Dependant, *, skip_repeats: bool=…, visited: list[DependencyCacheKey] | None=…, parent_oauth_scopes: list[str] | None=…) -> Dependant - changed:
function request_params_to_args(fields: Sequence[ModelField], received_params: Union[Mapping[str, Any], QueryParams, Headers]) -> tuple[dict[str, Any], list[Any]] → function request_params_to_args(fields: Sequence[ModelField], received_params: Mapping[str, Any] | QueryParams | Headers) -> tuple[dict[str, Any], list[Any]]
- changed:
function decimal_encoder(dec_value: Decimal) -> Union[int, float] → function decimal_encoder(dec_value: Decimal) -> int | float - changed:
function isoformat(o: Union[datetime.date, datetime.time]) -> str → function isoformat(o: datetime.date | datetime.time) -> str - changed:
function jsonable_encoder(obj: Annotated[Any, Doc('\n The input object to convert to JSON.\n ')], include: Annotated[Optional[IncEx], Doc("\n Pydantic's `include` parameter, passed to Pydantic models to set the\n fields to include.\n ")]=…, exclude: Annotated[Optional[IncEx], Doc("\n Pydantic's `exclude` parameter, passed to Pydant… → function jsonable_encoder(obj: Annotated[Any, Doc('\n The input object to convert to JSON.\n ')], include: Annotated[IncEx | None, Doc("\n Pydantic's `include` parameter, passed to Pydantic models to set the\n fields to include.\n ")]=…, exclude: Annotated[IncEx | None, Doc("\n Pydantic's `exclude` parameter, passed to Pydantic mod…
- changed:
constructor RequestValidationError(errors: Sequence[Any], *, body: Any=…, endpoint_ctx: Optional[EndpointContext]=…) -> None → constructor RequestValidationError(errors: Sequence[Any], *, body: Any=…, endpoint_ctx: EndpointContext | None=…) -> None - changed:
constructor ResponseValidationError(errors: Sequence[Any], *, body: Any=…, endpoint_ctx: Optional[EndpointContext]=…) -> None → constructor ResponseValidationError(errors: Sequence[Any], *, body: Any=…, endpoint_ctx: EndpointContext | None=…) -> None - changed:
constructor ValidationException(errors: Sequence[Any], *, endpoint_ctx: Optional[EndpointContext]=…) -> None → constructor ValidationException(errors: Sequence[Any], *, endpoint_ctx: EndpointContext | None=…) -> None - changed:
constructor WebSocketException(code: Annotated[int, Doc('\n A closing code from the\n [valid codes defined in the specification](https://datatracker.ietf.org/doc/html/rfc6455#section-7.4.1).\n ')], reason: Annotated[Union[str, None], Doc('\n The reason to close the WebSocket connection.\n\n It is UTF-8-encoded data. The in… → constructor WebSocketException(code: Annotated[int, Doc('\n A closing code from the\n [valid codes defined in the specification](https://datatracker.ietf.org/doc/html/rfc6455#section-7.4.1).\n ')], reason: Annotated[str | None, Doc('\n The reason to close the WebSocket connection.\n\n It is UTF-8-encoded data. The interpre… - changed:
constructor WebSocketRequestValidationError(errors: Sequence[Any], *, endpoint_ctx: Optional[EndpointContext]=…) -> None → constructor WebSocketRequestValidationError(errors: Sequence[Any], *, endpoint_ctx: EndpointContext | None=…) -> None
- changed:
field Components.callbacks: Optional[dict[str, Union[dict[str, PathItem], Reference, Any]]] → field Components.callbacks: dict[str, dict[str, PathItem] | Reference | Any] | None - changed:
field Components.examples: Optional[dict[str, Union[Example, Reference]]] → field Components.examples: dict[str, Example | Reference] | None - changed:
field Components.headers: Optional[dict[str, Union[Header, Reference]]] → field Components.headers: dict[str, Header | Reference] | None - changed:
field Components.links: Optional[dict[str, Union[Link, Reference]]] → field Components.links: dict[str, Link | Reference] | None - changed:
field Components.parameters: Optional[dict[str, Union[Parameter, Reference]]] → field Components.parameters: dict[str, Parameter | Reference] | None - changed:
field Components.pathItems: Optional[dict[str, Union[PathItem, Reference]]] → field Components.pathItems: dict[str, PathItem | Reference] | None - changed:
field Components.requestBodies: Optional[dict[str, Union[RequestBody, Reference]]] → field Components.requestBodies: dict[str, RequestBody | Reference] | None - changed:
field Components.responses: Optional[dict[str, Union[Response, Reference]]] → field Components.responses: dict[str, Response | Reference] | None - changed:
field Components.schemas: Optional[dict[str, Union[Schema, Reference]]] → field Components.schemas: dict[str, Schema | Reference] | None - changed:
field Components.securitySchemes: Optional[dict[str, Union[SecurityScheme, Reference]]] → field Components.securitySchemes: dict[str, SecurityScheme | Reference] | None - changed:
field Contact.email: Optional[EmailStr] → field Contact.email: EmailStr | None - changed:
field Contact.name: Optional[str] → field Contact.name: str | None - changed:
field Contact.url: Optional[AnyUrl] → field Contact.url: AnyUrl | None - changed:
field Discriminator.mapping: Optional[dict[str, str]] → field Discriminator.mapping: dict[str, str] | None - changed:
field Encoding.allowReserved: Optional[bool] → field Encoding.allowReserved: bool | None - changed:
field Encoding.contentType: Optional[str] → field Encoding.contentType: str | None - changed:
field Encoding.explode: Optional[bool] → field Encoding.explode: bool | None - changed:
field Encoding.headers: Optional[dict[str, Union[Header, Reference]]] → field Encoding.headers: dict[str, Union[Header, Reference]] | None - changed:
field Encoding.style: Optional[str] → field Encoding.style: str | None - changed:
field Example.description: Optional[str] → field Example.description: str | None - changed:
field Example.externalValue: Optional[AnyUrl] → field Example.externalValue: AnyUrl | None - changed:
field Example.summary: Optional[str] → field Example.summary: str | None - changed:
field Example.value: Optional[Any] → field Example.value: Any | None - changed:
field ExternalDocumentation.description: Optional[str] → field ExternalDocumentation.description: str | None - changed:
field HTTPBearer.bearerFormat: Optional[str] → field HTTPBearer.bearerFormat: str | None - changed:
field Info.contact: Optional[Contact] → field Info.contact: Contact | None - changed:
field Info.description: Optional[str] → field Info.description: str | None - changed:
field Info.license: Optional[License] → field Info.license: License | None - changed:
field Info.summary: Optional[str] → field Info.summary: str | None - changed:
field Info.termsOfService: Optional[str] → field Info.termsOfService: str | None - changed:
field License.identifier: Optional[str] → field License.identifier: str | None - changed:
field License.url: Optional[AnyUrl] → field License.url: AnyUrl | None - changed:
field Link.description: Optional[str] → field Link.description: str | None - changed:
field Link.operationId: Optional[str] → field Link.operationId: str | None - changed:
field Link.operationRef: Optional[str] → field Link.operationRef: str | None - changed:
field Link.parameters: Optional[dict[str, Union[Any, str]]] → field Link.parameters: dict[str, Any | str] | None - changed:
field Link.requestBody: Optional[Union[Any, str]] → field Link.requestBody: Any | str | None - changed:
field Link.server: Optional[Server] → field Link.server: Server | None - changed:
field MediaType.encoding: Optional[dict[str, Encoding]] → field MediaType.encoding: dict[str, Encoding] | None - changed:
field MediaType.example: Optional[Any] → field MediaType.example: Any | None - changed:
field MediaType.examples: Optional[dict[str, Union[Example, Reference]]] → field MediaType.examples: dict[str, Example | Reference] | None - changed:
field MediaType.schema_: Optional[Union[Schema, Reference]] → field MediaType.schema_: Schema | Reference | None - changed:
field OAuthFlow.refreshUrl: Optional[str] → field OAuthFlow.refreshUrl: str | None - changed:
field OAuthFlows.authorizationCode: Optional[OAuthFlowAuthorizationCode] → field OAuthFlows.authorizationCode: OAuthFlowAuthorizationCode | None - changed:
field OAuthFlows.clientCredentials: Optional[OAuthFlowClientCredentials] → field OAuthFlows.clientCredentials: OAuthFlowClientCredentials | None - changed:
field OAuthFlows.implicit: Optional[OAuthFlowImplicit] → field OAuthFlows.implicit: OAuthFlowImplicit | None - changed:
field OAuthFlows.password: Optional[OAuthFlowPassword] → field OAuthFlows.password: OAuthFlowPassword | None - changed:
field OpenAPI.components: Optional[Components] → field OpenAPI.components: Components | None - changed:
field OpenAPI.externalDocs: Optional[ExternalDocumentation] → field OpenAPI.externalDocs: ExternalDocumentation | None - changed:
field OpenAPI.jsonSchemaDialect: Optional[str] → field OpenAPI.jsonSchemaDialect: str | None - changed:
field OpenAPI.paths: Optional[dict[str, Union[PathItem, Any]]] → field OpenAPI.paths: dict[str, PathItem | Any] | None - changed:
field OpenAPI.security: Optional[list[dict[str, list[str]]]] → field OpenAPI.security: list[dict[str, list[str]]] | None - changed:
field OpenAPI.servers: Optional[list[Server]] → field OpenAPI.servers: list[Server] | None - changed:
field OpenAPI.tags: Optional[list[Tag]] → field OpenAPI.tags: list[Tag] | None - changed:
field OpenAPI.webhooks: Optional[dict[str, Union[PathItem, Reference]]] → field OpenAPI.webhooks: dict[str, PathItem | Reference] | None - changed:
field Operation.callbacks: Optional[dict[str, Union[dict[str, PathItem], Reference]]] → field Operation.callbacks: dict[str, dict[str, PathItem] | Reference] | None - changed:
field Operation.deprecated: Optional[bool] → field Operation.deprecated: bool | None - changed:
field Operation.description: Optional[str] → field Operation.description: str | None - changed:
field Operation.externalDocs: Optional[ExternalDocumentation] → field Operation.externalDocs: ExternalDocumentation | None - changed:
field Operation.operationId: Optional[str] → field Operation.operationId: str | None - changed:
field Operation.parameters: Optional[list[Union[Parameter, Reference]]] → field Operation.parameters: list[Parameter | Reference] | None - changed:
field Operation.requestBody: Optional[Union[RequestBody, Reference]] → field Operation.requestBody: RequestBody | Reference | None - changed:
field Operation.responses: Optional[dict[str, Union[Response, Any]]] → field Operation.responses: dict[str, Response | Any] | None - changed:
field Operation.security: Optional[list[dict[str, list[str]]]] → field Operation.security: list[dict[str, list[str]]] | None - changed:
field Operation.servers: Optional[list[Server]] → field Operation.servers: list[Server] | None - changed:
field Operation.summary: Optional[str] → field Operation.summary: str | None - changed:
field Operation.tags: Optional[list[str]] → field Operation.tags: list[str] | None - changed:
field ParameterBase.allowReserved: Optional[bool] → field ParameterBase.allowReserved: bool | None - changed:
field ParameterBase.content: Optional[dict[str, MediaType]] → field ParameterBase.content: dict[str, MediaType] | None - changed:
field ParameterBase.deprecated: Optional[bool] → field ParameterBase.deprecated: bool | None - changed:
field ParameterBase.description: Optional[str] → field ParameterBase.description: str | None - changed:
field ParameterBase.example: Optional[Any] → field ParameterBase.example: Any | None - changed:
field ParameterBase.examples: Optional[dict[str, Union[Example, Reference]]] → field ParameterBase.examples: dict[str, Example | Reference] | None - changed:
field ParameterBase.explode: Optional[bool] → field ParameterBase.explode: bool | None - changed:
field ParameterBase.required: Optional[bool] → field ParameterBase.required: bool | None - changed:
field ParameterBase.schema_: Optional[Union[Schema, Reference]] → field ParameterBase.schema_: Schema | Reference | None - changed:
field ParameterBase.style: Optional[str] → field ParameterBase.style: str | None - changed:
field PathItem.delete: Optional[Operation] → field PathItem.delete: Operation | None - changed:
field PathItem.description: Optional[str] → field PathItem.description: str | None - changed:
field PathItem.get: Optional[Operation] → field PathItem.get: Operation | None - changed:
field PathItem.head: Optional[Operation] → field PathItem.head: Operation | None - changed:
field PathItem.options: Optional[Operation] → field PathItem.options: Operation | None - changed:
field PathItem.parameters: Optional[list[Union[Parameter, Reference]]] → field PathItem.parameters: list[Parameter | Reference] | None - changed:
field PathItem.patch: Optional[Operation] → field PathItem.patch: Operation | None - changed:
field PathItem.post: Optional[Operation] → field PathItem.post: Operation | None - changed:
field PathItem.put: Optional[Operation] → field PathItem.put: Operation | None - changed:
field PathItem.ref: Optional[str] → field PathItem.ref: str | None - changed:
field PathItem.servers: Optional[list[Server]] → field PathItem.servers: list[Server] | None - changed:
field PathItem.summary: Optional[str] → field PathItem.summary: str | None - changed:
field PathItem.trace: Optional[Operation] → field PathItem.trace: Operation | None - changed:
field RequestBody.description: Optional[str] → field RequestBody.description: str | None - changed:
field RequestBody.required: Optional[bool] → field RequestBody.required: bool | None - changed:
field Response.content: Optional[dict[str, MediaType]] → field Response.content: dict[str, MediaType] | None - changed:
field Response.headers: Optional[dict[str, Union[Header, Reference]]] → field Response.headers: dict[str, Header | Reference] | None - changed:
field Response.links: Optional[dict[str, Union[Link, Reference]]] → field Response.links: dict[str, Link | Reference] | None - changed:
field Schema.allOf: Optional[list[SchemaOrBool]] → field Schema.allOf: list[SchemaOrBool] | None - changed:
field Schema.anchor: Optional[str] → field Schema.anchor: str | None - changed:
field Schema.anyOf: Optional[list[SchemaOrBool]] → field Schema.anyOf: list[SchemaOrBool] | None - changed:
field Schema.comment: Optional[str] → field Schema.comment: str | None - changed:
field Schema.const: Optional[Any] → field Schema.const: Any | None - changed:
field Schema.contentEncoding: Optional[str] → field Schema.contentEncoding: str | None - changed:
field Schema.contentMediaType: Optional[str] → field Schema.contentMediaType: str | None - changed:
field Schema.default: Optional[Any] → field Schema.default: Any | None - changed:
field Schema.defs: Optional[dict[str, SchemaOrBool]] → field Schema.defs: dict[str, SchemaOrBool] | None - changed:
field Schema.dependentRequired: Optional[dict[str, set[str]]] → field Schema.dependentRequired: dict[str, set[str]] | None - changed:
field Schema.dependentSchemas: Optional[dict[str, SchemaOrBool]] → field Schema.dependentSchemas: dict[str, SchemaOrBool] | None - changed:
field Schema.deprecated: Optional[bool] → field Schema.deprecated: bool | None - changed:
field Schema.description: Optional[str] → field Schema.description: str | None - changed:
field Schema.discriminator: Optional[Discriminator] → field Schema.discriminator: Discriminator | None - changed:
field Schema.dynamicAnchor: Optional[str] → field Schema.dynamicAnchor: str | None - changed:
field Schema.dynamicRef: Optional[str] → field Schema.dynamicRef: str | None - changed:
field Schema.enum: Optional[list[Any]] → field Schema.enum: list[Any] | None - changed:
field Schema.example: Annotated[Optional[Any], typing_deprecated('Deprecated in OpenAPI 3.1.0 that now uses JSON Schema 2020-12, although still supported. Use examples instead.')] → field Schema.example: Annotated[Any | None, typing_deprecated('Deprecated in OpenAPI 3.1.0 that now uses JSON Schema 2020-12, although still supported. Use examples instead.')] - changed:
field Schema.examples: Optional[list[Any]] → field Schema.examples: list[Any] | None - changed:
field Schema.exclusiveMaximum: Optional[float] → field Schema.exclusiveMaximum: float | None - changed:
field Schema.exclusiveMinimum: Optional[float] → field Schema.exclusiveMinimum: float | None - changed:
field Schema.externalDocs: Optional[ExternalDocumentation] → field Schema.externalDocs: ExternalDocumentation | None - changed:
field Schema.format: Optional[str] → field Schema.format: str | None - changed:
field Schema.id: Optional[str] → field Schema.id: str | None - changed:
field Schema.maxContains: Optional[int] → field Schema.maxContains: int | None - changed:
field Schema.maxItems: Optional[int] → field Schema.maxItems: int | None - changed:
field Schema.maxLength: Optional[int] → field Schema.maxLength: int | None - changed:
field Schema.maxProperties: Optional[int] → field Schema.maxProperties: int | None - changed:
field Schema.maximum: Optional[float] → field Schema.maximum: float | None - changed:
field Schema.minContains: Optional[int] → field Schema.minContains: int | None - changed:
field Schema.minItems: Optional[int] → field Schema.minItems: int | None - changed:
field Schema.minLength: Optional[int] → field Schema.minLength: int | None - changed:
field Schema.minProperties: Optional[int] → field Schema.minProperties: int | None - changed:
field Schema.minimum: Optional[float] → field Schema.minimum: float | None - changed:
field Schema.multipleOf: Optional[float] → field Schema.multipleOf: float | None - changed:
field Schema.oneOf: Optional[list[SchemaOrBool]] → field Schema.oneOf: list[SchemaOrBool] | None - changed:
field Schema.pattern: Optional[str] → field Schema.pattern: str | None - changed:
field Schema.patternProperties: Optional[dict[str, SchemaOrBool]] → field Schema.patternProperties: dict[str, SchemaOrBool] | None - changed:
field Schema.prefixItems: Optional[list[SchemaOrBool]] → field Schema.prefixItems: list[SchemaOrBool] | None - changed:
field Schema.properties: Optional[dict[str, SchemaOrBool]] → field Schema.properties: dict[str, SchemaOrBool] | None - changed:
field Schema.readOnly: Optional[bool] → field Schema.readOnly: bool | None - changed:
field Schema.ref: Optional[str] → field Schema.ref: str | None - changed:
field Schema.required: Optional[list[str]] → field Schema.required: list[str] | None - changed:
field Schema.schema_: Optional[str] → field Schema.schema_: str | None - changed:
field Schema.title: Optional[str] → field Schema.title: str | None - changed:
field Schema.type: Optional[Union[SchemaType, list[SchemaType]]] → field Schema.type: SchemaType | list[SchemaType] | None - changed:
field Schema.uniqueItems: Optional[bool] → field Schema.uniqueItems: bool | None - changed:
field Schema.vocabulary: Optional[str] → field Schema.vocabulary: str | None - changed:
field Schema.writeOnly: Optional[bool] → field Schema.writeOnly: bool | None - changed:
field Schema.xml: Optional[XML] → field Schema.xml: XML | None - changed:
field SecurityBase.description: Optional[str] → field SecurityBase.description: str | None - changed:
field Server.description: Optional[str] → field Server.description: str | None - changed:
field Server.url: Union[AnyUrl, str] → field Server.url: AnyUrl | str - changed:
field Server.variables: Optional[dict[str, ServerVariable]] → field Server.variables: dict[str, ServerVariable] | None - changed:
field ServerVariable.description: Optional[str] → field ServerVariable.description: str | None - changed:
field ServerVariable.enum: Annotated[Optional[list[str]], Field(min_length=1)] → field ServerVariable.enum: Annotated[list[str] | None, Field(min_length=1)] - changed:
field Tag.description: Optional[str] → field Tag.description: str | None - changed:
field Tag.externalDocs: Optional[ExternalDocumentation] → field Tag.externalDocs: ExternalDocumentation | None - changed:
field XML.attribute: Optional[bool] → field XML.attribute: bool | None - changed:
field XML.name: Optional[str] → field XML.name: str | None - changed:
field XML.namespace: Optional[str] → field XML.namespace: str | None - changed:
field XML.prefix: Optional[str] → field XML.prefix: str | None - changed:
field XML.wrapped: Optional[bool] → field XML.wrapped: bool | None
- changed:
function get_openapi(*, title: str, version: str, openapi_version: str=…, summary: Optional[str]=…, description: Optional[str]=…, routes: Sequence[BaseRoute], webhooks: Optional[Sequence[BaseRoute]]=…, tags: Optional[list[dict[str, Any]]]=…, servers: Optional[list[dict[str, Union[str, Any]]]]=…, terms_of_service: Optional[str]=…, contact: Optional[dict[str, Union[str, Any]]]=…, license_info: Opti… → function get_openapi(*, title: str, version: str, openapi_version: str=…, summary: str | None=…, description: str | None=…, routes: Sequence[BaseRoute], webhooks: Sequence[BaseRoute] | None=…, tags: list[dict[str, Any]] | None=…, servers: list[dict[str, str | Any]] | None=…, terms_of_service: str | None=…, contact: dict[str, str | Any] | None=…, license_info: dict[str, str | Any] | None=…, separa… - changed:
function get_openapi_operation_request_body(*, body_field: Optional[ModelField], model_name_map: ModelNameMap, field_mapping: dict[tuple[ModelField, Literal['validation', 'serialization']], dict[str, Any]], separate_input_output_schemas: bool=…) -> Optional[dict[str, Any]] → function get_openapi_operation_request_body(*, body_field: ModelField | None, model_name_map: ModelNameMap, field_mapping: dict[tuple[ModelField, Literal['validation', 'serialization']], dict[str, Any]], separate_input_output_schemas: bool=…) -> dict[str, Any] | None
- changed:
function Body(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Union[Callable[[], Any], None], Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\… → function Body(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Callable[[], Any] | None, Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\n… - changed:
function Cookie(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Union[Callable[[], Any], None], Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility… → function Cookie(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Callable[[], Any] | None, Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\n… - changed:
function Depends(dependency: Annotated[Optional[Callable[..., Any]], Doc('\n A "dependable" callable (like a function).\n\n Don\'t call it directly, FastAPI will call it for you, just pass the object\n directly.\n\n Read more about it in the\n [FastAPI docs for Dependencies](https://fastapi.tiangolo.com/tutorial/dependencies/)\n ')… → function Depends(dependency: Annotated[Callable[..., Any] | None, Doc('\n A "dependable" callable (like a function).\n\n Don\'t call it directly, FastAPI will call it for you, just pass the object\n directly.\n\n Read more about it in the\n [FastAPI docs for Dependencies](https://fastapi.tiangolo.com/tutorial/dependencies/)\n ')]=…… - changed:
function File(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Union[Callable[[], Any], None], Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\… → function File(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Callable[[], Any] | None, Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\n… - changed:
function Form(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Union[Callable[[], Any], None], Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\… → function Form(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Callable[[], Any] | None, Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\n… - changed:
function Header(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Union[Callable[[], Any], None], Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility… → function Header(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n ')]=…, *, default_factory: Annotated[Callable[[], Any] | None, Doc("\n A callable to generate the default value.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\n… - changed:
function Path(default: Annotated[Any, Doc("\n Default value if the parameter field is not set.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\n ")]=…, *, default_factory: Annotated[Union[Callable[[], Any], None], Doc("\n A callable to generate the default value.\… → function Path(default: Annotated[Any, Doc("\n Default value if the parameter field is not set.\n\n This doesn't affect `Path` parameters as the value is always required.\n The parameter is available only for compatibility.\n ")]=…, *, default_factory: Annotated[Callable[[], Any] | None, Doc("\n A callable to generate the default value.\n\n… - changed:
function Query(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n\n Read more about it in the\n [FastAPI docs about Query parameters](https://fastapi.tiangolo.com/tutorial/query-params-str-validations/#alternative-old-query-as-the-default-value)\n ')]=…, *, default_factory: Annotated[Union[Callable[[], Any], None], Doc("\… → function Query(default: Annotated[Any, Doc('\n Default value if the parameter field is not set.\n\n Read more about it in the\n [FastAPI docs about Query parameters](https://fastapi.tiangolo.com/tutorial/query-params-str-validations/#alternative-old-query-as-the-default-value)\n ')]=…, *, default_factory: Annotated[Callable[[], Any] | None, Doc("\n… - changed:
function Security(dependency: Annotated[Optional[Callable[..., Any]], Doc('\n A "dependable" callable (like a function).\n\n Don\'t call it directly, FastAPI will call it for you, just pass the object\n directly.\n\n Read more about it in the\n [FastAPI docs for Dependencies](https://fastapi.tiangolo.com/tutorial/dependencies/)\n '… → function Security(dependency: Annotated[Callable[..., Any] | None, Doc('\n A "dependable" callable (like a function).\n\n Don\'t call it directly, FastAPI will call it for you, just pass the object\n directly.\n\n Read more about it in the\n [FastAPI docs for Dependencies](https://fastapi.tiangolo.com/tutorial/dependencies/)\n ')]=…
- changed:
constructor Body(default: Any=…, *, default_factory: Union[Callable[[], Any], None]=…, annotation: Optional[Any]=…, embed: Union[bool, None]=…, media_type: str=…, alias: Optional[str]=…, alias_priority: Union[int, None]=…, validation_alias: Union[str, AliasPath, AliasChoices, None]=…, serialization_alias: Union[str, None]=…, title: Optional[str]=…, description: Optional[str]=…, gt: Optional[float… → constructor Body(default: Any=…, *, default_factory: Callable[[], Any] | None=…, annotation: Any | None=…, embed: bool | None=…, media_type: str=…, alias: str | None=…, alias_priority: int | None=…, validation_alias: str | AliasPath | AliasChoices | None=…, serialization_alias: str | None=…, title: str | None=…, description: str | None=…, gt: float | None=…, ge: float | None=…, lt: float | None=…… - changed:
constructor Cookie(default: Any=…, *, default_factory: Union[Callable[[], Any], None]=…, annotation: Optional[Any]=…, alias: Optional[str]=…, alias_priority: Union[int, None]=…, validation_alias: Union[str, AliasPath, AliasChoices, None]=…, serialization_alias: Union[str, None]=…, title: Optional[str]=…, description: Optional[str]=…, gt: Optional[float]=…, ge: Optional[float]=…, lt: Optional[floa… → constructor Cookie(default: Any=…, *, default_factory: Callable[[], Any] | None=…, annotation: Any | None=…, alias: str | None=…, alias_priority: int | None=…, validation_alias: str | AliasPath | AliasChoices | None=…, serialization_alias: str | None=…, title: str | None=…, description: str | None=…, gt: float | None=…, ge: float | None=…, lt: float | None=…, le: float | None=…, min_length: int |… - changed:
constructor File(default: Any=…, *, default_factory: Union[Callable[[], Any], None]=…, annotation: Optional[Any]=…, media_type: str=…, alias: Optional[str]=…, alias_priority: Union[int, None]=…, validation_alias: Union[str, AliasPath, AliasChoices, None]=…, serialization_alias: Union[str, None]=…, title: Optional[str]=…, description: Optional[str]=…, gt: Optional[float]=…, ge: Optional[float]=…,… → constructor File(default: Any=…, *, default_factory: Callable[[], Any] | None=…, annotation: Any | None=…, media_type: str=…, alias: str | None=…, alias_priority: int | None=…, validation_alias: str | AliasPath | AliasChoices | None=…, serialization_alias: str | None=…, title: str | None=…, description: str | None=…, gt: float | None=…, ge: float | None=…, lt: float | None=…, le: float | None=…,… - changed:
constructor Form(default: Any=…, *, default_factory: Union[Callable[[], Any], None]=…, annotation: Optional[Any]=…, media_type: str=…, alias: Optional[str]=…, alias_priority: Union[int, None]=…, validation_alias: Union[str, AliasPath, AliasChoices, None]=…, serialization_alias: Union[str, None]=…, title: Optional[str]=…, description: Optional[str]=…, gt: Optional[float]=…, ge: Optional[float]=…,… → constructor Form(default: Any=…, *, default_factory: Callable[[], Any] | None=…, annotation: Any | None=…, media_type: str=…, alias: str | None=…, alias_priority: int | None=…, validation_alias: str | AliasPath | AliasChoices | None=…, serialization_alias: str | None=…, title: str | None=…, description: str | None=…, gt: float | None=…, ge: float | None=…, lt: float | None=…, le: float | None=…,… - changed:
constructor Header(default: Any=…, *, default_factory: Union[Callable[[], Any], None]=…, annotation: Optional[Any]=…, alias: Optional[str]=…, alias_priority: Union[int, None]=…, validation_alias: Union[str, AliasPath, AliasChoices, None]=…, serialization_alias: Union[str, None]=…, convert_underscores: bool=…, title: Optional[str]=…, description: Optional[str]=…, gt: Optional[float]=…, ge: Optiona… → constructor Header(default: Any=…, *, default_factory: Callable[[], Any] | None=…, annotation: Any | None=…, alias: str | None=…, alias_priority: int | None=…, validation_alias: str | AliasPath | AliasChoices | None=…, serialization_alias: str | None=…, convert_underscores: bool=…, title: str | None=…, description: str | None=…, gt: float | None=…, ge: float | None=…, lt: float | None=…, le: floa… - changed:
constructor Param(default: Any=…, *, default_factory: Union[Callable[[], Any], None]=…, annotation: Optional[Any]=…, alias: Optional[str]=…, alias_priority: Union[int, None]=…, validation_alias: Union[str, AliasPath, AliasChoices, None]=…, serialization_alias: Union[str, None]=…, title: Optional[str]=…, description: Optional[str]=…, gt: Optional[float]=…, ge: Optional[float]=…, lt: Optional[float… → constructor Param(default: Any=…, *, default_factory: Callable[[], Any] | None=…, annotation: Any | None=…, alias: str | None=…, alias_priority: int | None=…, validation_alias: str | AliasPath | AliasChoices | None=…, serialization_alias: str | None=…, title: str | None=…, description: str | None=…, gt: float | None=…, ge: float | None=…, lt: float | None=…, le: float | None=…, min_length: int |… - changed:
constructor Path(default: Any=…, *, default_factory: Union[Callable[[], Any], None]=…, annotation: Optional[Any]=…, alias: Optional[str]=…, alias_priority: Union[int, None]=…, validation_alias: Union[str, AliasPath, AliasChoices, None]=…, serialization_alias: Union[str, None]=…, title: Optional[str]=…, description: Optional[str]=…, gt: Optional[float]=…, ge: Optional[float]=…, lt: Optional[float]… → constructor Path(default: Any=…, *, default_factory: Callable[[], Any] | None=…, annotation: Any | None=…, alias: str | None=…, alias_priority: int | None=…, validation_alias: str | AliasPath | AliasChoices | None=…, serialization_alias: str | None=…, title: str | None=…, description: str | None=…, gt: float | None=…, ge: float | None=…, lt: float | None=…, le: float | None=…, min_length: int | N… - changed:
constructor Query(default: Any=…, *, default_factory: Union[Callable[[], Any], None]=…, annotation: Optional[Any]=…, alias: Optional[str]=…, alias_priority: Union[int, None]=…, validation_alias: Union[str, AliasPath, AliasChoices, None]=…, serialization_alias: Union[str, None]=…, title: Optional[str]=…, description: Optional[str]=…, gt: Optional[float]=…, ge: Optional[float]=…, lt: Optional[float… → constructor Query(default: Any=…, *, default_factory: Callable[[], Any] | None=…, annotation: Any | None=…, alias: str | None=…, alias_priority: int | None=…, validation_alias: str | AliasPath | AliasChoices | None=…, serialization_alias: str | None=…, title: str | None=…, description: str | None=…, gt: float | None=…, ge: float | None=…, lt: float | None=…, le: float | None=…, min_length: int |… - changed:
field Depends.dependency: Optional[Callable[..., Any]] → field Depends.dependency: Callable[..., Any] | None - changed:
field Depends.scope: Union[Literal['function', 'request'], None] → field Depends.scope: Literal['function', 'request'] | None - changed:
field Security.scopes: Optional[Sequence[str]] → field Security.scopes: Sequence[str] | None
- changed:
async function serialize_response(*, field: Optional[ModelField]=…, response_content: Any, include: Optional[IncEx]=…, exclude: Optional[IncEx]=…, by_alias: bool=…, exclude_unset: bool=…, exclude_defaults: bool=…, exclude_none: bool=…, is_coroutine: bool=…, endpoint_ctx: Optional[EndpointContext]=…) -> Any → async function serialize_response(*, field: ModelField | None=…, response_content: Any, include: IncEx | None=…, exclude: IncEx | None=…, by_alias: bool=…, exclude_unset: bool=…, exclude_defaults: bool=…, exclude_none: bool=…, is_coroutine: bool=…, endpoint_ctx: EndpointContext | None=…) -> Any - changed:
constructor APIRoute(path: str, endpoint: Callable[..., Any], *, response_model: Any=…, status_code: Optional[int]=…, tags: Optional[list[Union[str, Enum]]]=…, dependencies: Optional[Sequence[params.Depends]]=…, summary: Optional[str]=…, description: Optional[str]=…, response_description: str=…, responses: Optional[dict[Union[int, str], dict[str, Any]]]=…, deprecated: Optional[bool]=…, name: Opti… → constructor APIRoute(path: str, endpoint: Callable[..., Any], *, response_model: Any=…, status_code: int | None=…, tags: list[str | Enum] | None=…, dependencies: Sequence[params.Depends] | None=…, summary: str | None=…, description: str | None=…, response_description: str=…, responses: dict[int | str, dict[str, Any]] | None=…, deprecated: bool | None=…, name: str | None=…, methods: set[str] | lis… - changed:
constructor APIRouter(*, prefix: Annotated[str, Doc('An optional path prefix for the router.')]=…, tags: Annotated[Optional[list[Union[str, Enum]]], Doc('\n A list of tags to be applied to all the *path operations* in this\n router.\n\n It will be added to the generated OpenAPI (e.g. visible at `/docs`).\n\n Read more about it in the\n… → constructor APIRouter(*, prefix: Annotated[str, Doc('An optional path prefix for the router.')]=…, tags: Annotated[list[str | Enum] | None, Doc('\n A list of tags to be applied to all the *path operations* in this\n router.\n\n It will be added to the generated OpenAPI (e.g. visible at `/docs`).\n\n Read more about it in the\n… - changed:
constructor APIWebSocketRoute(path: str, endpoint: Callable[..., Any], *, name: Optional[str]=…, dependencies: Optional[Sequence[params.Depends]]=…, dependency_overrides_provider: Optional[Any]=…) -> None → constructor APIWebSocketRoute(path: str, endpoint: Callable[..., Any], *, name: str | None=…, dependencies: Sequence[params.Depends] | None=…, dependency_overrides_provider: Any | None=…) -> None - changed:
function get_request_handler(dependant: Dependant, body_field: Optional[ModelField]=…, status_code: Optional[int]=…, response_class: Union[type[Response], DefaultPlaceholder]=…, response_field: Optional[ModelField]=…, response_model_include: Optional[IncEx]=…, response_model_exclude: Optional[IncEx]=…, response_model_by_alias: bool=…, response_model_exclude_unset: bool=…, response_model_exclude_d… → function get_request_handler(dependant: Dependant, body_field: ModelField | None=…, status_code: int | None=…, response_class: type[Response] | DefaultPlaceholder=…, response_field: ModelField | None=…, response_model_include: IncEx | None=…, response_model_exclude: IncEx | None=…, response_model_by_alias: bool=…, response_model_exclude_unset: bool=…, response_model_exclude_defaults: bool=…, resp… - changed:
function get_websocket_app(dependant: Dependant, dependency_overrides_provider: Optional[Any]=…, embed_body_fields: bool=…) -> Callable[[WebSocket], Coroutine[Any, Any, Any]] → function get_websocket_app(dependant: Dependant, dependency_overrides_provider: Any | None=…, embed_body_fields: bool=…) -> Callable[[WebSocket], Coroutine[Any, Any, Any]] - changed:
function request_response(func: Callable[[Request], Union[Awaitable[Response], Response]]) -> ASGIApp → function request_response(func: Callable[[Request], Awaitable[Response] | Response]) -> ASGIApp - changed:
method APIRouter.add_api_route(path: str, endpoint: Callable[..., Any], *, response_model: Any=…, status_code: Optional[int]=…, tags: Optional[list[Union[str, Enum]]]=…, dependencies: Optional[Sequence[params.Depends]]=…, summary: Optional[str]=…, description: Optional[str]=…, response_description: str=…, responses: Optional[dict[Union[int, str], dict[str, Any]]]=…, deprecated: Optional[bool]=…,… → method APIRouter.add_api_route(path: str, endpoint: Callable[..., Any], *, response_model: Any=…, status_code: int | None=…, tags: list[str | Enum] | None=…, dependencies: Sequence[params.Depends] | None=…, summary: str | None=…, description: str | None=…, response_description: str=…, responses: dict[int | str, dict[str, Any]] | None=…, deprecated: bool | None=…, methods: set[str] | list[str] | N… - changed:
method APIRouter.add_api_websocket_route(path: str, endpoint: Callable[..., Any], name: Optional[str]=…, *, dependencies: Optional[Sequence[params.Depends]]=…) -> None → method APIRouter.add_api_websocket_route(path: str, endpoint: Callable[..., Any], name: str | None=…, *, dependencies: Sequence[params.Depends] | None=…) -> None - changed:
method APIRouter.api_route(path: str, *, response_model: Any=…, status_code: Optional[int]=…, tags: Optional[list[Union[str, Enum]]]=…, dependencies: Optional[Sequence[params.Depends]]=…, summary: Optional[str]=…, description: Optional[str]=…, response_description: str=…, responses: Optional[dict[Union[int, str], dict[str, Any]]]=…, deprecated: Optional[bool]=…, methods: Optional[list[str]]=…, op… → method APIRouter.api_route(path: str, *, response_model: Any=…, status_code: int | None=…, tags: list[str | Enum] | None=…, dependencies: Sequence[params.Depends] | None=…, summary: str | None=…, description: str | None=…, response_description: str=…, responses: dict[int | str, dict[str, Any]] | None=…, deprecated: bool | None=…, methods: list[str] | None=…, operation_id: str | None=…, response_m… - changed:
method APIRouter.include_router(router: Annotated[APIRouter, Doc('The `APIRouter` to include.')], *, prefix: Annotated[str, Doc('An optional path prefix for the router.')]=…, tags: Annotated[Optional[list[Union[str, Enum]]], Doc('\n A list of tags to be applied to all the *path operations* in this\n router.\n\n It will be added to the generated OpenAPI… → method APIRouter.include_router(router: Annotated[APIRouter, Doc('The `APIRouter` to include.')], *, prefix: Annotated[str, Doc('An optional path prefix for the router.')]=…, tags: Annotated[list[str | Enum] | None, Doc('\n A list of tags to be applied to all the *path operations* in this\n router.\n\n It will be added to the generated OpenAPI (e.g. vi… - changed:
method APIRouter.route(path: str, methods: Optional[Collection[str]]=…, name: Optional[str]=…, include_in_schema: bool=…) -> Callable[[DecoratedCallable], DecoratedCallable] → method APIRouter.route(path: str, methods: Collection[str] | None=…, name: str | None=…, include_in_schema: bool=…) -> Callable[[DecoratedCallable], DecoratedCallable] - changed:
method APIRouter.websocket(path: Annotated[str, Doc('\n WebSocket path.\n ')], name: Annotated[Optional[str], Doc('\n A name for the WebSocket. Only used internally.\n ')]=…, *, dependencies: Annotated[Optional[Sequence[params.Depends]], Doc('\n A list of dependencies (using `Depends()`) to be used for this\n… → method APIRouter.websocket(path: Annotated[str, Doc('\n WebSocket path.\n ')], name: Annotated[str | None, Doc('\n A name for the WebSocket. Only used internally.\n ')]=…, *, dependencies: Annotated[Sequence[params.Depends] | None, Doc('\n A list of dependencies (using `Depends()`) to be used for this\n WebS… - changed:
method APIRouter.websocket_route(path: str, name: Union[str, None]=…) -> Callable[[DecoratedCallable], DecoratedCallable] → method APIRouter.websocket_route(path: str, name: str | None=…) -> Callable[[DecoratedCallable], DecoratedCallable]
- changed:
constructor APIKeyBase(location: APIKeyIn, name: str, description: Union[str, None], scheme_name: Union[str, None], auto_error: bool) → constructor APIKeyBase(location: APIKeyIn, name: str, description: str | None, scheme_name: str | None, auto_error: bool) - changed:
constructor APIKeyCookie(*, name: Annotated[str, Doc('Cookie name.')], scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[Optional[str], Doc('\n Security scheme description.\n\n It will be included i… → constructor APIKeyCookie(*, name: Annotated[str, Doc('Cookie name.')], scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[str | None, Doc('\n Security scheme description.\n\n It will be included in the… - changed:
constructor APIKeyHeader(*, name: Annotated[str, Doc('Header name.')], scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[Optional[str], Doc('\n Security scheme description.\n\n It will be included i… → constructor APIKeyHeader(*, name: Annotated[str, Doc('Header name.')], scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[str | None, Doc('\n Security scheme description.\n\n It will be included in the… - changed:
constructor APIKeyQuery(*, name: Annotated[str, Doc('Query parameter name.')], scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[Optional[str], Doc('\n Security scheme description.\n\n It will be in… → constructor APIKeyQuery(*, name: Annotated[str, Doc('Query parameter name.')], scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[str | None, Doc('\n Security scheme description.\n\n It will be included… - changed:
method APIKeyBase.check_api_key(api_key: Optional[str]) -> Optional[str] → method APIKeyBase.check_api_key(api_key: str | None) -> str | None
- changed:
constructor HTTPBase(*, scheme: str, scheme_name: Optional[str]=…, description: Optional[str]=…, auto_error: bool=…) → constructor HTTPBase(*, scheme: str, scheme_name: str | None=…, description: str | None=…, auto_error: bool=…) - changed:
constructor HTTPBasic(*, scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, realm: Annotated[Optional[str], Doc('\n HTTP Basic authentication realm.\n ')]=…, description: Annotated[Optional[str], Doc('\n Sec… → constructor HTTPBasic(*, scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, realm: Annotated[str | None, Doc('\n HTTP Basic authentication realm.\n ')]=…, description: Annotated[str | None, Doc('\n Security sch… - changed:
constructor HTTPBearer(*, bearerFormat: Annotated[Optional[str], Doc('Bearer token format.')]=…, scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[Optional[str], Doc('\n Security scheme description.\n\n… → constructor HTTPBearer(*, bearerFormat: Annotated[str | None, Doc('Bearer token format.')]=…, scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[str | None, Doc('\n Security scheme description.\n\n It w… - changed:
constructor HTTPDigest(*, scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[Optional[str], Doc('\n Security scheme description.\n\n It will be included in the generated OpenAPI (e.g. visible at `/do… → constructor HTTPDigest(*, scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[str | None, Doc('\n Security scheme description.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\…
- changed:
constructor OAuth2(*, flows: Annotated[Union[OAuthFlowsModel, dict[str, dict[str, Any]]], Doc('\n The dictionary of OAuth2 flows.\n ')]=…, scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[Optional[… → constructor OAuth2(*, flows: Annotated[OAuthFlowsModel | dict[str, dict[str, Any]], Doc('\n The dictionary of OAuth2 flows.\n ')]=…, scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[str | None, Doc('\… - changed:
constructor OAuth2AuthorizationCodeBearer(authorizationUrl: str, tokenUrl: Annotated[str, Doc('\n The URL to obtain the OAuth2 token.\n ')], refreshUrl: Annotated[Optional[str], Doc('\n The URL to refresh the token and obtain a new one.\n ')]=…, scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n… → constructor OAuth2AuthorizationCodeBearer(authorizationUrl: str, tokenUrl: Annotated[str, Doc('\n The URL to obtain the OAuth2 token.\n ')], refreshUrl: Annotated[str | None, Doc('\n The URL to refresh the token and obtain a new one.\n ')]=…, scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n… - changed:
constructor OAuth2PasswordRequestForm(*, grant_type: Annotated[Union[str, None], Form(pattern='^password$'), Doc('\n The OAuth2 spec says it is required and MUST be the fixed string\n "password". Nevertheless, this dependency class is permissive and\n allows not passing it. If you want to enforce it, use instead the\n `OAuth2PasswordRequ… → constructor OAuth2PasswordRequestForm(*, grant_type: Annotated[str | None, Form(pattern='^password$'), Doc('\n The OAuth2 spec says it is required and MUST be the fixed string\n "password". Nevertheless, this dependency class is permissive and\n allows not passing it. If you want to enforce it, use instead the\n `OAuth2PasswordRequestFor… - changed:
constructor SecurityScopes(scopes: Annotated[Optional[list[str]], Doc('\n This will be filled by FastAPI.\n ')]=…) → constructor SecurityScopes(scopes: Annotated[list[str] | None, Doc('\n This will be filled by FastAPI.\n ')]=…)
- changed:
constructor OpenIdConnect(*, openIdConnectUrl: Annotated[str, Doc('\n The OpenID Connect URL.\n ')], scheme_name: Annotated[Optional[str], Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[Optional[str], Doc('\n Security scheme d… → constructor OpenIdConnect(*, openIdConnectUrl: Annotated[str, Doc('\n The OpenID Connect URL.\n ')], scheme_name: Annotated[str | None, Doc('\n Security scheme name.\n\n It will be included in the generated OpenAPI (e.g. visible at `/docs`).\n ')]=…, description: Annotated[str | None, Doc('\n Security scheme descrip…
- changed:
function get_authorization_scheme_param(authorization_header_value: Optional[str]) -> tuple[str, str] → function get_authorization_scheme_param(authorization_header_value: str | None) -> tuple[str, str]
- changed:
function create_model_field(name: str, type_: Any, default: Optional[Any]=…, field_info: Optional[FieldInfo]=…, alias: Optional[str]=…, mode: Literal['validation', 'serialization']=…) -> ModelField → function create_model_field(name: str, type_: Any, default: Any | None=…, field_info: FieldInfo | None=…, alias: str | None=…, mode: Literal['validation', 'serialization']=…) -> ModelField - changed:
function get_value_or_default(first_item: Union[DefaultPlaceholder, DefaultType], *extra_items: Union[DefaultPlaceholder, DefaultType]) -> Union[DefaultPlaceholder, DefaultType] → function get_value_or_default(first_item: DefaultPlaceholder | DefaultType, *extra_items: DefaultPlaceholder | DefaultType) -> DefaultPlaceholder | DefaultType - changed:
function is_body_allowed_for_status_code(status_code: Union[int, str, None]) -> bool → function is_body_allowed_for_status_code(status_code: int | str | None) -> bool