# Import Temperature Information from Shelly Plus 2PM, build Thermostat in Red Node

**URL:** <https://discourse.nodered.org/t/import-temperature-information-from-shelly-plus-2pm-build-thermostat-in-red-node/96668>\
**Category:** General\
**Tags:** ui-template, shelly\
**Created:** [21 April 2025 06:27 UTC](https://discourse.nodered.org/t/import-temperature-information-from-shelly-plus-2pm-build-thermostat-in-red-node/96668 "2025-04-21T06:27:38Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mountain](https://avatars.discourse-cdn.com/v4/letter/m/258eb7/32.png) [@mountain](https://discourse.nodered.org/u/mountain)\
**Post date:** [21 April 2025 06:27 UTC](https://discourse.nodered.org/t/import-temperature-information-from-shelly-plus-2pm-build-thermostat-in-red-node/96668/1 "2025-04-21T06:27:38Z")

</div>

Hi, my name is Mountain and I'm pretty new to red node, nevertheless I managed to get most of my planned functions working. I am running a Victron Multiplus II GX system and want to use Shelly to automize various functions. For instance: after battery SOC has reached a certain level then use boiler heater; additional: heat up water boiler every night until the water has reached a certain temperature level. For this, a PT100 temperature sensor attached to the Shelly Plus 2PM is used.

What I managed to do: Get Information from Shelly into red node. I tried two methods and both work:  
a) via http request: [http://192.168.1.60/rpc/Temperature.GetStatus?id=100](http://192.168.1.60/rpc/Temperature.GetStatus?id=100). What I get in return is :

21.4.2025, 08:16:22  
[node: debug 16](https:// 752533-nodered.proxyrelay7.victronenergy. com/#)  
msg.payload : string[33]  
"{"id": 100,"tC":57.9, "tF":136.3

But then I am stucked how to proceed with this information. How do I transfer this string into a format that I can used it with a red node switch?

b) other method: I downloaded the palette library for shelly and integrated it into my canvas. The connection works and I get back the full information from the respective shelly

21.4.2025, 08:19:47[node: Eingangsobjekt](https:/ /762522-nodered.proxyrelay7.victronenergy.com/#)  
msg.payload : Object  
object  
ble: object  
cloud: object  
input0: object  
input1: object  
mqtt: object  
switch0: object  
switch1: object  
sys: object  
temperature100: object  
id: 100  
tC: 57.9  
tF: 136.3  
wifi: object  
ws: object

Same issue here: how to proceed.

Can someone please support me and tell me how do I build a thermostat with this information? I am a bloody beginner and have now jason script knowledge. There a plenty of videos on YT how to use the relais for Shelly with red node (I also managed this easily) but not how to work with the temperature.

Thank you for all how could help here.

---

<div class="post-metadata">

**Author:** ![E1cid](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/e1cid/32/77971_2.png) [@E1cid](https://discourse.nodered.org/u/E1cid)\
**Post date:** [21 April 2025 06:40 UTC](https://discourse.nodered.org/t/import-temperature-information-from-shelly-plus-2pm-build-thermostat-in-red-node/96668/2 "2025-04-21T06:40:11Z")

</div>

> [@mountain](#):
>
> "{"id": 100,"tC":57.9, "tF":136.3
> 
> But then I am stucked how to proceed with this information. How do I transfer this string into a format that I can used it with a red node switch?

Set the http request node to return a `parsed json object` then the tC would be in msg.payload.tC

There’s a great page in the docs ([Working with messages : Node-RED](https://nodered.org/docs/user-guide/messages)) that will explain how to use the debug panel to find the right path/value for any data item.

Pay particular attention to the part about the buttons that appear under your mouse pointer when you over hover a debug message property in the sidebar.

![BX00Cy7yHi](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/b/d/bd1f333a9e043b061b39917c328b0094d3e52d30.gif)

---

<div class="post-metadata">

**Author:** ![mountain](https://avatars.discourse-cdn.com/v4/letter/m/258eb7/32.png) [@mountain](https://discourse.nodered.org/u/mountain)\
**Post date:** [21 April 2025 07:51 UTC](https://discourse.nodered.org/t/import-temperature-information-from-shelly-plus-2pm-build-thermostat-in-red-node/96668/3 "2025-04-21T07:51:08Z")

</div>

Great, that helped a lot! Now it's working!

Thank you for this. Have a great day!

In case anybody with the same issues: This is how it worked for me:

```auto
[
    {
        "id": "5c369023262af9fe",
        "type": "tab",
        "label": "Flow 5",
        "disabled": false,
        "info": "",
        "env": []
    },
    {
        "id": "d88dd470.0ac7b8",
        "type": "inject",
        "z": "5c369023262af9fe",
        "name": "make request",
        "props": [
            {
                "p": "payload",
                "v": "",
                "vt": "date"
            },
            {
                "p": "topic",
                "v": "",
                "vt": "str"
            }
        ],
        "repeat": "",
        "crontab": "",
        "once": false,
        "topic": "",
        "payload": "",
        "payloadType": "date",
        "x": 130,
        "y": 120,
        "wires": [
            [
                "4792e4c08596f9b0"
            ]
        ]
    },
    {
        "id": "4792e4c08596f9b0",
        "type": "http request",
        "z": "5c369023262af9fe",
        "name": "",
        "method": "GET",
        "ret": "obj",
        "paytoqs": "ignore",
        "url": "http://192.168.1.60/rpc/Temperature.GetStatus?id=100",
        "tls": "",
        "persist": false,
        "proxy": "",
        "insecureHTTPParser": false,
        "authType": "",
        "senderr": false,
        "headers": [],
        "x": 310,
        "y": 120,
        "wires": [
            [
                "25d58ebbcf35ec6d"
            ]
        ]
    },
    {
        "id": "25d58ebbcf35ec6d",
        "type": "change",
        "z": "5c369023262af9fe",
        "name": "payload.tC",
        "rules": [
            {
                "t": "set",
                "p": "payload",
                "pt": "msg",
                "to": "payload.tC",
                "tot": "msg"
            }
        ],
        "action": "",
        "property": "",
        "from": "",
        "to": "",
        "reg": false,
        "x": 510,
        "y": 120,
        "wires": [
            [
                "345cb0bc783c660c"
            ]
        ]
    },
    {
        "id": "345cb0bc783c660c",
        "type": "switch",
        "z": "5c369023262af9fe",
        "name": "",
        "property": "payload",
        "propertyType": "msg",
        "rules": [
            {
                "t": "lt",
                "v": "45",
                "vt": "str"
            },
            {
                "t": "gt",
                "v": "45",
                "vt": "str"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 2,
        "x": 670,
        "y": 120,
        "wires": [
            [
                "4909fa5cafadef33"
            ],
            [
                "60902b282ad729f5"
            ]
        ]
    },
    {
        "id": "4909fa5cafadef33",
        "type": "debug",
        "z": "5c369023262af9fe",
        "name": "debug 21",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 840,
        "y": 80,
        "wires": []
    },
    {
        "id": "60902b282ad729f5",
        "type": "debug",
        "z": "5c369023262af9fe",
        "name": "debug 22",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 840,
        "y": 160,
        "wires": []
    }
]

```

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [20 July 2025 07:51 UTC](https://discourse.nodered.org/t/import-temperature-information-from-shelly-plus-2pm-build-thermostat-in-red-node/96668/4 "2025-07-20T07:51:27Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
