The complete msg.payload in Debug - howto

#1

Hi,
Is it possible to see the complete msg.payload using Debug node? I have a very long string (about 4096 characters) and only a part of it is visible in debug. Is there another way to see it?
Janek

#2

Yes, it's an option on the Output dropdown

image

#3

Actually, the option to show the "complete msg object" will not help showing such a long string... it is there to show the top level fields that are defined on the incoming msg object (topic and payload are just two of those fields, but there are others).

There is a section in settings.js that will allow you to show longer data fields in the debug sidebar:

// The maximum length, in characters, of any message sent to the debug sidebar tab
debugMaxLength: 1000,

Any changes you make to this file are only read once, so you will have to restart node-red for the change to take effect -- and beware that it will affect every debug node.

There is also a checkbox on the debug node itself that will redirect the entire output to the "system console", which is probably the easiest solution to start with. Whenever a new msg arrives you see it added to wherever your node-red server is logging its output.

2 Likes
#4

Thank you, it’s very helpful