- Sort Score
- Num 10 results
- Language All
Results 101 - 110 of 730 for item_a (0.04 seconds)
-
docs_src/body_updates/tutorial001_py310.py
} @app.get("/items/{item_id}", response_model=Item) async def read_item(item_id: str): return items[item_id] @app.put("/items/{item_id}", response_model=Item) async def update_item(item_id: str, item: Item): update_item_encoded = jsonable_encoder(item) items[item_id] = update_item_encoded
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Fri Jan 07 14:11:31 GMT 2022 - 856 bytes - Click Count (0) -
docs_src/query_params_str_validations/tutorial003_py310.py
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Fri May 13 23:38:22 GMT 2022 - 290 bytes - Click Count (0) -
docs_src/query_params_str_validations/tutorial003_an_py39.py
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 343 bytes - Click Count (0) -
docs_src/query_params_str_validations/tutorial007_an_py39.py
from typing import Annotated, Union from fastapi import FastAPI, Query app = FastAPI() @app.get("/items/") async def read_items( q: Annotated[Union[str, None], Query(title="Query string", min_length=3)] = None, ): results = {"items": [{"item_id": "Foo"}, {"item_id": "Bar"}]} if q: results.update({"q": q})
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Tue Mar 26 16:56:53 GMT 2024 - 350 bytes - Click Count (0) -
README.md
app = FastAPI() class Item(BaseModel): name: str price: float is_offer: Union[bool, None] = None @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):
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Thu Dec 25 11:01:37 GMT 2025 - 26.4K bytes - Click Count (0) -
docs_src/additional_responses/tutorial003_py39.py
from pydantic import BaseModel class Item(BaseModel): id: str value: str class Message(BaseModel): message: str app = FastAPI() @app.get( "/items/{item_id}", response_model=Item, responses={ 404: {"model": Message, "description": "The item was not found"}, 200: { "description": "Item requested by ID", "content": {Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 837 bytes - Click Count (0) -
docs/pt/docs/tutorial/query-params.md
Nesse caso, se vocĂȘ for para: ``` http://127.0.0.1:8000/items/foo?short=1 ``` ou ``` http://127.0.0.1:8000/items/foo?short=True ``` ou ``` http://127.0.0.1:8000/items/foo?short=true ``` ou ``` http://127.0.0.1:8000/items/foo?short=on ``` ou ``` http://127.0.0.1:8000/items/foo?short=yes ```
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 5K bytes - Click Count (0) -
docs/es/docs/tutorial/query-params.md
En este caso, si vas a: ``` http://127.0.0.1:8000/items/foo?short=1 ``` o ``` http://127.0.0.1:8000/items/foo?short=True ``` o ``` http://127.0.0.1:8000/items/foo?short=true ``` o ``` http://127.0.0.1:8000/items/foo?short=on ``` o ``` http://127.0.0.1:8000/items/foo?short=yes ```
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 4.8K bytes - Click Count (0) -
tests/test_tutorial/test_path_operation_advanced_configurations/test_tutorial002.py
from docs_src.path_operation_advanced_configuration.tutorial002_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() == {
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 1K bytes - Click Count (0) -
docs_src/path_params/tutorial001_py39.py
Created: Sun Dec 28 07:19:09 GMT 2025 - Last Modified: Wed Dec 17 20:41:43 GMT 2025 - 138 bytes - Click Count (0)