From 141dc9c34acf23b067948ee60e836b6f759ea772 Mon Sep 17 00:00:00 2001 From: Tom Jason Schwanke Date: Wed, 30 Oct 2024 17:19:42 +0100 Subject: [PATCH] Spotty Energy: more flexibility (#16973) --- templates/definition/tariff/spottyenergy.yaml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/templates/definition/tariff/spottyenergy.yaml b/templates/definition/tariff/spottyenergy.yaml index 4418d3e6df..61b4909be0 100644 --- a/templates/definition/tariff/spottyenergy.yaml +++ b/templates/definition/tariff/spottyenergy.yaml @@ -7,17 +7,24 @@ requirements: en: "Only available for Austria." group: price params: - - name: contractId + - name: contractid example: ffffffff-4444-6666-2222-aaaaaabbbbbb required: true help: de: "Die Vertragsnummer bekommst du im Kundenportal https://i.spottyenergie.at/" en: "You can get your contract id from the customer portal https://i.spottyenergie.at/" + - name: pricetype + default: CONSUMPTION + validvalues: ["MARKET", "CONSUMPTION", "GENERATION"] + required: true + help: + de: "Preistyp, entweder Börsenpreis, Verbrauchspreis oder Einspeisevergütung (falls vereinbart), siehe https://www.spottyenergie.at/blog/energie-smart-produzieren" + en: "Price type, either spotmarket price, consumption price or generation compensation (if contractually agreed), more info at https://www.spottyenergie.at/blog/energie-smart-produzieren" - preset: tariff-base render: | type: custom {{ include "tariff-base" . }} forecast: source: http - uri: https://i.spottyenergie.at/api/prices/MARKET/{{ .contractId }} + uri: https://i.spottyenergie.at/api/prices/{{ .pricetype }}/{{ .contractid }} jq: '[.[] | {start: .from, end: (.from | fromdate + 3600 | todate), price: (.price/100)}] | tostring'