Updated example, and added tests for bad request