Verifiable location infrastructure for agents, applications, and smart contracts
Research Preview — The Astral Protocol is under active development and not yet production-ready. APIs may change. We’re building in public and welcome feedback.
Location data is everywhere, but trust in location data is very brittle. GPS is spoofable. VPNs manipulate IP addresses. In most cases, location data can be edited freely or forged easily. When an agent, an application, or a smart contract needs to answer a spatial question — was this device actually there? Is this point inside that boundary? — there is no way to independently verify the claim or the computation. You’re taking someone’s word for it.Location data is becoming more and more important across a range of use cases — so we built the Astral Protocol to introduce verifiable location-based services.The system rests on two core capabilities:
Location Proofs
Verify where a device, user, or event actually was — using multi-factor evidence from independent proof-of-location systems
Verifiable Geocomputation
Ask spatial questions — distance, containment, intersection, area — and get back signed, cryptographically verifiable answers
Both produce signed results — cryptographic artifacts that any downstream system can verify independently. The result is the same whether it ends up in an autonomous agent’s decision loop, a compliance report, a backend database, or a smart contract.
Collect + Compose — Gather location evidence from various sources and compose it into a single, verifiable location proof.
Verify — Submit location proofs for evidence-based verification. The system evaluates stamps from independent proof-of-location systems and returns credibility scores.
Compute — Run spatial operations (distance, containment, intersection, area, length) inside a Trusted Execution Environment. PostGIS computes; the TEE signs.
Use the results anywhere — The signed results carry their own proof of correctness. Use them peer-to-peer, on centralized servers, or in smart contracts.
Create a location proof, verify it, then check if the verified position is inside a geofence:
Copy
import { AstralSDK } from '@decentralized-geo/astral-sdk';const astral = new AstralSDK({ chainId: 84532, apiUrl: 'https://api.astral.global'});// 1. Collect signals from a proof-of-location plugin on the deviceconst signals = await astral.stamps.collect({ name: 'proofmode', version: '0.1.0'});// 2. Create and sign a stamp from the raw signalsconst unsigned = await astral.stamps.create( { name: 'proofmode', version: '0.1.0' }, signals);const stamp = await astral.stamps.sign(unsigned, deviceSigner);// 3. Compose a location proof: a claim ("I was here") bundled with evidenceconst claim = { location: { type: 'Point', coordinates: [-122.4194, 37.7749] }, subject: { scheme: 'eth-address', value: '0x1234...' }, radius: 100, time: { start: Date.now() / 1000 - 60, end: Date.now() / 1000 }, // lpVersion, locationType, srs — Location Protocol v0.2 defaults}const proof = astral.proofs.create( claim, [stamp] // multi-stamp location proofs are supported, and more secure);// 4. Verify — the TEE evaluates the stamp's signatures, structure,// and consistency with the claimconst verified = await astral.verify.proof(proof, { chainId: 84532 });console.log(`Credibility: ${verified.credibility.confidence}`);// 5. Compute — use the verified location in a spatial operationconst inside = await astral.compute.contains({ container: geofencePolygon, geometry: verified.uid, chainId: 84532});console.log(`Inside geofence: ${inside.result}`);
The response includes the computation result, a cryptographic signature from the TEE, and references to the inputs — everything needed to verify the answer independently.The signed result is portable. Use it directly in your application:
Copy
// In an agent workflow — branch on the verified spatial answerif (inside.result) { confirmDelivery(inside); // the signed result is the audit trail}// In a backend — store the signed result as evidenceawait db.insert({ delivery_id, proof: inside });
Or submit it onchain to trigger smart contract logic:
Copy
// Submit as an EAS attestation — triggers your resolver contractawait astral.eas.submitDelegated(inside.delegatedAttestation);