@capibara Yes, you are getting there! The topic prefix is just as you say defined by the #define statement. The rest of the topic is defined as described in the API definition (Serial protocol) so: /node-id/sensorchild-id/command/ack/type/ The content of the message is the payload. Example: this is copied from my GW: ib9sensors-out/21/2/1/0/4 1014 => So the sensor id is 21/ the child is 2/ this is a "set" message/ no-ack/ payload type is V_PRESSURE. The content of the message is 1014 which is just the atmospheric pressure here today. I recommend using an MQTT client test tool like MQTT.fx It helps a lot when debugging. I am not the right guy to answer how to re-define the topic structure. I guess you will have to do some serious work on the MQTT GW software.