In [12]:
import geopandas as gpd
import requests
import json

In [3]:
url = 'http://services.arcgis.com/P3ePLMYs2RVChkJx/ArcGIS/rest/services/USA_Congressional_Districts/FeatureServer/0/query?where=STATE_ABBR%3D%27ME%27&objectIds=&time=&geometry=&geometryType=esriGeometryEnvelope&inSR=&spatialRel=esriSpatialRelIntersects&resultType=none&distance=0.0&units=esriSRUnit_Meter&returnGeodetic=false&outFields=&returnGeometry=true&returnCentroid=false&multipatchOption=xyFootprint&maxAllowableOffset=&geometryPrecision=&outSR=&datumTransformation=&returnIdsOnly=false&returnCountOnly=false&returnExtentOnly=false&returnDistinctValues=false&orderByFields=&groupByFieldsForStatistics=&outStatistics=&having=&resultOffset=&resultRecordCount=&returnZ=false&returnM=false&returnExceededLimitFeatures=true&quantizationParameters=&sqlFormat=none&f=pgeojson&token='

In [8]:
response = requests.get(url)

In [24]:
j = json.loads(response.content)

In [26]:
j['crs']


Out[26]:
{u'properties': {u'name': u'EPSG:3857'}, u'type': u'name'}

In [23]:
g = gpd.GeoDataFrame.from_features(j)


---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-23-d07b1eca4b46> in <module>()
----> 1 g = gpd.GeoDataFrame.from_features(j)

c:\python27\arcgis10.5\lib\site-packages\geopandas\geodataframe.pyc in from_features(cls, features, crs)
    214 
    215             d = {'geometry': shape(f['geometry']) if f['geometry'] else None}
--> 216             d.update(f['properties'])
    217             rows.append(d)
    218         df = GeoDataFrame.from_dict(rows)

TypeError: 'NoneType' object is not iterable