HTTP

This page describes HTTP Connectivity in more detail

If a device communicates over HTTP with akenza, an HTTP connector has to be setup and assigned to a data flow.

After creation, a secret is generated which has to be provided in the request. Both the secret and the device ID are set as query params in the HTTP request.

POST https://data-gateway.akenza.io/v3/capture?secret={uplinkSecret}&deviceId={deviceId}

The body can be any JSON object.

Query Parameters

Name
Type
Description

timestamp (optional)

string

The timestamp of the event (ISO-8601 formatted), defaults to the current time if not provided

topic (optional)

string

The data topic ("default" will be used if not provided)

uplinkSecret

string

The uplink secret used to authenticate the request (it is recommended to use the x-uplink-secret header instead)

deviceId

string

The physical device ID

Headers

Name
Type
Description

Content-Type

string

application/json

x-uplink-secret

string

The uplink secret used to authenticate the request

x-device-id

string

The physical device ID

{
    "id": "UUID",
    "timestamp": "ISO-8601 date string",
    "message": "uplink received"
}

The HTTP connectivity also supports the processing of array uplinks (not just a JSON property which is an array but the whole request body).

There are minimal differences when processing such an uplink in the script.

Refer to the example event for array uplinks in the Scripting section for more details.

Support for using secret and device id in the header

Requests can be submitted by using secret and device id in the header. The header key should be x-uplink-secret and x-device-id. The value of the header is the secret of the device connector and the physical device id. Both values can be found on the Device Detail Page within API-Configuration or in the uplink URL.

Last updated

Was this helpful?