You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The server returns error response with body {"statusCode": 400}
Expected Behavior
The error response body should provide information necessary to troubleshoot the issue. At minimum, it should say that the request body contained malformed JSON.
Without that, client developers have no idea how to fix the problem.
Additional information
Ideally, error responses should contain a single top-level error property that contains an object with additional details. This makes it easier to consume the response in places where the response body is available only (no access to response status code).
I personally think we should leverage strong-error-handler module, it handles security considerations needed for production and was already verified by real world usage in LB 3.x applications.
Description / Steps to reproduce / Feature proposal
Start
examples/todo
Execute the following request (notice the extra comma before closing
}
):Current Behavior
The server returns error response with body
{"statusCode": 400}
Expected Behavior
The error response body should provide information necessary to troubleshoot the issue. At minimum, it should say that the request body contained malformed JSON.
Without that, client developers have no idea how to fix the problem.
Additional information
Ideally, error responses should contain a single top-level
error
property that contains an object with additional details. This makes it easier to consume the response in places where the response body is available only (no access to response status code).I personally think we should leverage strong-error-handler module, it handles security considerations needed for production and was already verified by real world usage in LB 3.x applications.
See Reporting Issues for more tips on writing good issues
The text was updated successfully, but these errors were encountered: