Skip to content

docs: document body validation with custom content type parsers#6556

Merged
Eomm merged 2 commits intomainfrom
docs/body-content-type-validation
Mar 7, 2026
Merged

docs: document body validation with custom content type parsers#6556
Eomm merged 2 commits intomainfrom
docs/body-content-type-validation

Conversation

@mcollina
Copy link
Member

@mcollina mcollina commented Mar 5, 2026

Summary

  • Documents that when using the body schema content property for per-content-type validation, custom content type parsers need their content type listed in the schema or the incoming data will be parsed but not validated
  • Adds a concrete application/yaml example showing the correct setup
  • Adds a cross-reference note in the Content-Type Parser docs

Test plan

  • Review rendered markdown in both Validation-and-Serialization.md and ContentTypeParser.md
  • Verify anchor link #body-content-type-validation resolves correctly

🤖 Generated with Claude Code

When using the body schema `content` property to validate per content
type, custom content type parsers require their content type to be
listed in the schema for validation to apply. Without it, data is
parsed but not validated.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@mcollina mcollina requested review from Eomm and jsumners and removed request for Eomm March 5, 2026 14:37
@github-actions github-actions bot added the documentation Improvements or additions to documentation label Mar 5, 2026
Co-authored-by: James Sumners <321201+jsumners@users.noreply.github.com>
Signed-off-by: Matteo Collina <matteo.collina@gmail.com>
@Eomm Eomm merged commit 0d3b560 into main Mar 7, 2026
8 of 9 checks passed
@Eomm Eomm deleted the docs/body-content-type-validation branch March 7, 2026 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants