version 8.x-1.1
Middleware Services
Islandora middleware services utilize the Fedora 4 REST API and the Drupal Services module to create an API for the majority of interactions between the two systems. The Drupal uuid will be used to identify pcdm:Objects (and pcdm:Files thereof) when using these services. The breakdown of services is as follows:
- There will be a services to provide CRUD operations for
pcdm:Collections,pcdm:Objectsandpcdm:Files. - There will be a service to provide creational operations using zip content based on content model. For example:
POSTa zip file containing book pages Islandora Book Batch format to create an entire book object (with pages and derivatives processed asynchronously, of course).- There will be services per derivative type to perform operations based on the node UUID of the parent.
PATCHto generate a new thumbnail for apcdm:Object.
For more information on PCDM, please see this page.
Collection Service
Used for manipulating pcdm:Collections. Essentially wraps the Fedora 4 API requests for manipulating a Container identified by Drupal uuid. Node content in application/json format is massaged into application/sparql-update format in order to interact with Fedora.
Endpoint: http://localhost:8080/islandora-services/collection/
Actions:
-
GEThttp://localhost:8080/islandora-services/collection/{uuid}- Returns
application/ld+jsonRDF metadata for thepcdm:Collectionidentified by the supplied Drupal uuid.
- Returns
-
POSThttp://localhost:8080/islandora-services/collection/- Accepts
application/jsonserialized node data. - Creates a
pcdm:Collectionin Fedora using the Drupal node data, associating the newly minted path with the node's uuid. Iffedora:hasParentis supplied supplied inPOSTdata, that location will be used to create the new object as a child.
- Accepts
-
PUThttp://localhost:8080/islandora-services/collection/{uuid}- Accepts
application/jsonserialized node data. - Updates metadata in Fedora for the
pcdm:Collectionassociated with the provided Drupal uuid.
- Accepts
-
DELETEhttp://localhost:8080/islandora-services/collection/{uuid}- Deletes the
pcdm:Collectionin Fedora associated with provided Drupal uuid.
- Deletes the
Object Service
Used for manipulating pcdm:Objects. Essentially wraps the Fedora 4 API requests for manipulating a Container identified by Drupal uuid. Node content in application/json format is massaged into application/sparql-update format in order to interact with Fedora. Certain field values, as well as other files sent along in the message will be converted into pcdm:Files and attached to the newly created pcdm:Object.
Endpoint: http://localhost:8080/islandora-services/object/
Actions:
-
GEThttp://localhost:8080/islandora-services/object/{uuid}- Returns
application/ld+jsonRDF metadata for thepcdm:Objectidentified by the supplied Drupal uuid.
- Returns
-
POSThttp://localhost:8080/islandora-services/object/- Accepts
multipart/form-datamessages. One "part" of the message will be the JSON serialized Drupal node content. Other "parts" will be files used to createpcdm:Filesfor thepcdm:Object. - Creates a
pcdm:Objectin Fedora using the Drupal node data, associating the newly minted path with the node's uuid. Iffedora:hasParentis supplied supplied inPOSTdata, that location will be used to create the new object as a child. Certain field values as well as any other files contained in the message will be used to createpcdm:Filesassociated with thispcdm:Object.
- Accepts
-
PUThttp://localhost:8080/islandora-services/object/{uuid}- Accepts
multipart/form-datamessages. One "part" of the message will be the JSON serialized Drupal node content. Other "parts" will be files used to createpcdm:Filesfor thepcdm:Object. - Updates metadata in Fedora for the
pcdm:Objectassociated with the provided Drupal uuid. Certain field values as well as any other files contained in the message will be used to updatepcdm:Filesassociated with thispcdm:Object.
- Accepts
-
DELETEhttp://localhost:8080/islandora-services/object/{uuid}- Deletes the
pcdm:Objectin Fedora associated with provided Drupal uuid. Also deletes anypcdm:Filesdirectly contained by thepcdm:Object.
- Deletes the
File Services
Used for manipulating pcdm:Files associated with a pcdm:Object. They will essentially wrap the Fedora 4 API requests for manipulating a NonRDFSourceDescription identified by dcterms:title (obj, mods, dc, etc...) and its parent's Drupal uuid. There will be seperate implementations for each applicable dcterms:title, though each service will abide by a common conventions and behavior. This allows implementations to vary independently based on file type (technical metadata, descriptive metadata, archival binary), while allowing for new services to be easily added over time.
General Convention
Endpoint: http://localhost:8080/islandora-services/file/{uuid}/{dcterms:title} Actions:
-
GEThttp://localhost:8080/islandora-services/file/{uuid}/{dcterms:title}- Retrieves the
pcdm:Filecontent belonging to thepcdm:Object. Thepcdm:Fileis identified bydcterms:titleand its parents Drupal uuid.
- Retrieves the
-
POSThttp://localhost:8080/islandora-services/file/{uuid}/{dcterms:title}- Adds a
pcdm:Fileto thepcdm:Objectidentified by the provided Drupal uuid. The file's content will be set using thePOSTcontent, and the provideddcterms:titlewill be given to the newly createdpcdm:File.
- Adds a
-
PUThttp://localhost:8080/islandora-services/file/{uuid}/{dcterms:title}- Updates the
pcdm:Filewithdcterms:titleowned by thepcdm:Objectidentified by the provided Drupal uuid. The file's content will be set using thePUTcontent.
- Updates the
-
DELETEhttp://localhost:8080/islandora-services/file/{uuid}/{dcterms:title}- Deletes the
pcdm:Filewithdcterms:titleowned by thepcdm:Objectidentified by the provided Drupal uuid.
- Deletes the
Example Services
Some example services would include:
- http://localhost:8080/islandora/services/file/{uuid}/obj
- http://localhost:8080/islandora/services/file/{uuid}/dc
- http://localhost:8080/islandora/services/file/{uuid}/mods
- http://localhost:8080/islandora/services/file/{uuid}/fits
Implementations would differ in the sense that accept headers would be different, and data may have to be transformed differently before being inserted as the pcdm:File.
Derivative Services
Derivatives (while generally dealt with through Islandora Sync) may need to be dealt with manually, so services will be provided to handle all the common derivatives types an Islandora installation may require. Much like the file services, a general convention on naming and behavior will be enforced, but seperate implementations will be provided. This will allow for maximum flexibility and encourage new services to be easily added and contributed.
General Convention
Endpoint: http://localhost:8080/islandora-services/derivative/{uuid}/{type} Actions:
-
GEThttp://localhost:8080/islandora-services/derivative/{uuid}/{type}- Retrieves the derivative belonging to the
pcdm:Objectorpcdm:Collection. The derivative is identified by its type and its parents Drupal uuid.
- Retrieves the derivative belonging to the
-
POSThttp://localhost:8080/islandora-services/derivative/{uuid}/{type}- Adds a derivative to the
pcdm:Objectorpcdm:Collectionidentified by the provided Drupal uuid. The derivative's content will be set using thePOSTcontent. The result will reside in either Fedora or Drupal, depending on the derivative.
- Adds a derivative to the
-
PUThttp://localhost:8080/islandora-services/derivative/{uuid}/{type}- Updates the derviative for a
pcdm:Objectorpcdm:Collectionidentified by the provided Drupal uuid. The derivative's content will be set using thePUTcontent. The result will reside in either Fedora or Drupal, depending on the derivative.
- Updates the derviative for a
-
PATCHhttp://localhost:8080/islandora-services/derivative/{uuid}/{type}- Asynchronously regenerates the derivative for a
pcdm:Objectorpcdm:Collectionidentified by the provided Drupal uuid. The result will reside in either Fedora or Drupal, depending on the derivative.
- Asynchronously regenerates the derivative for a
-
DELETEhttp://localhost:8080/islandora-services/derivative/{uuid}/{type}- Deletes the derivative for the
pcdm:Objectorpcdm:Collectionidentified by the provided Drupal uuid. The derivative will be removed from either Fedora or Drupal, depending on the derivative.
- Deletes the derivative for the
Example Services
Some example services would include:
- http://localhost:8080/islandora/services/derivative/{uuid}/tn
- http://localhost:8080/islandora/services/derivative/{uuid}/medium_size
- http://localhost:8080/islandora/services/derivative/{uuid}/jp2
- http://localhost:8080/islandora/services/derivative/{uuid}/techmd
- http://localhost:8080/islandora/services/derivative/{uuid}/mp3
- http://localhost:8080/islandora/services/derivative/{uuid}/mp4
- http://localhost:8080/islandora/services/derivative/{uuid}/mkv
Implementations would differ in the sense that different derivatives will be created from varying sources using varying programs. Also, display derivatives should reside in Drupal (TN, JP2, etc...) while technical metadata should reside in Fedora. Within Drupal, different derivatives will reside as different field types.
Zip Ingest Services
Instead of multipart/form-data reqeusts, application/zip requests can be accepted to construct a pcdm:Object based on content model. While this is convienent for basic object types, it's required for more complicated content models such as Book, Newspaper, and Compound. Message bodies are assumed to be in Islandora Zip Importer format.
General Convention
Endpoint: http://localhost:8080/islandora/services/zip/ingest/{content_model}/ Actions:
POSThttp://localhost:8080/islandora/services/zip/ingest/{content_model}/- Accepts
application/zipmessages - Takes the supplied zip file, extracts its contents, and uses it to completely construct an object of the specified content-model.
- Accepts
Example services
- http://localhost:8080/islandora/services/zip/large_image
- http://localhost:8080/islandora/services/zip/audio
- http://localhost:8080/islandora/services/zip/video
- http://localhost:8080/islandora/services/zip/book
- http://localhost:8080/islandora/services/zip/newspaper
- http://localhost:8080/islandora/services/zip/compound