{"uid":"cap_ujD6LWuRU1uEBeKDX_8q4","slug":"fittings-point-in-polygon-28921bff","name":"fittings Point-in-Polygon","description":"Whether a coordinate falls inside a GeoJSON Polygon or MultiPolygon, honouring holes and reporting boundary hits.","url":"https://fittings.sh/v1/spatial/point-in-polygon","method":"POST","headers":{},"bodySchema":{"type":"object","properties":{"point":{"type":"object","description":"{lat, lon} or GeoJSON [longitude, latitude]"},"polygon":{"type":"object","description":"GeoJSON Polygon, MultiPolygon, Feature or bare ring, up to 20000 vertices"},"ignoreBoundary":{"type":"boolean","description":"Treat a point on an edge as outside. Defaults to false."}}},"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_CvoVLlJmHrzzO0BW2aEEw","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":"Determines whether a geographic point falls inside, outside, or on the boundary of a GeoJSON Polygon or MultiPolygon, correctly handling holes and boundary cases.","exampleAgentPrompt":"Is the point at latitude 51.5074, longitude -0.1278 inside this GeoJSON polygon I'm pasting — and if it lands exactly on an edge, count that as outside: {\"type\":\"Polygon\",\"coordinates\":[[[-0.15,51.49],[-0.10,51.49],[-0.10,51.52],[-0.15,51.52],[-0.15,51.49]]]}?","exampleUseCases":[{"title":"Delivery zone eligibility check","prompt":"I have a customer at lat 37.7749, lon -122.4194 — can you check if they fall inside this GeoJSON polygon that represents our San Francisco delivery zone? Treat boundary hits as inside."},{"title":"Geofence alert for restricted area","prompt":"Tell me if the coordinate lat 48.8566, lon 2.3522 is inside this restricted GeoJSON MultiPolygon I'm providing — I need to know if it's truly inside, outside, or exactly on the boundary."},{"title":"Electoral district containment check","prompt":"Does the point at latitude 40.7128, longitude -74.0060 fall within this GeoJSON polygon representing the district boundary? Treat points on the edge as outside."}],"resultDescription":"A JSON object indicating whether the point is inside the polygon (true/false), whether it landed exactly on a boundary edge, and the final classification accounting for the ignoreBoundary flag setting.","failureModes":["Malformed GeoJSON polygon input returns a validation error","Polygon exceeds 20,000 vertex limit and is rejected","Point coordinates provided in wrong order (lat/lon vs lon/lat) produce incorrect results","Self-intersecting or unclosed polygon rings may produce undefined results","Missing required point or polygon field returns a 400 error"],"whenToPreferThis":"Choose this endpoint when you need a precise, hole-aware point-in-polygon test on arbitrary GeoJSON shapes — including MultiPolygons with interior holes — and need explicit control over boundary semantics. It is ideal for geofencing, delivery zone checks, and regulatory containment queries where boundary edge cases matter and the polygon complexity can reach up to 20,000 vertices.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T00:48:08.922Z","isFirstParty":false}