Skip to content

Validate DELETE request bodies in OpenAPI 3.1 and later - #515

Merged
geemus merged 1 commit into
masterfrom
fix/delete-request-body
Nov 21, 2026
Merged

geemus merged 1 commit into
masterfrom
fix/delete-request-body

Conversation

@ydah

@ydah ydah commented Nov 20, 2026

Copy link
Copy Markdown
Member

DELETE operations skip body and Content-Type validation even when an OpenAPI 3.1 or 3.2 schema declares requestBody.

Use the shared body-method check to validate declared DELETE bodies. Invalid bodies and unsupported media types now return 400. Preserve OpenAPI 3.0 behavior, which requires ignoring DELETE request bodies.

@geemus geemus left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm, thanks!

@geemus
geemus merged commit da23f0e into master Nov 21, 2026
11 checks passed
@geemus
geemus deleted the fix/delete-request-body branch November 21, 2026 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants