TopoJSON driver
Driver short name
TopoJSON
Driver built-in by default
This driver is built-in by default
The driver can read the TopoJSON format. The driver does not support writing TopoJSON datasets.
Driver capabilities
Supports Georeferencing
This driver supports georeferencing
Supports VirtualIO
This driver supports virtual I/O operations (/vsimem/, etc.)
Datasource
The driver accepts three types of sources of data:
Uniform Resource Locator (URL) - a Web address to perform HTTP request.
Plain text file with TopoJSON data - identified from the file extension .json or .topojson
Text passed directly and encoded in Topo JSON
The URL/filename/text might be prefixed with
TopoJSON: to avoid any ambiguity with other drivers. Alternatively, starting
with GDAL 3.10, specifying the -if TopoJSON option to command line utilities
accepting it, or TopoJSON as the only value of the papszAllowedDrivers of
GDALOpenEx(), also forces the driver to recognize the passed
URL/filename/text.
Examples
Example 1: Reading a TopoJSON file with multiple layers
gdal vector info "https://cdn.jsdelivr.net/npm/us-atlas@3/counties-albers-10m.json"
Example 2: Writing a single layer from a TopoJSON file to GeoJSON file
gdal vector convert "https://cdn.jsdelivr.net/npm/us-atlas@3/counties-albers-10m.json" counties-albers-10m.geojson --layer counties