Introduction
The APIs can be used to fetch logged values and to list digital twins, connectors and tags.
Local and cloud APIs
The APIs exist both locally on the gateway and in the cloud. It is preffered to access the APIs on the gateway, due to heavier throttling in the cloud.
Local API
The local API uses the HTTP scheme where the host name is the IP address of the gateway, e.g. 192.168.2.1
(default on machine network).
http://<GatewayIp>/api/v1/twins
Cloud API
The cloud API uses the HTTPS scheme where the host name is portal.connectitude.com
.
https://portal.connectitude.com/api/v1/twins
Values
Values can be fetched using the following endpoint.
http://<GatewayIp>/api/v1/values?from={from}&to={to}&nodeId={nodeId}&tagId={tagId}&tagId={tagId}
Parameters | Description |
---|---|
from | ISO-8601 date string (for example 2021-03-02T09:11:11Z ) |
to | ISO-8601 date string (for example 2021-03-02T09:11:11Z ) |
nodeId | The node ID of the twin associated with this tag |
tagId | The ID of the tag (each request can contain multiple of these) |
Digital twins
Digital twins, such as machines, machine lines and factories, can be fetched using the following endpoint.
http://<GatewayIp>/api/v1/twins[?nodeId={nodeId}]
Parameters | Description |
---|---|
nodeId | The node context (optional) |
Connectors
Connectors, such as controllers for PLCs or LoRa devices, can be fetched using the following endpoint.
http://<GatewayIp>/api/v1/connectors[?nodeId={nodeId}]
Parameters | Description |
---|---|
nodeId | The node context (optional) |
Tags
Tags can be fetched using the following endpoint.
http://<GatewayIp>/api/v1/tags?connectorId={connectorId}
Parameters | Description |
---|---|
connectorId | The ID of the connector |