{"uid":"cap_lLuJU1-V3v3FStymF1jhV","slug":"geoprimitives-geojson-validator-15df9e4c","name":"geoprimitives GeoJSON Validator","description":"Validate GeoJSON against RFC 7946 and get back a structured list of problems, not a bare boolean. Checks structure, coordinate range, ring closure, ring winding order, consecutive duplicate vertices, self-intersections, and hole nesting. Every issue carries the feature, geometry, ring and position index it sits on, so a 500-feature collection is actionable rather than merely condemned. Reach for it before paying for an operation on data you did not author, and to find out why /v1/geometry, /v1/h3/polyfill or /v1/pip refused a document: those endpoints reject unclosed rings and out-of-range coordinates rather than guessing. Errors make a document invalid; warnings -- duplicate vertices, the crs member RFC 7946 removed -- do not, and are reported separately. One price per call whatever the document: a single Point costs exactly what a 1 MiB FeatureCollection costs, so send the whole collection rather than a document at a time. That is measured rather than assumed -- a Point is about 0.0015 ms of compute on this runtime and a 1 MiB collection about 10 ms, a spread far below what it costs to settle one payment -- which is why there is no size tier here to choose between and no bulk sibling to look for. Nothing is modified here: POST /v1/geojson/repair is the endpoint that rewrites. Limits: 1 MiB request body, and a self-intersection budget of 2000000 segment-pair comparisons per request, enough for any ring under about 1400 vertices. Rings past the budget are listed in checksSkipped with the reason, never silently passed as clean.","url":"https://api.geoprimitives.dev/v1/geojson/validate?utm_source=zero.xyz","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"type":{"enum":["FeatureCollection","Feature","Point","MultiPoint","LineString","MultiLineString","Polygon","MultiPolygon","GeometryCollection"],"type":"string","description":"GeoJSON type. Post the document itself: a Feature, a FeatureCollection, or a bare Geometry."},"features":{"type":"array","items":{"type":"object"},"description":"Present when type is FeatureCollection."},"geometry":{"type":"object","description":"Present when type is Feature. May be null."},"geometries":{"type":"array","items":{"type":"object"},"description":"Present when type is GeometryCollection."},"coordinates":{"type":"array","description":"Present on a bare Geometry other than GeometryCollection."}}},"responseSchema":null,"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.005","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"unknown","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.005/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.005","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_fDsTVzzYtU0ADQbLeJbMi","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.005","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Validates a GeoJSON document against RFC 7946 and returns a structured, indexed list of errors and warnings with precise feature, geometry, ring, and position references.","exampleAgentPrompt":"Can you validate this GeoJSON FeatureCollection for me and tell me exactly which features have problems, what's wrong with them, and where in the coordinates the issue is — I need to know before I run it through the polyfill?","exampleUseCases":[{"title":"Pre-flight check before geometry operation","prompt":"Before I send this 500-feature GeoJSON FeatureCollection to the polyfill endpoint, can you validate it and give me a list of every problem — unclosed rings, bad coordinates, self-intersections — with the exact feature and ring index so I know what to fix?"},{"title":"Diagnosing a rejected GeoJSON document","prompt":"My polygon GeoJSON keeps getting rejected by the geometry API — can you run it through the GeoJSON validator and tell me specifically what's wrong with it, like which ring is unclosed or which coordinates are out of range?"},{"title":"Auditing third-party GeoJSON data quality","prompt":"I just received this GeoJSON FeatureCollection from an external vendor and I need to know if it's RFC 7946 compliant before I use it — can you validate it and list all the errors and warnings with their positions?"}],"resultDescription":"A structured report containing two lists: 'errors' (issues that make the document invalid, e.g. unclosed rings, out-of-range coordinates, bad structure, self-intersections, wrong hole nesting) and 'warnings' (non-fatal issues, e.g. duplicate consecutive vertices, deprecated crs member). Each issue carries the feature index, geometry index, ring index, and position index where it occurs, making every finding directly actionable on collections of any size.","failureModes":["Malformed JSON body returns a parse error","Input is not a GeoJSON object (missing 'type' field) returns a structure error","Network timeout on very large documents","Unexpected geometry types not in the RFC 7946 spec may be flagged as structural errors"],"whenToPreferThis":"Choose this endpoint when you need actionable, indexed validation feedback rather than a bare pass/fail boolean. It is especially valuable before submitting GeoJSON to downstream geometry operations (polyfill, point-in-polygon, geometry processing) that reject invalid documents without explanation. Use it to audit third-party or user-authored GeoJSON, to diagnose why another endpoint refused a document, or any time you need to locate and fix specific geometry issues in a collection. The flat per-call pricing makes it cost-effective to validate entire FeatureCollections in one call rather than document by document.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-11T06:43:06.796Z","isFirstParty":false,"canonicalSlug":"geoprimitives-geojson-validator-15df9e4c"}