Update the scale threshold of all point layers in an ArcGIS Pro map.
# current project
aprx = arcpy.mp.ArcGISProject("CURRENT")
# get the map_obj
maps = aprx.listMaps("MyMap")
# if the map found
if len(maps) > 0:
map = maps[0]
# loop map layers
for lyr in map.listLayers():
# if feature layer that supports "MINTHRESHOLD"
if lyr.isFeatureLayer and lyr.supports("MINTHRESHOLD"):
# check if point layer
desc = arcpy.Describe(lyr)
if hasattr(desc, "shapeType") and desc.shapeType == "Point":
# set the threshold
print(f" ... updating scale threshold for {lyr.longName}")
lyr.minThreshold = 10000
