Refactor and decouple REST api framework

The recording API endpoints have been moved from the server.py module to a new class called recording.py.
Imports should be organized in groups with:

1. Python internal libraries together
2. 3rd party libraries together
3. Our own software's libraries together

and they should be sorted alphabetically when possible within those groups.