geofence_contains
Tests one or more points for containment inside a polygon you supply as GeoJSON (Polygon, MultiPolygon, or a Feature/FeatureCollection wrapping one). Pure geometry against your own shape - it does not search a place index, so use explore or search_places to find what's near a point instead. Boundary points count as contained. Up to 1000 points per call, against a polygon of up to 100 rings/parts and 1000 positions per ring; larger inputs are rejected. Runs locally with no external lookup, but still counts as one metered request like other tools, so batch points into a single call rather than looping. Errors, rather than returning false, when the polygon is structurally invalid. Returns one boolean per point, in order, plus contained_count and point_count.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| points | Yes | Points to test ({ lat, lon } each), up to 1000 | |
| polygon | No | A GeoJSON Polygon / MultiPolygon geometry, a Feature wrapping one, or a FeatureCollection |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| results | Yes | One containment boolean per input point (in order) | |
| warnings | No | ||
| point_count | Yes | Number of points tested | |
| contained_count | Yes | How many input points are contained |