SPATIAL-TEMPORAL VERIFICATION API

Field Verification With
Cryptographic Proof
of Space & Time

Beyond tracking — mathematical proof of presence.

Advanced spatial-temporal verification that cryptographically validates WHERE and WHEN data was captured. Multi-layer security with sensor fusion, AI analysis, and satellite correlation.

CRYPTOGRAPHIC HASH
SATELLITE VERIFIED
SENSOR FINGERPRINT
ULID
Unique Space-Time ID
50+
Proof Points
8
Security Layers
AI
Vision Analysis
spatial_temporal_proof.js
// Spatial-Temporal Verification with Cryptographic Proof
const response = await fetch('https://api.spatialproof.com/v1/verify', {
  method: 'GET',
  headers: { 'Authorization': `Bearer ${API_KEY}` },
  body: JSON.stringify({
    ulid: '01JXYZ1234567890ABCDEFGH' // Unique ID with embedded timestamp
  })
});

const proof = await response.json();

// Cryptographic Proof of Space & Time:
console.log(proof.spatial_temporal);
// {
//   timestamp: "2025-05-28T14:32:18.000000Z",  // WHEN
//   coordinates: [-26.919444, -49.066111],      // WHERE
//   hash: "sha256:8a7f3c2b1e4d9f6a3b5c8e2d1f", // PROOF
//   satellite_verified: true,                   // VERIFIED
//   trust_score: 94                             // TRUSTED
// }

What Makes Spatial-Temporal Proof Different

Traditional Tracking

GPS can be spoofed. Photos can be faked. Timestamps can be altered. No cryptographic proof.

Blockchain Alone

Proves WHEN something was recorded, but not WHERE it happened. No real-world verification.

Our Approach

Cryptographic proof of WHERE + WHEN. Multi-layer verification with sensors, satellite, and AI.

Innovative Technology: Our combination of ULID timestamps, sensor fusion, satellite correlation, and AI analysis creates mathematical proof of presence that's extremely difficult to forge.

Enterprise-Grade Verification
for Those Who Need Real Proof

Our API is designed for organizations that can't afford fraud. From government audits to carbon credit certifications, we provide the infrastructure layer of trust.

Governments

Integrate field verification into public programs, subsidies, and compliance systems with full audit trails.

Social Programs Land Registry Environmental Audits

Enterprises

Add verified field data to your supply chain, ESG reporting, and operational workflows.

Supply Chain ESG Reporting Field Operations

Certifiers

Automate verification workflows with AI-analyzed evidence and cryptographic proof chains.

Carbon Credits Organic Certification Fair Trade

NGOs & Foundations

Prove impact with verified field evidence. Build trust with donors and stakeholders.

Impact Verification Donor Reporting M&E Systems

50+ Data Points
Per Verification

Every capture includes comprehensive sensor data, satellite weather conditions at the exact moment, and AI-powered analysis. All cross-referenced for maximum authenticity.

Device Sensor Data

Real-time readings from device hardware

  • GPS Coordinates
    object
  • Altitude
    float
  • GPS Accuracy
    float
  • Compass Heading
    float
  • Accelerometer XYZ
    array
  • Gyroscope XYZ
    array
  • Light Sensor (Lux)
    float
  • Camera EXIF
    object
25+

sensor readings per capture

Satellite Weather

Open-Meteo historical data at capture time

  • Temperature
    °C
  • Humidity
    %
  • Cloud Cover
    %
  • Precipitation
    mm
  • Wind Speed/Direction
    object
  • Atmospheric Pressure
    hPa
  • Solar Radiation
    W/m²
  • Evapotranspiration
    mm
16

weather variables + interpretations

AI Vision Analysis

GPT-4o powered image understanding

  • Overall Trust Score
    0-100
  • Verdict
    enum
  • Vegetation Analysis
    object
  • Weather Correlation
    object
  • Species Identified
    array
  • Anomalies Detected
    array
  • Narrative Analysis
    object
  • Component Scores
    object
15+

AI-generated insights & scores

Simple, Powerful Endpoints

RESTful architecture designed for easy integration. Full JSON responses with comprehensive data.

GET /v1/verifications/{ulid}
Retrieve Complete Verification

Description

Retrieve a complete verification record by its ULID, including all sensor data, satellite weather conditions, and AI analysis results.

  • Full sensor data array with timestamps
  • Satellite weather at capture moment
  • AI vision analysis with scores
  • Security validation results
  • Media URLs (photo/video/audio)
  • Cryptographic proof chain
Response 200
{
  "success": true,
  "verification": {
    "ulid": "01JXYZ1234567890ABCDEFGH",
    "captured_at": "2025-05-28T14:32:18Z",
    "location": {
      "latitude": -26.9194,
      "longitude": -49.0661,
      "altitude": 42.5,
      "accuracy": 4.2
    },
    "sensor_readings": [...],
    "weather_data": {...},
    "ai_analysis": {...}
  }
}
POST /v1/organizations
Create Organization

Description

Register a new organization (Company, NGO, or Government Entity) to manage projects and verifications.

  • Support for Companies, NGOs, Government
  • Custom metadata fields
  • Team member management
  • API key generation
  • Billing configuration
  • Webhook settings
Request Body
{
  "type": "company", // company, ngo, government
  "name": "Trust Carbon Ltd",
  "tax_id": "48.468.140/0001-15",
  "country": "BR",
  "contact": {
    "email": "contact@trustcarbon.org",
    "phone": "+55 47 99999-9999"
  },
  "address": {
    "street": "Rua XV de Novembro, 1234",
    "city": "Blumenau",
    "state": "SC",
    "postal_code": "89010-000"
  }
}
POST /v1/projects
Create Verification Project

Description

Create a new verification project with custom zones, requirements, and collection types.

  • Define geofenced collection zones
  • Set verification requirements
  • Multiple project types
  • Polygon area definitions
  • Custom AI parameters
  • Webhook notifications
Request Body
{
  "organization_id": "org_1234567890",
  "name": "Atlantic Forest Reforestation MRV",
  "type": "reforestation", // Options below
  // Types: agriculture, reforestation, social_agriculture,
  // tower_inspection, infrastructure, carbon_credit,
  // biodiversity, water_quality, soil_health
  "description": "Carbon credit verification for REDD+",
  "collection_zones": [
    {
      "name": "Zone Alpha",
      "type": "polygon",
      "coordinates": [
        [-49.0661, -26.9194],
        [-49.0651, -26.9184],
        [-49.0641, -26.9194],
        [-49.0661, -26.9194]
      ],
      "bbox": {
        "min_lat": -26.9194,
        "max_lat": -26.9184,
        "min_lng": -49.0661,
        "max_lng": -49.0641
      }
    }
  ],
  "requirements": {
    "capture_mode": "photo",
    "min_accuracy_meters": 10,
    "require_ai_analysis": true,
    "min_trust_score": 70
  },
  "webhook_url": "https://your-app.com/webhook"
}
POST /v1/collections
Request Field Collection

Description

Create a collection request at specific coordinates. Field agents receive notifications to capture verification at the location.

  • Pin exact GPS coordinates
  • Set collection deadline
  • Assign to specific agents
  • Custom instructions
  • Priority levels
  • Real-time notifications
Request Body
{
  "project_id": "proj_987654321",
  "location": {
    "latitude": -26.9194,
    "longitude": -49.0661,
    "radius_meters": 50
  },
  "type": "reforestation_monitoring",
  "priority": "high",
  "instructions": "Capture 360° photos of planted trees. Include canopy coverage and undergrowth. Verify species: Araucaria angustifolia",
  "requirements": {
    "photos": 4,
    "video": false,
    "audio_note": true
  },
  "deadline": "2025-06-15T23:59:59Z",
  "assigned_to": ["agent_123"],
  "metadata": {
    "plot_id": "A-47",
    "phase": "6-month-review"
  }
}
GET /v1/projects
List All Projects

Description

Retrieve all projects for your organization with filtering and pagination options.

  • Filter by type, status, date
  • Pagination support
  • Sort by multiple fields
  • Include statistics
  • Export formats (JSON, CSV)
Query Parameters
GET /v1/projects?type=reforestation&status=active&page=1&limit=20

// Response
{
  "success": true,
  "projects": [
    {
      "id": "proj_987654321",
      "name": "Atlantic Forest Reforestation",
      "type": "reforestation",
      "status": "active",
      "verifications_count": 847,
      "area_hectares": 125.4,
      "created_at": "2025-01-15T10:00:00Z"
    }
  ],
  "pagination": {
    "page": 1,
    "limit": 20,
    "total": 156
  }
}
PUT /v1/projects/{id}
Update Project

Description

Update project details, zones, or requirements. Add new collection areas or modify existing ones.

  • Update zones and polygons
  • Modify requirements
  • Change project status
  • Add team members
  • Update webhooks
Request Body
{
  "name": "Atlantic Forest Reforestation - Phase 2",
  "status": "active",
  "add_zones": [
    {
      "name": "Zone Beta",
      "coordinates": [...]
    }
  ],
  "requirements": {
    "min_trust_score": 80
  }
}
DELETE /v1/projects/{id}
Archive Project

Description

Archive a project (soft delete). Data is retained for compliance but project becomes inactive.

  • Soft delete with data retention
  • Export before archive option
  • Restore capability
  • Compliance audit trail
Response
{
  "success": true,
  "message": "Project archived successfully",
  "archived_at": "2025-06-01T15:30:00Z",
  "data_export_url": "https://api.spatialproof.com/exports/proj_987654321.zip"
}
POST /v1/verifications/{ulid}/analyze
Trigger AI Analysis

Description

Trigger or re-run AI vision analysis on a verification. Our GPT-4o powered engine analyzes the image, correlates with weather data, and generates comprehensive insights.

  • Scene classification & description
  • Vegetation & agriculture analysis
  • Weather-to-image correlation
  • Manipulation detection
  • Species identification
  • Carbon relevance assessment
Response 200
{
  "status": "completed",
  "analysis": {
    "overall_score": 94,
    "verdict": "verified",
    "confidence_level": "high",
    "scenario": {
      "primary": "FOREST",
      "environment_type": "outdoor"
    },
    "scores": {
      "image_quality": 92,
      "authenticity": 98,
      "weather_correlation": 95
    },
    "narrative_analysis": {...},
    "vegetation_analysis": {...}
  }
}
GET /v1/verifications
List Verifications

Description

Query verifications with advanced filtering by location, date, score, and more.

  • Filter by project, zone, date range
  • Geospatial queries (bbox, radius)
  • Filter by AI scores
  • Export to CSV/KML/GeoJSON
  • Aggregation statistics
Query Example
GET /v1/verifications?
  project_id=proj_987654321&
  min_score=70&
  bbox=-49.1,-27.0,-49.0,-26.9&
  date_from=2025-01-01&
  date_to=2025-06-30&
  format=geojson

Complete Data at Your Fingertips

Every API response is richly structured with all the data you need for verification, analysis, and compliance.

Response Sections
{
  "success": true,
  "verification": {
    "ulid": "01JXYZ1234567890ABCDEFGH",
    "captured_at": "2025-05-28T14:32:18.000000Z",
    "capture_mode": "photo",
    "project_id": "proj_987654321",
    "organization_id": "org_1234567890",
    
    // 📍 Location with Anti-Spoof Validation
    "location": {
      "latitude": -26.919444,
      "longitude": -49.066111,
      "altitude": 42.5,
      "accuracy": 4.2,
      "speed": 0.0,
      "heading": 127.5
    },
    
    // 📱 Device Information
    "device": {
      "model": "SM-G991B",
      "brand": "Samsung",
      "os": "Android 14",
      "app_version": "2.1.0"
    },
    
    // 🔒 Security Validation
    "security": {
      "is_mock_location": false,
      "is_rooted": false,
      "is_emulator": false,
      "has_vpn": false,
      "passed": true,
      "hash": "sha256:8a7f3c2b1e..."
    },
    
    // 📊 Real-time Sensor Data (25+ readings)
    "sensor_data": {
      "accelerometer": { "x": 0.12, "y": -0.08, "z": 9.81 },
      "gyroscope": { "x": 0.001, "y": -0.002, "z": 0.001 },
      "magnetometer": { "x": 99.1, "y": 209.1, "z": -636.2 },
      "compass": { "heading": 127.5, "accuracy": 2 },
      "light": { "estimatedLux": 15420 },
      "pressure": { "hPa": 1015.2 }
    },
    
    // 🛰️ Satellite Weather Data (Open-Meteo)
    "weather_data": {
      "temperature_2m": 26.5,
      "relative_humidity_2m": 72,
      "cloudcover_percent": 35,
      "precipitation_mm": 0,
      "wind_speed_kmh": 12.5,
      "pressure_msl_hpa": 1015.2,
      "shortwave_radiation_wm2": 620,
      "et0_fao_evapotranspiration_mm": 0.35
    },
    
    // 🤖 AI Vision Analysis (GPT-4o)
    "ai_analysis": {
      "overall_score": 94,
      "verdict": "verified",
      "vegetation_analysis": {
        "coverage_percent": 92,
        "health_status": "excellent",
        "species_identified": [
          {
            "common_name": "Brazilian Pine",
            "scientific_name": "Araucaria angustifolia"
          }
        ]
      }
    },
    
    // 🖼️ Media Assets
    "media": {
      "photo_url": "https://cdn.spatialproof.com/...",
      "video_url": null,
      "audio_url": null
    },
    
    "certificate_url": "https://spatialproof.com/verify/01JXYZ..."
  }
}
# Get verification by ULID
curl -X GET "https://api.spatialproof.com/v1/verifications/01JXYZ1234567890ABCDEFGH" \
  -H "Authorization: Bearer sp_live_xxxxxxxxxxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json"

# Create a new project
curl -X POST "https://api.spatialproof.com/v1/projects" \
  -H "Authorization: Bearer sp_live_xxxxxxxxxxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "organization_id": "org_1234567890",
    "name": "Atlantic Forest Reforestation MRV",
    "type": "reforestation",
    "collection_zones": [
      {
        "name": "Zone Alpha",
        "type": "polygon",
        "coordinates": [
          [-49.0661, -26.9194],
          [-49.0651, -26.9184],
          [-49.0641, -26.9194],
          [-49.0661, -26.9194]
        ]
      }
    ]
  }'

# Request a field collection
curl -X POST "https://api.spatialproof.com/v1/collections" \
  -H "Authorization: Bearer sp_live_xxxxxxxxxxxxxxxxxxxxxxxx" \
  -H "Content-Type: application/json" \
  -d '{
    "project_id": "proj_987654321",
    "location": {
      "latitude": -26.9194,
      "longitude": -49.0661
    },
    "type": "reforestation_monitoring",
    "priority": "high"
  }'
import requests
import json

# Configuration
API_KEY = "sp_live_xxxxxxxxxxxxxxxxxxxxxxxx"
BASE_URL = "https://api.spatialproof.com/v1"

headers = {
    "Authorization": f"Bearer {API_KEY}",
    "Content-Type": "application/json"
}

# Get verification by ULID
def get_verification(ulid):
    response = requests.get(
        f"{BASE_URL}/verifications/{ulid}",
        headers=headers
    )
    return response.json()

# Create a new project
def create_project(project_data):
    response = requests.post(
        f"{BASE_URL}/projects",
        headers=headers,
        json=project_data
    )
    return response.json()

# Request field collection
def request_collection(project_id, lat, lng):
    data = {
        "project_id": project_id,
        "location": {
            "latitude": lat,
            "longitude": lng,
            "radius_meters": 50
        },
        "type": "reforestation_monitoring",
        "priority": "high"
    }
    response = requests.post(
        f"{BASE_URL}/collections",
        headers=headers,
        json=data
    )
    return response.json()

# Example usage
if __name__ == "__main__":
    # Get verification
    verification = get_verification("01JXYZ1234567890ABCDEFGH")
    print(f"Trust Score: {verification['verification']['ai_analysis']['overall_score']}")
    
    # Create project
    project = {
        "organization_id": "org_1234567890",
        "name": "Atlantic Forest Reforestation",
        "type": "reforestation"
    }
    result = create_project(project)
    print(f"Project created: {result['project']['id']}")
// Configuration
const API_KEY = 'sp_live_xxxxxxxxxxxxxxxxxxxxxxxx';
const BASE_URL = 'https://api.spatialproof.com/v1';

const headers = {
  'Authorization': `Bearer ${API_KEY}`,
  'Content-Type': 'application/json'
};

// Get verification by ULID
async function getVerification(ulid) {
  const response = await fetch(`${BASE_URL}/verifications/${ulid}`, {
    method: 'GET',
    headers: headers
  });
  return await response.json();
}

// Create a new project
async function createProject(projectData) {
  const response = await fetch(`${BASE_URL}/projects`, {
    method: 'POST',
    headers: headers,
    body: JSON.stringify(projectData)
  });
  return await response.json();
}

// Request field collection
async function requestCollection(projectId, lat, lng) {
  const data = {
    project_id: projectId,
    location: {
      latitude: lat,
      longitude: lng,
      radius_meters: 50
    },
    type: 'reforestation_monitoring',
    priority: 'high',
    instructions: 'Capture 360° photos of planted trees'
  };
  
  const response = await fetch(`${BASE_URL}/collections`, {
    method: 'POST',
    headers: headers,
    body: JSON.stringify(data)
  });
  return await response.json();
}

// Example usage
(async () => {
  try {
    // Get verification
    const verification = await getVerification('01JXYZ1234567890ABCDEFGH');
    console.log('Trust Score:', verification.verification.ai_analysis.overall_score);
    
    // Create project with zones
    const project = {
      organization_id: 'org_1234567890',
      name: 'Atlantic Forest Reforestation',
      type: 'reforestation',
      collection_zones: [{
        name: 'Zone Alpha',
        type: 'polygon',
        coordinates: [
          [-49.0661, -26.9194],
          [-49.0651, -26.9184],
          [-49.0641, -26.9194],
          [-49.0661, -26.9194]
        ]
      }]
    };
    const result = await createProject(project);
    console.log('Project created:', result.project.id);
    
  } catch (error) {
    console.error('Error:', error);
  }
})();
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.net.URI;
import com.google.gson.Gson;
import com.google.gson.JsonObject;

public class SpatialProofClient {
    private static final String API_KEY = "sp_live_xxxxxxxxxxxxxxxxxxxxxxxx";
    private static final String BASE_URL = "https://api.spatialproof.com/v1";
    private final HttpClient httpClient;
    private final Gson gson;
    
    public SpatialProofClient() {
        this.httpClient = HttpClient.newHttpClient();
        this.gson = new Gson();
    }
    
    // Get verification by ULID
    public JsonObject getVerification(String ulid) throws Exception {
        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create(BASE_URL + "/verifications/" + ulid))
            .header("Authorization", "Bearer " + API_KEY)
            .header("Content-Type", "application/json")
            .GET()
            .build();
            
        HttpResponse response = httpClient.send(
            request, 
            HttpResponse.BodyHandlers.ofString()
        );
        
        return gson.fromJson(response.body(), JsonObject.class);
    }
    
    // Create a new project
    public JsonObject createProject(JsonObject projectData) throws Exception {
        String requestBody = gson.toJson(projectData);
        
        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create(BASE_URL + "/projects"))
            .header("Authorization", "Bearer " + API_KEY)
            .header("Content-Type", "application/json")
            .POST(HttpRequest.BodyPublishers.ofString(requestBody))
            .build();
            
        HttpResponse response = httpClient.send(
            request, 
            HttpResponse.BodyHandlers.ofString()
        );
        
        return gson.fromJson(response.body(), JsonObject.class);
    }
    
    // Request field collection
    public JsonObject requestCollection(String projectId, double lat, double lng) throws Exception {
        JsonObject location = new JsonObject();
        location.addProperty("latitude", lat);
        location.addProperty("longitude", lng);
        location.addProperty("radius_meters", 50);
        
        JsonObject data = new JsonObject();
        data.addProperty("project_id", projectId);
        data.add("location", location);
        data.addProperty("type", "reforestation_monitoring");
        data.addProperty("priority", "high");
        
        String requestBody = gson.toJson(data);
        
        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create(BASE_URL + "/collections"))
            .header("Authorization", "Bearer " + API_KEY)
            .header("Content-Type", "application/json")
            .POST(HttpRequest.BodyPublishers.ofString(requestBody))
            .build();
            
        HttpResponse response = httpClient.send(
            request, 
            HttpResponse.BodyHandlers.ofString()
        );
        
        return gson.fromJson(response.body(), JsonObject.class);
    }
    
    public static void main(String[] args) {
        try {
            SpatialProofClient client = new SpatialProofClient();
            
            // Get verification
            JsonObject verification = client.getVerification("01JXYZ1234567890ABCDEFGH");
            System.out.println("Trust Score: " + 
                verification.getAsJsonObject("verification")
                    .getAsJsonObject("ai_analysis")
                    .get("overall_score").getAsInt());
            
            // Create project
            JsonObject projectData = new JsonObject();
            projectData.addProperty("organization_id", "org_1234567890");
            projectData.addProperty("name", "Atlantic Forest Reforestation");
            projectData.addProperty("type", "reforestation");
            
            JsonObject result = client.createProject(projectData);
            System.out.println("Project created: " + 
                result.getAsJsonObject("project").get("id").getAsString());
                
        } catch (Exception e) {
            e.printStackTrace();
        }
    }
}
using System;
using System.Net.Http;
using System.Net.Http.Headers;
using System.Text;
using System.Threading.Tasks;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;

public class SpatialProofClient
{
    private const string ApiKey = "sp_live_xxxxxxxxxxxxxxxxxxxxxxxx";
    private const string BaseUrl = "https://api.spatialproof.com/v1";
    private readonly HttpClient httpClient;

    public SpatialProofClient()
    {
        httpClient = new HttpClient();
        httpClient.DefaultRequestHeaders.Authorization = 
            new AuthenticationHeaderValue("Bearer", ApiKey);
        httpClient.DefaultRequestHeaders.Accept.Add(
            new MediaTypeWithQualityHeaderValue("application/json"));
    }

    // Get verification by ULID
    public async Task<JObject> GetVerificationAsync(string ulid)
    {
        var response = await httpClient.GetAsync($"{BaseUrl}/verifications/{ulid}");
        response.EnsureSuccessStatusCode();
        var content = await response.Content.ReadAsStringAsync();
        return JObject.Parse(content);
    }

    // Create a new project
    public async Task<JObject> CreateProjectAsync(JObject projectData)
    {
        var json = JsonConvert.SerializeObject(projectData);
        var content = new StringContent(json, Encoding.UTF8, "application/json");
        
        var response = await httpClient.PostAsync($"{BaseUrl}/projects", content);
        response.EnsureSuccessStatusCode();
        var responseContent = await response.Content.ReadAsStringAsync();
        return JObject.Parse(responseContent);
    }

    // Request field collection
    public async Task<JObject> RequestCollectionAsync(
        string projectId, 
        double latitude, 
        double longitude)
    {
        var data = new JObject
        {
            ["project_id"] = projectId,
            ["location"] = new JObject
            {
                ["latitude"] = latitude,
                ["longitude"] = longitude,
                ["radius_meters"] = 50
            },
            ["type"] = "reforestation_monitoring",
            ["priority"] = "high",
            ["instructions"] = "Capture 360° photos of planted trees"
        };
        
        var json = JsonConvert.SerializeObject(data);
        var content = new StringContent(json, Encoding.UTF8, "application/json");
        
        var response = await httpClient.PostAsync($"{BaseUrl}/collections", content);
        response.EnsureSuccessStatusCode();
        var responseContent = await response.Content.ReadAsStringAsync();
        return JObject.Parse(responseContent);
    }

    public static async Task Main(string[] args)
    {
        var client = new SpatialProofClient();
        
        // Get verification
        var verification = await client.GetVerificationAsync("01JXYZ1234567890ABCDEFGH");
        Console.WriteLine($"Trust Score: {verification["verification"]["ai_analysis"]["overall_score"]}");
        
        // Create project
        var projectData = new JObject
        {
            ["organization_id"] = "org_1234567890",
            ["name"] = "Atlantic Forest Reforestation",
            ["type"] = "reforestation"
        };
        
        var result = await client.CreateProjectAsync(projectData);
        Console.WriteLine($"Project created: {result["project"]["id"]}");
        
        // Request collection
        var collection = await client.RequestCollectionAsync(
            "proj_987654321", 
            -26.9194, 
            -49.0661
        );
        Console.WriteLine($"Collection requested: {collection["collection"]["id"]}");
    }
}
<?php

class SpatialProofClient {
    private const API_KEY = 'sp_live_xxxxxxxxxxxxxxxxxxxxxxxx';
    private const BASE_URL = 'https://api.spatialproof.com/v1';
    
    private $headers;
    
    public function __construct() {
        $this->headers = [
            'Authorization: Bearer ' . self::API_KEY,
            'Content-Type: application/json'
        ];
    }
    
    // Get verification by ULID
    public function getVerification($ulid) {
        $ch = curl_init();
        curl_setopt($ch, CURLOPT_URL, self::BASE_URL . "/verifications/{$ulid}");
        curl_setopt($ch, CURLOPT_HTTPHEADER, $this->headers);
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
        
        $response = curl_exec($ch);
        curl_close($ch);
        
        return json_decode($response, true);
    }
    
    // Create a new project
    public function createProject($projectData) {
        $ch = curl_init();
        curl_setopt($ch, CURLOPT_URL, self::BASE_URL . '/projects');
        curl_setopt($ch, CURLOPT_HTTPHEADER, $this->headers);
        curl_setopt($ch, CURLOPT_POST, true);
        curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($projectData));
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
        
        $response = curl_exec($ch);
        curl_close($ch);
        
        return json_decode($response, true);
    }
    
    // Request field collection
    public function requestCollection($projectId, $lat, $lng) {
        $data = [
            'project_id' => $projectId,
            'location' => [
                'latitude' => $lat,
                'longitude' => $lng,
                'radius_meters' => 50
            ],
            'type' => 'reforestation_monitoring',
            'priority' => 'high',
            'instructions' => 'Capture 360° photos of planted trees'
        ];
        
        $ch = curl_init();
        curl_setopt($ch, CURLOPT_URL, self::BASE_URL . '/collections');
        curl_setopt($ch, CURLOPT_HTTPHEADER, $this->headers);
        curl_setopt($ch, CURLOPT_POST, true);
        curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
        
        $response = curl_exec($ch);
        curl_close($ch);
        
        return json_decode($response, true);
    }
    
    // Create organization
    public function createOrganization($type, $name, $taxId, $country) {
        $data = [
            'type' => $type, // company, ngo, government
            'name' => $name,
            'tax_id' => $taxId,
            'country' => $country
        ];
        
        $ch = curl_init();
        curl_setopt($ch, CURLOPT_URL, self::BASE_URL . '/organizations');
        curl_setopt($ch, CURLOPT_HTTPHEADER, $this->headers);
        curl_setopt($ch, CURLOPT_POST, true);
        curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
        
        $response = curl_exec($ch);
        curl_close($ch);
        
        return json_decode($response, true);
    }
}

// Example usage
$client = new SpatialProofClient();

// Get verification
$verification = $client->getVerification('01JXYZ1234567890ABCDEFGH');
echo "Trust Score: " . $verification['verification']['ai_analysis']['overall_score'] . "\n";

// Create organization
$org = $client->createOrganization(
    'company',
    'Trust Carbon Ltd',
    '48.468.140/0001-15',
    'BR'
);
echo "Organization created: " . $org['organization']['id'] . "\n";

// Create project
$projectData = [
    'organization_id' => 'org_1234567890',
    'name' => 'Atlantic Forest Reforestation',
    'type' => 'reforestation',
    'collection_zones' => [
        [
            'name' => 'Zone Alpha',
            'type' => 'polygon',
            'coordinates' => [
                [-49.0661, -26.9194],
                [-49.0651, -26.9184],
                [-49.0641, -26.9194],
                [-49.0661, -26.9194]
            ]
        ]
    ]
];

$project = $client->createProject($projectData);
echo "Project created: " . $project['project']['id'] . "\n";

// Request collection
$collection = $client->requestCollection(
    'proj_987654321', 
    -26.9194, 
    -49.0661
);
echo "Collection requested: " . $collection['collection']['id'] . "\n";

?>
require 'net/http'
require 'uri'
require 'json'

class SpatialProofClient
  API_KEY = 'sp_live_xxxxxxxxxxxxxxxxxxxxxxxx'
  BASE_URL = 'https://api.spatialproof.com/v1'
  
  def initialize
    @headers = {
      'Authorization' => "Bearer #{API_KEY}",
      'Content-Type' => 'application/json'
    }
  end
  
  # Get verification by ULID
  def get_verification(ulid)
    uri = URI("#{BASE_URL}/verifications/#{ulid}")
    http = Net::HTTP.new(uri.host, uri.port)
    http.use_ssl = true
    
    request = Net::HTTP::Get.new(uri)
    @headers.each { |key, value| request[key] = value }
    
    response = http.request(request)
    JSON.parse(response.body)
  end
  
  # Create a new project
  def create_project(project_data)
    uri = URI("#{BASE_URL}/projects")
    http = Net::HTTP.new(uri.host, uri.port)
    http.use_ssl = true
    
    request = Net::HTTP::Post.new(uri)
    @headers.each { |key, value| request[key] = value }
    request.body = project_data.to_json
    
    response = http.request(request)
    JSON.parse(response.body)
  end
  
  # Request field collection
  def request_collection(project_id, lat, lng)
    data = {
      'project_id' => project_id,
      'location' => {
        'latitude' => lat,
        'longitude' => lng,
        'radius_meters' => 50
      },
      'type' => 'reforestation_monitoring',
      'priority' => 'high',
      'instructions' => 'Capture 360° photos of planted trees'
    }
    
    uri = URI("#{BASE_URL}/collections")
    http = Net::HTTP.new(uri.host, uri.port)
    http.use_ssl = true
    
    request = Net::HTTP::Post.new(uri)
    @headers.each { |key, value| request[key] = value }
    request.body = data.to_json
    
    response = http.request(request)
    JSON.parse(response.body)
  end
  
  # Create organization
  def create_organization(type, name, tax_id, country)
    data = {
      'type' => type, # company, ngo, government
      'name' => name,
      'tax_id' => tax_id,
      'country' => country
    }
    
    uri = URI("#{BASE_URL}/organizations")
    http = Net::HTTP.new(uri.host, uri.port)
    http.use_ssl = true
    
    request = Net::HTTP::Post.new(uri)
    @headers.each { |key, value| request[key] = value }
    request.body = data.to_json
    
    response = http.request(request)
    JSON.parse(response.body)
  end
end

# Example usage
client = SpatialProofClient.new

# Get verification
verification = client.get_verification('01JXYZ1234567890ABCDEFGH')
puts "Trust Score: #{verification['verification']['ai_analysis']['overall_score']}"

# Create organization
org = client.create_organization(
  'company',
  'Trust Carbon Ltd',
  '48.468.140/0001-15',
  'BR'
)
puts "Organization created: #{org['organization']['id']}"

# Create project
project_data = {
  'organization_id' => 'org_1234567890',
  'name' => 'Atlantic Forest Reforestation',
  'type' => 'reforestation',
  'collection_zones' => [
    {
      'name' => 'Zone Alpha',
      'type' => 'polygon',
      'coordinates' => [
        [-49.0661, -26.9194],
        [-49.0651, -26.9184],
        [-49.0641, -26.9194],
        [-49.0661, -26.9194]
      ]
    }
  ]
}

project = client.create_project(project_data)
puts "Project created: #{project['project']['id']}"

# Request collection
collection = client.request_collection(
  'proj_987654321',
  -26.9194,
  -49.0661
)
puts "Collection requested: #{collection['collection']['id']}"

Intelligence Built Into
Every Verification

Our GPT-4o powered vision engine doesn't just store data — it analyzes, correlates, and provides expert-level insights automatically.

Vegetation Analysis

Detailed flora assessment

Automatically identifies plant species, assesses health status, estimates coverage, and detects signs of disease or stress. Perfect for carbon credit MRV and agricultural monitoring.

species_identified[] health_status coverage_percent biodiversity_index

Weather Correlation

Satellite vs. Image matching

Cross-references visible weather conditions in the image with satellite data at the exact capture time. Detects discrepancies that could indicate fraud or manipulation.

sky_condition_match lighting_match precipitation_match discrepancies[]

Authenticity Detection

Anti-manipulation analysis

Analyzes image quality, lighting consistency, shadow patterns, and sensor data correlation to detect potential manipulation, recycled images, or AI-generated content.

authenticity_score manipulation_detected anomalies[] sensor_correlation

Narrative Reports

Expert-level documentation

Generates detailed, human-readable reports describing the scene, findings, and conclusions. Ready for audit submissions, compliance reports, and stakeholder communication.

executive_summary scene_description recommendations[] carbon_relevance

Integration in 3 Steps

From API access to production-ready verification — we'll guide you every step of the way.

1

Request API Access

Contact our team to discuss your use case and get your API credentials. We'll help you design the optimal integration for your needs.

# Your API key will look like this:
API_KEY="sp_live_xxxxxxxxxxxxxxxxxxxxxxxx"

# Base URL for all requests:
BASE_URL="https://api.spatialproof.com/v1"
2

Create Your Project

Set up a project with your collection zones, requirements, and webhook endpoints. Invite field agents through our mobile app.

curl -X POST "https://api.spatialproof.com/v1/projects" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Forest Monitoring Q4",
    "webhook_url": "https://your-app.com/webhooks/spatial"
  }'
3

Receive & Process Verifications

Field agents capture verifications using our mobile app. You receive real-time webhooks with full data, or query our API on-demand.

# Webhook payload example:
{
  "event": "verification.completed",
  "verification": {
    "ulid": "01JXYZ...",
    "ai_analysis": {
      "overall_score": 94,
      "verdict": "verified"
    }
  }
}

Ready to Build With
Verified Ground Truth?

Contact our team to discuss your use case, request API access, and get started with the world's most comprehensive field verification infrastructure.