Area
Calculate the area of a polygon in square meters.Request body
number
required
Target chain ID (e.g.,
84532 for Base Sepolia).Input
required
The polygon geometry to measure. See Input types for accepted formats.
string
EAS schema UID. The server uses a default schema if not provided.
string
Ethereum address to receive the attestation. Defaults to the zero address.
Example request
Response
Returns a NumericComputeResponse.number
required
Area in square meters (e.g.,
5432.10).string
required
Always
"square_meters".string
required
Always
"area".number
required
Unix timestamp of computation.
string[]
required
Array of input references.
AttestationData
required
Signed EAS attestation. See AttestationData.
DelegatedAttestationData
required
Signature for delegated onchain submission. See DelegatedAttestationData.
Example response
Notes
- Uses PostGIS
ST_Areawith geodetic calculation - Result is in square meters with square centimeter precision
- The onchain attested value is scaled to square centimeters (integer) for EVM compatibility
- Only valid for polygon geometries
SDK Method
See
astral.compute.area()