Looking for explanation of how to generate "web_map_as_json" string as the argument to mapping.export_map()
This link
arcgis.mapping module — arcgis 1.8.0 documentation
refers yo to the documentation in arcgis help topics
Web map printing with arcpy.mp—ArcPy | Documentation
which has some stuff to read, and maybe the section on
would help
This seemed to do the trick:
wm_as_json = json.loads(str(wm.definition))
wm_as_json['mapOptions'] = json.loads('''{ "extent" : { "xmin":-88.55, "ymin":17.55, "xmax":-72.75, "ymax":38.05, "spatialReference" : { "wkid" : 4326 } }}''')
wm_as_json['exportOptions'] = json.loads('''{ "dpi" : 300, "outputSize" : [1000,1000]}''')
mapping.export_map(webmap_as_json=wm_as_json)