Getting Started with
Herbrich-API
Unified access to all Herbrich Corporation services through a single, centralized platform. No API keys required for read operations.
https://api.herbrich.org/v1/
Currently public read-only. Login / JWT for write comes next.
Core Concepts
Foundational entities of the Herbrich grid model.
GridNode Entity
Primary infrastructure node. Central unit of the Herbrich grid.
GridNodeConnection Linked
Directed edge between nodes with type and parameters.
NodeApplication
Software / service deployed on a GridNode. Versioned, stateful workloads linked to node lifecycle.
Delphinariat
Isolated compute enclosure within a node. Provides sandboxed execution for experimental subsystems.
Endpoints
4 routes · public · JSON/grid/nodes/{id}
Fetch single node by UUID
/grid/nodes/{id}/connections
List all connections for node
/grid/nodes/{id}/applications
List deployed applications
/grid/nodes/{id}/subnodes
List child sub-nodes
f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3
→ Erzbistum Hamburg
Quick Start
Two calls to get you going. Replace ID if needed.import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import com.google.gson.JsonObject;
import com.google.gson.JsonParser;
public class Main {
public static void main(String[] args) throws Exception {
HttpClient client = HttpClient.newHttpClient();
HttpRequest request = HttpRequest.newBuilder()
.uri(URI.create("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3"))
.GET().build();
HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
JsonObject node = JsonParser.parseString(response.body()).getAsJsonObject();
System.out.println("Node: " + node.get("HerbrichName").getAsString());
System.out.println("Hall: " + node.get("HallAddress").getAsString());
}
}
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import com.google.gson.JsonArray;
import com.google.gson.JsonParser;
public class Main {
public static void main(String[] args) throws Exception {
HttpClient client = HttpClient.newHttpClient();
HttpRequest req = HttpRequest.newBuilder()
.uri(URI.create("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections"))
.GET().build();
HttpResponse<String> res = client.send(req, HttpResponse.BodyHandlers.ofString());
JsonArray conns = JsonParser.parseString(res.body()).getAsJsonArray();
conns.forEach(c -> {
var o = c.getAsJsonObject();
System.out.println(o.get("Name").getAsString() + " [" + o.get("Type").getAsString() + "]: " + o.get("Param").getAsString());
});
}
}
package main
import ("encoding/json"; "fmt"; "net/http")
func main() {
resp, err := http.Get("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3")
if err != nil { panic(err) }
defer resp.Body.Close()
var node map[string]interface{}
json.NewDecoder(resp.Body).Decode(&node)
fmt.Printf("Node: %v\n", node["HerbrichName"])
fmt.Printf("Hall: %v\n", node["HallAddress"])
}
package main
import ("encoding/json"; "fmt"; "net/http")
type Connection struct { Name, Type, Param string }
func main() {
resp, _ := http.Get("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections")
defer resp.Body.Close()
var conns []Connection
json.NewDecoder(resp.Body).Decode(&conns)
for _, c := range conns { fmt.Printf("%s [%s]: %s\n", c.Name, c.Type, c.Param) }
}
curl https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3
curl https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections
import requests
url = "https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3"
node = requests.get(url).json()
print(node["HerbrichName"])
print(node["HallAddress"])
import requests
for conn in requests.get("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections").json():
print(f"{conn['Name']} - {conn['Type']}: {conn['Param']}")
const node = await (await fetch("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3")).json();
console.log(node.HerbrichName);
console.log(node.HallAddress);
const connections = await (await fetch("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections")).json();
connections.forEach(c => console.log(`${c.Name} - ${c.Type}: ${c.Param}`));
interface GridNode { HerbrichName: string; HallAddress: string; }
const node = await (await fetch(`https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3`)).json() as GridNode;
console.log(node.HerbrichName, node.HallAddress);
interface GridNodeConnection { Name: string; Type: string; Param: string; }
const conns = await (await fetch(`https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections`)).json() as GridNodeConnection[];
conns.forEach(c => console.log(`${c.Name} [${c.Type}]: ${c.Param}`));
using System.Net.Http.Json;
var client = new HttpClient();
var node = await client.GetFromJsonAsync<GridNode>("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3");
Console.WriteLine(node?.HerbrichName);
Console.WriteLine(node?.HallAddress);
using System.Net.Http.Json;
var client = new HttpClient();
var conns = await client.GetFromJsonAsync<List<GridNodeConnection>>("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections");
foreach (var c in conns!) Console.WriteLine($"{c.Name} - {c.Type}: {c.Param}");
Imports System.Net.Http
Imports Newtonsoft.Json
Dim client As New HttpClient()
Dim node = JsonConvert.DeserializeObject(Of GridNode)(
Await client.GetStringAsync("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3"))
Console.WriteLine(node.HerbrichName)
Console.WriteLine(node.HallAddress)
Imports System.Net.Http
Imports Newtonsoft.Json
Dim client As New HttpClient()
Dim conns = JsonConvert.DeserializeObject(Of List(Of GridNodeConnection))(
Await client.GetStringAsync("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections"))
For Each conn In conns
Console.WriteLine($"{conn.Name} - {conn.Type}: {conn.Param}")
Next
import java.net.http.*
import org.json.JSONObject
fun main() {
val res = HttpClient.newHttpClient().send(
HttpRequest.newBuilder().uri(URI.create("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3")).GET().build(),
HttpResponse.BodyHandlers.ofString())
val node = JSONObject(res.body())
println(node.getString("HerbrichName"))
}
import java.net.http.*
import org.json.JSONArray
fun main() {
val res = HttpClient.newHttpClient().send(
HttpRequest.newBuilder().uri(URI.create("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections")).build(),
HttpResponse.BodyHandlers.ofString())
val conns = JSONArray(res.body())
for (i in 0 until conns.length()) {
val c = conns.getJSONObject(i)
println("${c.getString("Name")} [${c.getString("Type")}]: ${c.getString("Param")}")
}
}
import Foundation
struct GridNode: Decodable {
let herbrichName: String; let hallAddress: String
enum CodingKeys: String, CodingKey { case herbrichName = "HerbrichName"; case hallAddress = "HallAddress" }
}
let url = URL(string: "https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3")!
let (data, _) = try await URLSession.shared.data(from: url)
let node = try JSONDecoder().decode(GridNode.self, from: data)
print(node.herbrichName, node.hallAddress)
import Foundation
struct Connection: Decodable {
let name, type, param: String
enum CodingKeys: String, CodingKey { case name = "Name"; case type = "Type"; case param = "Param" }
}
let url = URL(string: "https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections")!
let (data, _) = try await URLSession.shared.data(from: url)
try JSONDecoder().decode([Connection].self, from: data).forEach {
print("\($0.name) [\($0.type)]: \($0.param)")
}
use reqwest;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let node: serde_json::Value = reqwest::get("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3").await?.json().await?;
println!("{}", node["HerbrichName"]);
Ok(())
}
use reqwest;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let conns: serde_json::Value = reqwest::get("https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections").await?.json().await?;
println!("{:#?}", conns);
Ok(())
}
const std = @import("std");
// see full Zig sample in docs — uses std.http.Client + std.json
// GET https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3
const std = @import("std");
// GET https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3/connections
HttpClient + Gson
JSON-LD Linked Data
RDF · OWL
All resources are JSON-LD compatible. Use @context https://www.herbrich.org/ontology/ for semantic interoperability.
{
"@context": "https://www.herbrich.org/ontology/",
"@type": "GridNodeConnection",
"@id": "https://api.herbrich.org/v1/grid/connections/conn-42",
"Name": "Hauptstrom",
"Type": "POWER",
"Param": "400V/32A",
"Description": "Primäre Stromversorgung für Erzbistum Hamburg",
"sourceNode": {
"@id": "https://api.herbrich.org/v1/grid/nodes/f4b3c7d1-e8a9-4b62-9f38-a1c7d6e5b4a3",
"@type": "GridNode",
"HerbrichName": "Erzbistum Hamburg"
}
}