[#3 #6] Updated REST API after review

- Fixed code after review.
- Seperated rest-api into rest-api and rest-utils namespaces.
- Added simple tests using Midje.