Skip to content
This repository has been archived by the owner on Apr 27, 2022. It is now read-only.

Europeana REST API adapter for Blacklight. Used in Europeana Collections.

License

Notifications You must be signed in to change notification settings

europeana/europeana-blacklight

Repository files navigation

Europeana::Blacklight

Build Status Security Maintainability Test Coverage

Ruby gem providing an adapter to use the Europeana REST API as a data source for Blacklight.

Usage

See the Quick Start Guide.

Features

Supported Blacklight features

  • Search
  • View record
  • Pagination of search results
  • Field facets
  • Query facets
  • Facet limits
  • Fielded search
  • Bookmarks
  • Range queries

Unsupported Blacklight features

  • Result sorting :(
  • "Did you mean" spellcheck
  • MLT Solr-style (but see custom features)

Custom features

  • Nested EDM field names
  • MLT by record ID in :mlt URL parameter
  • Query facets with arbitrary API parameters

Query facets

In the configuration for query facet fields, the :fq option is a Hash, to permit specification of multiple parameters to be passed to the API:

configure_blacklight do |config|
  config.add_facet_field 'Cities (reusable content)', query: {
    paris: { label: 'Paris', fq: { qf: 'paris', reusability: 'open' } },
    berlin: { label: 'Berlin', fq: { qf: 'berlin', reusability: 'open' } }
  }
end

Warning: query facets are achieved by sending additional queries to the API. If you configure 2 query facets each with 10 facet values, this will result in an additional 20 queries being sent to the API.

License

Licensed under the EUPL v1.2.

For full details, see LICENSE.md.