Skip to content

Add Geospatial Metadata Support to Hypercerts #1

@daviddao

Description

@daviddao

Describe the feature you'd like to request

Hypercerts would benefit from the ability to include standardized geospatial metadata to better represent the geographic scope and impact of projects. This enhancement would enable more precise tracking, filtering, and visualization of impact claims based on their geographic attributes.

Describe the solution you'd like

A proposal would be to implement a standard EAS schema for geospatial attestations that can be referenced by hypercerts through their existing metadata fields. An example schema for example could look like this:

struct GeospatialAttestation {
    // Primary location identifiers
    bytes32 locationHash;    // Hash of canonical location string
    string[] regionCodes;    // ISO-3166, NUTS, or other standard codes
    
    // Optional detailed geometry (GeoJSON as compressed string)
    string geometry;         // Compressed GeoJSON geometry
    
    // Metadata
    uint8 precisionLevel;    // Enum: COUNTRY=0, REGION=1, CITY=2, EXACT=3
    uint64 validFromTime;    // Unix timestamp
    uint64 validToTime;      // Unix timestamp
    
    // Reference fields
    address attestor;        // Address of the geographic data provider
    bytes32 sourceId;        // Reference to source of geographic claim
}

with a potential reference in hypercerts metadata through:

{
  "name": "Example Impact Claim",
  "description": "...",
  "external_url": "...",
  "properties": {
    "geospatial_attestations": [
      {
        "schema": "0x...",  // EAS schema ID for GeospatialAttestation
        "uid": "0x..."      // UID of the specific attestation
      }
    ]
  }

Describe alternatives you've considered

Alternatively one can simply store an IPFS cid directly into the metadata field.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions