get_cameras_along_route
Retrieve traffic cameras along a straight-line corridor between two coordinates. Provide origin and destination to get cameras sorted by their position along the route.
Instructions
Get traffic cameras along a straight-line route between two points.
Same API call as the VanCam web app (vancam.ai) route view. Cameras are returned sorted by route_fraction (0 = origin, 1 = destination).
Note: Uses a straight line between origin and destination (PostGIS ST_MakeLine), not a driving route polyline. Buffer is meters perpendicular to that line.
Parameters: origin_lat, origin_lon: Route start (WGS84) dest_lat, dest_lon: Route end (WGS84) buffer: Corridor width in meters (default 100, web app uses 100) limit: Max cameras (1–100, default 50, web app uses 50) active_only: If true, only camera_class=open
Returns: JSON with type route_search, buffer_meters, cameras[] with route_fraction.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| buffer | No | ||
| dest_lat | Yes | ||
| dest_lon | Yes | ||
| origin_lat | Yes | ||
| origin_lon | Yes | ||
| active_only | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |