{"uid":"cap_rJHH-wYoZ_12Zs0dcV-eM","slug":"geo-point-in-polygon-707c6963","name":"geo-point-in-polygon","description":"Ray-casting point-in-polygon test (planar approximation - fine for city/region-scale polygons).","url":"https://x402.agentindex.world/geo/point-in-polygon?utm_source=zero.xyz","method":"GET","headers":{},"bodySchema":{"type":"object","properties":{"point":{"type":"object","title":"LatLon","required":["lat","lon"],"properties":{"lat":{"type":"number","title":"Lat","maximum":90,"minimum":-90},"lon":{"type":"number","title":"Lon","maximum":180,"minimum":-180}}},"polygon":{"type":"array","items":{"type":"object","title":"LatLon","required":["lat","lon"],"properties":{"lat":{"type":"number","title":"Lat","maximum":90,"minimum":-90},"lon":{"type":"number","title":"Lon","maximum":180,"minimum":-180}}},"title":"Polygon","minItems":3}}},"responseSchema":{"type":"json","example":{"inside":true}},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.001","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.001/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.001","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_9hkytW91aWgEpYR2dDCPa","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.001","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 coordinate (lat/lon) lies inside or outside a given polygon using ray-casting with planar approximation.","exampleAgentPrompt":"Is the point at latitude 40.7128, longitude -74.0060 inside the polygon defined by these corners: (40.70, -74.02), (40.70, -73.99), (40.73, -73.99), (40.73, -74.02)?","exampleUseCases":[{"title":"Delivery zone eligibility check","prompt":"I need to know if the customer's location at lat 51.5074, lon -0.1278 falls inside my delivery zone polygon, which has these corners: (51.49, -0.15), (51.49, -0.10), (51.52, -0.10), (51.52, -0.15). Are they eligible for delivery?"},{"title":"Geofence alert for fleet tracking","prompt":"Check if this truck's current GPS position — latitude 37.7749, longitude -122.4194 — is still inside our permitted operating zone defined by the polygon: (37.76, -122.44), (37.76, -122.40), (37.79, -122.40), (37.79, -122.44)."},{"title":"Neighborhood boundary classification","prompt":"Does the coordinate lat 48.8566, lon 2.3522 fall within the polygon representing the 1st arrondissement of Paris? The polygon vertices are: (48.849, 2.340), (48.849, 2.365), (48.863, 2.365), (48.863, 2.340)."}],"resultDescription":"A boolean result indicating whether the provided geographic point (lat/lon) is inside or outside the specified polygon, computed via ray-casting with planar approximation suitable for city- or region-scale polygons.","failureModes":["Polygon has fewer than 3 vertices — minItems:3 constraint violation","Invalid latitude (outside -90 to 90) or longitude (outside -180 to 180)","Planar approximation may produce inaccurate results for very large or pole-spanning polygons","Malformed JSON payload for point or polygon objects","Missing required lat/lon fields in point or polygon vertices"],"whenToPreferThis":"Use this endpoint when you need a lightweight, pay-per-call geospatial containment test without maintaining a geospatial database or library. Ideal for city- or region-scale polygons where planar approximation is acceptable. Best suited for serverless agent workflows needing on-demand geofencing without API key management.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-10-16T06:31:26.667Z","isFirstParty":false,"canonicalSlug":"geo-point-in-polygon-707c6963"}