23.12.2022, 10:13
A possible solution is to send 1/0 instead of true/false. Then you can use aggregate functions.
Code:
if type(value) == 'boolean' then
value = value and 1 or 0
end
body = string.format('%s,name=%s,addr=%s value=%s', influxtable, name, addr, escape(value))