-
-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
API server returns incorrect HTTP status code #326
Comments
The reason it is useful to return the proper code is that it enables better handling of the response - trying to insert something unprocessable should maybe trigger a manual review (i.e. when inserting a carrier bound to an account, the account does not exist) whereas inserting a duplicate entry does not require that, and automated flows benefit from this distinction. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
jambonz-api-server/lib/routes/api/error.js
Lines 16 to 18 in d33d0aa
When trying to create a resource that already exists, the code returned is 422 (unprocessable resource) when it should return a 409 (conflict).
The text was updated successfully, but these errors were encountered: