ckanext-gztr v0.1.0 is releasing soon! We recommend waiting and watching for the v0.1.0 release before using it.
ckanext-gztr

Features

Features your CKAN water data hub includes when enabling the Geoconnex integration.

Geoconnex features

If your CKAN instance stores CKAN datasets or custom geospatial features about real-world hydrologic features with ckanext-gztr, you can opt-in to retrieve and share data with the Geoconnex water data knowledge graph.

By enabling the Geoconnex integration for your CKAN instance, your instance will be provided dataset discovery in Geoconnex among participating Geoconnex-enabled CKAN instances.

Explore the multiple benefits that this synchronization has to offer here, and on the next page we'll cover how to enable Geoconnex capabilities for your CKAN instance.

Mint Persistent Identifiers (PIDs) for your CKAN instance's data

Mint Geoconnex PID example

By enabling the Geoconnex integration, your compatible CKAN datasets should be minted a Geoconnex persistent identifier (PID) as a new URL to link to your CKAN dataset's landing page. We use the CKAN dataset id value from the /api/3/action/package_show endpoint as the PID unique ID value, along with a namespace you'll define when enabling the Geoconnex integration such as New_Mexico_Water_Data_Catalog.

For example review the following diagram then the bullet point list afterwards as they relate to the CKAN-Geoconnex integration:

Geoconnex diagram

  • Persistent IDs (URL) (on the left side): your CKAN dataset's minted PID (e.g. https://geoconnex.us/ckan/New_Mexico_Water_Data_Catalog/2e27c468-37a6-435d-b57f-1b8f9cea3717)
  • Observed or Modeled Data: a CKAN dataset
  • Landing page: a CKAN dataset's landing page (e.g. https://catalog.newmexicowaterdata.org/dataset/2e27c468-37a6-435d-b57f-1b8f9cea3717)
  • Structured/Linked Data (JSON-LD): JSON-LD that describes the CKAN dataset and includes reference PIDs that the CKAN dataset is about
  • Persistent IDs (URL) (on the right side): Geoconnex reference feature PID(s) based on geospatial features you've selected in the dataset publisher gazetteer (e.g. Santa Fe, so the PID is https://geoconnex.us/ref/places/3570500)

Associate real-world features/locations with your CKAN datasets

As mentioned in the previous section, there are real-world geospatial features/locations that you can associate with your CKAN datasets. This association is achieved through the dataset publisher gazetteer.

You may review the Geoconnex reference collections lab to learn how to import water data geospatial collections from the Geoconnex reference API to access the data from the dataset publisher gazetteer while also ensuring the imported data is compatible with the Geoconnex integration.

Expose Geoconnex-compatible JSON-LD linked data on CKAN dataset landing pages

With the Geoconnex integration enabled along with the relevant configuration values:

# == ckanext-gztr | Geoconnex options (more info at https://gztr.dathere.com/docs/geoconnex-integration) ==
ckanext.gztr.geoconnex.enabled = true
# The namespace that should exist in the namespaces/bulk/ckan directory at https://github.com/internetofwater/geoconnex.us
ckanext.gztr.geoconnex.namespace = New_Mexico_Water_Data_Catalog
# Embeds Geoconnex-compatible JSON-LD within each compatible CKAN dataset's landing page
ckanext.gztr.geoconnex.enable_dataset_jsonld = true

Your compatible CKAN datasets should include JSON-LD embedded in each landing page's HTML. For example the JSON-LD may look similar to the following:

{
  "@context": {
    "@vocab": "https://schema.org/",
    "gsp": "http://www.opengis.net/ont/geosparql#"
  },
  "@id": "https://geoconnex.us/ckan/New_Mexico_Water_Data_Catalog/2e27c468-37a6-435d-b57f-1b8f9cea3717",
  "@type": "Dataset",
  "about": [
    {
      "@id": "https://geoconnex.us/ref/places/3570500"
    }
  ],
  "name": "Northwest Well and City Wellfield Water Level Monitoring Program",
  "provider": {
    "@type": "Organization",
    "name": "City of Santa Fe"
  },
  "url": "https://catalog.newmexicowaterdata.org/dataset/2e27c468-37a6-435d-b57f-1b8f9cea3717"
}

Explore the Geoconnex web UI for your geospatial features

When your geospatial collections have geoconnex_pid in a feature's properties value, the Geoconnex URI can be accessed from a geospatial feature's information modal by clicking the information modal button.

More features

These features are currently planned as part of the Geoconnex integration. The infrastructure exists, and what's next is ensuring they work as intended. In particular the features are:

  • Sync your geospatial collections with Geoconnex reference features
  • Find your CKAN instance's data linked on the Geoconnex Explorer
  • Query for your CKAN instance's data with SPARQL against the Geoconnex knowledge graph
  • Run a SPARQL query with the SPARQL Helper
  • Run a SPARQL query using Python

On this page