scala-webapp-template icon indicating copy to clipboard operation
scala-webapp-template copied to clipboard

Start returning error messages when invoking APIs with wrong parameters

Open AlexITC opened this issue 2 years ago • 4 comments

Right now, when you invoke an unknown endpoint, you get back an empty error message, same way, when you invoke an endpoint with an invalid argument, you get an empty error message.

This behavior can be very annoying when getting started with the project, let's make sure to return proper error messages.

AlexITC avatar Apr 11 '22 13:04 AlexITC

Hi, Can I take up this issue if possible?

ritikBhandari avatar Apr 11 '22 14:04 ritikBhandari

For sure!

AlexITC avatar Apr 11 '22 18:04 AlexITC

What's the desired behavior? e.g. if I hit localhost:8080/badRoute or localhost:8080/dashboard&myArg=badArg I get returned to Home now. Should these redirect to a standard 404/400 page, respectively? Or should it still redirect to home, with a message displayed on the page?

DrewRoby avatar Oct 12 '23 11:10 DrewRoby

localhost:8080 is frontend, localhost:9000 is backend, the issue relates to returning better error messages when invoking backend apis, for example, localhost:9000/auth/methrows an error if you are not authenticated.

AlexITC avatar Oct 12 '23 13:10 AlexITC