Publish Zigbee sensor to MQTT

I need to publish the info of one temperature zigbee sensor to MQTT but with the format:

[{"k":"key","t":timestamp miliseconds,"v":value}]

I know that using an automation with mqtt post service I can do it, but how I give it the format?