SKOS Shuttle API is available for selections and update operations.
Security considerations
The API service is exclusively provided upon transport layer security with TLS 1.2
The API service needs the "api" right from SKOS Shuttle User Management (see tutorials).
The service must be authenticated against a valid SKOS Shuttle user.
In order for the called operation to be executed, the api user needs the corresponding (role) groups and rights for that operation.
Every api access is logged and historized.
Output formats
The API delivers results per default in JSON format. Further formats are available.
JSON :/GET parameter: format=json
YAML :/GET parameter: format=yaml
XML :/GET parameter: format=xml
Language tags
Langage tags like "en", "fr", ... are a short form for the corresponding language which is stored in the RDF data with every label.
With SKOS Shuttle API you can restrict which labels (in which tags) should be returned with the results.
Use /GET parameter: langs=en{,fr,it,...}
Per default the API returns labels in all languages.
Example:
Labels in all languages:Omit this parameter
Labels only in English:/GET parameter: langs=en
Labels only in English or French:/GET parameter: langs=en,fr
Namespaces
Namespaces can be forced to be returned either in short form or in full form.
Per default Namespaces are returned in short form.
Return namespaces in short form:/GET parameter: ns=short or omit parameter
Return namespaces in full form /GET parameter:/GET parameter: ns=full
RDF format on download/upload
RDF export / import operation support the following formats
Per default the used format is RDFXML
N3 :/GET parameter: rdfformat=N3
NTRIPLES :/GET parameter: rdfformat=NTRIPLES
NQUADS :/GET parameter: rdfformat=NQUADS
RDFXML :/GET parameter: rdfformat=RDFXML or omit parameter
TRIG :/GET parameter: rdfformat=TRIG
TURTLE :/GET parameter: rdfformat=TURTLE
Additional RDF safe cheks
Additional RDF (SPARQL) update checks are performed to ensure, the updates coming from the API requests are effectevely stored.
Every update is performed using SPARQL-UPDATE queries. The latter does not quit update operations with a precise statistic of what was changed by that queries.
SKOS Shuttle API can additionally query the repository, whether the corresponding statements (RDF triples) where effectively modified by the action you specified on your API call.
Per default RDF save check is OFF.
Activate this check using:/GET parameter: safe=true
POST vs GET data
Wherever possible the API uses /GET requests. Even if the request specifies an update. For those cases where additional data is required
- like for example some RDF content - the API uses /POST raw body content with additional query string parameters).
Available API services
Thesaurus operations
Thesaurus operations have the following generic syntax:
/thesaurus/PTHENAME/action/PARAMETERS
Where:
PTHENAME : is the project name for a SKOS Shuttle thesaurus
PARAMETERS : a sequence of querystring parameters without initial "?"
Management operations
Management operations have the following generic syntax:
/mgnt/action/PARAMETERS
Where:
PARAMETERS : a sequence of querystring parameters without initial "?"
Thesaurus SELECT operations
Thesaurus SELECT operations returns extracted RDF data from a SKOS Shuttle project.
conceptSchemes
/GET /thesaurus/PTHENAME/conceptSchemes /PARAMETERS
Delivers all concept schemes in project PTHENAME
searchConcepts
/GET /thesaurus/PTHENAME/searchConcepts /PARAMETERS
Delivers concepts upon text search
REQUIRED PARAMETERS
Output format
t|text=Text used to search for concepts - can contains also blanks or round parentheses ()
parenthesis)
ADDITIONAL PARAMETERS
Limit
limit=a positive number (default 10) to limit SPARQL statement retrieval
Offset
offset=a positive number (default 0) to shift SPARQL statement retrieval
Search in
sin|searchin= pl | al | hl | rl | sd | dd | * - search for text in:
pl - skos:prefLabel, al - skos:altLabel, hl - skos:hiddenLabel, rl - rdfs:label, sd - skos:definition, dd - dc:description
Only predicates
op|onlyp=p1,p2,p3 - select results containing only these comma separated predicates (short or full URIs)
Only literals
ol|onlyliterals=true|false - search only in literals (default: true)
Counting
count|countconcepts=true|false - executes also a count queries without limit to measure all fitting concepts (default: false)
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GETTY_AAT/searchConcepts /t=furni&sl=en&l=en&limit=100&onlyliterals=true&count=true
{
"conceptsearch": {
"retrieved_concepts": 15,
"fitting_concepts": 112,
"concepts": {
"GETTY_AAT:300038860": {
"skos:prefLabel": [
{
"case furniture": "en"
}
],
"rdfs:label": [
{
"carcase furniture": "en"
},
{
"case pieces": "en"
},
{
"cases (furniture)": "en"
},
{
"furniture, carcase": "en"
},
{
"furniture, case": "en"
},
{
"pieces, case": "en"
},
{
"case furniture": "en"
}
],
"skos:altLabel": [
{
"carcase furniture": "en"
},
{
"case pieces": "en"
},
{
"cases (furniture)": "en"
},
{
"furniture, carcase": "en"
},
{
"furniture, case": "en"
},
{
"pieces, case": "en"
}
]
},
"GETTY_AAT:300040215": {
"skos:prefLabel": [
{
"furniture components": "en"
}
],
"rdfs:label": [
{
"furniture component": "en"
},
{
"furniture components": "en"
},
{
"components, furniture": "en"
}
],
"skos:altLabel": [
{
"furniture component": "en"
},
{
"components, furniture": "en"
}
]
},
"GETTY_AAT:300039337": {
"skos:prefLabel": [
{
"support furniture": "en"
}
],
"rdfs:label": [
{
"support furniture": "en"
},
{
"furniture, support": "en"
}
],
"skos:altLabel": [
{
"furniture, support": "en"
}
]
},
"GETTY_AAT:300040038": {
"skos:prefLabel": [
{
"patent furniture": "en"
}
],
"rdfs:label": [
{
"furniture, patent": "en"
},
{
"patent furniture": "en"
},
{
"patented furniture": "en"
}
],
"skos:altLabel": [
{
"furniture, patent": "en"
},
{
"patented furniture": "en"
}
]
},
"GETTY_AAT:300038494": {
"skos:prefLabel": [
{
"benches (furniture)": "en"
}
],
"rdfs:label": [
{
"bancos (benches)": "en"
},
{
"banks (benches)": "en"
},
{
"bench (furniture)": "en"
},
{
"benches (furniture)": "en"
}
],
"skos:altLabel": [
{
"bancos (benches)": "en"
},
{
"banks (benches)": "en"
},
{
"bench (furniture)": "en"
}
]
},
"GETTY_AAT:300037680": {
"skos:prefLabel": [
{
"furniture": "en"
}
],
"rdfs:label": [
{
"furniture": "en"
}
]
},
"GETTY_AAT:300039306": {
"rdfs:label": [
{
"side boards (furniture)": "en"
},
{
"sideboard (furniture)": "en"
},
{
"sideboards (furniture)": "en"
}
]
},
"GETTY_AAT:300037769": {
"skos:prefLabel": [
{
"seating furniture": "en"
}
],
"rdfs:label": [
{
"furniture, seat": "en"
},
{
"furniture, seating": "en"
},
{
"seat furniture": "en"
},
{
"seating furniture": "en"
}
],
"skos:altLabel": [
{
"furniture, seat": "en"
},
{
"furniture, seating": "en"
},
{
"seat furniture": "en"
}
]
},
"GETTY_AAT:300039360": {
"skos:prefLabel": [
{
"secretaries (furniture)": "en"
}
],
"rdfs:label": [
{
"secrétaire": "en"
},
{
"secrétaires": "en"
},
{
"secretaries (furniture)": "en"
},
{
"secretary (furniture)": "en"
}
],
"skos:altLabel": [
{
"secrétaire": "en"
},
{
"secrétaires": "en"
},
{
"secretary (furniture)": "en"
}
]
},
"GETTY_AAT:300386291": {
"skos:prefLabel": [
{
"furniture manufactories": "en"
}
],
"rdfs:label": [
{
"furniture manufactories": "en"
},
{
"furniture manufactory": "en"
},
{
"manufactories, furniture": "en"
}
],
"skos:altLabel": [
{
"furniture manufactory": "en"
},
{
"manufactories, furniture": "en"
}
]
},
"GETTY_AAT:300241953": {
"skos:prefLabel": [
{
"furnishings components": "en"
}
],
"rdfs:label": [
{
"components, furnishings": "en"
},
{
"furnishings component": "en"
},
{
"furnishings components": "en"
}
],
"skos:altLabel": [
{
"components, furnishings": "en"
},
{
"furnishings component": "en"
}
]
},
"GETTY_AAT:300263333": {
"rdfs:label": [
{
"furniture genre": "en"
},
{
"furniture genres": "en"
},
{
"genres, furniture": "en"
}
],
"skos:altLabel": [
{
"furniture genre": "en"
},
{
"genres, furniture": "en"
}
]
},
"GETTY_AAT:300165808": {
"skos:prefLabel": [
{
"suites (furniture)": "en"
}
],
"rdfs:label": [
{
"suite (furniture)": "en"
},
{
"suites (furniture)": "en"
}
],
"skos:altLabel": [
{
"suite (furniture)": "en"
}
]
},
"GETTY_AAT:300040033": {
"skos:prefLabel": [
{
"inflatable furniture": "en"
}
],
"rdfs:label": [
{
"air-supported furniture": "en"
},
{
"blow-up furniture": "en"
},
{
"furniture, air-supported": "en"
},
{
"furniture, blow-up": "en"
},
{
"furniture, inflatable": "en"
},
{
"furniture, pneumatic": "en"
},
{
"inflatable furniture": "en"
},
{
"pneumatic furniture": "en"
}
],
"skos:altLabel": [
{
"air-supported furniture": "en"
},
{
"blow-up furniture": "en"
},
{
"furniture, air-supported": "en"
},
{
"furniture, blow-up": "en"
},
{
"furniture, inflatable": "en"
},
{
"furniture, pneumatic": "en"
},
{
"pneumatic furniture": "en"
}
]
},
"GETTY_AAT:300136596": {
"skos:prefLabel": [
{
"tallboys (furniture)": "en"
}
],
"rdfs:label": [
{
"tallboy (furniture)": "en"
},
{
"tallboys (furniture)": "en"
}
],
"skos:altLabel": [
{
"tallboy (furniture)": "en"
}
]
}
}
}
}
REQUIRED PARAMETERS
(none)
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/conceptSchemes /format=xml
GEOPLACES:1
en
GEO Places
topConcepts
/GET /thesaurus/PTHENAME/topConcepts /PARAMETERS
Delivers all top concepts for a given concept scheme in project PTHENAME
REQUIRED PARAMETERS
Output format
u|uri=SHORT or FULL URI of concept scheme
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/topConcepts /u=GEOPLACES:1&format=yaml
!com.semweb.skosshuttle.api.Results
labeled:
GEOPLACES:3:
- en: CITIES
GEOPLACES:2:
- en: NATIONS
concepts
/GET /thesaurus/PTHENAME/concepts /PARAMETERS
Delivers information to specified concepts in project PTHENAME
REQUIRED PARAMETERS
URI's of several concepts
u|uri={SHORT or FULL URI of concept}*
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/concepts /u=GEOPLACES:4&u=GEOPLACES:10
[
{
"unlabeled": {
"skos:related": [
"GEOPLACES:7",
"GEOPLACES:8"
],
"skos:broader": [
"GEOPLACES:2"
],
"dcterms:creator": [
"Semweb"
],
"dcterms:created": [
"2016-05-17T09:54:45.399Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-17T09:54:45.399Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Switzerland"
}
]
}
},
{
"unlabeled": {
"skos:related": [
"GEOPLACES:6"
],
"skos:broader": [
"GEOPLACES:3"
],
"dcterms:creator": [
"Semweb"
],
"dcterms:created": [
"2016-05-17T07:58:39.410Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-17T08:00:39.410Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Duesseldorf"
}
]
}
}
]
concept
/GET /thesaurus/PTHENAME/concept /PARAMETERS
Delivers information to one specified concept in project PTHENAME
REQUIRED PARAMETERS
URI of one concept
u|uri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/concept /u=GEOPLACES:10
{
"unlabeled": {
"skos:related": [
"GEOPLACES:6"
],
"skos:broader": [
"GEOPLACES:3"
],
"dcterms:creator": [
"Semweb"
],
"dcterms:created": [
"2016-05-17T07:58:39.410Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-17T08:00:39.410Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Duesseldorf"
}
]
}
}
conceptSubtree
/GET /thesaurus/PTHENAME/conceptSubtree /PARAMETERS
Delivers concepts in subtree of specified concept in project PTHENAME
REQUIRED PARAMETERS
URI of one concept
u|uri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/conceptSubtree /u=GEOPLACES:3
{
"unlabeled": {
"skos:narrower": [
"GEOPLACES:7",
"GEOPLACES:8",
"GEOPLACES:10",
"GEOPLACES:11",
"GEOPLACES:12"
],
"dcterms:creator": [
"Semweb"
],
"skos:topConceptOf": [
"GEOPLACES:1"
],
"dcterms:created": [
"2016-05-17T06:02:39.407Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-18T20:52:28.476Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "CITIES"
}
],
"skos:definition": [
{
"en": "Some cities in Europa"
}
]
},
"recursive": {
"skos:narrower": [
{
"unlabeled": {
"skos:related": [
"GEOPLACES:4"
],
"skos:broader": [
"GEOPLACES:3"
],
"dcterms:creator": [
"Semweb"
],
"dcterms:created": [
"2016-05-17T07:56:39.409Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-17T22:06:32.500Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Geneva"
}
]
}
},
{
"unlabeled": {
"skos:related": [
"GEOPLACES:4"
],
"skos:broader": [
"GEOPLACES:3"
],
"dcterms:creator": [
"Semweb"
],
"dcterms:created": [
"2016-05-17T07:56:39.409Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-17T08:01:39.410Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Zurich"
}
]
}
},
{
"unlabeled": {
"skos:related": [
"GEOPLACES:6"
],
"skos:broader": [
"GEOPLACES:3"
],
"dcterms:creator": [
"Semweb"
],
"dcterms:created": [
"2016-05-17T07:58:39.410Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-17T08:00:39.410Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Duesseldorf"
}
]
}
},
{
"unlabeled": {
"skos:broader": [
"GEOPLACES:3"
],
"dcterms:creator": [
"Semweb"
],
"dcterms:created": [
"2016-05-17T22:13:16.837Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-17T22:13:16.837Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Geneva"
}
]
}
},
{
"unlabeled": {
"skos:broader": [
"GEOPLACES:3"
],
"dcterms:creator": [
"Semweb"
],
"dcterms:created": [
"2016-05-17T22:15:34.550Z"
],
"rdf:type": [
"skos:Concept"
],
"dcterms:modified": [
"2016-05-17T22:15:34.550Z"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Geneva"
}
]
}
}
]
}
}
getdocmetadata
/GET /thesaurus/PTHENAME/getdocmetadata /PARAMETERS
Delivers information to one specified document in project PTHENAME
REQUIRED PARAMETERS
URI of one document
d|docuri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/getdocmetadata /d=semwebo:doc/po_jpg
{
"unlabeled": {
"semwebo:date": ["2016-06-23T22:00:00.000Z"],
"semwebo:filename": ["API title 4 TICINO.jpg"],
"dcterms:creator": ["fabio"],
"semwebo:doctype": ["jpg"],
"rdf:type": ["semwebo:doc"],
"dcterms:modified": ["2016-06-24T12:27:12.139Z"]
},
"labeled": {
"dcterms:description": [{
"de": "API DESC 4 ticino"
}],
"dcterms:title": [{
"de": "API title 4 TICINO"
}]
}
}
getdoc
/GET /thesaurus/PTHENAME/getdoc /PARAMETERS
Delivers the specified document in project PTHENAME
REQUIRED PARAMETERS
URI of one document
d|docuri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/getdoc /d=semwebo:doc/po_jpg
... the content of the document including content type (mime type) data to process the document
getlanguagetrack
/GET /thesaurus/PTHENAME/getlanguagetrack /PARAMETERS
Delivers the language track in project PTHENAME as text (see example)
OPTIONAL PARAMETERS
Provide language to be set as first in output
l|langs=en
Force recompute language track (might take longer)
l|relangs={true|false}
Example
/GET /thesaurus/GEOPLACES/getlanguagetrack /langs=en&relangs=true
en,de,fr
broaders
/GET /thesaurus/PTHENAME/broaders /PARAMETERS
Delivers descriptors of related concepts to one specified concept in project PTHENAME
REQUIRED PARAMETERS
URI of one concept
u|uri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/broaders /u=GEOPLACES:8&format=json
{
"unlabeled": {
"skos:broader": [
"GEOPLACES:3"
]
}
}
narrowers
/GET /thesaurus/PTHENAME/narrowers /PARAMETERS
Delivers descriptors of narrower concepts to one specified concept in project PTHENAME
REQUIRED PARAMETERS
URI of one concept
u|uri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/PTHENAME/narrowers /u=GEOPLACES:3&format=json
{
"unlabeled": {
"skos:narrower": [
"GEOPLACES:7",
"GEOPLACES:8",
"GEOPLACES:10",
"GEOPLACES:11",
"GEOPLACES:12"
]
}
}
related
/GET /thesaurus/PTHENAME/related /PARAMETERS
Delivers descriptors of related concepts to one specified concept in project PTHENAME
REQUIRED PARAMETERS
URI of one concept
u|uri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/related/u=GEOPLACES:4&format=json
{
"unlabeled": {
"skos:related": [
"GEOPLACES:7",
"GEOPLACES:8"
]
}
}
entitytypes
/GET /thesaurus/PTHENAME/entitytypes /PARAMETERS
Delivers rdf:type of given descriptor in project PTHENAME
REQUIRED PARAMETERS
URI of one concept
u|uri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Language tags
langs=en{,fr,...}
Namespaces
ns=short|full
Example
/GET /thesaurus/GEOPLACES/entitytypes /u=GEOPLACES:3
{
"unlabeled": {
"rdf:type": [
"skos:Concept"
]
}
}
namespaces
/GET /thesaurus/PTHENAME/namespaces /PARAMETERS
Delivers all the namespaces (of properties) in project PTHENAME
REQUIRED PARAMETERS
(None)
URI of one concept
u|uri=SHORT or FULL URI of concept
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Example
/GET /thesaurus/GEOPLACES/namespaces /
{
"unlabeled": {
"virt": [
"http://www.openlinksw.com/virtuoso/xslt"
],
...
"opl-gs": [
"http://www.openlinksw.com/schemas/getsatisfaction/"
],
"wfw": [
"http://wellformedweb.org/CommentAPI/"
],
"ogc": [
"http://www.opengis.net/"
],
"semwebo": [
"http://semweb.ch/onto/"
],
"xslwd": [
"http://www.w3.org/TR/WD-xsl/"
],
"radio": [
"http://www.radiopop.co.uk/"
],
"sioct": [
"http://rdfs.org/sioc/types#"
],
"umbel-ac": [
"http://umbel.org/umbel/ac/"
],
...
"wikidata": [
"http://www.wikidata.org/entity/"
]
}
}
properties
/GET /thesaurus/PTHENAME/properties /PARAMETERS
Delivers properties in project PTHENAME
REQUIRED PARAMETERS
(None)
GENERIC PARAMETERS
Output format
format=json|yaml|xml
Example
/GET /thesaurus/GEOPLACES/properties /
{
"unlabeled": {
"rdfs:subClassOf": [
"semwebo:thesaurus_properties",
"rdfs:Resource"
],
"semwebo:namespace": [
"semwebo:ns/54",
"semwebo:ns/55",
"semwebo:ns/56",
...
"semwebo:ns/51",
"semwebo:ns/52",
"semwebo:ns/53"
],
"dcterms:creator": [
"sam"
],
"dcterms:created": [
"2016-05-17T07:47:45.332Z"
],
"rdf:type": [
"semwebo:thesaurus_properties",
"rdfs:Class"
]
},
"labeled": {
"skos:prefLabel": [
{
"en": "Thesaurus Properties"
}
],
"skos:definition": [
{
"en": "Thesaurus Preferences"
}
],
"skos:scopeNote": [
{
"en": "First note for Thesaurus"
}
]
}
}
rdfexportsubtree
/GET /thesaurus/PTHENAME/rdfexportsubtree /PARAMETERS
Export narrowers subtree of concept
REQUIRED PARAMETERS
URI of one Concept
u|uri={SHORT or FULL URI of concept}
GENERIC PARAMETERS
RDF Output format
rdfformat=N3|NTRIPLES|NQUADS|RDFXML|TRIG|TURTLE
Example
/GET /thesaurus/GEOPLACES/rdfexportsubtree /u=GEOPLACES:4
2016-05-17T06:02:22.680+02:00
Semweb
Some cities in Europa
CITIES
2016-05-18T20:52:22.687+02:00
2016-05-17T07:56:22.687+02:00
Semweb
Geneva
2016-05-17T22:06:22.688+02:00
2016-05-17T07:56:22.688+02:00
Semweb
Zurich
2016-05-17T08:01:22.688+02:00
2016-05-17T07:58:22.689+02:00
Semweb
Duesseldorf
2016-05-17T08:00:22.689+02:00
2016-05-17T22:13:22.690+02:00
Semweb
Geneva
2016-05-17T22:13:22.690+02:00
2016-05-17T22:15:22.691+02:00
Semweb
Geneva
2016-05-17T22:15:22.691+02:00
snapshot
/GET /thesaurus/PTHENAME/snapshot /
Export RDFXML Snapshot of thesaurus in project
REQUIRED PARAMETERS
(None)
GENERIC PARAMETERS
(None)
Example
/GET /thesaurus/GEOPLACES/snapshot /
Thesaurus UPDATE operations
Thesaurus SELECT operations returns extracted RDF data from a SKOS Shuttle project.
addConceptScheme
/GET /thesaurus/PTHENAME/addConceptScheme /PARAMETERS
Add a new concept scheme to project PTHENAME
REQUIRED PARAMETERS
preferred Label for concept scheme
pl|preflabel={text for preferred label}
Concept URI
u|uri={Text}
OPTIONAL PARAMETERS
Base URI
tu|thebaseuri={Base URI of the new concept scheme (any)}
Definition
d|definition={Text}
Creator
cr|creator={Name of the creator}
Contributor
co|contributor={Name of the contributor}
Identifier
i|identifier={Any identification acronym or number}
Homepage
h|homepage={Text}
Issued
is|issued={Issued date for this concept scheme}
Scope note
l|lang={language tag for preferred label (thesaurus default if omitted)}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/addConceptScheme /preflabel=TESTCONCEPTSCHEME&thebaseuri=http://zbw.stw.eu/geo&lang=de&definition=DEFINITIONFORANEWCONCEPTSCHEMEWITHOUTBLANKS&creator=Sam%20Souci&homepage=https://it.semweb.ch&scopenote=Thisisascopenotewidhoutblanks&issued=12.05.2016&safe=true&format=xml
uri
http://zbw.stw.eu/geo/0
/GET /thesaurus/GEOPLACES/addConceptScheme /preflabel=TESTCONCEPTSCHEME&thebaseuri=http://zbw.stw.eu/geo&lang=de&definition=DEFINITIONFORANEWCONCEPTSCHEMEWITHOUTBLANKS&creator=Sam%20Souci&homepage=https://it.semweb.ch&scopenote=Thisisascopenotewidhoutblanks&issued=12.05.2016&safe=true
{
"update": {
"uri": "http://zbw.stw.eu/geo/0"
}
}
deleteConceptScheme
/GET /thesaurus/PTHENAME/deleteConceptScheme /PARAMETERS
Delete an existing concept scheme in project PTHENAME
REQUIRED PARAMETERS
Concept URI
u|uri={Text}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/deleteConceptScheme /u=http://zbw.stw.eu/geo/0
{
"update": {
"result": "ok"
}
}
addConcept
/GET /thesaurus/PTHENAME/addConcept /PARAMETERS
Add a new concept to PTHENAME and generate a new descriptor
REQUIRED PARAMETERS
preferred Label for concept scheme
pl|preflabel={text for preferred label}
Concept URI (specify a broader concept for the added concept)
b|broaderuri={SHORT or FULL URI of broader concept} If safe=true, SKOS Shuttle checks that this URI exists before creating the concept
OPTIONAL PARAMETERS
Forced concept URI
u|concepturi={SHORT or FULL URI of concept} If safe=true, SKOS Shuttle checks that this URI does not yet exists. If you omit this optional parameter, SKOS Shuttle generates a new descriptor for the concept on the basis of thebaseuriname/thebaseuri defined below (or uses the standard values) a
Language tag
l|lang={Languge tag for the preferred label of the new concept} This forces SKOS Shuttle to create the concept using exactely this URI
ScopeNote
sn|skopenote={Any scope note to be added to concept}
Alternative Label
al|altlabel={Any alternative label to be added to concept}
Hidden Label
hl|hiddenlabel={Any hidden label to be added to concept}
Base URI
bu|thebaseuri={Base URI of the new concept (any)} Attention: Do NOT use a superset of thesaurus default base URI! Eg. if thesaurus default base URI were http://semweb.ch/u - do not use http://semweb.ch/u/b .
Base URI Qname
bun|thebaseuriname={Base URI (Q) name of the new concept (any)}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/addConcept /safe=true&b=GEOPLACES:3&preflabel=Test%20ConceptLabel%20TXT&lang=en&thebaseuri=http%3A%2F%2Fzbw.stw.eu%2Fgeo&bun=GEO
{
"update": {
"uri": "http://zbw.stw.eu/geo/0"
}
}
deleteConcept
/GET /thesaurus/PTHENAME/deleteConcept /PARAMETERS
Delete an existing concept in PTHENAME
REQUIRED PARAMETERS
preferred Label for concept scheme
pl|preflabel={text for preferred label}
Concept URI
u|uri={SHORT or FULL URI of concept}}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/deleteConcept /u=http://zbw.stw.eu/geo/0
{
"update": {
"result": "ok"
}
}
uploaddoc
/POST /thesaurus/PTHENAME/uploaddoc /PARAMETERS + RAW BODY PAYLOAD
upload content as document and associate that document with an existing concept in PTHENAME
REQUIRED PARAMETERS
Concept URI
u|uri={SHORT or FULL URI of concept}}
Document URI
d|docuri={SHORT or FULL URI of document - ADVICE : please use the pattern semwebo:doc/filename_extension to be compliant with SKOS Shuttle documents processing! }}
DOC meta data format
df|docformat={filename extension for content as it were stored in a filename}}
DOC meta data title
t|title={title of document}}
DOC description
de|description={description of document}}
DOC meta data date FROM
d1|datefrom={date (from) in format dd.mm.yyyy}}
OPTIONAL PARAMETERS
DOC meta data date TO
d2|dateto={date (to) in format dd.mm.yyyy} use this if you want to specify a range}
DOC meta data filename TO
fn|filename={filename to be stored} if omitted, the value of Document URI is taken}
DOC meta data language
l|lang={language tag to be used with text DOC meta data}
DOC coding
c|coding={base64 - to indicate that the sent payload content is coded in base64}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/POST /thesaurus/GEOPLACES/uploaddoc /thesaurus/GEOPLACES/uploaddoc/u=GEOPLACES:111&d=semwebo:doc/xx_jpg&df=jpg&t=API title 4 TICINO&de=API DESC 4 xx&d1=24.06.2016&coding=base64&safe=true
{
"docupload": {
"result": "ok"
}
}
associatedoc
/GET /thesaurus/PTHENAME/associatedoc /PARAMETERS
Associates a document with an existing concept in PTHENAME
REQUIRED PARAMETERS
Concept URI
u|uri={SHORT or FULL URI of concept}}
Document URI
d|docuri={SHORT or FULL URI of document}}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/associatedoc /u=GEOPLACES:7&d=semwebo:doc/ticino2_jpg
{
"docassoc": {
"result": "ok"
}
}
dissociatedoc
/GET /thesaurus/PTHENAME/dissociatedoc /PARAMETERS
Dissociates a document from a concept in PTHENAME (deletes the doc from the project if no further assotiations exist)
REQUIRED PARAMETERS
Concept URI
u|uri={SHORT or FULL URI of concept}}
Document URI
d|docuri={SHORT or FULL URI of document}}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/dissociatedoc /u=GEOPLACES:7&d=semwebo:doc/ticino2_jpg
{
"docassoc": {
"result": "ok"
}
}
addLiteral
/GET /thesaurus/PTHENAME/addLiteral /PARAMETERS
Add a literal to an existing concept in PTHENAME
REQUIRED PARAMETERS
Text for literal
nt|text={text for literal}
Concept URI
u|uri={SHORT or FULL URI of concept}}
Property of Literal
sk|skosproperty={prefLabel|altLabel|hiddenLabel|definition|scopeNote}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/addLiteral /safe=true&u=GEOPLACES:10&text=Ddorf&lang=en&skosproperty=altLabel
{
"update": {
"result": "ok"
}
}
updateLiteral
/GET /thesaurus/PTHENAME/updateLiteral /PARAMETERS
Change literal text to an existing concept in PTHENAME
REQUIRED PARAMETERS
Current text of literal
ct|currtext={text for literal}
New text of literal
nt|newtext={text for literal}
Concept URI
u|uri={SHORT or FULL URI of concept}}
Property of Literal
sk|skosproperty={prefLabel|altLabel|hiddenLabel|definition|scopeNote}
OPTIONAL PARAMETERS
Language tag
l|lang={Languge tag for the label of the literal (thesaurus default if omitted)}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/updateLiteral /safe=true&u=GEOPLACES:10&currtext=Ddorf&newtext=D'dorf&lang=en&skosproperty=altLabel
{
"update": {
"result": "ok"
}
}
deleteLiteral
/GET /thesaurus/PTHENAME/deleteLiteral /PARAMETERS
Delete literal from an existing concept in PTHENAME
REQUIRED PARAMETERS
Current text of literal
t|text={text for literal}
Concept URI
u|uri={SHORT or FULL URI of concept}}
Property of Literal
sk|skosproperty={prefLabel|altLabel|hiddenLabel|definition|scopeNote}
OPTIONAL PARAMETERS
Language tag
l|lang={Languge tag for the label of the literal (thesaurus default if omitted)}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/deleteLiteral /safe=true&u=GEOPLACES:10&text=D'dorf&lang=en&skosproperty=altLabel
{
"update": {
"result": "ok"
}
}
addRelation
/GET /thesaurus/PTHENAME/addRelation /PARAMETERS
Add a (SKOS) relation between two concepts in PTHENAME
REQUIRED PARAMETERS
URI of source concept
u|source={SHORT or FULL URI of concept}}
URI of target concept
v|target={SHORT or FULL URI of concept}}
SKOS relation
sr|skosrelation={broader|narrower|related}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/addRelation /safe=true&u=GEOPLACES:10&v=GEOPLACES:4&skosrelation=broader
{
"update": {
"result": "ok"
}
}
deleteRelation
/GET /thesaurus/PTHENAME/deleteRelation /PARAMETERS
Delete a (SKOS) relation between two concepts in PTHENAME
REQUIRED PARAMETERS
URI of source concept
u|source={SHORT or FULL URI of concept}}
URI of target concept
v|target={SHORT or FULL URI of concept}}
SKOS relation
sr|skosrelation={broader|narrower|related}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Safe Check
safe=true|false
Example
/GET /thesaurus/GEOPLACES/deleteRelation
safe=true&u=GEOPLACES:10&v=GEOPLACES:4&skosrelation=broader
{
"update": {
"result": "ok"
}
}
rdfimportsubtree
/POST /thesaurus/PTHENAME/rdfimportsubtree /PARAMETERS + RAW BODY PAYLOAD
Substitute a subtree with imported content in PTHENAME
REQUIRED PARAMETERS
URI of subtree root concept
u|source={SHORT or FULL URI of concept}}
RDF Input format
rdfformat=N3|NTRIPLES|NQUADS|RDFXML|TRIG|TURTLE
RDF content
RDF content in POST raw body payload
GENERIC PARAMETERS
Output format
format=json|xml|yaml
OPTIONAL PARAMETERS
Recompute language track (might take longer)
l|relangs={true|false}
Example
/POST /thesaurus/GEOPLACES/rdfimportsubtree /u=GEOPLACES:10&rdfformat=RDFXML
{
"update": {
"result": "ok"
}
}
rdfimport
/POST /thesaurus/PTHENAME/rdfimport /PARAMETERS + RAW BODY PAYLOAD
Import RDF in PTHENAME
REQUIRED PARAMETERS
RDF Input format
rdfformat=N3|NTRIPLES|NQUADS|RDFXML|TRIG|TURTLE
RDF content
RDF content in POST raw body payload
OPTIONAL PARAMETERS
Recompute language track (might take longer)
l|relangs={true|false}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/POST /thesaurus/GEOPLACES/rdfimportsubtree /rdfformat=TURTLE
{
"update": {
"result": "ok"
}
}
sparql
/POST /thesaurus/PTHENAME/sparql / + RAW BODY PAYLOAD
Execute SPARQL in PTHENAME
REQUIRED PARAMETERS
RDF content
SPARQL query in POST raw body payload query=select * {?s ?p ?o} limit 3
OPTIONAL PARAMETERS
GENERIC PARAMETERS
Output format
format=json|xml
Example
/POST /thesaurus/ASSEMBLY/sparql /format=xml +PAYLOAD: query=select * {?s ?p ?o} limit 3
http://semweb.ch/onto/ns/0
http://semweb.ch/onto/ns_prefix
ASSEMBLY
http://semweb.ch/onto/ns/0
http://semweb.ch/onto/ns_uri
https://semweb.ch/assembly/
http://semweb.ch/onto/ns/1
http://semweb.ch/onto/ns_prefix
dcterms
sparqlupdate
/POST /thesaurus/PTHENAME/sparqlupdate / + RAW BODY PAYLOAD
Execute SPARQL-UPDATE in PTHENAME
REQUIRED PARAMETERS
RDF content
SPARQL-UPDATE query in POST raw body payload
OPTIONAL PARAMETERS
Recompute language track (might take longer)
l|relangs={true|false}
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/POST /thesaurus/GEOPLACES/sparqlupdate /
{
"update": {
"result": "ok"
}
}
recoversnapshot
/POST /thesaurus/PTHENAME/recoversnapshot / + RAW BODY PAYLOAD
Upload an RDFXML snapshot in PTHENAME
REQUIRED PARAMETERS
RDF content
RDFXML snapshot content in POST raw body payload
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/POST /thesaurus/GEOPLACES/recoversnapshot /
{
"update": {
"result": "ok"
}
}
Management SELECT operations
Management SELECT operations return extracted management data from a SKOS Shuttle project.
services
/GET /mgnt/services /PARAMETERS
Returns a list of all API services in the account
REQUIRED PARAMETERS
(None)
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/GET /mgnt/services /
{
"services": [
{
"name": "thesaurus",
"subject": "[conceptSchemes, properties, topConcepts, concept, concepts, entitytypes, conceptSubtree, broaders, narrowers, related, rdfexportsubtree, namespaces, snapshot, addConceptScheme, addConcept, addLiteral, addRelation, updateLiteral, deleteConcept, deleteConceptScheme, deleteLiteral, deleteRelation, rdfimportsubtree, rdfimport, sparqlupdate, recoversnapshot]"
},
{
"name": "mgnt",
"subject": "[services, projects, groups, rights, user, users, rightsforgroup, groupsandrightsforuser]"
}
]
}
projects
/GET /mgnt/projects /PARAMETERS
Returns a list of all projects in the account
REQUIRED PARAMETERS
(None)
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/GET /mgnt/projects /
{
"projects": [
{
"name": "GEOPLACES",
"serviceurl": "GEOPLACES_INTERNAL_PROJECT",
"thelang": "en",
"loginname": "eptestuser",
"pw": "test",
"thebaseuri": "http://mycompany.ch/base",
"validated": true,
"selected4project": true
}
]
}
groups
/GET /mgnt/groups /PARAMETERS
Returns a list of all groups in the account
REQUIRED PARAMETERS
(None)
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/GET /mgnt/groups /
{
"groups": [
{
"groupname": "admin",
"comment": "The admin group cannot be deleted"
},
{
"groupname": "root",
"comment": "Used for automatical created users"
}
]
}
rights
/GET /mgnt/rights /PARAMETERS
Returns a list of all rights in the account
REQUIRED PARAMETERS
(None)
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/GET /mgnt/rights /
{
"rights": [
{
"rightname": "skosnavigator",
"comment": "Navigate SKOS Elements"
},
{
"rightname": "skosupdate",
"comment": "Read/Insert/Delete/Update SKOS Elements"
},
{
"rightname": "triplenavigator",
"comment": "Navigate Triples"
},
{
"rightname": "tripleupdate",
"comment": "Read/Insert/Delete/Update triples"
},
{
"rightname": "rdfimport",
"comment": "RDF Import (merge or replace)"
},
{
"rightname": "rdfexport",
"comment": "RDF export"
},
{
"rightname": "rdfimportexport",
"comment": "Both directions import/export"
},
{
"rightname": "projectupdate",
"comment": "Read/Insert/Delete/Update Projects"
},
{
"rightname": "projectdata",
"comment": "Delete / Create Endpoint Project data"
},
{
"rightname": "projectep",
"comment": "Insert/Delete Endpoint Information"
},
{
"rightname": "userupdate",
"comment": "Read/Insert/Delete/Update users and Groups"
},
{
"rightname": "admin",
"comment": "All rights - except creating other admin's users"
},
{
"rightname": "root",
"comment": "All rights"
},
{
"rightname": "api",
"comment": "Right to access the api using other rights to specify access"
},
{
"rightname": "expertview",
"comment": "Shows RDF information on displayed items"
},
{
"rightname": "nop",
"comment": "Basis right - with no rights"
}
]
}
users
/GET /mgnt/users /PARAMETERS
Returns a list of all users in the account
REQUIRED PARAMETERS
(None)
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/GET /mgnt/users /
{
"users": [
{
"realname": "sam",
"loginname": "sam",
"pw": "**********"
}
]
}
user
/GET /mgnt/user /PARAMETERS
Returns a list of all users in the account
REQUIRED PARAMETERS
Login name of user
ul|userlogin={name used to login}*
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/GET /mgnt/users /userlogin=sam
{
"users": [
{
"realname": "sam",
"loginname": "sam",
"pw": "*********"
}
]
}
rightsforgroup
/GET /mgnt/rightsforgroup /PARAMETERS
Returns a list of all rights for a given group in the account
REQUIRED PARAMETERS
Group name
gn|groupname={Group name}*
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/GET /mgnt/rightsforgroup /groupname=root
{
"groups": [
{
"groupname": "root",
"comment": "Used for automatical created users",
"rights": [
{
"rightname": "api",
"comment": "Right to access the api using other rights to specify access"
},
{
"rightname": "root",
"comment": "All rights"
}
]
}
]
}
groupsandrightsforuser
/GET /mgnt/groupsandrightsforuser /PARAMETERS
Returns a list of all rights and groups for a given user in the account
REQUIRED PARAMETERS
Login name of user
ul|userlogin={name used to login}*
GENERIC PARAMETERS
Output format
format=json|xml|yaml
Example
/GET /mgnt/groupsandrightsforuser /userlogin=sam
{
"users": [
{
"realname": "sam",
"loginname": "sam",
"pw": "*********",
"groups": [
{
"groupname": "root",
"comment": "Used for automatical created users",
"rights": [
{
"rightname": "api",
"comment": "Right to access the api using other rights to specify access"
},
{
"rightname": "root",
"comment": "All rights"
}
]
}
]
}
]
}