Skip to content

Latest commit

 

History

History
170 lines (105 loc) · 4.88 KB

File metadata and controls

170 lines (105 loc) · 4.88 KB

Publishing metadata to OGC API - Records

OGC API - Records provides geospatial data access functionality to vector data.

To add vector data to pygeoapi, you can use the dataset example in :ref:`configuration` as a baseline and modify accordingly.

Providers

pygeoapi core record providers are listed below, along with a matrix of supported query parameters.

Provider properties (filters) resulttype q bbox datetime sortby properties (display) domains CQL transactions
ElasticsearchCatalogue results/hits
TinyDBCatalogue results/hits
CSWFacade results/hits

Below are specific connection examples based on supported providers.

Connection examples

ElasticsearchCatalogue

Note

Requires Python packages elasticsearch and elasticsearch-dsl

Note

Elasticsearch 8 or greater is supported.

To publish an Elasticsearch index, the following are required in your index:

providers:
    - type: record
      name: ElasticsearchCatalogue
      data: http://localhost:9200/some_metadata_index
      id_field: identifier
      time_field: datetimefield

The ES provider also has the support for the CQL queries as indicated in the table above.

.. seealso::
  :ref:`cql2` for more details on how to use Common Query Language (CQL) to filter the collection with specific queries.

TinyDBCatalogue

Note

Requires Python package tinydb

To publish a TinyDB index, the following are required in your index:

providers:
    - type: record
      editable: true|false  # optional, default is false
      name: TinyDBCatalogue
      data: /path/to/file.db
      id_field: identifier
      time_field: datetimefield

CSWFacade

Note

Requires Python package OWSLib

To publish a CSW using pygeoapi, the CSW base URL (data) is required. Note that the CSW Record core model is supported as a baseline.

providers:
    - type: record
      name: CSWFacade
      data: https://demo.pycsw.org/cite/csw
      id_field: identifier
      time_field: datetime
      title_field: title

Including extra query parameters

See the :ref:`publishing vector section <including-extra-query-parameters>` for more information on including extra query parameters.

Metadata search examples

Note

provider id_field values support slashes (i.e. my/cool/identifier). The client request would then be responsible for encoding the identifier accordingly (i.e. http://localhost:5000/collections/my-metadata/items/my%2Fcool%2Fidentifier)