import FreeCAD as A, FreeCADGui as G, json, os p=r'C:\projects\wheel\models\fan_direct_motor_side_140\Assembly.FCStd' d=A.openDocument(p);d.recompute();o=[] for a in d.Objects: if hasattr(a,'Shape') and not a.Shape.isNull(): b=a.Shape.BoundBox; o.append({'name':a.Name,'label':a.Label,'visible':a.ViewObject.Visibility,'bounds':[b.XMin,b.XMax,b.YMin,b.YMax,b.ZMin,b.ZMax]}) open(r'C:\projects\wheel\models\objects_dump.json','w',encoding='utf8').write(json.dumps(o,ensure_ascii=False,indent=2)) A.closeDocument(d.Name);os._exit(0)