Removed api variable and added method

Beginning of RESTful refactor
Fix wrong controller bug
Changed test controller to tests
Removed id field