Search Options

Results per page
Sort
Preferred Languages
Advance

Results 41 - 50 of 587 for Junior (0.17 sec)

  1. docs_src/body/tutorial001.py

    from typing import Union
    
    from fastapi import FastAPI
    from pydantic import BaseModel
    
    
    class Item(BaseModel):
        name: str
        description: Union[str, None] = None
        price: float
        tax: Union[float, None] = None
    
    
    app = FastAPI()
    
    
    @app.post("/items/")
    async def create_item(item: Item):
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Sat May 14 11:59:59 GMT 2022
    - 309 bytes
    - Viewed (0)
  2. docs_src/body_multiple_params/tutorial001_an_py39.py

    from typing import Annotated, Union
    
    from fastapi import FastAPI, Path
    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: Annotated[int, Path(title="The ID of the item to get", ge=0, le=1000)],
        q: Union[str, None] = None,
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Sat Mar 18 12:29:59 GMT 2023
    - 610 bytes
    - Viewed (0)
  3. docs_src/nosql_databases/tutorial001.py

        bucket.timeout = 30
        bucket.n1ql_timeout = 300
        return bucket
    
    
    class User(BaseModel):
        username: str
        email: Union[str, None] = None
        full_name: Union[str, None] = None
        disabled: Union[bool, None] = None
    
    
    class UserInDB(User):
        type: str = USERPROFILE_DOC_TYPE
        hashed_password: str
    
    
    def get_user(bucket: Bucket, username: str):
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Sat May 14 11:59:59 GMT 2022
    - 1.3K bytes
    - Viewed (0)
  4. docs_src/body_multiple_params/tutorial005_an_py39.py

    from typing import Annotated, 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: Annotated[Item, Body(embed=True)]):
        results = {"item_id": item_id, "item": item}
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Sat Mar 18 12:29:59 GMT 2023
    - 428 bytes
    - Viewed (0)
  5. docs_src/body_nested_models/tutorial003.py

    from typing import Set, Union
    
    from fastapi import FastAPI
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        name: str
        description: Union[str, None] = None
        price: float
        tax: Union[float, None] = None
        tags: Set[str] = set()
    
    
    @app.put("/items/{item_id}")
    async def update_item(item_id: int, item: Item):
        results = {"item_id": item_id, "item": item}
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Sat May 14 11:59:59 GMT 2022
    - 414 bytes
    - Viewed (0)
  6. docs_src/path_operation_configuration/tutorial001_py39.py

    from typing import Union
    
    from fastapi import FastAPI, status
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        name: str
        description: Union[str, None] = None
        price: float
        tax: Union[float, None] = None
        tags: set[str] = set()
    
    
    @app.post("/items/", response_model=Item, status_code=status.HTTP_201_CREATED)
    async def create_item(item: Item):
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Sat May 14 11:59:59 GMT 2022
    - 401 bytes
    - Viewed (0)
  7. docs_src/body_multiple_params/tutorial005.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(embed=True)):
        results = {"item_id": item_id, "item": item}
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Fri May 13 23:38:22 GMT 2022
    - 407 bytes
    - Viewed (0)
  8. .github/actions/notify-translations/app/main.py

    def get_graphql_response(
        *,
        settings: Settings,
        query: str,
        after: Union[str, None] = None,
        category_id: Union[str, None] = None,
        discussion_number: Union[int, None] = None,
        discussion_id: Union[str, None] = None,
        comment_id: Union[str, None] = None,
        body: Union[str, None] = None,
    ) -> Dict[str, Any]:
        headers = {"Authorization": f"token {settings.input_token.get_secret_value()}"}
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Wed Sep 27 23:01:46 GMT 2023
    - 12.4K bytes
    - Viewed (0)
  9. docs_src/schema_extra_example/tutorial001_pv1.py

    from typing import Union
    
    from fastapi import FastAPI
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    class Item(BaseModel):
        name: str
        description: Union[str, None] = None
        price: float
        tax: Union[float, None] = None
    
        class Config:
            schema_extra = {
                "examples": [
                    {
                        "name": "Foo",
                        "description": "A very nice Item",
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Fri Jul 07 17:12:13 GMT 2023
    - 669 bytes
    - Viewed (0)
  10. docs_src/query_params_str_validations/tutorial009.py

    from typing import Union
    
    from fastapi import FastAPI, Query
    
    app = FastAPI()
    
    
    @app.get("/items/")
    async def read_items(q: Union[str, None] = Query(default=None, alias="item-query")):
        results = {"items": [{"item_id": "Foo"}, {"item_id": "Bar"}]}
        if q:
            results.update({"q": q})
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Fri May 13 23:38:22 GMT 2022
    - 313 bytes
    - Viewed (0)
Back to top