evcc-io/assets/js/components/Config/defaultYaml/tariffSolar.yaml
Michael Geers a4ed1080e1
Config UI: add tariffs (#26698)
Co-authored-by: Maschga <88616799+Maschga@users.noreply.github.com>
Co-authored-by: andig <cpuidle@gmail.com>
Co-authored-by: andig <andi@evcc.io>
2026-03-01 11:06:34 +00:00

28 lines
686 B
YAML

## PV production forecast
tariff: solar
forecast: # hourly solar production forecast (W)
source: js
script: |
var rates = [];
var now = new Date();
for (var i = 0; i < 48; i++) {
var start = new Date(now.getTime() + i * 3600000);
rates.push({
start: start.toISOString(),
end: new Date(start.getTime() + 3600000).toISOString(),
value: 2000 // W
});
}
JSON.stringify(rates);
## HTTP example (uncomment to use)
#forecast: # hourly solar production forecast (W)
# source: http
# uri: https://example.com/api/solar
# jq: |
# map({
# "start": .start,
# "end": .end,
# "value": .power
# }) | tostring