Changed the response type to JSON