Any thoughts?
If I copy this JSON from this location (web link) to a local file I can import to File GDB.
import arcpy
import os
arcpy.env.workspace = r"C:\Users\xyz\Desktop\GIS\IMPORT DEQ DATA"
arcpy.conversion.JSONToFeatures("myjsonfeatures.json", os.path.join("Datasets.gdb", "myfeatures"))
But I want to read the URL live as I want to run this script a couple times a day. How do I do that...
I tried the below but does not work
import arcpy
import os
geoJSON = "https://apps.deq.virginia.gov/arcgis/rest/services/public/EDMA/MapServer/104/query?outFields=*&where=1%3D1&f=geojson"
arcpy.env.workspace = r"C:\Users\xyz\Desktop\GIS\IMPORT DEQ DATA"
arcpy.conversion.JSONToFeatures(geoJSON, os.path.join("DEQ_Datasets.gdb", "myfeatures"))
", line 512, in <lambda>
return lambda *args: val(*gp_fixargs(args, True))
arcgisscripting.ExecuteError: Failed to execute. Parameters are not valid.
ERROR 000814: Invalid file type
Failed to execute (JSONToFeatures).