- Sort Score
- Result 10 results
- Languages All
Results 301 - 310 of 540 for item_c (0.07 sec)
-
docs_src/path_operation_advanced_configuration/tutorial001_py39.py
from fastapi import FastAPI app = FastAPI() @app.get("/items/", operation_id="some_specific_id_you_define") async def read_items():
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 167 bytes - Viewed (0) -
docs/de/docs/tutorial/handling-errors.md
### Die resultierende Response { #the-resulting-response } Wenn der Client `http://example.com/items/foo` anfordert (ein `item_id` `"foo"`), erhält dieser Client einen HTTP-Statuscode 200 und diese JSON-Response: ```JSON { "item": "The Foo Wrestlers" } ``` Aber wenn der Client `http://example.com/items/bar` anfordert (ein nicht-existierendes `item_id` `"bar"`), erhält er einen HTTP-Statuscode 404 (der „Not Found“-Error) und eine JSON-Response wie:Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 10.4K bytes - Viewed (0) -
docs_src/custom_response/tutorial001b_py39.py
from fastapi import FastAPI from fastapi.responses import ORJSONResponse app = FastAPI() @app.get("/items/", response_class=ORJSONResponse) async def read_items():
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 215 bytes - Viewed (0) -
docs/de/docs/python-types.md
{* ../../docs_src/python_types/tutorial007_py39.py hl[1] *} Das bedeutet: * Die Variable `items_t` ist ein `tuple` mit 3 Elementen, einem `int`, einem weiteren `int` und einem `str`. * Die Variable `items_s` ist ein `set`, und jedes seiner Elemente ist vom Typ `bytes`. #### Dict { #dict }Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 17.9K bytes - Viewed (1) -
docs/de/docs/tutorial/query-params.md
Wenn Sie nun zu: ``` http://127.0.0.1:8000/items/foo?short=1 ``` oder ``` http://127.0.0.1:8000/items/foo?short=True ``` oder ``` http://127.0.0.1:8000/items/foo?short=true ``` oder ``` http://127.0.0.1:8000/items/foo?short=on ``` oder ``` http://127.0.0.1:8000/items/foo?short=yes ```
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 5K bytes - Viewed (0) -
tests/test_tutorial/test_path_operation_advanced_configurations/test_tutorial003.py
from docs_src.path_operation_advanced_configuration.tutorial003_py39 import app client = TestClient(app) def test_get(): response = client.get("/items/") assert response.status_code == 200, response.text assert response.json() == [{"item_id": "Foo"}] def test_openapi_schema(): response = client.get("/openapi.json") assert response.status_code == 200, response.text assert response.json() == {
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 580 bytes - Viewed (0) -
docs/zh/docs/tutorial/handling-errors.md
在介绍依赖项与安全的章节中,您可以了解更多用 `raise` 异常代替 `return` 值的优势。 本例中,客户端用 `ID` 请求的 `item` 不存在时,触发状态码为 `404` 的异常: {* ../../docs_src/handling_errors/tutorial001.py hl[11] *} ### 响应结果 请求为 `http://example.com/items/foo`(`item_id` 为 `「foo」`)时,客户端会接收到 HTTP 状态码 - 200 及如下 JSON 响应结果: ```JSON { "item": "The Foo Wrestlers" } ``` 但如果客户端请求 `http://example.com/items/bar`(`item_id` `「bar」` 不存在时),则会接收到 HTTP 状态码 - 404(「未找到」错误)及如下 JSON 响应结果:Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Oct 11 17:48:49 UTC 2025 - 8.2K bytes - Viewed (0) -
docs_src/custom_response/tutorial001_py39.py
from fastapi import FastAPI from fastapi.responses import UJSONResponse app = FastAPI() @app.get("/items/", response_class=UJSONResponse) async def read_items():
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 197 bytes - Viewed (0) -
tests/benchmarks/test_general_performance.py
class LargeOut(BaseModel): items: list[dict[str, Any]] metadata: dict[str, Any] app = FastAPI() @app.post("/sync/validated", response_model=ItemOut) def sync_validated(item: ItemIn, dep: Annotated[int, Depends(dep_b)]): return ItemOut(name=item.name, value=item.value, dep=dep) @app.get("/sync/dict-no-response-model") def sync_dict_no_response_model(): return {"name": "foo", "value": 123}
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 20:40:26 UTC 2025 - 11.1K bytes - Viewed (0) -
docs/fr/docs/python-types.md
/// Ce qui signifie : "la variable `items` est une `list`, et chacun de ses éléments a pour type `str`. En faisant cela, votre éditeur pourra vous aider, même pendant que vous traitez des éléments de la liste. <img src="/img/python-types/image05.png"> Sans types, c'est presque impossible à réaliser. Vous remarquerez que la variable `item` n'est qu'un des éléments de la list `items`.
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Nov 09 16:39:20 UTC 2024 - 10K bytes - Viewed (0)