- Sort Score
- Result 10 results
- Languages All
Results 71 - 80 of 177 for Tax (0.02 sec)
-
tests/test_tutorial/test_body_multiple_params/test_tutorial004.py
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Fri Dec 26 10:43:02 UTC 2025 - 9.3K bytes - Viewed (0) -
tests/test_pydanticv2_dataclasses_uuid_stringified_annotations.py
from inline_snapshot import snapshot @dataclass class Item: id: uuid.UUID name: str price: float tags: list[str] = field(default_factory=list) description: Union[str, None] = None tax: Union[float, None] = None app = FastAPI() @app.get("/item", response_model=Item) async def read_item(): return { "id": uuid.uuid4(), "name": "Island In The Moon",Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 21:25:59 UTC 2025 - 1.1K bytes - Viewed (0) -
docs_src/schema_extra_example/tutorial005_an_py310.py
from typing import Annotated from fastapi import Body, FastAPI from pydantic import BaseModel app = FastAPI() class Item(BaseModel): name: str description: str | None = None price: float tax: float | None = None @app.put("/items/{item_id}") async def update_item( *, item_id: int, item: Annotated[ Item, Body( openapi_examples={
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Aug 26 18:03:13 UTC 2023 - 1.5K bytes - Viewed (0) -
docs_src/schema_extra_example/tutorial005_py39.py
from typing import Union from fastapi import Body, FastAPI from pydantic import BaseModel app = FastAPI() class Item(BaseModel): name: str description: Union[str, None] = None price: float tax: Union[float, None] = None @app.put("/items/{item_id}") async def update_item( *, item_id: int, item: Item = Body( openapi_examples={ "normal": {
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Wed Dec 17 20:41:43 UTC 2025 - 1.4K bytes - Viewed (0) -
tests/test_tutorial/test_body_multiple_params/test_tutorial003.py
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 18:19:10 UTC 2025 - 7.4K bytes - Viewed (0) -
docs/ko/docs/tutorial/body-multiple-params.md
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Mon Nov 18 02:25:44 UTC 2024 - 5.1K bytes - Viewed (0) -
docs/zh/docs/tutorial/body-multiple-params.md
```JSON hl_lines="2" { "item": { "name": "Foo", "description": "The pretender", "price": 42.0, "tax": 3.2 } } ``` 而不是: ```JSON { "name": "Foo", "description": "The pretender", "price": 42.0, "tax": 3.2 } ``` ## 总结 你可以添加多个请求体参数到*路径操作函数*中,即使一个请求只能有一个请求体。 但是 **FastAPI** 会处理它,在函数中为你提供正确的数据,并在*路径操作*中校验并记录正确的模式。Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Mon Nov 18 02:25:44 UTC 2024 - 4.7K bytes - Viewed (0) -
tests/test_tutorial/test_response_model/test_tutorial005.py
"title": "Description", "anyOf": [{"type": "string"}, {"type": "null"}], }, "tax": {"title": "Tax", "type": "number", "default": 10.5}, }, }, "ValidationError": { "title": "ValidationError",
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 18:19:10 UTC 2025 - 6.5K bytes - Viewed (0) -
tests/test_tutorial/test_response_model/test_tutorial006.py
"title": "Description", "anyOf": [{"type": "string"}, {"type": "null"}], }, "tax": {"title": "Tax", "type": "number", "default": 10.5}, }, }, "ValidationError": { "title": "ValidationError",
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Sat Dec 27 18:19:10 UTC 2025 - 6.5K bytes - Viewed (0) -
docs/ko/docs/tutorial/response-model.md
"price": 62, "tax": 20.2 } ``` 응답에 해당 값들이 포함됩니다. #### 기본값과 동일한 값을 갖는 데이터 If the data has the same values as the default ones, like the item with ID `baz`: ID가 `baz`인 항목(items)처럼 기본값과 동일한 값을 갖는다면: ```Python hl_lines="3 5-6" { "name": "Baz", "description": None, "price": 50.2, "tax": 10.5, "tags": [] } ```
Registered: Sun Dec 28 07:19:09 UTC 2025 - Last Modified: Mon Nov 18 02:25:44 UTC 2024 - 7.9K bytes - Viewed (0)