Configuring Enrichment Services in CUE

Configuring CUE to access an enrichment service is very straightforward – all you need to do is add a few entries to the CUE configuration file, /etc/escenic/cue-web/config.yml. Open this file for editing. If it does not already contain an enrichmentServices entry, then add one:

enrichmentServices:

Underneath this entry, you can add sub-entries for all the enrichment services you want to define. An enrichment service configuration contains the following entries:

  - name: service-name
    href: http://host:port/service-url
    title: service-title
    triggers:
      - name: trigger-name

where:

name

Is the name of the enrichment service. The name must be unique since CUE identifies the services by their name. Any service definition with a duplicate name will be ignored.

href

Is the URI of the enrichment service. CUE will POST the current content item to this URI as an Atom entry.

title

Is the title of the enrichment service. This title is displayed by CUE in headers and labels as appropriate.

triggers

Is a list of one or more triggers defining when CUE is to POST the content item to the enrichment service.

Optionally, a trigger may include a mimeTypes setting. This is a list of MIME type for which the trigger is to fire. If you specify this property, then the trigger will only fire for the MIME types specified in the list. The possible MIME types that may appear are:

x-ece/story

CUE story-type content item

x-ece/picture

CUE image content item

x-ece/video

CUE video content item

x-ece/gallery

CUE gallery content item

x-ece/new-content

New CUE content that has not yet been saved

x-ece/section

CUE section

x-ece/section-page

CUE section page

x-ece/*

All kinds of CUE content

Some triggers may have properties that need to be specified, in which case the service configuration will also include a properties value consisting of a sequence of one or more property settings.

Here is an example trigger definition with both a mimeTypes setting and a list of properties.

triggers:
      - name: trigger-name
        mimeTypes: [mimetype-list]
        properties:
          property-name: property-value
          property-name: property-value

See Enrichment Service Triggers for further information.