I'm thinking of using https://www.esri.com/arcgis-blog/products/analytics/analytics/updating-your-hosted-feature-services-with-arcgis-pro-and-the-arcgis-api-for-python/ to automate my feature services from one project, instead of a separate project for each service. mp = prj.listMaps()[0] is what tells it to use the first map in the project.
How does one find the Map # in a project with hundreds of maps? Say I want to publish the 30th map in the project.
Python is only outputting
prjPath <SPAN class="operator token">=</SPAN> r<SPAN class="string token">"X:\GIS_Final\data\basedata\basemap\Maps\ArcGIS\ARCGIS_SERVER\GRSM_SPECIAL_USE_PERMITS\GRSM_SPECIAL_USE_PERMITS.aprx"</SPAN>
prj <SPAN class="operator token">=</SPAN> arcpy<SPAN class="punctuation token">.</SPAN>mp<SPAN class="punctuation token">.</SPAN>ArcGISProject<SPAN class="punctuation token">(</SPAN>prjPath<SPAN class="punctuation token">)</SPAN>
mp <SPAN class="operator token">=</SPAN> prj<SPAN class="punctuation token">.</SPAN>listMaps<SPAN class="punctuation token">(</SPAN><SPAN class="punctuation token">)</SPAN>
mp
<SPAN class="punctuation token">[</SPAN><SPAN class="operator token"><</SPAN>arcpy<SPAN class="punctuation token">.</SPAN>_mp<SPAN class="punctuation token">.</SPAN>Map object at <SPAN class="number token">0x000002560D31BDD8</SPAN><SPAN class="operator token">></SPAN><SPAN class="punctuation token">]</SPAN>
mp <SPAN class="operator token">=</SPAN> prj<SPAN class="punctuation token">.</SPAN>listMaps
mp
<SPAN class="operator token"><</SPAN>bound method ArcGISProject<SPAN class="punctuation token">.</SPAN>listMaps of <SPAN class="operator token"><</SPAN>arcpy<SPAN class="punctuation token">.</SPAN>_mp<SPAN class="punctuation token">.</SPAN>ArcGISProject object at <SPAN class="number token">0x00000256089FDFD0</SPAN><SPAN class="operator token">>></SPAN><SPAN class="line-numbers-rows"><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN><SPAN></SPAN></SPAN>