Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 991 for _body (0.01 sec)

  1. docs/en/docs/tutorial/body-fields.md

    # Body - Fields { #body-fields }
    
    The same way you can declare additional validation and metadata in *path operation function* parameters with `Query`, `Path` and `Body`, you can declare validation and metadata inside of Pydantic models using Pydantic's `Field`.
    
    ## Import `Field` { #import-field }
    
    First, you have to import it:
    
    {* ../../docs_src/body_fields/tutorial001_an_py310.py hl[4] *}
    
    
    /// warning
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sun Aug 31 09:15:41 UTC 2025
    - 2.3K bytes
    - Viewed (0)
  2. docs/zh/docs/tutorial/body-fields.md

    `Field` 的工作方式和 `Query`、`Path`、`Body` 相同,参数也相同。
    
    /// note | 技术细节
    
    实际上,`Query`、`Path` 都是 `Params` 的子类,而 `Params` 类又是 Pydantic 中 `FieldInfo` 的子类。
    
    Pydantic 的 `Field` 返回也是 `FieldInfo` 的类实例。
    
    `Body` 直接返回的也是 `FieldInfo` 的子类的对象。后文还会介绍一些 `Body` 的子类。
    
    注意,从 `fastapi` 导入的 `Query`、`Path` 等对象实际上都是返回特殊类的函数。
    
    ///
    
    /// tip | 提示
    
    注意,模型属性的类型、默认值及 `Field` 的代码结构与*路径操作函数*的参数相同,只不过是用 `Field` 替换了`Path`、`Query`、`Body`。
    
    ///
    
    ## 添加更多信息
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Mon Nov 18 02:25:44 UTC 2024
    - 1.6K bytes
    - Viewed (0)
  3. docs/de/docs/tutorial/body-nested-models.md

    # Body – Verschachtelte Modelle { #body-nested-models }
    
    Mit **FastAPI** können Sie (dank Pydantic) beliebig tief verschachtelte Modelle definieren, validieren, dokumentieren und verwenden.
    
    ## Listen als Felder { #list-fields }
    
    Sie können ein Attribut als Kindtyp definieren, zum Beispiel eine Python-`list`.
    
    {* ../../docs_src/body_nested_models/tutorial001_py310.py hl[12] *}
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 17 20:41:43 UTC 2025
    - 7.6K bytes
    - Viewed (0)
  4. docs/ru/docs/tutorial/body-fields.md

    # Body - Поля { #body-fields }
    
    Таким же способом, как вы объявляете дополнительную валидацию и метаданные в параметрах *функции обработки пути* с помощью функций `Query`, `Path` и `Body`, вы можете объявлять валидацию и метаданные внутри Pydantic моделей, используя функцию `Field` из Pydantic.
    
    ## Импорт `Field` { #import-field }
    
    Сначала вы должны импортировать его:
    
    {* ../../docs_src/body_fields/tutorial001_an_py310.py hl[4] *}
    
    /// warning | Внимание
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Tue Sep 30 11:24:39 UTC 2025
    - 4.2K bytes
    - Viewed (0)
  5. docs/de/docs/tutorial/body-updates.md

    # Body – Aktualisierungen { #body-updates }
    
    ## Ersetzendes Aktualisieren mit `PUT` { #update-replacing-with-put }
    
    Um einen Artikel zu aktualisieren, können Sie die <a href="https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/PUT" class="external-link" target="_blank">HTTP `PUT`</a> Operation verwenden.
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Wed Dec 24 10:28:19 UTC 2025
    - 5.1K bytes
    - Viewed (0)
  6. docs/es/docs/tutorial/body-multiple-params.md

    # Cuerpo - Múltiples Parámetros { #body-multiple-parameters }
    
    Ahora que hemos visto cómo usar `Path` y `Query`, veamos usos más avanzados de las declaraciones del request body.
    
    ## Mezclar `Path`, `Query` y parámetros del cuerpo { #mix-path-query-and-body-parameters }
    
    Primero, por supuesto, puedes mezclar las declaraciones de parámetros de `Path`, `Query` y del request body libremente y **FastAPI** sabrá qué hacer.
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Tue Dec 16 16:33:45 UTC 2025
    - 5.2K bytes
    - Viewed (0)
  7. docs/en/docs/tutorial/body-multiple-params.md

    # Body - Multiple Parameters { #body-multiple-parameters }
    
    Now that we have seen how to use `Path` and `Query`, let's see more advanced uses of request body declarations.
    
    ## Mix `Path`, `Query` and body parameters { #mix-path-query-and-body-parameters }
    
    First, of course, you can mix `Path`, `Query` and request body parameter declarations freely and **FastAPI** will know what to do.
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Sep 20 12:58:04 UTC 2025
    - 4.9K bytes
    - Viewed (0)
  8. docs/de/docs/tutorial/body-multiple-params.md

    Aber wenn Sie möchten, dass es einen JSON-Body mit einem Schlüssel `item` erwartet, und darin den Inhalt des Modells, so wie es das tut, wenn Sie mehrere Body-Parameter deklarieren, dann können Sie den speziellen `Body`-Parameter `embed` setzen:
    
    ```Python
    item: Item = Body(embed=True)
    ```
    
    so wie in:
    
    {* ../../docs_src/body_multiple_params/tutorial005_an_py310.py hl[17] *}
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Sep 20 15:10:09 UTC 2025
    - 5.5K bytes
    - Viewed (0)
  9. docs/uk/docs/tutorial/body-multiple-params.md

    Наприклад, розширюючи попередню модель, Ви можете вирішити додати ще один ключ `importance` в те ж саме тіло запиту разом із `item` і `user`.
    
    Якщо Ви оголосите його як є, то, оскільки це одиничне значення,  **FastAPI**  припускатиме, що це параметр запиту (query parameter).
    
    Але Ви можете вказати **FastAPI** обробляти його як інший ключ тіла (body key), використовуючи `Body`:
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Fri Feb 28 14:19:00 UTC 2025
    - 7.4K bytes
    - Viewed (0)
  10. docs/en/docs/tutorial/body-updates.md

    # Body - Updates { #body-updates }
    
    ## Update replacing with `PUT` { #update-replacing-with-put }
    
    To update an item you can use the <a href="https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/PUT" class="external-link" target="_blank">HTTP `PUT`</a> operation.
    
    You can use the `jsonable_encoder` to convert the input data to data that can be stored as JSON (e.g. with a NoSQL database). For example, converting `datetime` to `str`.
    
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 20 15:55:38 UTC 2025
    - 4.1K bytes
    - Viewed (0)
Back to top