I am using rocketpant for rest API implementation. From this doc I can see rocketpant has considered error handling in controller nicely.
However, it seems like it does not consider routing error, so if the requested url has no route defined, instead of returning json error, it render back html 404 page, which is not correct for API design.