Distance calculator: geodesic distance, bearing and destination point on WGS-84
geo_distanceDistance calculator: distance and direction between WGS-84 coordinates: geodesic distance by Vincenty with a haversine fallback, initial and final bearing, the midpoint, and the destination point reached from a start point on a given bearing and distance. Also computes the cumulative length of a supplied coordinate path. Results in metres, kilometres, nautical miles and miles. Price: $0.05 per successful call, paid over x402 (USDC on Base).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| op | No | distance (default), destination, midpoint or path. Accepted: distance, destination, midpoint, path. | |
| lat1 | No | Start latitude. Accepted: a number between -90 and 90. | |
| lat2 | No | End latitude. Accepted: a number between -90 and 90. | |
| lon1 | No | Start longitude. Accepted: a number between -180 and 180. | |
| lon2 | No | End longitude. Accepted: a number between -180 and 180. | |
| path | No | Comma-separated lat,lon pairs for op=path, at most 200 points. Accepted: comma-separated lat,lon pairs, at most 200 points. | |
| method | No | vincenty (default, WGS-84) or haversine. Accepted: vincenty, haversine. | |
| bearing | No | Initial bearing in degrees for op=destination. Accepted: number 0-360. | |
| distance_m | No | Distance in metres for op=destination, 0 to 1e9 (about 25 Earth circumferences); larger values are 400 INVALID_PARAM. Accepted: a number between 0 and 1e9 (metres). |