Value_json formating


the following problem, which I cannot solve:

I get the following values as a string using

value_template: "{{value_json ['caller']}}"


“+491234567890 0123456789”

But I only want to have “+491234567890” in the string. What should the filter look like for this?

Best wishes

value_template: "{{ (value_json['caller']).split(" ")[0] }}"

That’s it!
The problem is the missing “+”

Should be ok in the actual value_template if you use a single line template in quotes. e.g. try this in the template editor, so it returns a string not a number:

"{{ (value_json.caller.split(" ")[0] }}"