reset of data, and error handling

Updated the readme and composer to reflect the changes
Created neater error handling, still json response