Using Units, you can attach currencies or other units to a Metric Value. Each metric can have different Units associated with different values(i.e. Closed Won Deals could have EUR and USD sales stored).

Similar to Dimensions, you can also attach a Unit to your Metric Values. While dimensions provide extra information (like, which store $sales: 230 came from), Units describe the value itself (what does ‘230’ measure?). Most often, Units are used to specify different currencies.

  • cURL
  • PHP
  • JavaScript
  • Ruby
  • Java
  • Go
  • Python
curl https://push.databox.com \
-u 2cdt4yoytbvockc51cowgs4gsss84ow4s: \
-H 'Content-Type: application/json' \
-H 'Accept: application/vnd.databox.v2+json' \
-d '{
      "$sales": 50000,
      "unit": "USD"
      "$sales": 33000,
      "unit": "EUR"
// Not supported yet
// Not supported yet
# Not supported yet
// Not supported yet
// Not supported yet
# Not supported yet

To see the Units displayed with the Metric Value in Databox, you need to set the Number format. You can display the unit as a prefix (Prefixed unit) or postfix (Postfixed unit). Learn more about Visual preferences.

Pro Tip: If you’re selling products in multiple currencies, you can store sales events to the same metric (as shown in the example above). When visualizing such metrics, aggregations and other functions will be applied to each unit separately, so you’ll never mix your dollars with euros, in this case.