Search Options

Results per page
Sort
Preferred Languages
Advance

Results 571 - 580 of 849 for Pydantics (0.21 sec)

  1. tests/test_tutorial/test_header_params/test_tutorial002_py310.py

                                        "title": "Strange Header",
                                    }
                                )
                                | IsDict(
                                    # TODO: remove when deprecating Pydantic v1
                                    {"title": "Strange Header", "type": "string"}
                                ),
                                "name": "strange_header",
                                "in": "header",
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 4.2K bytes
    - Viewed (0)
  2. tests/test_tutorial/test_header_params/test_tutorial003_an.py

                                        ],
                                    }
                                )
                                | IsDict(
                                    # TODO: remove when deprecating Pydantic v1
                                    {
                                        "title": "X-Token",
                                        "type": "array",
                                        "items": {"type": "string"},
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 4.1K bytes
    - Viewed (0)
  3. docs/ja/docs/how-to/conditional-openapi.md

    * リクエストボディとレスポンスのためのPydanticモデルの定義を見直す。
    * 依存関係に基づきすべての必要なパーミッションとロールを設定する。
    * パスワードを絶対に平文で保存しない。パスワードハッシュのみを保存する。
    * PasslibやJWTトークンに代表される、よく知られた暗号化ツールを使って実装する。
    * そして必要なところでは、もっと細かいパーミッション制御をOAuth2スコープを使って行う。
    * など
    
    それでも、例えば本番環境のような特定の環境のみで、あるいは環境変数の設定によってAPIドキュメントをどうしても無効にしたいという、非常に特殊なユースケースがあるかもしれません。
    
    ## 設定と環境変数による条件付き OpenAPI
    
    生成するOpenAPIとドキュメントUIの構成は、共通のPydanticの設定を使用して簡単に切り替えられます。
    
    例えば、
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  4. docs_src/schema_extra_example/tutorial005_py310.py

    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: Item = Body(
            openapi_examples={
                "normal": {
                    "summary": "A normal example",
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat Aug 26 18:03:13 UTC 2023
    - 1.3K bytes
    - Viewed (0)
  5. docs_src/path_operation_configuration/tutorial005.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.post(
        "/items/",
        response_model=Item,
        summary="Create an item",
        response_description="The created item",
    )
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sat May 14 11:59:59 UTC 2022
    - 741 bytes
    - Viewed (0)
  6. docs/es/docs/tutorial/path-params.md

    De la misma manera hay muchas herramientas compatibles. Incluyendo herramientas de generación de código para muchos lenguajes.
    
    ## Pydantic
    
    Toda la validación de datos es realizada tras bastidores por <a href="https://docs.pydantic.dev/" class="external-link" target="_blank">Pydantic</a>, así que obtienes todos sus beneficios. Así sabes que estás en buenas manos.
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 9.4K bytes
    - Viewed (0)
  7. docs/em/docs/how-to/conditional-openapi.md

    * ⚒ 💭 👆 ✔️ 👍 🔬 Pydantic 🏷 👆 📨 💪 &amp; 📨.
    * 🔗 🙆 ✔ ✔ &amp; 🔑 ⚙️ 🔗.
    * 🙅 🏪 🔢 🔐, 🕴 🔐#️⃣.
    * 🛠️ &amp; ⚙️ 👍-💭 🔐 🧰, 💖 🇸🇲 &amp; 🥙 🤝, ♒️.
    * 🚮 🌅 🧽 ✔ 🎛 ⏮️ Oauth2️⃣ ↔ 🌐❔ 💪.
    * ...♒️.
    
    👐, 👆 5️⃣📆 ✔️ 📶 🎯 ⚙️ 💼 🌐❔ 👆 🤙 💪 ❎ 🛠️ 🩺 🌐 (✅ 🏭) ⚖️ ⚓️ 🔛 📳 ⚪️➡️ 🌐 🔢.
    
    ## 🎲 🗄 ⚪️➡️ ⚒ &amp; 🇨🇻 {
    
    👆 💪 💪 ⚙️ 🎏 Pydantic ⚒ 🔗 👆 🏗 🗄 &amp; 🩺 ⚜.
    
    🖼:
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 2K bytes
    - Viewed (0)
  8. tests/test_tutorial/test_response_model/test_tutorial006_py310.py

                    "Item": {
                        "title": "Item",
                        "required": IsOneOf(
                            ["name", "description", "price", "tax"],
                            # TODO: remove when deprecating Pydantic v1
                            ["name", "price"],
                        ),
                        "type": "object",
                        "properties": {
                            "name": {"title": "Name", "type": "string"},
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Aug 04 20:47:07 UTC 2023
    - 6.2K bytes
    - Viewed (0)
  9. tests/test_response_model_data_filter_no_inheritance.py

    from typing import List
    
    from fastapi import FastAPI
    from fastapi.testclient import TestClient
    from pydantic import BaseModel
    
    app = FastAPI()
    
    
    class UserCreate(BaseModel):
        email: str
        password: str
    
    
    class UserDB(BaseModel):
        email: str
        hashed_password: str
    
    
    class User(BaseModel):
        email: str
    
    
    class PetDB(BaseModel):
        name: str
        owner: UserDB
    
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 1.7K bytes
    - Viewed (0)
  10. tests/test_tutorial/test_body_nested_models/test_tutorial009.py

                        "input": "foo",
                    }
                ]
            }
        ) | IsDict(
            # TODO: remove when deprecating Pydantic v1
            {
                "detail": [
                    {
                        "loc": ["body", "__key__"],
                        "msg": "value is not a valid integer",
                        "type": "type_error.integer",
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Thu Apr 18 19:40:57 UTC 2024
    - 4.2K bytes
    - Viewed (0)
Back to top