Skip to content

Documentation for Console

anjeve edited this page Feb 28, 2012 · 11 revisions

The Console is a administrative component in charge of storing the Linking Specifications pushed by the Workbench and the execution reports pushed bu the Runtime. It is also used to monitor the status of the platform. The Console is split in two parts: a graphical interface and a REST API.

User interface

The main screen of the application shows the latest tasks sent to the console and the latest execution reports from the runtime overview The detail view is used to have more information about a specific task which as to be selected in the list on the left part of the interface detail Once a linking task has been selected, more information are displayed show To edit these information, you need to be logged using the admin login box on the upper right part of the interface login Once logged, new controls are available logged Including an editor to update a task editor

API

The base URI for the calls is the address at which the console is deployed plus a "/api". For instance http://latc-console.few.vu.nl/api. A description of the API can also be found in the source code

In the following, {UUID} refers to the UUID of a task. Although it is possible to use either the UUID or the slug of a task to reference it, developers are advised to rely on the UUID which is immutable and assigned at creation time of a task.

Get the list of Linking Tasks

Call GET api/tasks

Call example http://latc-console.few.vu.nl/api/tasks?limit=2&executable=true

This call takes two optional parameters

  • limit: the maximum amount of items to return (for example, limit=5)
  • executable: filter tasks to return only those for which the executable status is either true (executable=true) or false (executable=false)

The result is an array if tasks with the following information

  • author: the author name
  • created: the task creation time
  • identifier: the UUID of the task
  • executable: the executable flag (cf user interface)
  • vetted: the vetted flag (cf user interface)
  • title: a short title
  • description: text explaining what the task does

Example result (cut to one task only)

{"task":[{
"author":"Unknown",
"title":"geonames -> linkedgeodata (memorial)",
"slug":"geonamesTolinkedgeodata(memorial)",
"created":"2011-05-10T18:45:34",
"description":"No description",
"executable":true,
"vetted":false,
"identifier":"ff8081812fdacc98012fdacc9fc4004a",
"modified":"2011-05-10T18:45:34"
}]
}

Add a new Linking Task

Call POST api/tasks

Call example: see sample code PostTask

This call requires two parameters

  • api_key: the API key
  • specification: the configuration file for Silk

This call takes three optional parameters

  • title: the title of the task
  • author: the author
  • description: a long description of what the task does

The result is the UUID assigned by the Console to the task

Get the Linking Specification of a task

Call GET api/task/{UUID}/configuration

Call example http://latc-console.few.vu.nl/api/task/ff8081812f351c21012f352a1f5e007c/configuration

This call takes no parameter, the value returned is the XML configuration for Silk associated to the task.

Update the Linking Specification of a task

Call PUT api/task/{UUID}/configuration

This call requires two parameters

  • api_key: the API key
  • configuration: the configuration file for Silk

Get the notifications for a task

Call GET api/task/{UUID}/notifications

Call example http://latc-console.few.vu.nl/api/task/ff8081812f351c21012f352a1f5e007c/notifications.json

The result is an array of messages with the following information.

  • identifier: the identifier of the notification
  • message: the message posted with this notification
  • severity: the severity (warn, info)
  • date: the creation date of the notification

This result can be formatted in ATOM or JSON, depending on the content negotiation performed. It is also possible to select a particular format by adding json or atom as a suffix to the call.

Example result for http://latc-console.few.vu.nl/api/task/ff8081812f351c21012f352a1f5e007c/notifications.json

{"notification":[{
"message":"Task created",
"severity":"info",
"date":"2011-04-08T14:50:43",
"identifier":"ff8081812f351c21012f352a1f83007d"
}]}

Post a new notification for a task

Call PUT api/task/{UUID}/notifications

Call example: see sample code PostNotification

This call requires one parameter

  • api_key: the API key

This call takes three optional parameters

  • message: the message associated to the notification
  • severity: the severity of the message
  • data: a data payload in JSON. This may contain any kind of information.

The value returned upon successful completion of the call is the identifier of the notification.

Get a triple set associated to a task

Call GET api/task/{UUID}/tripleset/{NAME}

Call example http://latc-console.few.vu.nl/api/task/ff8081812e2e36ce012e2e36cf7c0002/tripleset/good

The parameter {NAME} is the name given to the triple set. This name is freely chosen by the application(s) sending and retrieving triple sets.

The result of the call is the set of triples as it was submitted

Example result for http://latc-console.few.vu.nl/api/task/ff8081812e2e36ce012e2e36cf7c0002/tripleset/good

s p o. 
s2 p2 o2.

Post a triple set associated to a task

Call PUT api/task/{UUID}/tripleset/{NAME}

Call example: see sample code PostTripleSet

This call requires two parameters

  • api_key: the API key
  • triples: the set of triples to save

If a set of triples is already save under the name {NAME}, its content is overridden with the new triples. Otherwise, a new set is created.

The value returned upon successful completion of the call is the internal identifier of the triple set (only used internally by the console).

Delete a Linking Task

Call DELETE api/task/{UUID}

This call requires one parameter

  • api_key: the API key

Get the metadata about a task

Call GET api/task/{UUID}

Call example http://latc-console.few.vu.nl/api/task/ff8081812f351c21012f352a1f5e007c

The result is an array of messages with the following information.

  • author: the author of the task
  • title: the title of the task
  • slug: the title without any space or '->'
  • description: the author of the task
  • created: the date of creation
  • modified: the date of last modification
  • vetted: the vetted flag
  • executable: the executable flag
  • identifier: the UUID of the task

Example result:

{
"author":"Christophe",
"title":"am -> dbpedia (person)",
"created":"2011-04-08T14:50:43",
"vetted":false,
"description":"No description",
"executable":true,
"slug":"amTodbpedia(person)",
"identifier":"ff8081812f351c21012f352a1f5e007c",
"modified":"2012-01-18T15:46:10"
}

Update the metadata about a task

Call PUT api/task/{UUID}

This call takes 5 optional parameters

  • author: the author of the task
  • title: the title of the task
  • description: the author of the task
  • vetted: the vetted flag
  • executable: the executable flag