API

Get all components

Retrieve all components.

GET /component HTTP/1.1
Host: [SEMCOM_HOST]
[
  {
    "@id": "https://node.semcom.digita.ai/c/https://node.semcom.digita.ai/c/001",
    "@type": [
      "http://semcom.digita.ai/voc#component"
    ],
    "http://semcom.digita.ai/voc#label": [
      {
        "@id": "Component 1"
      }
    ],
    "http://semcom.digita.ai/voc#description": [
      {
        "@id": "Lorem psum sid amet."
      }
    ],
    "http://semcom.digita.ai/voc#author": [
      {
        "@id": "https://digita.ai"
      }
    ],
    "http://semcom.digita.ai/voc#version": [
      {
        "@id": "0.1.0"
      }
    ],
    "http://semcom.digita.ai/voc#latest": [
      {
        "@value": "true",
        "@type": "http://www.w3.org/2001/XMLSchema#boolean"
      }
    ]
  },
  {
    "@id": "https://node.semcom.digita.ai/c/https://node.semcom.digita.ai/c/002",
    "@type": [
      "http://semcom.digita.ai/voc#component"
    ],
    "http://semcom.digita.ai/voc#label": [
      {
        "@id": "Component 2"
      }
    ],
    "http://semcom.digita.ai/voc#description": [
      {
        "@id": "Lorem psum sid amet."
      }
    ],
    "http://semcom.digita.ai/voc#author": [
      {
        "@id": "https://digita.ai"
      }
    ],
    "http://semcom.digita.ai/voc#version": [
      {
        "@id": "0.1.0"
      }
    ],
    "http://semcom.digita.ai/voc#latest": [
      {
        "@value": "true",
        "@type": "http://www.w3.org/2001/XMLSchema#boolean"
      }
    ]
  }
]

Get all components with content negotiation

Retrieve all components as Turtle.

GET /component HTTP/1.1
Host: [SEMCOM_HOST]
Accept: text/turtle
<https://node.semcom.digita.ai/c/https://node.semcom.digita.ai/c/001> a <http://semcom.digita.ai/voc#component>;
    <http://semcom.digita.ai/voc#label> <Component 1>;
    <http://semcom.digita.ai/voc#description> <Lorem psum sid amet.>;
    <http://semcom.digita.ai/voc#author> <https://digita.ai>;
    <http://semcom.digita.ai/voc#version> <0.1.0>;
    <http://semcom.digita.ai/voc#latest> true.
<https://node.semcom.digita.ai/c/https://node.semcom.digita.ai/c/002> a <http://semcom.digita.ai/voc#component>;
    <http://semcom.digita.ai/voc#label> <Component 2>;
    <http://semcom.digita.ai/voc#description> <Lorem psum sid amet.>;
    <http://semcom.digita.ai/voc#author> <https://digita.ai>;
    <http://semcom.digita.ai/voc#version> <0.1.0>;
    <http://semcom.digita.ai/voc#latest> true.

Query components

Query components based on a filter.

POST /component/query HTTP/1.1
Host: [SEMCOM_HOST]
Accept: text/turtle
Content-Type: application/json

{
  "uri": "https://node.semcom.digita.ai/c/001"
}
<https://node.semcom.digita.ai/c/https://node.semcom.digita.ai/c/001> a <http://semcom.digita.ai/voc#component>;
    <http://semcom.digita.ai/voc#label> <Component 1>;
    <http://semcom.digita.ai/voc#description> <Lorem psum sid amet.>;
    <http://semcom.digita.ai/voc#author> <https://digita.ai>;
    <http://semcom.digita.ai/voc#version> <0.1.0>;
    <http://semcom.digita.ai/voc#latest> true.

Save component

Save a new component.

POST /component HTTP/1.1
Host: [SEMCOM_HOST]
Accept: text/turtle
Content-Type: application/json

[
  {
    "uri": "https://node.semcom.digita.ai/c/003",
    "label": "test5",
    "description": "test5",
    "author": "test5",
    "version": "test5",
    "latest": "true"
  }
]
<https://node.semcom.digita.ai/c/https://node.semcom.digita.ai/c/003> a <http://semcom.digita.ai/voc#component>;
    <http://semcom.digita.ai/voc#label> <test5>;
    <http://semcom.digita.ai/voc#description> <test5>;
    <http://semcom.digita.ai/voc#author> <test5>;
    <http://semcom.digita.ai/voc#version> <test5>;
    <http://semcom.digita.ai/voc#latest> <true>.