From 54b6cd782d7f756153cead1c9edcdd03cb4dc9d0 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Tue, 17 Mar 2026 22:59:47 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=A8=20Auto=20format?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- docs/en/docs/tutorial/path-params.md | 2 +- docs_src/path_params/tutorial006_py310.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/docs/en/docs/tutorial/path-params.md b/docs/en/docs/tutorial/path-params.md index 8909124799..f405547220 100644 --- a/docs/en/docs/tutorial/path-params.md +++ b/docs/en/docs/tutorial/path-params.md @@ -250,7 +250,7 @@ And you only have to declare them once. That's probably the main visible advantage of **FastAPI** compared to alternative frameworks (apart from the raw performance). -### Path Parameters with Validation { #path-params-validation } +### Path Parameters with Validation { #path-parameters-with-validation } You can also add validation to your path parameters using Path. diff --git a/docs_src/path_params/tutorial006_py310.py b/docs_src/path_params/tutorial006_py310.py index 083be07c43..e0e8c1be6e 100644 --- a/docs_src/path_params/tutorial006_py310.py +++ b/docs_src/path_params/tutorial006_py310.py @@ -2,6 +2,7 @@ from fastapi import FastAPI, Path app = FastAPI() + @app.get("/items/{item_id}") def read_item(item_id: int = Path(..., ge=1, le=1000)): - return {"item_id": item_id} \ No newline at end of file + return {"item_id": item_id}