Correct responding with `405 Method Not Allowed` instead of `404 Not Found` in API.