Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 28 of 28 for Tag (0.16 sec)

  1. docs/en/docs/tutorial/path-operation-configuration.md

    <img src="/img/tutorial/path-operation-configuration/image01.png">
    
    ### Tags with Enums
    
    If you have a big application, you might end up accumulating **several tags**, and you would want to make sure you always use the **same tag** for related *path operations*.
    
    In these cases, it could make sense to store the tags in an `Enum`.
    
    **FastAPI** supports that the same way as with plain strings:
    
    ```Python hl_lines="1  8-10  13  18"
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Oct 17 05:59:11 GMT 2023
    - 5.5K bytes
    - Viewed (0)
  2. fastapi/openapi/models.py

        # Using Any for Specification Extensions
        callbacks: Optional[Dict[str, Union[Dict[str, PathItem], Reference, Any]]] = None
        pathItems: Optional[Dict[str, Union[PathItem, Reference]]] = None
    
    
    class Tag(BaseModelWithConfig):
        name: str
        description: Optional[str] = None
        externalDocs: Optional[ExternalDocumentation] = None
    
    
    class OpenAPI(BaseModelWithConfig):
        openapi: str
        info: Info
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 22:49:33 GMT 2024
    - 15K bytes
    - Viewed (1)
  3. docs/pt/docs/tutorial/path-operation-configuration.md

    <img src="/img/tutorial/path-operation-configuration/image01.png">
    
    ### Tags com Enums
    
    Se você tem uma grande aplicação, você pode acabar acumulando **várias tags**, e você gostaria de ter certeza de que você sempre usa a **mesma tag** para *operações de rota* relacionadas.
    
    Nestes casos, pode fazer sentido armazenar as tags em um `Enum`.
    
    **FastAPI** suporta isso da mesma maneira que com strings simples:
    
    ```Python hl_lines="1  8-10  13  18"
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Oct 17 05:59:11 GMT 2023
    - 5.9K bytes
    - Viewed (0)
  4. docs/de/docs/tutorial/bigger-applications.md

    Aber wir wollen schlauer sein und den Code etwas vereinfachen.
    
    Wir wissen, dass alle *Pfadoperationen* in diesem Modul folgendes haben:
    
    * Pfad-`prefix`: `/items`.
    * `tags`: (nur ein Tag: `items`).
    * Zusätzliche `responses`.
    * `dependencies`: Sie alle benötigen die von uns erstellte `X-Token`-Abhängigkeit.
    
    Anstatt also alles zu jeder *Pfadoperation* hinzuzufügen, können wir es dem `APIRouter` hinzufügen.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Mar 30 20:27:59 GMT 2024
    - 21.1K bytes
    - Viewed (0)
  5. docs/en/docs/release-notes.md

    ## 0.87.0
    
    Highlights of this release:
    
    * [Upgraded Starlette](https://github.com/encode/starlette/releases/tag/0.21.0)
        * Now the `TestClient` is based on HTTPX instead of Requests. 🚀
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri May 03 23:25:42 GMT 2024
    - 388.1K bytes
    - Viewed (1)
  6. docs/zh/docs/tutorial/body-nested-models.md

        ```Python hl_lines="14"
        {!> ../../../docs_src/body_nested_models/tutorial002.py!}
        ```
    
    ## Set 类型
    
    但是随后我们考虑了一下,意识到标签不应该重复,它们很大可能会是唯一的字符串。
    
    Python 具有一种特殊的数据类型来保存一组唯一的元素,即 `set`。
    
    然后我们可以导入 `Set` 并将 `tag` 声明为一个由 `str` 组成的 `set`:
    
    === "Python 3.10+"
    
        ```Python hl_lines="12"
        {!> ../../../docs_src/body_nested_models/tutorial003_py310.py!}
        ```
    
    === "Python 3.9+"
    
        ```Python hl_lines="14"
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Fri Mar 22 01:42:11 GMT 2024
    - 9.3K bytes
    - Viewed (0)
  7. docs/de/docs/tutorial/security/oauth2-jwt.md

    Auf diese Weise können Sie einen Token mit einer Gültigkeitsdauer von beispielsweise einer Woche erstellen. Und wenn der Benutzer am nächsten Tag mit dem Token zurückkommt, wissen Sie, dass der Benutzer immer noch bei Ihrem System angemeldet ist.
    
    Plain Text
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Sat Mar 30 20:27:06 GMT 2024
    - 15.1K bytes
    - Viewed (0)
  8. fastapi/applications.py

                    The tags that are not declared MAY be organized randomly or based
                    on the tools' logic. Each tag name in the list MUST be unique.
    
                    The value of each item is a `dict` containing:
    
                    * `name`: The name of the tag.
                    * `description`: A short description of the tag.
                        [CommonMark syntax](https://commonmark.org/) MAY be used for rich
    Python
    - Registered: Sun May 05 07:19:11 GMT 2024
    - Last Modified: Tue Apr 02 02:48:51 GMT 2024
    - 172.2K bytes
    - Viewed (0)
Back to top