Payload data in Real Time Event tree

Hi,

I am creating a real-time channel between Weweb and Xano where Xano pushes a count from a database table. However, when trying to assign the data to a variable, under Event payload shows null and has no children.

However, if I look at the network traffic, I can see the data under payload.

I managed to see a workaround were I had to add the data child manually - event?.[‘data’]?.[‘payload’]?.[‘data’].

Is this a bug?

Thanks

Steve

Hi Steve,

Not a bug. The Event tree in the editor is a sample, that’s why the payload is empty.

That sample is empty on On realtime - All events because each event type carries a different payload. Your path is correct for a db event. On the Change variable value action, you can bind the variable to event?.[‘data’]?.[‘payload’]?.[‘data’]. You can also use the Log action to see the value the workflow receives when it runs.

Hi Steve

That null payload is the sample the editor shows. On realtime all events does not have one fixed payload, so the tree stays empty even when a message comes in.

Your network tab is the real message. The count is payload.data, which is 1 in your screenshot. The path you added by hand is the right binding for Change variable value.

Drop a Log action on the Event and run it in preview. That shows the value the workflow gets.

Best Regards

Thanks for the clarification.

Steve