Creating import checks
The first step is creating import checks. An import check contains all the data of a sensor and creates an endpoint to which values can be sent. Import checks can be created by navigating to the checks view. At the bottom right, the plus button can be clicked to add a new sensor. We then can click on the external sensor option
We fill in the name, select the sensor type and click create.
Sensor types contain the definition of how data is formatted and should be displayed. A sensor type contains information such as the metric + unit (e.g. Temperature = ºC), data types and expected json values. Read here on how to create your own sensor type
Sending data to an import check
The last step is sending data to the api. After saving the check, we see the settings page. Here the endpoint is shown with an example call.
We can do a post to
With these values (values change based on import check and sensor type):
"timestamp": "A valid ISO 8601 DateTime format value with an explicitly set timezone value (e.g. 2017-01-17T19:23:02Z, 2017-01-17T19:23:02+06:45).",
"status": "ok || fail",
"error": "custom error text message"
Notice that we are sending the values inside an array. We can send multiple sensor values (multiple import checks) in one call:
Make sure you add your api keys to the Authorization header: find out how to generate and use api keys.