Implemented the response status "ok" and "error"
Fixed error with the json object returned