Skip to main content
Research Preview — This API is under development.

Length

Calculate the length of a line in meters.

Request Body

number
required
Target chain ID (e.g., 84532 for Base Sepolia, 8453 for Base).
Input
required
The line geometry to measure.
string
required
EAS schema UID to issue the attestation against.
string
Ethereum address to receive the attestation. Defaults to zero address if not provided.

Example Request

Example Response

Notes

  • Uses PostGIS ST_Length function with geodetic calculation
  • Result is in meters with centimeter precision
  • Valid for LineString and MultiLineString geometries

SDK Method

See astral.compute.length()