Tradfri Color HSB

Try to add the color channel via generic mqtt device for my tradfri bulb.
Usualy the payload from tradfri bulbs via zigbee2mqtt is like this:

color-x', payload '0.4681'
color-y', payload '0.4402'

When I use any color Mode selection on the channel (HSB, RGB, CIE), i´m getting “Invalid JSON” from zigbee2mqtt log. I thing the values must be transform in any way.

How I can configure the channel, so the color information will be translate correctly?

What is the actual full message that is published by zigbee2mqtt?

Openhab Log:
2021-01-02 23:45:25.476 [INFO ] [openhab.event.ItemCommandEvent ] - Item 'EGBueroDecke_EG_Buero_Decke_Color' received command 321,0,10

Zigbee2mqtt Log:

Jan 02 23:45:25 rasp npm[634]: Zigbee2MQTT:debug 2021-01-02 23:45:25: Received MQTT message on 'zigbee2mqtt/EG_Buero_Decke/set' with data '321,0,10'
Jan 02 23:45:25 rasp npm[634]: Zigbee2MQTT:error 2021-01-02 23:45:25: Invalid JSON '321,0,10', skipping...

OK, so this problem is a message from openHAB to zigbee2mqtt.

Well, it’s not a JSON string as zigbee2mqtt complained about. I would recommend using formatBeforePublish, and checking this post:

I don’t have a colour bulb, so I’m afraid I don’t have the exact answer, but hopefully the above will get you close!

It works now.
I have set the channel to color mode “RGB”,
in the field “outgoing value format” i use this string:
{“color”:{“r”:%s,“g”:%s,“b”:%s}}

Tanks for the hints