Fiddled to function to use variable named body to satisfy tests.
Modified unit tests to allow for changed function calls. Fixed stray typo in api.py