Listings and their output

Every listing function returns a Listing: a lazy, read-only sequence of entries with three ways out – the entries themselves, a table, and JSON.

A lazy sequence

Nothing is read until a listing is first used, and then the entries are kept:

from geodetic_engine import catalog

listing = catalog.crs(authority="EPSG", kind="geocentric")
print(repr(listing))
print(len(listing), "entries")
print(repr(listing))
<Listing crs {'authority': ['EPSG'], 'kind': 'geocentric', 'deprecated': False}: unread>
252 entries
<Listing crs {'authority': ['EPSG'], 'kind': 'geocentric', 'deprecated': False}: 252 entries>

It is a Sequence: index it, slice it, test it, loop over it. first() returns the first entry or None, and one() the only one, raising when there is none or more:

print(listing[0], "|", listing[-1])
print(catalog.crs(code="EPSG:4936").one())
TWD97 (EPSG:3822) | MAGNA-SIRGAS 2018 (EPSG:20044)
ETRS89 (EPSG:4936)
catalog.crs(authority="EPSG", name="UTM zone 32N").one()
---------------------------------------------------------------------------
NotUniqueError                            Traceback (most recent call last)
Cell In[3], line 1
----> 1 catalog.crs(authority="EPSG", name="UTM zone 32N").one()

File /workspace/geodetic_engine/catalog/_listing.py:153, in Listing.one(self)
    151     shown = ", ".join(str(entry) for entry in entries[:5])
    152     more = f" and {len(entries) - 5} more" if len(entries) > 5 else ""
--> 153     raise NotUniqueError(
    154         f"{len(entries)} {self._kind} entries match {self._filters!r}: "
    155         f"{shown}{more}"
    156     )
    157 return entries[0]

NotUniqueError: 29 crs entries match {'authority': ['EPSG'], 'name': 'UTM zone 32N', 'deprecated': False}: ELD79 / UTM zone 32N (EPSG:2077), Manoca 1962 / UTM zone 32N (EPSG:2215), ETRS89 / UTM zone 32N (N-E) (EPSG:3044), ETRS89-ITA [IGM95] / UTM zone 32N (EPSG:3064), LGD2006 / UTM zone 32N (EPSG:3199) and 24 more

A listing belongs to the database it was made for. If PROJ’s search path is switched to another database, a listing not yet read refuses to be read, and any listing refuses to be exported as JSON, since the export names the database that answered. Both raise CatalogError; call the listing function again. Entries already read stay as they are.

A table

to_dataframe() gives one row per entry. References become "name (AUTH:CODE)", enumerations their value, and the first area of use is spread over area_of_use, west, south, east and north. The columns are the same when the listing is empty:

catalog.operations(source_crs="EPSG:4230", target_crs="EPSG:4326", max_accuracy=2).to_dataframe()
authority_code auth_name code name kind method source_crs target_crs accuracy version grid_names area_of_use west south east north superseded_by osdu_ids deprecated
0 EPSG:1275 EPSG 1275 ED50 to WGS 84 (17) transformation Geocentric translations (geog2D domain) (EPSG:... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 2 IGN-Fra () France - onshore and offshore, mainland and Co... -9.86 41.15 10.38 51.56 () (reference-data--CoordinateTransformation:EPSG... False
1 EPSG:1311 EPSG 1311 ED50 to WGS 84 (18) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 UKOOA-CO () Denmark - offshore North Sea; Ireland - offsho... -16.1 47.42 10.86 63.89 () (reference-data--CoordinateTransformation:EPSG... False
2 EPSG:1612 EPSG 1612 ED50 to WGS 84 (23) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 EPSG-Nor N62 2001 () Norway - offshore north of 62°N. Also Svalbard... -3.35 62 38.01 84.73 () (reference-data--CoordinateTransformation:EPSG... False
3 EPSG:1613 EPSG 1613 ED50 to WGS 84 (24) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 EPSG-Nor S62 2001 () Norway - offshore south of 62°N - North Sea. 1.37 56.08 10.81 62.01 () (reference-data--CoordinateTransformation:EPSG... False
4 EPSG:1627 EPSG 1627 ED50 to WGS 84 (25) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 EPSG-Dnk () Denmark - onshore. 7.98 54.5 15.28 57.81 () (reference-data--CoordinateTransformation:EPSG... False
5 EPSG:1629 EPSG 1629 ED50 to WGS 84 (26) transformation Geocentric translations (geog2D domain) (EPSG:... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 EPSG-Gib () Gibraltar - onshore and offshore. -5.42 36 -4.89 36.16 () (reference-data--CoordinateTransformation:EPSG... False
6 EPSG:1631 EPSG 1631 ED50 to WGS 84 (27) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1.5 EPSG-Esp Bal () Spain - Balearic Islands. 1.12 38.59 4.39 40.15 () (reference-data--CoordinateTransformation:EPSG... False
7 EPSG:1633 EPSG 1633 ED50 to WGS 84 (28) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1.5 EPSG-Esp () Spain - onshore mainland except northwest (nor... -7.54 35.95 3.39 43.56 () (reference-data--CoordinateTransformation:EPSG... False
8 EPSG:1635 EPSG 1635 ED50 to WGS 84 (29) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1.5 EPSG-Esp NW () Spain - onshore mainland north of 41°30'N and ... -9.37 41.5 -4.5 43.82 () (reference-data--CoordinateTransformation:EPSG... False
9 EPSG:1784 EPSG 1784 ED50 to WGS 84 (30) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 2 EPSG-Tur () Türkiye (Turkey) - onshore and offshore. 25.62 34.2 44.83 43.45 () (reference-data--CoordinateTransformation:EPSG... False
10 EPSG:1989 EPSG 1989 ED50 to WGS 84 (34) transformation Coordinate Frame rotation (geog2D domain) (EPS... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 CGC-Prt 1m () Portugal - mainland - onshore. -9.56 36.95 -6.19 42.16 () () False
11 EPSG:1998 EPSG 1998 ED50 to WGS 84 (36) transformation Position Vector transformation (geog2D domain)... ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 EPSG-Ger Nsea () Germany - offshore North Sea. 3.34 53.58 8.88 55.92 () () False
12 EPSG:8047 EPSG 8047 ED50 to WGS 84 (15) concatenated_operation NaN ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1.5 NMA-Nor N65 1991 () Norway - offshore north of 65°N. Also Svalbard. -3.35 65 38 84.73 (EPSG:8569, EPSG:1612) (reference-data--CoordinateTransformation:EPSG... False
13 EPSG:8569 EPSG 8569 ED50 to WGS 84 (21) concatenated_operation NaN ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1.5 EPSG-Nor N65 1997 () Norway - offshore north of 65°N. Also Svalbard. -3.35 65 38 84.73 (EPSG:1612,) () False
14 EPSG:15933 EPSG 15933 ED50 to WGS 84 (41) transformation NTv2 (EPSG:9615) ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 OGP-Esp v2 (SPED2ETV2.gsb,) Spain - mainland, Balearic Islands and Ceuta -... -9.37 35.84 4.39 43.82 () () False
15 ESRI:108068 ESRI 108068 ED_1950_To_WGS_1984_NTv2_PENR2009 transformation NTv2 (EPSG:9615) ED50 (EPSG:4230) WGS 84 (EPSG:4326) 0.9 NaN (PENR2009,) Spain - mainland and Ceuta - onshore. -9.37 35.84 3.39 43.82 () () False
16 ESRI:108069 ESRI 108069 ED_1950_To_WGS_1984_NTv2_BALR2009 transformation NTv2 (EPSG:9615) ED50 (EPSG:4230) WGS 84 (EPSG:4326) 0.9 NaN (BALR2009,) Spain - Balearic Islands. 1.12 38.59 4.39 40.15 () () False
17 ESRI:108119 ESRI 108119 ED_1950_To_WGS_1984_NTv2_Baleares transformation NTv2 (EPSG:9615) ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 NaN (baleares,) Spain - Balearic Islands. 1.12 38.59 4.39 40.15 () () False
18 ESRI:108136 ESRI 108136 ED_1950_To_WGS_1984_NTv2_Peninsula transformation NTv2 (EPSG:9615) ED50 (EPSG:4230) WGS 84 (EPSG:4326) 1 NaN (peninsula,) Spain - mainland and Ceuta - onshore. -9.37 35.84 3.39 43.82 () () False
19 ESRI:108359 ESRI 108359 ED_1950_To_WGS_1984_NTv2_Catalonia transformation NTv2 (EPSG:9615) ED50 (EPSG:4230) WGS 84 (EPSG:4326) 0.05 NaN (100800401,) Spain - Catalonia onshore. 0.16 40.49 3.39 42.86 () () False

JSON

Two JSON forms, for two purposes.

An object’s definition: official PROJJSON

Each entry’s to_json_dict() is the object’s full definition as PROJJSON, exactly as PROJ exports it, $schema included. It is what pyproj’s own to_json_dict() returns for the same code, and PROJ can read it back:

import pyproj

entry = catalog.ellipsoids(code="EPSG:7019").one()
definition = entry.to_json_dict()
print(definition)
print(pyproj.crs.Ellipsoid.from_json_dict(definition).name)
{'$schema': 'https://proj.org/schemas/v0.7/projjson.schema.json', 'type': 'Ellipsoid', 'name': 'GRS 1980', 'semi_major_axis': 6378137, 'inverse_flattening': 298.257222101, 'id': {'authority': 'EPSG', 'code': 7019}}
GRS 1980

PROJ exports a coordinate system, unit or method only inside another object. For those, to_json_dict() is the form PROJ writes there, which PROJJSON’s schema defines, but which its schema does not accept as a document of its own. A grid file has no PROJJSON form.

Entry

to_json_dict()

Validates against

CRS, operation, datum, ellipsoid, prime meridian

PROJ’s export

The PROJJSON schema

Coordinate system

PROJ’s export from a CRS using it, else assembled the same way

PROJJSON’s coordinate_system definition

Unit

PROJJSON’s unit object, with its id

PROJJSON’s unit definition

Method

PROJJSON’s method object

PROJJSON’s method definition

Grid

The listing item

The listing schema’s grid_item

A listing: PROJJSON-shaped items in an envelope

PROJJSON has no place for what a listing is about: it allows no property its schema does not name, and names no deprecation, replacement, OSDU id or grid availability. So to_json_dict() wraps items in a small envelope that records the database that answered and the filters asked for. Each item uses PROJJSON’s names and value shapes wherever PROJJSON has the property – type, name, id, area, bbox, accuracy, references as {name, id} – and adds the rest beside them:

import json

document = catalog.datums(code="EPSG:6258").to_json_dict()
print(json.dumps({**document, "database": "..."}, indent=2)[:1500])
{
  "$schema": "https://equinor.github.io/geodetic-engine/schemas/catalog-listing-v1.schema.json",
  "type": "CatalogListing",
  "kind": "datums",
  "database": "...",
  "filters": {
    "code": "EPSG:6258",
    "deprecated": false
  },
  "count": 1,
  "items": [
    {
      "type": "DatumEnsemble",
      "name": "European Terrestrial Reference System 1989 ensemble",
      "id": {
        "authority": "EPSG",
        "code": 6258
      },
      "kind": "geodetic",
      "area": "Europe - onshore and offshore: Albania; Andorra; Austria; Belgium; Bosnia and Herzegovina; Bulgaria; Croatia; Czechia; Denmark; Estonia; Faroe Islands; Finland; France; Germany; Gibraltar; Greece; Hungary; Ireland; Italy; Kosovo; Latvia; Liechtenstein; Lithuania; Luxembourg; Malta; Moldova; Monaco; Montenegro; Netherlands; North Macedonia; Norway including Svalbard and Jan Mayen; Poland; Portugal - mainland; Romania; San Marino; Serbia; Slovakia; Slovenia; Spain - mainland and Balearic islands; Sweden; Switzerland; United Kingdom (UK) including Channel Islands and Isle of Man; Vatican City State.",
      "bbox": {
        "south_latitude": 33.26,
        "west_longitude": -16.1,
        "north_latitude": 84.73,
        "east_longitude": 38.0
      },
      "ellipsoid": {
        "name": "GRS 1980",
        "id": {
          "authority": "EPSG",
          "code": 7019
        }
      },
      "prime_meridian": {
        "name": "Greenwich",
        "id": {
          "authority": "EPSG",
          "code

include_definitions=True adds each entry’s full PROJJSON to its item as definition. It builds every object through PROJ, so it takes longer on a large listing.

filters holds the filters that were given; one left out was not asked for. The exception is deprecated, which a listing that has the filter always states: false is the default, current objects only, and null is deprecated=None, deprecated objects as well.

The listing schema

The envelope is described by a JSON Schema, draft-07 like PROJJSON’s own, which refers to the official PROJJSON v0.7 schema for id, bbox and every definition. It ships with the package as listing_schema() and is published at LISTING_SCHEMA_URL. To validate offline, resolve PROJJSON’s schema from PROJ’s data directory:

import os
from pathlib import Path

import jsonschema
from referencing import Registry, Resource

projjson_path = next(
    Path(directory, "projjson.schema.json")
    for directory in pyproj.datadir.get_data_dir().split(os.pathsep)
    if Path(directory, "projjson.schema.json").is_file()
)
projjson = json.loads(projjson_path.read_text())
registry = Registry().with_resource(projjson["$id"], Resource.from_contents(projjson))
validator = jsonschema.Draft7Validator(catalog.listing_schema(), registry=registry)

document = catalog.crs(code="EPSG:25832").to_json_dict(include_definitions=True)
validator.validate(document)
print("valid:", document["$schema"])
valid: https://equinor.github.io/geodetic-engine/schemas/catalog-listing-v1.schema.json
The listing schema
{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "https://equinor.github.io/geodetic-engine/schemas/catalog-listing-v1.schema.json",
  "title": "geodetic-engine catalog listing, version 1",
  "description": "What geodetic_engine.catalog.Listing.to_json_dict() returns. Items use PROJJSON's property names and value shapes wherever PROJJSON has the property, and refer to the official PROJJSON v0.7 schema for id, bbox, unit, method, coordinate_system and every full definition. Properties PROJJSON has no place for, such as deprecated, are added beside them.",
  "type": "object",
  "properties": {
    "$schema": { "type": "string" },
    "type": { "const": "CatalogListing" },
    "kind": {
      "enum": [
        "crs",
        "operations",
        "datums",
        "ellipsoids",
        "prime_meridians",
        "units",
        "methods",
        "coordinate_systems",
        "grids"
      ]
    },
    "database": { "$ref": "#/definitions/database" },
    "filters": { "type": "object" },
    "count": { "type": "integer", "minimum": 0 },
    "items": { "type": "array" }
  },
  "required": ["type", "kind", "database", "filters", "count", "items"],
  "additionalProperties": false,
  "allOf": [
    { "$ref": "#/definitions/items_of/crs" },
    { "$ref": "#/definitions/items_of/operations" },
    { "$ref": "#/definitions/items_of/datums" },
    { "$ref": "#/definitions/items_of/ellipsoids" },
    { "$ref": "#/definitions/items_of/prime_meridians" },
    { "$ref": "#/definitions/items_of/units" },
    { "$ref": "#/definitions/items_of/methods" },
    { "$ref": "#/definitions/items_of/coordinate_systems" },
    { "$ref": "#/definitions/items_of/grids" }
  ],
  "definitions": {
    "items_of": {
      "crs": {
        "if": { "properties": { "kind": { "const": "crs" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/crs_item" } } } }
      },
      "operations": {
        "if": { "properties": { "kind": { "const": "operations" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/operation_item" } } } }
      },
      "datums": {
        "if": { "properties": { "kind": { "const": "datums" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/datum_item" } } } }
      },
      "ellipsoids": {
        "if": { "properties": { "kind": { "const": "ellipsoids" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/ellipsoid_item" } } } }
      },
      "prime_meridians": {
        "if": { "properties": { "kind": { "const": "prime_meridians" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/prime_meridian_item" } } } }
      },
      "units": {
        "if": { "properties": { "kind": { "const": "units" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/unit_item" } } } }
      },
      "methods": {
        "if": { "properties": { "kind": { "const": "methods" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/method_item" } } } }
      },
      "coordinate_systems": {
        "if": { "properties": { "kind": { "const": "coordinate_systems" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/coordinate_system_item" } } } }
      },
      "grids": {
        "if": { "properties": { "kind": { "const": "grids" } } },
        "then": { "properties": { "items": { "items": { "$ref": "#/definitions/grid_item" } } } }
      }
    },

    "projjson": { "$ref": "https://proj.org/schemas/v0.7/projjson.schema.json" },
    "id": { "$ref": "https://proj.org/schemas/v0.7/projjson.schema.json#/definitions/id" },
    "bbox": { "$ref": "https://proj.org/schemas/v0.7/projjson.schema.json#/definitions/bbox" },
    "ids": { "type": "array", "items": { "$ref": "#/definitions/id" } },
    "strings": { "type": "array", "items": { "type": "string" } },
    "reference": {
      "description": "Another object in the database, as PROJJSON states an ensemble member or a method: a name and an id.",
      "type": "object",
      "properties": {
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" }
      },
      "required": ["name", "id"],
      "additionalProperties": false
    },
    "references": { "type": "array", "items": { "$ref": "#/definitions/reference" } },
    "usages": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "area": { "type": "string" },
          "bbox": { "$ref": "#/definitions/bbox" }
        },
        "required": ["area", "bbox"],
        "additionalProperties": false
      }
    },
    "accuracy": {
      "description": "An accuracy in metres, as a string, as PROJJSON states one.",
      "type": "string"
    },

    "database": {
      "type": "object",
      "properties": {
        "path": { "type": "string" },
        "proj_version": { "type": "string" },
        "metadata": { "type": "object", "additionalProperties": { "type": "string" } },
        "fingerprints": {
          "type": "array",
          "items": {
            "type": "object",
            "properties": {
              "path": { "type": "string" },
              "sha256": { "type": "string", "pattern": "^[0-9a-f]{64}$" }
            },
            "required": ["path", "sha256"],
            "additionalProperties": false
          }
        }
      },
      "required": ["path", "proj_version", "metadata", "fingerprints"],
      "additionalProperties": false
    },

    "crs_item": {
      "type": "object",
      "properties": {
        "type": {
          "enum": [
            "GeographicCRS",
            "GeodeticCRS",
            "ProjectedCRS",
            "DerivedProjectedCRS",
            "VerticalCRS",
            "CompoundCRS",
            "EngineeringCRS",
            "BoundCRS"
          ]
        },
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" },
        "kind": {
          "enum": [
            "geographic_2d",
            "geographic_3d",
            "geocentric",
            "geodetic",
            "projected",
            "derived_projected",
            "vertical",
            "compound",
            "engineering"
          ]
        },
        "area": { "type": "string" },
        "bbox": { "$ref": "#/definitions/bbox" },
        "usages": { "$ref": "#/definitions/usages" },
        "projection_method": { "type": "string" },
        "datums": { "$ref": "#/definitions/references" },
        "coordinate_system": { "$ref": "#/definitions/reference" },
        "axis_units": { "$ref": "#/definitions/references" },
        "bound": { "type": "boolean" },
        "osdu_ids": { "$ref": "#/definitions/strings" },
        "has_persistable_reference": { "type": "boolean" },
        "deprecated": { "type": "boolean" },
        "replaced_by": { "$ref": "#/definitions/ids" },
        "aliases": { "$ref": "#/definitions/strings" },
        "definition": { "$ref": "#/definitions/projjson" }
      },
      "required": ["type", "name", "id", "kind", "bound", "deprecated"],
      "additionalProperties": false
    },

    "operation_item": {
      "type": "object",
      "properties": {
        "type": {
          "enum": [
            "Conversion",
            "Transformation",
            "ConcatenatedOperation",
            "PointMotionOperation"
          ]
        },
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" },
        "kind": {
          "enum": [
            "conversion",
            "transformation",
            "concatenated_operation",
            "point_motion_operation"
          ]
        },
        "area": { "type": "string" },
        "bbox": { "$ref": "#/definitions/bbox" },
        "usages": { "$ref": "#/definitions/usages" },
        "method": { "$ref": "#/definitions/reference" },
        "source_crs": { "$ref": "#/definitions/reference" },
        "target_crs": { "$ref": "#/definitions/reference" },
        "accuracy": { "$ref": "#/definitions/accuracy" },
        "version": { "type": "string" },
        "grids": { "$ref": "#/definitions/strings" },
        "optional_grids": { "$ref": "#/definitions/strings" },
        "steps": { "$ref": "#/definitions/references" },
        "superseded_by": { "$ref": "#/definitions/ids" },
        "osdu_ids": { "$ref": "#/definitions/strings" },
        "has_persistable_reference": { "type": "boolean" },
        "deprecated": { "type": "boolean" },
        "replaced_by": { "$ref": "#/definitions/ids" },
        "aliases": { "$ref": "#/definitions/strings" },
        "definition": { "$ref": "#/definitions/projjson" }
      },
      "required": ["type", "name", "id", "kind", "deprecated"],
      "additionalProperties": false
    },

    "datum_item": {
      "type": "object",
      "properties": {
        "type": {
          "enum": [
            "GeodeticReferenceFrame",
            "DynamicGeodeticReferenceFrame",
            "VerticalReferenceFrame",
            "DynamicVerticalReferenceFrame",
            "DatumEnsemble",
            "EngineeringDatum"
          ]
        },
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" },
        "kind": { "enum": ["geodetic", "vertical", "engineering"] },
        "area": { "type": "string" },
        "bbox": { "$ref": "#/definitions/bbox" },
        "usages": { "$ref": "#/definitions/usages" },
        "ellipsoid": { "$ref": "#/definitions/reference" },
        "prime_meridian": { "$ref": "#/definitions/reference" },
        "frame_reference_epoch": { "type": "number" },
        "members": { "$ref": "#/definitions/references" },
        "accuracy": { "$ref": "#/definitions/accuracy" },
        "publication_date": { "type": "string" },
        "deprecated": { "type": "boolean" },
        "replaced_by": { "$ref": "#/definitions/ids" },
        "aliases": { "$ref": "#/definitions/strings" },
        "definition": { "$ref": "#/definitions/projjson" }
      },
      "required": ["type", "name", "id", "kind", "deprecated"],
      "additionalProperties": false
    },

    "ellipsoid_item": {
      "type": "object",
      "properties": {
        "type": { "const": "Ellipsoid" },
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" },
        "semi_major_axis": { "type": "number", "description": "In metres." },
        "semi_minor_axis": { "type": "number", "description": "In metres." },
        "inverse_flattening": { "type": "number", "description": "Absent for a sphere." },
        "celestial_body": { "type": "string" },
        "deprecated": { "type": "boolean" },
        "replaced_by": { "$ref": "#/definitions/ids" },
        "aliases": { "$ref": "#/definitions/strings" },
        "definition": { "$ref": "#/definitions/projjson" }
      },
      "required": ["type", "name", "id", "semi_major_axis", "semi_minor_axis", "deprecated"],
      "additionalProperties": false
    },

    "prime_meridian_item": {
      "type": "object",
      "properties": {
        "type": { "const": "PrimeMeridian" },
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" },
        "longitude": {
          "type": "number",
          "description": "In decimal degrees, as PROJJSON states a longitude without a unit."
        },
        "deprecated": { "type": "boolean" },
        "replaced_by": { "$ref": "#/definitions/ids" },
        "aliases": { "$ref": "#/definitions/strings" },
        "definition": { "$ref": "#/definitions/projjson" }
      },
      "required": ["type", "name", "id", "longitude", "deprecated"],
      "additionalProperties": false
    },

    "unit_item": {
      "type": "object",
      "properties": {
        "type": {
          "enum": ["LinearUnit", "AngularUnit", "ScaleUnit", "TimeUnit", "ParametricUnit", "Unit"]
        },
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" },
        "kind": {
          "enum": [
            "linear",
            "linear_per_time",
            "angular",
            "angular_per_time",
            "scale",
            "scale_per_time",
            "time",
            "parametric"
          ]
        },
        "conversion_factor": { "type": "number" },
        "proj_short_name": { "type": "string" },
        "deprecated": { "type": "boolean" },
        "replaced_by": { "$ref": "#/definitions/ids" },
        "aliases": { "$ref": "#/definitions/strings" },
        "definition": {
          "$ref": "https://proj.org/schemas/v0.7/projjson.schema.json#/definitions/unit"
        }
      },
      "required": ["type", "name", "id", "kind", "deprecated"],
      "additionalProperties": false
    },

    "method_item": {
      "type": "object",
      "properties": {
        "type": { "const": "OperationMethod" },
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" },
        "kind": { "enum": ["conversion", "transformation"] },
        "parameters": { "$ref": "#/definitions/references" },
        "operation_count": { "type": "integer", "minimum": 0 },
        "deprecated": { "type": "boolean" },
        "replaced_by": { "$ref": "#/definitions/ids" },
        "aliases": { "$ref": "#/definitions/strings" },
        "definition": {
          "$ref": "https://proj.org/schemas/v0.7/projjson.schema.json#/definitions/method"
        }
      },
      "required": ["type", "name", "id", "kind", "operation_count", "deprecated"],
      "additionalProperties": false
    },

    "axis": {
      "type": "object",
      "properties": {
        "name": { "type": "string" },
        "abbreviation": { "type": "string" },
        "direction": { "type": "string" },
        "meridian": {
          "type": "object",
          "properties": { "longitude": { "type": "number" } },
          "required": ["longitude"],
          "additionalProperties": false
        },
        "unit": { "$ref": "#/definitions/reference" }
      },
      "required": ["name", "abbreviation", "direction"],
      "additionalProperties": false
    },

    "coordinate_system_item": {
      "type": "object",
      "properties": {
        "type": { "const": "CoordinateSystem" },
        "name": { "type": "string" },
        "id": { "$ref": "#/definitions/id" },
        "subtype": {
          "enum": [
            "Cartesian",
            "spherical",
            "ellipsoidal",
            "vertical",
            "ordinal",
            "parametric",
            "affine",
            "TemporalDateTime",
            "TemporalCount",
            "TemporalMeasure"
          ]
        },
        "dimension": { "type": "integer", "minimum": 1 },
        "axis": { "type": "array", "items": { "$ref": "#/definitions/axis" } },
        "deprecated": { "type": "boolean" },
        "replaced_by": { "$ref": "#/definitions/ids" },
        "aliases": { "$ref": "#/definitions/strings" },
        "definition": {
          "$ref": "https://proj.org/schemas/v0.7/projjson.schema.json#/definitions/coordinate_system"
        }
      },
      "required": ["type", "name", "id", "subtype", "dimension", "axis", "deprecated"],
      "additionalProperties": false
    },

    "grid_item": {
      "description": "A grid file. It has no PROJJSON form and no authority code.",
      "type": "object",
      "properties": {
        "name": { "type": "string" },
        "original_names": { "$ref": "#/definitions/strings" },
        "old_proj_name": { "type": "string" },
        "format": { "type": "string" },
        "proj_method": { "type": "string" },
        "kind": {
          "enum": ["horizontal", "vertical", "geocentric", "velocity", "deformation", "unknown"]
        },
        "url": { "type": "string" },
        "direct_download": { "type": "boolean" },
        "open_license": { "type": "boolean" },
        "installed": { "type": "boolean" },
        "remote_available": { "type": "boolean" },
        "used_by": { "$ref": "#/definitions/ids" },
        "area": { "type": "string" },
        "bbox": { "$ref": "#/definitions/bbox" },
        "usages": { "$ref": "#/definitions/usages" },
        "definition": { "type": "object" }
      },
      "required": ["name", "kind", "direct_download", "installed", "used_by"],
      "additionalProperties": false
    }
  }
}

A change to the envelope that breaks a consumer comes with a new schema version; the PROJJSON version follows PROJ.

Provenance

database() names the proj.db that answered, with the versions of the datasets it holds and fingerprints of every database on PROJ’s search path. The fingerprints are those a TransformationResult records, so a listing and a transformation can be tied to the same database:

info = catalog.database()
print(info.proj_version, info.epsg_version)
print([str(a) for a in catalog.authorities()])
9.9.0 v13.102
['EPSG v13.102', 'ESRI ArcGIS Pro 3.6', 'IAU_2015', 'IGNF 3.1.0', 'NKG 1.0.w', 'NRCAN', 'OGC', 'OSDU', 'PROJ 9.9.0']