Get Virtual Hub
This endpoint retrieves detailed information about a specific virtual hub within an organisation using its unique hub ID. The response includes key attributes such as the virtual hub’s unique identifier, name, description, creation and update timestamps, and associated organisation ID. Additionally, the response provides details on the virtual hub’s connected ports, specifying the linked physical hub ID and corresponding port ID for each connection. This structured overview enables better visibility into the virtual hub’s configuration, port mappings, and overall network connectivity. By retrieving information on a specific virtual hub, organisations can efficiently manage and monitor their hub infrastructure.
Syntax: see 'CCall Structure
Type = 'GET'
|
'https://connect.cambrionix.com/api/hardware/v1/virtual-hubs/virtual-hub-id' |
| Variable | Description |
|---|---|
| virtual-hub-id | This is the id of the virtual hub as a unique 128-bit number |
Returns:
|
{ "created": { "time": time }, "updated": { "time": time }, "id": "virtual-hub-id", "organization": { "id": "organisation-id" }, "name": "virtual-hub-name", "description": "virtual-hub-description", "ports": { "virtual-hub-port": { "hub": { "id": "hub-serial" }, "port": { "id": hub-port } } } |
| Output | Description |
|---|---|
| time | The hub time, shown as an integer in ms |
| virtual-hub-id | This is the id of the virtual hub as a unique 128-bit number |
| organisation-id | This is the id of the organisation as a unique 128-bit number |
| virtual-hub-name | This is the name of the virtual hub |
| virtual-hub-description | This is the description of the virtual hub |
| virtual-hub-port | This is theport number of the virtual hub |
| hub-serial | This is the serial number of the hub |
| hub-port | This is the port number of the hub |
Example
curl -X 'GET' \
'https://connect.cambrionix.com/api/hardware/v1/virtual-hubs/00f7543a-d6ef-4059-8691-9ce54a9f12e1' \
-H 'accept: application/json' \
-H 'Authorization: Bearer eyJhbGciOiJSUzI5l2QdQQA'
Returns
{
"result": [
{
"created": {
"time": 1724248462488
},
"updated": {
"time": 1724248462488
},
"id": "00f7543a-d6ef-4059-8691-9ce54a9f12e1",
"organization": {
"id": "dafc70d5-a4c8-42a3-ad8d-a8ccb5fa313f"
},
"name": "hub 1",
"description": "aaa",
"ports": {
"1": {
"hub": {
"id": "0000006567CDF436"
},
"port": {
"id": 2
}
},
"2": {
"hub": {
"id": "0000006567CDF436"
},
"port": {
"id": 5
}
},
"3": {
"hub": {
"id": "0000006567CDF436"
},
"port": {
"id": 8
}
},
"4": {
"hub": {
"id": "DJ00B475"
},
"port": {
"id": 1
}
}
}
}
}
}
Errors
If there is an error in the API method then JSON-RPC Error Object a will be returned