great refactoring

rename all_handler to generic_handler
create AuthorizedAPIRequestHandler class
rename set_device_id method to authorize and move it to above class
make User and Device classes to maintain hierarchy
response 401 Unauthorized status if no device_id supplied
rewrite device assigning to use PinNumber and another new features

some minor changes