This a easy rosbridge client socket connection in python to publish and subscribe any topic in ROS when its RosBridge server is launched.
Create a class Object pass your IP address and port number at which ROSbridge is working try publishing messages at a any topic of your desire.
For more details refer rospy client library or refer this github Repo