Collecting assets

From Azban Wiki
Jump to navigation Jump to search



One of the advantages offered by the Azban platform is the ability to easily collect data from any system and have it displayed directly in the Dashboard.

Each such unit of data is referred to as an asset.

Since assets are collected 'per-device', all of the examples presented here make use of the $DKEY environment variable to identify the device when calling the backend.


Collecting assets is done by making HTTP requests to the backend.

Two forms are available, one using GET and the other using POST.

Simple form (GET)

The simplest option is to make an HTTP GET request to:{DEVICE_ID}/{ASSET_DATA}

An example of this using curl is shown below:

# Collect asset 'hello world'

Advanced form (POST)

For more advanced use cases (involving more data), an HTTP POST request with an str form-parameter can be made to{DEVICE_ID}

Examples of this using curl are shown below:

# Collect asset 'hello world'
curl -F 'str=hello world'$DKEY

# Collect asset from variable '$my_variable'
curl -F "str=$my_variable"$DKEY

# Collect asset from output of 'whoami' command
whoami | curl -F 'str=<-'$DKEY