restgdfΒΆ

Improved Esri REST I/O for GeoPandas.

PyPI version Python versions Downloads License CI Publish to PyPI coverage llms.txt Ask DeepWiki Pydantic v2

restgdf is an async-first wrapper around Esri/ArcGIS REST Feature and Map services. It reads all features past the server’s maxRecordCount, returns validated pydantic models for every response, and hands you a geopandas.GeoDataFrame ready for analysis.

import asyncio
from aiohttp import ClientSession
from restgdf import FeatureLayer

url = "https://maps1.vcgov.org/arcgis/rest/services/Beaches/MapServer/6"

async def main():
    async with ClientSession() as session:
        layer = await FeatureLayer.from_url(url, session=session)
        return await layer.getgdf()

gdf = asyncio.run(main())

Explore the docsΒΆ

πŸš€ Quickstart

Install, connect to a FeatureServer, and pull a GeoDataFrame in under ten lines.

Quickstart
πŸ” Authentication

Pass ArcGIS tokens directly or let ArcGISTokenSession mint and refresh them for you.

Authentication
πŸ“¦ Pydantic models

Every ArcGIS response is a typed BaseModel β€” LayerMetadata, FeaturesResponse, CrawlReport, and more.

Pydantic models
πŸ“– API reference

FeatureLayer, Directory, ArcGISTokenSession, and the migration helpers in restgdf.compat.

API reference
πŸ›  Utilities

Low-level crawl, HTTP, token, and GeoDataFrame helpers.

Utilities
πŸ” Migration 1.x β†’ 2.0

Upgrading from restgdf 1.x? The breaking-changes table and rewrite recipes live here.

Migrating from restgdf 1.x to 2.0
πŸ€– Docs for LLMs

Every page is also published as plain Markdown (append .md to any URL), plus llms.txt / llms-full.txt indexes for RAG pipelines and coding agents.

https://restgdf.readthedocs.io/en/latest/llms.txt

Indices and tablesΒΆ