Skip to content

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

Merged
tiangolo merged 1 commit into
fastapi:masterfrom
TheArchons:patch-1
May 24, 2026
Merged

✏️ Use Annotated in inline example in docs/en/docs/tutorial/body-multiple-params.md#15591
tiangolo merged 1 commit into
fastapi:masterfrom
TheArchons:patch-1

Conversation

@TheArchons
Copy link
Copy Markdown
Contributor

The full example in the "Body - Multiple Parameters" tutorial recommends and uses Annotated, but one line still uses the non-Annotated version.

Pull Request

Discussion: This seemed like an obvious issue with a straightforward fix, so I did not start a discussion.

Description

My PR updates the line to use Annotated.

AI Disclaimer

No AI used :)

Checklist

  • This PR is an obvious typo fix, or it links to a GitHub Discussion for the proposed code change.
  • I added tests for the change. - No tests needed
  • The new or updated tests fail on the main branch and pass on this PR. - No tests needed
  • Coverage stays at 100%.
  • The documentation explains the change if needed.

The full example in the tutorial recommends and uses Annotated, but one line still uses the non-Annotated syntax.
Copilot AI review requested due to automatic review settings May 23, 2026 21:02
@github-actions github-actions Bot added the docs Documentation about how to use FastAPI label May 23, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Updates the FastAPI tutorial snippet for embedded body parameters to use typing.Annotated with Body(embed=True) instead of a default value assignment.

Changes:

  • Replaced item: Item = Body(embed=True) with item: Annotated[Item, Body(embed=True)] in the documentation snippet.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/en/docs/tutorial/body-multiple-params.md
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 23, 2026

@tiangolo tiangolo changed the title Use Annotated in Body - Multiple Parameters Tutorial Example ✏️ Use Annotated in inline example in docs/en/docs/tutorial/body-multiple-params.md May 24, 2026
Copy link
Copy Markdown
Member

@tiangolo tiangolo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, thanks! 🍰

@tiangolo tiangolo merged commit 3e3d389 into fastapi:master May 24, 2026
57 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation about how to use FastAPI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants