Reference

Local API

Applies to Anacom Earth 0.10.0 · Perichora 0.5.0No other versions have public documentation.

Anacom Earth serves its workspace from a local HTTP API bound to 127.0.0.1. It is not a cloud service and has no public endpoint.

Overview

  • The server listens on loopback only, on a free port chosen at start (from 8765 upward). perichora app status prints the URL.
  • Requests must carry a loopback Host; cross-origin requests are refused.
  • Two interfaces with separate gates: the research API (read-only) and the management API (paired sessions only).
  • OpenAPI documents for both are generated from the implementation and ship with the source (earth_web/openapi.json, openapi.manage.json).

Research API (public, read-only)

Supported for local tools and scripts. GET only; any write method is refused.

Research API endpoints
Method and pathReturnsNotes
GET /api/statusAppStatusVersion, mode, scope flags and catalogue integrity state. Always available.
GET /api/map/regionsMapRegionsRegion outlines for the map. 503 when the catalogue is absent or fails verification.
GET /api/geo/overviewGeoOverviewGeo research definition summary.
GET /api/geo/regions/{region_id}GeoRegionDetailregion_id matches ^[a-z0-9-]{1,40}$.
GET /api/terra/overviewTerraOverviewTerra research definition summary.
GET /api/terra/regions/{region_id}TerraRegionDetailSame identifier rule.
GET /api/{system}/regions/{region_id}/gridGridLayersystem is geo or terra.
GET /api/modelsModelManagerRead-only view of the local runtime, registry and research definitions.
Terminal
curl -s http://127.0.0.1:PORT/api/status
Response (public-restricted build, abridged)
{
  "app": "Anacom Earth",
  "version": "0.10.0",
  "mode": "local_read_only",
  "scope": {
    "audience": "local_research",
    "scientific_inference": false,
    "deployment_allowed": false
  },
  "catalogue": {
    "status": "not_included",
    "detail": "This build does not include the research catalogue because its source redistribution rights are unreviewed. Model management is unaffected."
  }
}

Management API (internal)

Management API routes
RoutePurpose
POST /manage/v1/sessionExchange a pairing code (10–16 characters) for a session
GET /manage/v1/sessionCurrent session state
POST /manage/v1/session/endEnd the session
POST /manage/v1/pairing-codesMint a further pairing code (paired sessions only)
GET /manage/v1/stateRegistry, library, storage and limits
GET, POST /manage/v1/operationsList or submit an operation (inspect, install, verify, refresh, remove)
GET /manage/v1/operations/{op_id}Operation progress
POST /manage/v1/operations/{op_id}/cancelCancel an operation

There is no route for adding publisher trust, running shell commands, reading credentials or fetching arbitrary URLs.

Errors and limits

  • Errors are generic JSON bodies without stack traces or paths.
  • Management requests are JSON only, at most 4 KiB, with separate rate limits for anonymous and paired traffic; 429 means slow down.
  • One management operation runs at a time (409 if another is active). Operations are idempotent by key and cancellable.