Extension Dataset Snippets


Extension Basics

Title
Dataset Snippets
Name
ckanext-datasetsnippets
Type
Public extension
Description
CKAN extension providing markup snippets for dataset pages and dataset search, allowing dataset content to be embedded in external CMS systems.
CKAN versions
Download-Url (zip)
Last commit
a month ago (2026-02-03 23:53:38)
Url to repo
Category
Content Management


Background Infos

Description (long)
Show details

ckanext-datasetsnippets

This plugin belongs to a set of plugins for the Datenregister – the non-public CKAN instance that is part of Berlin’s open data portal daten.berlin.de. ckanext-datasetsnippets provides markup snippets for dataset pages and dataset search. These snippets can be loaded from the data portal’s public CMS to handle all requests for datasets.

Requirements

This plugin has been tested with CKAN 2.9.10 (which requires Python 3).

API

The Snippet API has the following two endpoints:

/snippet/dataset

This is the search endpoint of the snippet API, which is equivalent to /dataset in the regular CKAN UI. Without additional parameters, this returns markup for the paginated list of all datasets. Parameters (search facets, ordering etc.) can be used to restrict the result. The parameters are identical to the regular CKAN search parameters.

/snippet/dataset/<id>

This is the dataset detail endpoint of the snippet API, which is equivalent to /dataset/<id> in the regular CKAN UI. <id> is the name or id of a dataset.

Parameters

Both endpoints allow a root_breadcrumb parameter to set the root element of the breadcrumb returned in the snippets.

Configuration

The plugin introduces the following configuration options:

# Defines the path component prefixed to links in snippets
datasetsnippets.path = 'datensaetze'

# Datasets shown per result page in pagination
datasetsnippets.datasets_per_page = 10

# String used as root element for breadcrumb
datasetsnippets.default_root_breadcrumb = 'Berlin Open Data'

# URL to the datenportal for generating feeds
datasetsnippets.datenportal_url = link_to_portal

# Title string used in feeds
datasetsnippets.datenportal_title = 'Berlin Open Data'

Plugin Interfaces Implemented

  • ITemplateHelpers
  • IBlueprint
  • IAuthFunctions

License

This material is copyright © BerlinOnline GmbH.

This extension is open and licensed under the GNU Affero General Public License (AGPL) v3.0.

Version
Version release date
(not set)
Contact name
BerlinOnline GmbH
Contakt email
(not set)
Contact Url
(not set)


Installation Guide

Configuration hints

Part of the Berlin Open Data portal infrastructure. Used to embed CKAN content in external CMS.

Plugins to configure (ckan.ini)
datasetsnippets
CKAN Settings (ckan.ini)
# datasetsnippets.path = 'datensaetze'
# datasetsnippets.datasets_per_page = 10
# datasetsnippets.default_root_breadcrumb = 'Berlin Open Data'
# datasetsnippets.datenportal_url = link_to_portal
# datasetsnippets.datenportal_title = 'Berlin Open Data'
DB migration to be executed
(not set)
<< back to Extensions