node-red-contrib-octopus-intelligent 1.2.0 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +83 -0
- package/README.md +619 -222
- package/examples/ha-dashboard.yaml +470 -0
- package/lib/api-metrics.js +31 -0
- package/lib/auth.js +20 -0
- package/lib/categories/account.js +30 -0
- package/lib/categories/applicable-rates.js +91 -0
- package/lib/categories/completed-dispatches.js +35 -0
- package/lib/categories/electricity.js +132 -0
- package/lib/categories/flex-planned-dispatches.js +36 -0
- package/lib/categories/free-electricity.js +61 -0
- package/lib/categories/gas.js +94 -0
- package/lib/categories/home-mini.js +37 -0
- package/lib/categories/intelligent.js +123 -0
- package/lib/categories/octoplus.js +32 -0
- package/lib/categories/saving-sessions.js +50 -0
- package/lib/categories/wheel-of-fortune.js +49 -0
- package/lib/discovery.js +85 -0
- package/lib/graphql.js +44 -0
- package/lib/payload.js +76 -0
- package/lib/scheduler.js +33 -0
- package/lib/timezone.js +49 -0
- package/octopus-intelligent.html +71 -4
- package/octopus-intelligent.js +628 -386
- package/package.json +2 -1
package/lib/discovery.js
ADDED
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
// lib/discovery.js
|
|
2
|
+
'use strict';
|
|
3
|
+
const { graphqlPost } = require('./graphql');
|
|
4
|
+
const { obtainToken } = require('./auth');
|
|
5
|
+
|
|
6
|
+
const DISCOVERY_QUERY = `
|
|
7
|
+
query discover($account: String!) {
|
|
8
|
+
account(accountNumber: $account) {
|
|
9
|
+
electricityAgreements { validFrom }
|
|
10
|
+
gasAgreements { validFrom }
|
|
11
|
+
properties {
|
|
12
|
+
electricityMeterPoints {
|
|
13
|
+
mpan
|
|
14
|
+
direction
|
|
15
|
+
meters {
|
|
16
|
+
serialNumber
|
|
17
|
+
smartImportElectricityMeter { deviceId }
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
gasMeterPoints { mprn meters { serialNumber } }
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
devices(accountNumber: $account) {
|
|
24
|
+
id
|
|
25
|
+
deviceType
|
|
26
|
+
status { isSuspended }
|
|
27
|
+
}
|
|
28
|
+
}`;
|
|
29
|
+
|
|
30
|
+
function parseDiscovery(data) {
|
|
31
|
+
const acct = data.account || {};
|
|
32
|
+
const devices = data.devices || [];
|
|
33
|
+
const evDevice = devices.find(d => d.deviceType === 'ELECTRIC_VEHICLES') || null;
|
|
34
|
+
const props = (acct.properties || [])[0] || {};
|
|
35
|
+
const elecPoints = props.electricityMeterPoints || [];
|
|
36
|
+
const gasPoints = props.gasMeterPoints || [];
|
|
37
|
+
|
|
38
|
+
// Find import and export meter points by direction. Accounts may have
|
|
39
|
+
// either or both. Position in the array is NOT reliable — observed live
|
|
40
|
+
// (2026-05-11) that the export meter can appear at index 0.
|
|
41
|
+
const importPoint = elecPoints.find(p => p.direction === 'IMPORT') || null;
|
|
42
|
+
const exportPoint = elecPoints.find(p => p.direction === 'EXPORT') || null;
|
|
43
|
+
|
|
44
|
+
// Home Mini device ID: scan all meter points for smartImportElectricityMeter.
|
|
45
|
+
let smartMeterDeviceId = null;
|
|
46
|
+
for (const point of elecPoints) {
|
|
47
|
+
for (const meter of (point.meters || [])) {
|
|
48
|
+
if (meter.smartImportElectricityMeter && meter.smartImportElectricityMeter.deviceId) {
|
|
49
|
+
smartMeterDeviceId = meter.smartImportElectricityMeter.deviceId;
|
|
50
|
+
break;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
if (smartMeterDeviceId) break;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
const firstImportMeter = importPoint && importPoint.meters && importPoint.meters[0] ? importPoint.meters[0] : null;
|
|
57
|
+
|
|
58
|
+
return {
|
|
59
|
+
hasIntelligent: !!evDevice,
|
|
60
|
+
hasElectricity: (acct.electricityAgreements || []).length > 0,
|
|
61
|
+
hasGas: (acct.gasAgreements || []).length > 0,
|
|
62
|
+
deviceId: evDevice ? evDevice.id : null,
|
|
63
|
+
deviceSuspended: evDevice ? evDevice.status.isSuspended : null,
|
|
64
|
+
smartMeterDeviceId,
|
|
65
|
+
electricityMpan: importPoint ? importPoint.mpan : null,
|
|
66
|
+
electricityExportMpan: exportPoint ? exportPoint.mpan : null,
|
|
67
|
+
electricitySerial: firstImportMeter ? firstImportMeter.serialNumber : null,
|
|
68
|
+
gasMprn: gasPoints[0] ? gasPoints[0].mprn : null,
|
|
69
|
+
gasSerial: gasPoints[0] && gasPoints[0].meters[0] ? gasPoints[0].meters[0].serialNumber : null
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
async function discoverProducts(apiKey, account) {
|
|
74
|
+
const token = await obtainToken(apiKey);
|
|
75
|
+
const response = await graphqlPost({ query: DISCOVERY_QUERY, variables: { account } }, token);
|
|
76
|
+
if (response.data.errors) {
|
|
77
|
+
throw new Error(`Discovery failed: ${JSON.stringify(response.data.errors)}`);
|
|
78
|
+
}
|
|
79
|
+
if (!response.data.data) {
|
|
80
|
+
throw new Error('Discovery response missing data');
|
|
81
|
+
}
|
|
82
|
+
return parseDiscovery(response.data.data);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
module.exports = { discoverProducts, parseDiscovery };
|
package/lib/graphql.js
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
const https = require('https');
|
|
3
|
+
const { version } = require('../package.json');
|
|
4
|
+
|
|
5
|
+
// User-Agent is REQUIRED for api.backend.octopus.energy — the default Node.js UA
|
|
6
|
+
// is blocked at the edge (403). Sending a real UA on every request keeps both
|
|
7
|
+
// the main and backend endpoints reachable from a single transport.
|
|
8
|
+
const USER_AGENT = `node-red-contrib-octopus-intelligent/${version}`;
|
|
9
|
+
|
|
10
|
+
function graphqlPost(body, token, hostname = 'api.octopus.energy') {
|
|
11
|
+
return new Promise((resolve, reject) => {
|
|
12
|
+
const payload = JSON.stringify(body);
|
|
13
|
+
const headers = {
|
|
14
|
+
'Content-Type': 'application/json',
|
|
15
|
+
'Content-Length': Buffer.byteLength(payload),
|
|
16
|
+
'User-Agent': USER_AGENT
|
|
17
|
+
};
|
|
18
|
+
// Kraken expects the raw JWT. Both endpoints accept this. Adding a
|
|
19
|
+
// "JWT " prefix passes main-endpoint validation but fails sub-resolver
|
|
20
|
+
// auth on api.backend.octopus.energy (verified live 2026-05-11).
|
|
21
|
+
if (token) headers['Authorization'] = token;
|
|
22
|
+
const req = https.request({
|
|
23
|
+
hostname,
|
|
24
|
+
path: '/v1/graphql/',
|
|
25
|
+
method: 'POST',
|
|
26
|
+
headers
|
|
27
|
+
}, (res) => {
|
|
28
|
+
let raw = '';
|
|
29
|
+
res.on('data', chunk => raw += chunk);
|
|
30
|
+
res.on('end', () => {
|
|
31
|
+
try {
|
|
32
|
+
resolve({ data: JSON.parse(raw), status: res.statusCode, headers: res.headers });
|
|
33
|
+
} catch (e) {
|
|
34
|
+
reject(new Error('Failed to parse API response: ' + e.message));
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
});
|
|
38
|
+
req.on('error', reject);
|
|
39
|
+
req.write(payload);
|
|
40
|
+
req.end();
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
module.exports = { graphqlPost };
|
package/lib/payload.js
ADDED
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
// lib/payload.js
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
function mergePayload(base, newData) {
|
|
5
|
+
return Object.assign({}, base, newData);
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
function buildDefaultPayload(state) {
|
|
9
|
+
if (!state || typeof state !== 'object') {
|
|
10
|
+
throw new TypeError('buildDefaultPayload: state must be an object');
|
|
11
|
+
}
|
|
12
|
+
const { confirmedLimit, confirmedTime, pendingLimit, pendingTime, chargingNow, smartChargingSuspended } = state;
|
|
13
|
+
return {
|
|
14
|
+
// V1 fields — unchanged
|
|
15
|
+
next_start: null, total_energy: 0, next_kwh: '0', next_source: 'unknown',
|
|
16
|
+
confirmed_limit: confirmedLimit, confirmed_time: confirmedTime,
|
|
17
|
+
pending_limit: pendingLimit, pending_time: pendingTime,
|
|
18
|
+
charging_now: chargingNow,
|
|
19
|
+
next_poll: null, next_poll_raw: null,
|
|
20
|
+
refresh_available_at: null,
|
|
21
|
+
api_requests_hour: 0, api_complexity_hour: 0, api_complexity_percent: 0,
|
|
22
|
+
slot1_start: null, slot1_end: null, slot2_start: null, slot2_end: null,
|
|
23
|
+
slot3_start: null, slot3_end: null,
|
|
24
|
+
window_start: null, window_end: null,
|
|
25
|
+
next_start_raw: null,
|
|
26
|
+
slot1_start_raw: null, slot1_end_raw: null, slot2_start_raw: null, slot2_end_raw: null,
|
|
27
|
+
slot3_start_raw: null, slot3_end_raw: null,
|
|
28
|
+
window_start_raw: null, window_end_raw: null,
|
|
29
|
+
timezone_detected: null, timezone_applied: null,
|
|
30
|
+
next_start_locale: null,
|
|
31
|
+
slot1_start_locale: null, slot1_end_locale: null,
|
|
32
|
+
slot2_start_locale: null, slot2_end_locale: null,
|
|
33
|
+
slot3_start_locale: null, slot3_end_locale: null,
|
|
34
|
+
window_start_locale: null, window_end_locale: null,
|
|
35
|
+
smart_charging: smartChargingSuspended === null ? null : !smartChargingSuspended,
|
|
36
|
+
// V2 fields — new categories
|
|
37
|
+
electricity_unit_rate: null, electricity_standing_charge: null,
|
|
38
|
+
electricity_tariff_code: null, electricity_valid_from: null, electricity_valid_to: null,
|
|
39
|
+
electricity_export_unit_rate: null, electricity_export_standing_charge: null,
|
|
40
|
+
electricity_export_tariff_code: null, electricity_export_valid_from: null, electricity_export_valid_to: null,
|
|
41
|
+
electricity_consumption_kwh: null, electricity_consumption_cost: null,
|
|
42
|
+
electricity_consumption_from: null, electricity_consumption_to: null,
|
|
43
|
+
electricity_export_consumption_kwh: null,
|
|
44
|
+
electricity_export_consumption_from: null, electricity_export_consumption_to: null,
|
|
45
|
+
electricity_export_rate: [], electricity_export_rate_count: 0,
|
|
46
|
+
electricity_export_rate_current_pence: null, electricity_export_rate_current_gbp: null,
|
|
47
|
+
electricity_export_rate_prev_pence: null, electricity_export_rate_prev_gbp: null, electricity_export_rate_prev_to: null,
|
|
48
|
+
electricity_export_rate_next_pence: null, electricity_export_rate_next_gbp: null, electricity_export_rate_next_from: null,
|
|
49
|
+
electricity_export_rate_error: null,
|
|
50
|
+
electricity_rates_error: null, electricity_consumption_error: null,
|
|
51
|
+
gas_unit_rate: null, gas_standing_charge: null,
|
|
52
|
+
gas_tariff_code: null, gas_valid_from: null, gas_valid_to: null,
|
|
53
|
+
gas_consumption_kwh: null, gas_consumption_cost: null,
|
|
54
|
+
gas_consumption_from: null, gas_consumption_to: null,
|
|
55
|
+
gas_rates_error: null, gas_consumption_error: null,
|
|
56
|
+
wheel_of_fortune_electricity_spins: null, wheel_of_fortune_electricity_max: null,
|
|
57
|
+
wheel_of_fortune_electricity_used: null,
|
|
58
|
+
wheel_of_fortune_gas_spins: null, wheel_of_fortune_gas_max: null,
|
|
59
|
+
wheel_of_fortune_gas_used: null, wheel_of_fortune_error: null,
|
|
60
|
+
mini_demand_kw: null, mini_consumption_delta_kwh: null, mini_read_at: null, home_mini_error: null,
|
|
61
|
+
saving_session_available: null, saving_session_start: null, saving_session_end: null,
|
|
62
|
+
saving_session_joined: null, saving_session_points: null, saving_sessions_error: null,
|
|
63
|
+
free_electricity_active: null, free_electricity_available: null,
|
|
64
|
+
free_electricity_start: null, free_electricity_end: null, free_electricity_error: null,
|
|
65
|
+
intelligent_error: null,
|
|
66
|
+
completed_dispatches: [], completed_dispatches_count: 0, completed_dispatches_error: null,
|
|
67
|
+
flex_planned_dispatches: [], flex_planned_dispatches_count: 0, flex_planned_dispatches_error: null,
|
|
68
|
+
applicable_rates: [], applicable_rates_count: 0,
|
|
69
|
+
applicable_rates_current_pence: null, applicable_rates_error: null,
|
|
70
|
+
account_balance_pence: null, account_balance_pounds: null, account_error: null,
|
|
71
|
+
octoplus_enrolled: null, octoplus_enrollment_status: null,
|
|
72
|
+
octoplus_loyalty_points_user: null, octoplus_error: null
|
|
73
|
+
};
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
module.exports = { mergePayload, buildDefaultPayload };
|
package/lib/scheduler.js
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
function isDue(cat) {
|
|
4
|
+
if (!cat.enabled) return false;
|
|
5
|
+
if (cat.lastPolled === 0) return true;
|
|
6
|
+
const slot = ts => Math.floor(ts / cat.intervalMs);
|
|
7
|
+
return slot(Date.now()) > slot(cat.lastPolled);
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
function alignedStart(nowMs) {
|
|
11
|
+
const ms = nowMs % 1000;
|
|
12
|
+
return ms === 0 ? 1000 : 1000 - ms;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
function createScheduler(onTick) {
|
|
16
|
+
let handle = null;
|
|
17
|
+
|
|
18
|
+
function start() {
|
|
19
|
+
const delay = alignedStart(Date.now());
|
|
20
|
+
setTimeout(() => {
|
|
21
|
+
onTick();
|
|
22
|
+
handle = setInterval(onTick, 1000);
|
|
23
|
+
}, delay);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
function stop() {
|
|
27
|
+
if (handle) { clearInterval(handle); handle = null; }
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
return { start, stop };
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
module.exports = { isDue, alignedStart, createScheduler };
|
package/lib/timezone.js
ADDED
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
function convertToTimezone(dateStr, tz) {
|
|
4
|
+
if (!dateStr || typeof dateStr !== 'string') return dateStr;
|
|
5
|
+
try {
|
|
6
|
+
const date = new Date(dateStr.replace(' ', 'T'));
|
|
7
|
+
if (isNaN(date.getTime())) return dateStr;
|
|
8
|
+
const parts = new Intl.DateTimeFormat('en-CA', {
|
|
9
|
+
timeZone: tz,
|
|
10
|
+
year: 'numeric', month: '2-digit', day: '2-digit',
|
|
11
|
+
hour: '2-digit', minute: '2-digit', second: '2-digit',
|
|
12
|
+
hour12: false, hourCycle: 'h23'
|
|
13
|
+
}).formatToParts(date);
|
|
14
|
+
const get = (type) => (parts.find(p => p.type === type) || {}).value || '00';
|
|
15
|
+
const y = get('year'), mo = get('month'), d = get('day');
|
|
16
|
+
const h = get('hour'), mi = get('minute'), s = get('second');
|
|
17
|
+
const localAsUtc = Date.UTC(
|
|
18
|
+
parseInt(y, 10), parseInt(mo, 10) - 1, parseInt(d, 10),
|
|
19
|
+
parseInt(h, 10), parseInt(mi, 10), parseInt(s, 10)
|
|
20
|
+
);
|
|
21
|
+
const offsetMins = Math.round((localAsUtc - date.getTime()) / 60000);
|
|
22
|
+
const sign = offsetMins >= 0 ? '+' : '-';
|
|
23
|
+
const absMin = Math.abs(offsetMins);
|
|
24
|
+
const offsetStr = `${sign}${String(Math.floor(absMin / 60)).padStart(2, '0')}:${String(absMin % 60).padStart(2, '0')}`;
|
|
25
|
+
return `${y}-${mo}-${d} ${h}:${mi}:${s}${offsetStr}`;
|
|
26
|
+
} catch (e) {
|
|
27
|
+
return dateStr;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
function resolveTimezone(nd) {
|
|
32
|
+
try {
|
|
33
|
+
const persisted = nd.context().get('timezone');
|
|
34
|
+
if (persisted && typeof persisted === 'string' && persisted.trim().length > 0) {
|
|
35
|
+
return persisted.trim();
|
|
36
|
+
}
|
|
37
|
+
} catch (e) {}
|
|
38
|
+
const override = nd.timezoneOverride;
|
|
39
|
+
if (override && typeof override === 'string' && override.trim().length > 0) {
|
|
40
|
+
return override.trim();
|
|
41
|
+
}
|
|
42
|
+
try {
|
|
43
|
+
return Intl.DateTimeFormat().resolvedOptions().timeZone || 'UTC';
|
|
44
|
+
} catch (e) {
|
|
45
|
+
return 'UTC';
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
module.exports = { convertToTimezone, resolveTimezone };
|
package/octopus-intelligent.html
CHANGED
|
@@ -5,10 +5,24 @@
|
|
|
5
5
|
defaults: {
|
|
6
6
|
name: { value: "Octopus Intelligent" },
|
|
7
7
|
accountNumber: { value: "", required: true },
|
|
8
|
-
broker: { type: "mqtt-broker", required: false },
|
|
8
|
+
broker: { type: "mqtt-broker", required: false },
|
|
9
9
|
refreshInterval: { value: 5, validate: RED.validators.number() },
|
|
10
10
|
enableMqtt: { value: true },
|
|
11
|
-
timezoneOverride: { value: "" }
|
|
11
|
+
timezoneOverride: { value: "" },
|
|
12
|
+
// Electricity
|
|
13
|
+
electricityEnabled: { value: true },
|
|
14
|
+
electricityRatesInterval: { value: 60, validate: RED.validators.number() },
|
|
15
|
+
electricityConsumptionInterval: { value: 60, validate: RED.validators.number() },
|
|
16
|
+
// Gas
|
|
17
|
+
gasEnabled: { value: true },
|
|
18
|
+
gasRatesInterval: { value: 60, validate: RED.validators.number() },
|
|
19
|
+
gasConsumptionInterval: { value: 60, validate: RED.validators.number() },
|
|
20
|
+
// Wheel of Fortune
|
|
21
|
+
enableWheelOfFortune: { value: false },
|
|
22
|
+
wheelOfFortuneInterval: { value: 60, validate: RED.validators.number() },
|
|
23
|
+
// Home Mini
|
|
24
|
+
enableHomeMini: { value: false },
|
|
25
|
+
homeMiniInterval: { value: 1, validate: RED.validators.number() }
|
|
12
26
|
},
|
|
13
27
|
credentials: {
|
|
14
28
|
apiKey: { type: "password" }
|
|
@@ -39,8 +53,9 @@
|
|
|
39
53
|
<hr>
|
|
40
54
|
|
|
41
55
|
<div class="form-row">
|
|
42
|
-
<label for="node-input-refreshInterval"><i class="fa fa-
|
|
43
|
-
<input type="number" id="node-input-refreshInterval" placeholder="5">
|
|
56
|
+
<label for="node-input-refreshInterval"><i class="fa fa-bolt"></i> Intelligent (Min)</label>
|
|
57
|
+
<input type="number" id="node-input-refreshInterval" placeholder="5" style="width:70px;">
|
|
58
|
+
<span style="margin-left:6px;font-size:0.85em;color:#888;">Charging slots poll interval</span>
|
|
44
59
|
</div>
|
|
45
60
|
|
|
46
61
|
<div class="form-row">
|
|
@@ -63,6 +78,58 @@
|
|
|
63
78
|
<label for="node-input-broker"><i class="fa fa-globe"></i> MQTT Broker</label>
|
|
64
79
|
<input type="text" id="node-input-broker">
|
|
65
80
|
</div>
|
|
81
|
+
|
|
82
|
+
<hr>
|
|
83
|
+
|
|
84
|
+
<div class="form-row">
|
|
85
|
+
<label style="width:100%;font-weight:bold;color:#555;margin-bottom:2px;">
|
|
86
|
+
<i class="fa fa-clock-o"></i> API Polling Intervals (minutes)
|
|
87
|
+
</label>
|
|
88
|
+
</div>
|
|
89
|
+
|
|
90
|
+
<div class="form-row" style="display:flex;align-items:center;flex-wrap:wrap;gap:6px;">
|
|
91
|
+
<label for="node-input-electricityEnabled" style="width:120px;flex-shrink:0;">
|
|
92
|
+
<i class="fa fa-bolt"></i> Electricity
|
|
93
|
+
</label>
|
|
94
|
+
<input type="checkbox" id="node-input-electricityEnabled" style="width:auto;">
|
|
95
|
+
<span style="font-size:0.85em;color:#555;margin-left:6px;">Rates:</span>
|
|
96
|
+
<input type="number" id="node-input-electricityRatesInterval" style="width:55px;" placeholder="60">
|
|
97
|
+
<span style="font-size:0.85em;color:#555;">Consumption:</span>
|
|
98
|
+
<input type="number" id="node-input-electricityConsumptionInterval" style="width:55px;" placeholder="60">
|
|
99
|
+
</div>
|
|
100
|
+
|
|
101
|
+
<div class="form-row" style="display:flex;align-items:center;flex-wrap:wrap;gap:6px;">
|
|
102
|
+
<label for="node-input-gasEnabled" style="width:120px;flex-shrink:0;">
|
|
103
|
+
<i class="fa fa-fire"></i> Gas
|
|
104
|
+
</label>
|
|
105
|
+
<input type="checkbox" id="node-input-gasEnabled" style="width:auto;">
|
|
106
|
+
<span style="font-size:0.85em;color:#555;margin-left:6px;">Rates:</span>
|
|
107
|
+
<input type="number" id="node-input-gasRatesInterval" style="width:55px;" placeholder="60">
|
|
108
|
+
<span style="font-size:0.85em;color:#555;">Consumption:</span>
|
|
109
|
+
<input type="number" id="node-input-gasConsumptionInterval" style="width:55px;" placeholder="60">
|
|
110
|
+
</div>
|
|
111
|
+
|
|
112
|
+
<div class="form-row" style="display:flex;align-items:center;flex-wrap:wrap;gap:6px;">
|
|
113
|
+
<label for="node-input-enableWheelOfFortune" style="width:120px;flex-shrink:0;">
|
|
114
|
+
<i class="fa fa-star"></i> Wheel of Fortune
|
|
115
|
+
</label>
|
|
116
|
+
<input type="checkbox" id="node-input-enableWheelOfFortune" style="width:auto;">
|
|
117
|
+
<span style="font-size:0.85em;color:#666;margin-left:4px;">Octoplus only</span>
|
|
118
|
+
<span style="font-size:0.85em;color:#555;margin-left:6px;">Every:</span>
|
|
119
|
+
<input type="number" id="node-input-wheelOfFortuneInterval" style="width:55px;" placeholder="60">
|
|
120
|
+
<span style="font-size:0.85em;color:#888;">min</span>
|
|
121
|
+
</div>
|
|
122
|
+
|
|
123
|
+
<div class="form-row" style="display:flex;align-items:center;flex-wrap:wrap;gap:6px;">
|
|
124
|
+
<label for="node-input-enableHomeMini" style="width:120px;flex-shrink:0;">
|
|
125
|
+
<i class="fa fa-home"></i> Home Mini
|
|
126
|
+
</label>
|
|
127
|
+
<input type="checkbox" id="node-input-enableHomeMini" style="width:auto;">
|
|
128
|
+
<span style="font-size:0.85em;color:#666;margin-left:4px;">requires hardware</span>
|
|
129
|
+
<span style="font-size:0.85em;color:#555;margin-left:6px;">Every:</span>
|
|
130
|
+
<input type="number" id="node-input-homeMiniInterval" style="width:55px;" placeholder="1">
|
|
131
|
+
<span style="font-size:0.85em;color:#888;">min</span>
|
|
132
|
+
</div>
|
|
66
133
|
</script>
|
|
67
134
|
|
|
68
135
|
<script type="text/html" data-help-name="octopus-intelligent">
|