First working? version with websockets