Here's the code:
from arcgis.gis import GIS
from arcgis.apps.survey123 import SurveyManager
from arcgis.features import FeatureLayer
gis = GIS()
survey_manager = SurveyManager(gis)
my_S123s = gis.content.search(query="type: Form", max_items=1000) # "Form" guarantees a Survey123
for s123 in my_S123s:
the_survey = survey_manager.get(s123.itemid)
aFLay = FeatureLayer(the_survey.parent_fl_url, gis)
# do something with aFLay
the_survey = None
As you can see, I am looping through all Survey123 Form items in my GIS, creating a Survey123, then creating a FeatureLayer using the parent_fl_id of the Survey123.
Performance is terrible. I expect to be able whip through them. I'm looking for a more efficient way to get from Survey123 to FeatureLayer.
How can I get the Feature Layer from the Survey123 Form without so much pain and suffering.
As always, TIA.