Name your JSON fields with vocabulary terms, and the hub supplies their meaning: it embeds the @semaptic object that describes every value, and converts the document to RDF.
Every key that is a vocabulary term gets the term's template from the registry, with the templates of the nodes it introduces and the prefixes they use. Every other key gets an empty entry ("key": {}), to be described by hand; until it is, it converts as a plain literal. An existing @semaptic object is replaced. @annotations records the date and that the API assembled the block.
Body: The document, up to 10 MB.
| Query | Default | Meaning |
|---|---|---|
| base | — | The namespace the document's entities are minted in: an absolute http(s) IRI ending in / or #. |
| report | false | Return { document, report } rather than the document alone. |
curl -X POST "https://semaptichub.inesctec.pt/api/semaptic" \ -H "Content-Type: application/json" \ --data-binary @document.json
The conversion the RDF Transformer runs, with the hub's datatypes. The document must carry its @semaptic object — send it to /api/semaptic first, or use /api/json-to-rdf.
Body: The document with its @semaptic object, up to 5 MB.
| Query | Default | Meaning |
|---|---|---|
| format ttl | nt | rdf | jsonld | ttl | The RDF format. Without it, the Accept header decides; Turtle by default. |
| base | — | The namespace the document's entities are minted in: an absolute http(s) IRI ending in / or #. |
| skolemize | false | Name anonymous nodes with stable IRIs, so that the graphs of several documents merge. |
| align | true | Link values to their instant (time:hasTime), from a time axis or a record's own timestamp. |
| maxArrayItems | 0 | Keep at most this many elements of each array (0 = all): to convert a sample of a large document. |
curl -X POST "https://semaptichub.inesctec.pt/api/rdf" \ -H "Content-Type: application/json" \ --data-binary @document.json
The @semaptic object is assembled from the registry and the document converted in one step, as /api/semaptic then /api/rdf would. Any @semaptic object the document carries is ignored. When a key is not a vocabulary term, nothing is converted and the answer names the keys.
Body: The document, up to 5 MB.
| Query | Default | Meaning |
|---|---|---|
| format ttl | nt | rdf | jsonld | ttl | The RDF format. Without it, the Accept header decides; Turtle by default. |
| base | — | The namespace the document's entities are minted in: an absolute http(s) IRI ending in / or #. |
| skolemize | false | Name anonymous nodes with stable IRIs, so that the graphs of several documents merge. |
| align | true | Link values to their instant (time:hasTime), from a time axis or a record's own timestamp. |
| maxArrayItems | 0 | Keep at most this many elements of each array (0 = all): to convert a sample of a large document. |
curl -X POST "https://semaptichub.inesctec.pt/api/json-to-rdf" \ -H "Content-Type: application/json" \ --data-binary @document.json
| Query | Default | Meaning |
|---|---|---|
| category | — | Only the terms in this category. |
curl "https://semaptichub.inesctec.pt/api/parameters"
curl "https://semaptichub.inesctec.pt/api/categories"
curl "https://semaptichub.inesctec.pt/api/ontologies"
Each row is one statement of a term's template (subject, predicate, object), including the rows of the nodes it introduces.
| Query | Default | Meaning |
|---|---|---|
| parameter * | — | A term; repeat for several (at most 500). |
curl "https://semaptichub.inesctec.pt/api/semantics"
Also served at the vocabulary's namespace, https://semaptichub.inesctec.pt/vocabulary/, to requests that prefer RDF.
| Query | Default | Meaning |
|---|---|---|
| format ttl | nt | rdf | ttl | Without it, the Accept header decides; Turtle by default. |
curl "https://semaptichub.inesctec.pt/api/vocabulary"
Stored for an administrator to review; the email is used only to follow up on the suggestion.
curl -X POST "https://semaptichub.inesctec.pt/api/suggest-parameter" \ -H "Content-Type: application/json" \ --data-binary @document.json
The document endpoints send CORS headers, so a page on any site can call them, and are rate-limited per client. Load /api/openapi.json into Swagger UI, Postman or a code generator to get a client.