✏️ Use Annotated in inline example in docs/en/docs/tutorial/body-multiple-params.md (#15591)

This commit is contained in:
Alexander Li
2026-05-24 04:00:37 -07:00
committed by GitHub
parent 84f205c8f7
commit 3e3d38930e

View File

@@ -126,7 +126,7 @@ By default, **FastAPI** will then expect its body directly.
But if you want it to expect a JSON with a key `item` and inside of it the model contents, as it does when you declare extra body parameters, you can use the special `Body` parameter `embed`:
```Python
item: Item = Body(embed=True)
item: Annotated[Item, Body(embed=True)]
```
as in: