- Sort Score
- Result 10 results
- Languages All
Results 81 - 90 of 2,649 for ID (0.14 sec)
-
docs/he/docs/index.md
@app.get("/") def read_root(): return {"Hello": "World"} @app.get("/items/{item_id}") def read_item(item_id: int, q: Union[str, None] = None): return {"item_id": item_id, "q": q} @app.put("/items/{item_id}") def update_item(item_id: int, item: Item): return {"item_name": item.name, "item_id": item_id} ```
Plain Text - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Thu Apr 18 23:58:47 GMT 2024 - 21.2K bytes - Viewed (0) -
docs_src/schema_extra_example/tutorial003_an_py310.py
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( examples=[ { "name": "Foo", "description": "A very nice Item",
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jun 30 18:25:16 GMT 2023 - 673 bytes - Viewed (0) -
docs_src/schema_extra_example/tutorial003.py
@app.put("/items/{item_id}") async def update_item( item_id: int, item: Item = Body( examples=[ { "name": "Foo", "description": "A very nice Item", "price": 35.4, "tax": 3.2, } ], ), ): results = {"item_id": item_id, "item": item}
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Jun 30 18:25:16 GMT 2023 - 612 bytes - Viewed (0) -
docs_src/body_multiple_params/tutorial003_an_py310.py
tax: float | None = None class User(BaseModel): username: str full_name: str | None = None @app.put("/items/{item_id}") async def update_item( item_id: int, item: Item, user: User, importance: Annotated[int, Body()] ): results = {"item_id": item_id, "item": item, "user": user, "importance": importance}
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Sat Mar 18 12:29:59 GMT 2023 - 550 bytes - Viewed (0) -
docs/zh/docs/advanced/generate-clients.md
...这是因为客户端生成器为每个 *路径操作* 使用OpenAPI的内部 **操作 ID(operation ID)**。 OpenAPI要求每个操作 ID 在所有 *路径操作* 中都是唯一的,因此 FastAPI 使用**函数名**、**路径**和**HTTP方法/操作**来生成此操作ID,因为这样可以确保这些操作 ID 是唯一的。 但接下来我会告诉你如何改进。 🤓 ## 自定义操作ID和更好的方法名 您可以**修改**这些操作ID的**生成**方式,以使其更简洁,并在客户端中具有**更简洁的方法名称**。 在这种情况下,您必须确保每个操作ID在其他方面是**唯一**的。 例如,您可以确保每个*路径操作*都有一个标签,然后根据**标签**和*路径操作***名称**(函数名)来生成操作ID。 ### 自定义生成唯一ID函数
Plain Text - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Wed Apr 03 03:42:11 GMT 2024 - 9.1K bytes - Viewed (0) -
guava-gwt/pom.xml
<repositories> <repository> <id>sonatype-google-snapshots</id> <name>sonatype-google-snapshots</name> <url>https://oss.sonatype.org/content/repositories/google-snapshots/</url> <snapshots> <enabled>true</enabled> </snapshots> </repository> </repositories> <pluginRepositories> <pluginRepository> <id>sonatype-snapshots</id> <name>sonatype-snapshots</name>
XML - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Thu Apr 11 15:00:55 GMT 2024 - 19.8K bytes - Viewed (0) -
docs_src/body_multiple_params/tutorial004.py
class User(BaseModel): username: str full_name: Union[str, None] = None @app.put("/items/{item_id}") async def update_item( *, item_id: int, item: Item, user: User, importance: int = Body(gt=0), q: Union[str, None] = None, ): results = {"item_id": item_id, "item": item, "user": user, "importance": importance} if q: results.update({"q": q})
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri Mar 10 18:49:18 GMT 2023 - 653 bytes - Viewed (0) -
docs_src/body_multiple_params/tutorial004_an_py39.py
class User(BaseModel): username: str full_name: Union[str, None] = None @app.put("/items/{item_id}") async def update_item( *, item_id: int, item: Item, user: User, importance: Annotated[int, Body(gt=0)], q: Union[str, None] = None, ): results = {"item_id": item_id, "item": item, "user": user, "importance": importance} if q: results.update({"q": q})
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Sat Mar 18 12:29:59 GMT 2023 - 674 bytes - Viewed (0) -
docs_src/body_fields/tutorial001.py
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Fri May 13 23:38:22 GMT 2022 - 561 bytes - Viewed (0) -
docs_src/python_types/tutorial011_py39.py
from pydantic import BaseModel class User(BaseModel): id: int name: str = "John Doe" signup_ts: Union[datetime, None] = None friends: list[int] = [] external_data = { "id": "123", "signup_ts": "2017-06-01 12:22", "friends": [1, "2", b"3"], } user = User(**external_data) print(user) # > User id=123 name='John Doe' signup_ts=datetime.datetime(2017, 6, 1, 12, 22) friends=[1, 2, 3]
Python - Registered: Sun May 05 07:19:11 GMT 2024 - Last Modified: Sat Sep 02 15:56:35 GMT 2023 - 492 bytes - Viewed (0)