Convert script python to .json file

and if i want to send the object name with the distance, should i just modif this line in python "client.subscribe("distance", 2)" ?