X-ref Database System

API

X-ref has a powerful API which makes it possible to integrate X-ref with other systems. Via X-ref's API it is possible to search, edit, create and delete database records.


database system api
api.html Database system API

The system administrator can limit the authority for the API user so that the API user only can edit/delete collection items that the user (or the user's group) has created. The system administrator can also, for security reasons, limit the number of possible calls per time unit.



A call to the api could look like this:

myurl.se/api/v1/docs?find=TI:sweden,YE:2010

This would be a search call to find all documents containing sweden in the title field (TI) and 2010 in the year field (YE).


The reply could look like this (json):

{ "nextPageUrl": "myurl.se/api/v1/docs?find=TI:Sweden,YE:2010&page=2",
"numberOfHits": 40,
"currentPage": 1,
"numberOfPages": 4,
"docs": [
   {
    "fields": [
     {
      "code": "HitNr",
      "value": "1"
     },      {       "code": "DocumentID",
      "value": "1909"
     },
     {
      "code": "TI",
      "value": "My fantastic time in Sweden"
     },
     {
      "code": "AU",
      "value": "Sven Svensson"
     },
     {
      "code": "KEY",
      "value": "Travel ; Sweden ; Swedish culture"
     },
     {
      "code": "YE",
      "value": "2010"
     }
    ],
    "url": "myurl.se/api/v1/docs/1909"
  },
  {
    "fields": [
     {
      "code": "HitNr",
      "value": "2"
     },
     {
      "code": "DocumentID",
      "value": "1922"
     },
etc...