`json.dumps(pos)` (or `json.dumps([pos.x,pos.y,pos.z])`)