$npx skillfedfor your agent

pydantic-geojson

Pydantic validation for GeoJson

Worth itPyPI GISReleased Mar 202684.1K downloads / moMITPure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — pydantic_geojson-0.3.2-py3-none-any.whl
v0.3.2 · released 2026-03-01 · Python <4.0,>=3.9 · 1 runtime deps: pydantic

Yes. The package is actively maintained, has no known vulnerabilities, installs with minimal friction (one dependency), and directly solves the problem of validating GeoJSON data in Python. Use it if you need type-safe GeoJSON handling in any application, especially those using Pydantic or FastAPI.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.9 or later.
  • Low friction: single dependency on pydantic, pure-Python wheel, actively maintained with recent commits and support for current Python versions (3.9 through 3.14).

License · maintenance · safety

MIT (permissive) — MIT license is permissive; you can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions.

last release 2026-03-01 (166 days) · last repo commit 2026-08-11 · 39 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 84,051 downloads/mo, #14,030 on PyPI

Verify before relying

pip install pydantic_geojson

from pydantic_geojson import PointModel

point = PointModel(
    type="Point",
    coordinates=[-105.01621, 39.57422]
)
print(point)
  • Whether coordinate validation (longitude -180 to 180, latitude -90 to 90) is enforced at parse time or only on explicit validation calls.
  • Performance characteristics when parsing large FeatureCollections or deeply nested GeometryCollections.
Same gist for agents: .md · .json

What it is and what it does

pydantic-geojson wraps the GeoJSON specification (RFC 7946) in Pydantic models, letting you parse and validate geographic data with full type safety. It provides model classes for all nine GeoJSON object types: Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, Feature, and FeatureCollection. Each model enforces the correct structure and coordinate ranges automatically.

The library integrates directly with Pydantic's validation pipeline, so you can use it in FastAPI endpoints, define custom property schemas for features, and get automatic OpenAPI documentation. It handles both raw GeoJSON dictionaries (via model construction) and nested geometry validation, making it useful for APIs, geospatial data pipelines, and any application that needs to trust incoming geographic data.

Use it for

  • Validate incoming GeoJSON in FastAPI endpoints with automatic OpenAPI schema generation.
  • Parse and type-check geographic features from external APIs or file uploads.
  • Define typed property schemas for GeoJSON features to enforce application-specific metadata.
  • Build geospatial REST APIs where coordinate ranges and geometry types must be correct.
  • Store and validate geographic data in applications that work with maps or location services.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

The package is actively maintained, has no known vulnerabilities, installs with minimal friction (one dependency), and directly solves the problem of validating GeoJSON data in Python. Use it if you need type-safe GeoJSON handling in any application, especially those using Pydantic or FastAPI.

Install

pydantic-geojson on PyPI

Before you install

Low friction: single dependency on pydantic, pure-Python wheel, actively maintained with recent commits and support for current Python versions (3.9 through 3.14).

Requires Python 3.9 or later.

License in practice

MIT license is permissive; you can use, modify, and distribute this package freely in commercial and private projects with minimal restrictions.

Quickstart

pip install pydantic_geojson

from pydantic_geojson import PointModel

point = PointModel(
    type="Point",
    coordinates=[-105.01621, 39.57422]
)
print(point)

Verify before relying

  • Whether coordinate validation (longitude -180 to 180, latitude -90 to 90) is enforced at parse time or only on explicit validation calls.
  • Performance characteristics when parsing large FeatureCollections or deeply nested GeometryCollections.

Package facts

LicenseMIT permissive
Python supportSupports the current Python release <4.0,>=3.9
Install frictionLow. Pure-Python wheel
Runtime dependencies
1 package
pydantic
MaintenanceActively maintained 166 days since the last release
Last repo commit
First released
Downloads84,051 / month, #14,030 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Intended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseProgramming Language :: Python :: 3Programming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Programming Language :: Python :: 3.9Programming Language :: Python :: Implementation :: CPythonTopic :: Scientific/Engineering :: GIS

Evidence: pydantic_geojson-0.3.2-py3-none-any.whl

Tags

Capabilities
geojson validation pydanticgeojson type modelsrfc 7946 validationgeographic data validationgeojson schema validationpydantic geojson modelscoordinate validationfeature collection models
Topics
geospatialgisfastapi-compatible
PyPI keywords
pydanticvalidationgeojsonschemagisgeojsonjson-schemarestfastapiswaggeropenapi

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “rfc 7946 validation”

  • pydantic-geojsonProvides Pydantic-based type-safe validation and models for GeoJSON…
  • geojson-pydanticProvides Pydantic models that validate and serialize GeoJSON data…
  • fqdnValidates fully-qualified domain names (FQDNs) against RFC 1123…

Give your agent the search over MCP, or paste the wish link into any chat.

More GIS packages

shapely Worth it
PyPI · GIS · released Sep 2025

Shapely provides Python tools for creating, manipulating, and analyzing 2D geometric objects (points, lines, polygons) using the GEOS library, with both scalar and vectorized NumPy-based operations.

BSD-3-Clausecompiled wheel · 3.10+
85.8Mdownloads / mo
pyproj Unrated
PyPI · Scientific/Engineering · released Aug 2025

pyproj provides a Python interface to PROJ, enabling cartographic projections and coordinate system transformations for geospatial applications.

MITcompiled wheel · 3.11+
28.0Mdownloads / mo
geopandas Worth it
PyPI · GIS · released Jun 2026

GeoPandas extends pandas DataFrames to handle geographic data, combining pandas operations with shapely geometry and spatial analysis capabilities that would otherwise require a spatial database.

Install it if you work with geographic data in Python and want to avoid setting up a spatial database or learning a separate GIS tool.

BSD-3-Clausepure Python · 3.10+
24.8Mdownloads / mo
geopy Worth it
PyPI · Python Modules · released Jul 2026

geopy is a Python client for geocoding and distance calculation that converts addresses to coordinates and vice versa using multiple web-based geocoding services, and computes geodesic and great-circle distances between geographic points.

Install it if you need geocoding or distance calculations in your application.

MITpure Python · 3.8+
19.0Mdownloads / mo
pyogrio Worth it
PyPI · GIS · released Jun 2026

Pyogrio provides fast, bulk-oriented read and write access to vector spatial data formats (Shapefile, GeoPackage, GeoJSON, etc.) via GDAL/OGR bindings, typically for use with GeoPandas GeoDataFrames.

MITcompiled wheel · 3.10+
17.2Mdownloads / mo
h3 Worth it
PyPI · GIS · released May 2026

h3 provides Python bindings to Uber's H3 geospatial indexing library, converting geographic coordinates into hierarchical hexagonal grid cells and performing spatial operations on them.

Apache-2.0compiled wheel · 3.10+
12.1Mdownloads / mo

See also geojson · geojson-pydantic · sigstore-models · antimeridian · pygeoif · geomet · sigstore-rekor-types · openresponses-types · stac-pydantic · djangorestframework-gis