# JSON Ninja?

**URL:** <https://community.squaredup.com/t/json-ninja/110>\
**Category:** Dashboard Server\
**Tags:** custom-labelling, dashboards\
**Created:** [April 21, 2016, 9:19pm UTC](https://community.squaredup.com/t/json-ninja/110 "2016-04-21T21:19:41Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![blakewilson](https://community.squaredup.com/letter_avatar_proxy/v4/letter/b/4da419/32.png) [@blakewilson](https://community.squaredup.com/u/blakewilson)\
**Post date:** [April 21, 2016, 9:19pm UTC](https://community.squaredup.com/t/json-ninja/110/1 "2016-04-21T21:19:41Z")

</div>

Has anyone out there cracked the JSON code for custom labeling? I’ve seen at least 1 community answer for using some JSON to feed some properties into a custom label, and I’m wanting more! I’ve recently opened a support request for this information, specifically around finding parameters I can pass for VMWare Virtual Machine properties.

Anyone?

---

<div class="post-metadata">

**Author:** ![thedestroyer100](https://community.squaredup.com/letter_avatar_proxy/v4/letter/t/34f0e0/32.png) [@thedestroyer100](https://community.squaredup.com/u/thedestroyer100)\
**Post date:** [April 22, 2016, 9:04am UTC](https://community.squaredup.com/t/json-ninja/110/2 "2016-04-22T09:04:06Z")

</div>

It isn’t JSON code for the custom labelling, it’s actually a type of Mustache syntax. Anything inside {{double curlys}} gets evaluated. So it is possible to put in variable names and basic JavaScript functions.

It is possible to use basic JavaScript functions such as:

```
{{Name.replace('.domain.local','')}}, Host: {{HostServerName}}
```

&nbsp;

To find the variable names that you can use for an object, you can use the Operations Manager Shell to query SCOM:

```
Get-SCOMMonitoringObject -id <insert_object_id> | fl
```

This will list out all of the extended properties, the Squared Up custom labelling does not require the [Class.Name] part of the variable. To use any extended properties you will have to check the ‘load extended properties’ box.

---

<div class="post-metadata">

**Author:** ![phippsy2900](https://community.squaredup.com/letter_avatar_proxy/v4/letter/p/f6c823/32.png) [@phippsy2900](https://community.squaredup.com/u/phippsy2900)\
**Post date:** [November 11, 2016, 4:53pm UTC](https://community.squaredup.com/t/json-ninja/110/3 "2016-11-11T16:53:02Z")

</div>

Is this possible for Status applets in SquaredUpV3? Where would you place the replace statement in the JSON?

---

<div class="post-metadata">

**Author:** ![me1](https://community.squaredup.com/letter_avatar_proxy/v4/letter/m/a4c791/32.png) [@me1](https://community.squaredup.com/u/me1)\
**Post date:** [April 22, 2016, 7:32am UTC](https://community.squaredup.com/t/json-ninja/110/4 "2016-04-22T07:32:23Z")

</div>

I belive this is java script type of syntax? Anyway, you can use the properties discovered on each object for labelling. I’m not your ninja, but here is an exaple of what we have done to display our disks

**{{Name}}** on {{PrincipalName}}

---

<div class="post-metadata">

**Author:** ![jaspervd](https://community.squaredup.com/letter_avatar_proxy/v4/letter/j/7ea924/32.png) [@jaspervd](https://community.squaredup.com/u/jaspervd)\
**Post date:** [November 14, 2016, 4:22pm UTC](https://community.squaredup.com/t/json-ninja/110/5 "2016-11-14T16:22:41Z")

</div>

Hey Phippsy, as far as I know it is not possible in v3 yet, they are working on feature parity with v2 which should be ready by the end of this year.
