Correct place to format mqtt payload json string for display?

Totally noobie for openHAB. I’m receiving simple json string {“t”: “22.5”, “rh”: “45.5”} via mqtt as an item. I’m showing that as a info on basicUI panel (or cell or what is it called) but I would like to format the text and pick the values from this json.

Can someone shed light what would be the correct ‘place’ to do this string manipulation for display purposes and can I use eg. JSONpath helper tools?

Please share your Thing configuration using the Code tab within the UI, and using code fences in this forum.

Also install the JSONPATH Transformation Service into openHAB, from the UI.

Have look onto those MQTT Transformation Examples in the documentation.