GeoLens
Overview
PostGIS-native geospatial data catalog with OGC API Features compliance
GeoLens API 1.0.0
Section titled “GeoLens API 1.0.0”Overview
GeoLens is a self-hosted spatial data catalog that ingests vector files (GeoPackage, Shapefile, GeoJSON, CSV), stores them in PostGIS, and exposes them through a standards-compliant OGC API.
OGC Conformance Classes
- OGC API Common 1.0 — Core, Landing Page, JSON, OAS 3.0
- OGC API Features Part 1 — Core, GeoJSON, OAS 3.0
- OGC API Features Part 3 — Filtering (CQL2-Text, CQL2-JSON)
QGIS Quick-start
- Layer > Add Layer > WFS / OGC API Features
- URL:
{your-server}/api/ - GeoLens advertises collections automatically.
GDAL / ogr2ogr Quick-start
# List collections
ogrinfo OAPIF:{your-server}/api/
# Download a collection to GeoPackage
ogr2ogr -f GPKG output.gpkg OAPIF:{your-server}/api/ {collection-id}
Authentication
GeoLens supports three authentication methods. Public datasets are accessible without credentials; private/restricted datasets require one of:
| Method | Usage |
|---|---|
| API Key header | X-Api-Key: <key> |
| JWT Bearer token | Authorization: Bearer <token> |
| API Key query param | ?api_key=<key> |
Priority: header API key > query param API key > JWT > anonymous.
GDAL / ogr2ogr with API Key
# List collections (including private ones accessible to your key)
ogrinfo "OAPIF:{your-server}/api/?api_key=YOUR_KEY"
# Download a private collection
ogr2ogr -f GPKG out.gpkg "OAPIF:{your-server}/api/?api_key=YOUR_KEY" {collection-id}
QGIS with API Key
In the WFS / OGC API Features connection dialog, append ?api_key=YOUR_KEY
to the server URL.