Export

(Machine translated):

Information in KulturNav can be exported to various file formats and in multiple ways. The possibilities available are determined by your authorization. The export functions are linked to logged-in users.

Export of information can be done from datasets and folders in different file formats. Data dumps - entire pieces of the KulturNav database - can be exported by defining a search string. Learn more about this below. Additionally, all published data is also available to be extracted and saved through KulturNav's API in raw data form.

  • You export a Dataset if you want to obtain an entire dataset. Datasets can contain very large amounts of data. Learn more about datasets.
  • Folders enable you to select information from many different datasets as a subset in a folder, tailored for export.

Selections can involve various categories of information. This means that what is exported from a folder usually consists only of information that is common to the data within the folder. You can obtain more comprehensive data by specifying the category from which you want complete data, instead of the default All types, in the Content property. For example, if you have both terms and events in a folder, you can obtain complete properties for terms by selecting Term in the Content property during folder editing before exporting the data.

File Extensions in URL

In addition to specifying the format in the header using Accept on GET, you can add a file extension to the URL:

{uuid}.json  

returns the entity in JSON format

{uuid}.rdf  

returns the entity in RDF/XML

{uuid}.json-ld  

returns the entity in JSON-LD

{uuid}.geojson  

returns the entity's geodata in GeoJSON format

Export Functions

In the header of a dataset, there are four export options that you activate by clicking the links:

  • RDF/XML: Exports the entire dataset as an RDF/XML file. Note that the file is compressed as a Gnu Zipped Archive, which needs to be extracted before the file can be used (e.g., with WINZIP, 7-ZIP, etc).
  • JSON-LD: Exports the entire dataset as a JSON-LD file. Note that the file is compressed as a Gnu Zipped Archive, which needs to be extracted before the file can be used (e.g., with WINZIP, 7-ZIP, etc).
  • JSON: Exports the entire dataset to a JSON file. Note that the file is compressed as a Gnu Zipped Archive, which needs to be extracted before the file can be used (e.g., with WINZIP, 7-ZIP, etc).
  • CSV: Exports the dataset as a CSV file that can be opened in Excel. Note that MS Excel has a limitation of 32,767 characters per cell. Extensive properties such as "Consists of" (which exports all parts, e.g., Farms within a Municipality) will be split into multiple rows.

In the function menu of a dataset or folder, you will find the following export options. The available options depend on your authorization.

  • Export dataset (CSV): Exports the dataset as a CSV file that can be opened in Excel. This function is available for all logged-in users.
  • Export dataset (text): Exports the dataset as a text file that can be imported into KulturNav. This function is available for system administrators.
  • Export entry (JSON): Exports the current entry to a JSON file. The file can be imported into another instance of KulturNav, providing an easy way to move individual records between, for example, a test and production environment. This function is available for system administrators.
  • Export dataset (JSON): Exports the entire dataset to a JSON file. The file can be imported into another instance of KulturNav, offering a convenient way to transfer data between, for instance, a test and production environment. Note that the file is compressed as a Gnu Zipped Archive, which needs to be extracted before the file can be used (e.g., with WINZIP, 7-ZIP, etc).
  • Export dataset (RDF/XML): Exports the entire dataset as an RDF/XML file. This function is available for all logged-in users. Note that the file is compressed as a Gnu Zipped Archive, which needs to be extracted before the file can be used (e.g., with WINZIP, 7-ZIP, etc).
  • Export dataset (JSON-LD): Exports the entire dataset as a JSON-LD file. This function is available for all logged-in users. Note that the file is compressed as a Gnu Zipped Archive, which needs to be extracted before the file can be used (e.g., with WINZIP, 7-ZIP, etc).
  • Export dataset (Geojson): Exports the dataset as a GeoJSON file containing coordinate data and limited other information about the entities. Learn more about geodata.
  • Export dataset (CSV with coordinates): Exports the dataset's geodata as a simple CSV file containing entity names and coordinates in both WGS-84 (columns Longitude and Latitude) and, if applicable, other coordinate systems (columns X and Y and SRS).

Export RDF Data - Data Dumps

You can export RDF data as a data dump by defining a search phrase in two export methods. For examples of search phrases, refer to the API documentation, and field names are available in KulturNav's schema. This function does not require login.

RDF/XML

URL parameter exportRdfxml. Creates a data dump (file) in RDF/XML format combined with a custom-defined search string (searchstring) that defines the selection of entities. You can retrieve data "page by page" by specifying a starting point (offset) and the number of records per page you want (max). You use /api/count/{searchstring} to count the total number of hits.

../exportRdfxml/search/{searchstring}/<offset>/<max>  

JSON-LD

URL parameter exportJsonLD. Creates a data dump (file) in JSON-LD format combined with a custom-defined search string (searchstring) that defines the selection of entities. You can retrieve data "page by page" by specifying a starting point (offset) and the number of records per page you want (max). You use /api/count/{searchstring} to count the total number of hits.

../exportJsonLD/search/{searchstring}/<offset>/<max>  

Example:

To count the number of records - all organization records in KulturNav:

/api/count/entityType:Organization  

To export the first 100 organizations in KulturNav to an RDF/XML dump:

/exportRdfxml/search/entityType:Organization/0/100  

To export the next 100 records:

/exportRdfxml/search/entityType:Organization/100/100  

To export the dataset of Norwegian prime ministers to an RDF/XML dump:

/exportRdfxml/search/entity.dataset:72a2bc06-25bc-4091-99ae-9ea12d3f6036/0/60  

To export a change dump in RDF/XML format containing the first 100 person records from the Photographer Registry (Sweden), changed since February 1, 2020:

/exportRdfxml/search/entity.dataset:1f368832-7649-4386-97b6-ae40cce8752b,savedAt:>20200201 000000-S/0/100