Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 5 of 5 for body_fields (0.06 sec)

  1. fastapi/dependencies/utils.py

            and not is_union_of_base_models(first_field.type_)
        ):
            return True
        return False
    
    
    async def _extract_form_body(
        body_fields: list[ModelField],
        received_body: FormData,
    ) -> dict[str, Any]:
        values = {}
    
        for field in body_fields:
            value = _get_multidict_value(field, received_body)
            field_info = field.field_info
            if (
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 37.6K bytes
    - Viewed (3)
  2. tests/test_tutorial/test_body_fields/test_tutorial001.py

            "tutorial001_an_py39",
            pytest.param("tutorial001_an_py310", marks=needs_py310),
        ],
    )
    def get_client(request: pytest.FixtureRequest):
        mod = importlib.import_module(f"docs_src.body_fields.{request.param}")
    
        client = TestClient(mod.app)
        return client
    
    
    def test_items_5(client: TestClient):
        response = client.put("/items/5", json={"item": {"name": "Foo", "price": 3.0}})
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 18:19:10 UTC 2025
    - 6.3K bytes
    - Viewed (0)
  3. fastapi/openapi/utils.py

    def get_openapi_operation_request_body(
        *,
        body_field: Optional[ModelField],
        model_name_map: ModelNameMap,
        field_mapping: dict[
            tuple[ModelField, Literal["validation", "serialization"]], dict[str, Any]
        ],
        separate_input_output_schemas: bool = True,
    ) -> Optional[dict[str, Any]]:
        if not body_field:
            return None
        assert isinstance(body_field, ModelField)
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 23.2K bytes
    - Viewed (0)
  4. fastapi/routing.py

    ) -> Callable[[Request], Coroutine[Any, Any, Response]]:
        assert dependant.call is not None, "dependant.call must be a function"
        is_coroutine = dependant.is_coroutine_callable
        is_body_form = body_field and isinstance(body_field.field_info, params.Form)
        if isinstance(response_class, DefaultPlaceholder):
            actual_response_class: type[Response] = response_class.value
        else:
            actual_response_class = response_class
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 12:54:56 UTC 2025
    - 174.6K bytes
    - Viewed (0)
  5. docs/en/docs/release-notes.md

    * ✅ Simplify tests for body_multiple_params. PR [#13170](https://github.com/fastapi/fastapi/pull/13170) by [@alejsdev](https://github.com/alejsdev).
    * ✅ Simplify tests for body_fields. PR [#13169](https://github.com/fastapi/fastapi/pull/13169) by [@alejsdev](https://github.com/alejsdev).
    * ✅ Simplify tests for body. PR [#13168](https://github.com/fastapi/fastapi/pull/13168) by [@alejsdev](https://github.com/alejsdev).
    Registered: Sun Dec 28 07:19:09 UTC 2025
    - Last Modified: Sat Dec 27 19:06:15 UTC 2025
    - 586.7K bytes
    - Viewed (0)
Back to top