Search Options

Results per page
Sort
Preferred Languages
Advance

Results 11 - 20 of 566 for Model2 (0.09 sec)

  1. docs/en/docs/tutorial/response-model.md

    ## See it in the docs
    
    When you see the automatic docs, you can check that the input model and output model will both have their own JSON Schema:
    
    <img src="/img/tutorial/response-model/image01.png">
    
    And both models will be used for the interactive API documentation:
    
    <img src="/img/tutorial/response-model/image02.png">
    
    ## Other Return Type Annotations
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 18.1K bytes
    - Viewed (0)
  2. docs/en/docs/tutorial/query-param-models.md

    # Query Parameter Models
    
    If you have a group of **query parameters** that are related, you can create a **Pydantic model** to declare them.
    
    This would allow you to **re-use the model** in **multiple places** and also to declare validations and metadata for all the parameters at once. 😎
    
    /// note
    
    This is supported since FastAPI version `0.115.0`. 🤓
    
    ///
    
    ## Query Parameters with a Pydantic Model
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 3.8K bytes
    - Viewed (0)
  3. docs/en/docs/tutorial/extra-models.md

    # Extra Models
    
    Continuing with the previous example, it will be common to have more than one related model.
    
    This is especially the case for user models, because:
    
    * The **input model** needs to be able to have a password.
    * The **output model** should not have a password.
    * The **database model** would probably need to have a hashed password.
    
    /// danger
    
    Never store user's plaintext passwords. Always store a "secure hash" that you can then verify.
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 7.7K bytes
    - Viewed (0)
  4. docs/pt/docs/tutorial/request-form-models.md

    ////
    
    O **FastAPI** irá **extrair** as informações para **cada campo** dos **dados do formulário** na requisição e dar para você o modelo Pydantic que você definiu.
    
    ## Confira os Documentos
    
    Você pode verificar na UI de documentação em `/docs`:
    
    <div class="screenshot">
    <img src="/img/tutorial/request-form-models/image01.png">
    </div>
    
    ## Proibir Campos Extras de Formulários
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 3.1K bytes
    - Viewed (0)
  5. docs/pt/docs/tutorial/cookie-param-models.md

    # Modelos de Parâmetros de Cookie
    
    Se você possui um grupo de **cookies** que estão relacionados, você pode criar um **modelo Pydantic** para declará-los. 🍪
    
    Isso lhe permitiria **reutilizar o modelo** em **diversos lugares** e também declarar validações e metadata para todos os parâmetros de uma vez. 😎
    
    /// note | Nota
    
    Isso é suportado desde a versão `0.115.0` do FastAPI. 🤓
    
    ///
    
    /// tip | Dica
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Mon Oct 07 20:18:07 UTC 2024
    - 4.4K bytes
    - Viewed (0)
  6. docs/en/docs/reference/openapi/models.md

    # OpenAPI `models`
    
    OpenAPI Pydantic models used to generate and validate the generated OpenAPI.
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Wed Oct 18 12:36:40 UTC 2023
    - 125 bytes
    - Viewed (0)
  7. docs/de/docs/tutorial/response-model.md

    Zum Beispiel könnten Sie **ein Dict zurückgeben** wollen, oder ein Datenbank-Objekt, aber **es als Pydantic-Modell deklarieren**. Auf diese Weise übernimmt das Pydantic-Modell alle Datendokumentation, -validierung, usw. für das Objekt, welches Sie zurückgeben (z. B. ein Dict oder ein Datenbank-Objekt).
    
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 19.8K bytes
    - Viewed (0)
  8. tests/test_filter_pydantic_sub_model/test_filter_pydantic_sub_model_pv1.py

        return client
    
    
    @needs_pydanticv1
    def test_filter_sub_model(client: TestClient):
        response = client.get("/model/modelA")
        assert response.status_code == 200, response.text
        assert response.json() == {
            "name": "modelA",
            "description": "model-a-desc",
            "model_b": {"username": "test-user"},
        }
    
    
    @needs_pydanticv1
    def test_validator_is_cloned(client: TestClient):
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Fri Jul 07 17:12:13 UTC 2023
    - 4.5K bytes
    - Viewed (0)
  9. docs/en/docs/tutorial/cookie-param-models.md

    # Cookie Parameter Models
    
    If you have a group of **cookies** that are related, you can create a **Pydantic model** to declare them. 🍪
    
    This would allow you to **re-use the model** in **multiple places** and also to declare validations and metadata for all the parameters at once. 😎
    
    /// note
    
    This is supported since FastAPI version `0.115.0`. 🤓
    
    ///
    
    /// tip
    
    This same technique applies to `Query`, `Cookie`, and `Header`. 😎
    
    ///
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 4K bytes
    - Viewed (0)
  10. docs/de/docs/tutorial/body-nested-models.md

    Aber dieser Typ kann selbst ein anderes Pydantic-Modell sein.
    
    Sie können also tief verschachtelte JSON-„Objekte“ deklarieren, mit spezifischen Attributnamen, -typen, und -validierungen.
    
    Alles das beliebig tief verschachtelt.
    
    ### Ein Kindmodell definieren
    
    Wir können zum Beispiel ein `Image`-Modell definieren.
    
    //// tab | Python 3.10+
    
    ```Python hl_lines="7-9"
    Registered: Sun Nov 03 07:19:11 UTC 2024
    - Last Modified: Sun Oct 06 20:36:54 UTC 2024
    - 10.3K bytes
    - Viewed (0)
Back to top