I have a python script which downloads a .CSV from the internet, dyn segs the mile markers, creates a feature class, then uploads it to our portal environment and the script runs great and as expected. The issue is that the script takes the feature class and uploads it as a hosted feature layer into our root folder in Portal. I want to be able to put this hosted feature class into a named folder that already exists in our Portal environment using python. Thanks!
Hi @NateRogers1
Im going to make an assumption that you are using ArcPy and the arcpy.UploadServiceDefinition_server() function, there is an in_folder parameter you can use.
arcpy.UploadServiceDefinition_server(sd_output_filename, server_url, in_folder_type="EXISTING", in_folder="NAME OF FOLDER")
If my assumption is incorrect, you can share some code for assessment.