Variable Object

Describes the JSON object of a Variable.

A Variable in Ubidots can store one or more data points. Variables are the most granular entity and can either be raw or synthetic.

Property

Type

Description

id

String

Id of Variable

label

String

Label of Variable

name

String

Name of Variable

createdAt

String

Date Variable was created

syntheticExpression

String

Synthethic Expression of a the Synthetic Variable

description

String

Description of Device

device

Object

Device it belongs to

lastActivity

Number

Date of of Variable's last activity

lastValue

Object

Last value of the Variable

properties

Object

Properties of Variable, including support for:

  • _color: Variable's color in #rrggbb hexadecimal format.
  • _icon: Font Awesome name of Variable's icon.

tags

String Array

Tags of Device

type

String

"raw" or "synthetic"

unit

String

Unit of Variable, can be anything

url

String

Url of Variable

valuesUrl

String

URL of Values of the Variable

Device
{
            "createdAt": "2019-12-18T14:38:38.354415Z",
            "syntheticExpression": "",
            "description": "",
            "device": {
                "id": "6e309da44fc8455a9cceb5aa",
                "label": "first-device",
                "name": "First Device",
                "url": "http://industrial.ubidots.com/api/v2.0/devices/6e309da44fc8455a9cceb5aa"
            },
            "icon": "",
            "id": "781b33e657aa5dfa39e69391",
            "label": "first-variable",
            "lastActivity": null,
            "lastValue": {},
            "name": "First Variable",
            "properties": {
                "_color": "#2FBD68",
                "_icon": "raindrops"
            },
            "tags": [],
            "type": "raw",
            "unit": null,
            "url": "http://industrial.ubidots.com/api/v2.0/variables/781b33e657aa5dfa39e69391",
            "valuesUrl": "http://industrial.ubidots.com/api/v1.6/variables/781b33e657aa5dfa39e69391/values"
        }