Hi, I have I think a rather simple query which hopefully someone can help with.
The API returns a value of 13.29 V using Postman
"current_sensor_state": "13.29 V",
I think with the below value template I am using, I need to extract the number only (exclude the space and the unit of measurement (V)
- scan_interval: 1800
resource: https://console.radiobridge.com/api/visualization/v1/devices/[REDACTED]
headers:
Authorization: !secret radiobridge_token
Organization: [REDACTED]
Accept: application/json
Content-Type: application/json
sensor:
- name: volmeter_current_sensor_state
value_template: "{{ value_json.data.device_status.current_sensor_state }}"
unique_id: radiobridge_volmeter_current_sensor_state
device_class: voltage
unit_of_measurement: "V"
Do you think someone could help me to extract just the value with the correct value template please?
Many thanks.