First template node does not use [ ] for arrays.
Second , i don't think that is possible in the template node. Best create a msg property from the flow var prior to the template node.
Or you could do your template in a change node with JSONata.
What happens if you
set msg.payload to 'blah.blah[' & $$.cueIndex & '].blah'
what is the output, as it seems from the error it expects something before ], but throws error as it get ] and not what is expected.
Thank you so much, got everything working correctly in the JSONata expression of the change node,
But I now need to find the simplest / cleanest way to use this message variable in the flow variable in the template node, best would be to be able to do everything inside.
But if I got no choice, will prepare the data outside in a change node, tho I don't really like the idea... lol
Not knowing the node configuration of your flow makes it difficult to give an definite ideas. in your change node can you not template there by concatenating strings and msg/context vars. Or as said define flow context to a msg var, then you can use the msg var in the template node.