Select to view content in your preferred language

Programmatically upload images to AGOL

503
1
02-18-2022 01:10 PM
Labels (2)
MichaelWen
Emerging Contributor

I'm looking for a way to programmatically upload a geotif file to AGOL, and then share the image out as a Image Service or another way. 

I tried using the AddItem REST API but no luck so far. 

Is there anything in JS API or ArcPy that can be used for this purpose?

We'd prefer to get this done without using ArcGIS Server or ArcGIS Desktop/Pro.

Thanks.

0 Kudos
1 Reply
Jon-PaulMcCool
Occasional Contributor

It looks like you should be able to do this using ArcPy, but I haven't done it myself. 

https://pro.arcgis.com/en/pro-app/latest/arcpy/sharing/introduction-to-arcpy-sharing.htm

Be aware (if you weren't already) that to share raster data as an image service via AGOL you'll need ArcGIS Image for AGOL. Otherwise you can store a geotiff on AGOL, but you can't host it as an image service.

0 Kudos