Implment and test parsing JSON requests.
This meant adding an additional if statement for detecting content-type = application/json,
parsing the body of the request as json, and providing new helper methods for getting json
data out of keys.