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-2.9/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
mimeType
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
Escenic story-type content item
x-ece/image
Escenic image content item
x-ece/video
Escenic video content item
x-ece/gallery
Escenic gallery content item
x-ece/event
Escenic event content item
x-ece/new-content
New Escenic content that has not yet been saved
x-ece/section
Escenic section
x-ece/section-page
Escenic section page
x-ece/list
Escenic list
x-ece/*
All kinds of Escenic content
x-cci/assignment
Newsgate assignment
x-cci/storyfolder
Newsgate story folder
x-cci/*
All kinds of Newsgate content
*/*
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
mimeType
setting and a list of properties.triggers: - name: trigger-name mimeType: [mimetype-list] properties: property-name: property-value property-name: property-value
See Enrichment Service Triggers for further information.