-
-
Notifications
You must be signed in to change notification settings - Fork 8k
Labels
needs triageThis issue has not been looked intoThis issue has not been looked into
Description
Is there an existing issue for this?
- I have searched the existing issues
Current behavior
Statuscode 422
is represented by enum value HttpStatus.UNPROCESSABLE_ENTITY
(see https://github.com/nestjs/nest/blob/master/packages/common/enums/http-status.enum.ts#L46). However, https://www.rfc-editor.org/rfc/rfc9110.html#name-422-unprocessable-content defines 422
as Unprocessable Content, and not Unprocessable Entity. See also https://www.iana.org/assignments/http-status-codes/http-status-codes.xhtml.
In the Java World Spring Framework already fixed 422
as Unprocessable Content: spring-projects/spring-framework#32870.
Minimum reproduction code
https://github.com/juergenzimmermann/buch
Steps to reproduce
Obvious.
Expected behavior
There should be an enum value HttpStatus.UNPROCESSABLE_CONTENT
for statuscode 422
.
NestJS version
@nestjs/common 11.1.6
Packages versions
"dependencies": {
"@nestjs/apollo": "13.1.0",
"@nestjs/axios": "4.0.1",
"@nestjs/common": "11.1.6",
"@nestjs/config": "4.0.2",
"@nestjs/core": "11.1.6",
"@nestjs/graphql": "13.1.0",
"@nestjs/microservices": "11.1.6",
"@nestjs/platform-express": "11.1.6",
"@nestjs/swagger": "11.2.0",
"@nestjs/terminus": "11.0.0"
},
"devDependencies": {
"@nestjs/cli": "11.0.10",
"@nestjs/schematics": "11.0.7",
"@nestjs/testing": "11.1.6"
}
}
Node.js version
24.7.0
In which operating systems have you tested?
- macOS
- Windows
- Linux
Other
No response
Metadata
Metadata
Assignees
Labels
needs triageThis issue has not been looked intoThis issue has not been looked into