Refactor-out socket routes into separate module