iobroker.teslafi 0.1.1 → 0.1.3
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/README.md +19 -4
- package/admin/jsonConfig.json +46 -1
- package/build/lib/teslafiAPICaller.js +5 -5
- package/io-package.json +27 -27
- package/package.json +7 -7
package/README.md
CHANGED
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|

|
|
14
14
|

|
|
15
15
|
|
|
16
|
-

|
|
17
17
|
[](https://github.com/hombach/ioBroker.teslafi/actions/workflows/codeql-analysis.yml)
|
|
18
18
|
[](https://ci.appveyor.com/project/hombach/iobroker-teslafi)
|
|
19
19
|
[](https://snyk.io/test/github/hombach/ioBroker.teslafi)
|
|
@@ -26,9 +26,13 @@
|
|
|
26
26
|
|
|
27
27
|
[](https://nodei.co/npm/iobroker.teslafi/)
|
|
28
28
|
|
|
29
|
-
## Adapter
|
|
29
|
+
## Adapter for Polling TeslaFi Data from Your Car
|
|
30
30
|
|
|
31
|
-
This adapter
|
|
31
|
+
This adapter enables the integration of data from your TeslaFi account API for use within ioBroker.
|
|
32
|
+
|
|
33
|
+
## Configuration
|
|
34
|
+
|
|
35
|
+
Enter your TeslaFi API key in the designated field on the configuration screen. You can also adjust the polling interval to suit your requirements.
|
|
32
36
|
|
|
33
37
|
## Sentry
|
|
34
38
|
|
|
@@ -37,10 +41,21 @@ This adapter employs Sentry libraries to automatically report exceptions and cod
|
|
|
37
41
|
## Donate
|
|
38
42
|
|
|
39
43
|
<a href="https://www.paypal.com/donate/?hosted_button_id=6EE4YUJRK7UWC"><img src="https://raw.githubusercontent.com/Hombach/ioBroker.teslafi/master/docu/bluePayPal.svg" height="40"></a>
|
|
40
|
-
If you enjoyed this project
|
|
44
|
+
If you enjoyed this project — or just feeling generous, consider buying me a beer. Cheers! :beers:
|
|
41
45
|
|
|
42
46
|
## Changelog
|
|
43
47
|
|
|
48
|
+
### 0.1.3 (2024-10-30)
|
|
49
|
+
|
|
50
|
+
- (hombach) fix typo in error text
|
|
51
|
+
- (hombach) optimize responsive design
|
|
52
|
+
- (hombach) bump dependencies
|
|
53
|
+
|
|
54
|
+
### 0.1.2 (2024-10-28)
|
|
55
|
+
|
|
56
|
+
- (hombach) introduce to ioBroker latest repo
|
|
57
|
+
- (hombach) bump dependencies
|
|
58
|
+
|
|
44
59
|
### 0.1.1 (2024-10-26)
|
|
45
60
|
|
|
46
61
|
- (hombach) fix npm error
|
package/admin/jsonConfig.json
CHANGED
|
@@ -75,9 +75,11 @@
|
|
|
75
75
|
"type": "header",
|
|
76
76
|
"text": "",
|
|
77
77
|
"noTranslation": true,
|
|
78
|
+
"xs": 12,
|
|
78
79
|
"sm": 12,
|
|
79
80
|
"md": 12,
|
|
80
81
|
"lg": 12,
|
|
82
|
+
"xl": 12,
|
|
81
83
|
"size": 3
|
|
82
84
|
},
|
|
83
85
|
"_helpLink": {
|
|
@@ -100,9 +102,52 @@
|
|
|
100
102
|
},
|
|
101
103
|
"href": "https://github.com/hombach/ioBroker.teslafi/blob/master/README.md",
|
|
102
104
|
"newLine": true,
|
|
105
|
+
"xs": 12,
|
|
106
|
+
"sm": 12,
|
|
107
|
+
"md": 12,
|
|
108
|
+
"lg": 12,
|
|
109
|
+
"xl": 12
|
|
110
|
+
},
|
|
111
|
+
|
|
112
|
+
"_divider0": {
|
|
113
|
+
"newLine": true,
|
|
114
|
+
"type": "divider",
|
|
115
|
+
"color": "primary"
|
|
116
|
+
},
|
|
117
|
+
|
|
118
|
+
"_donate": {
|
|
119
|
+
"type": "staticImage",
|
|
120
|
+
"tooltip": "PayPal.Me",
|
|
121
|
+
"noTranslation": true,
|
|
122
|
+
"href": "https://www.paypal.com/donate/?hosted_button_id=6EE4YUJRK7UWC",
|
|
123
|
+
"src": "https://raw.githubusercontent.com/hombach/ioBroker.teslafi/master/docu/bluePayPal.svg",
|
|
124
|
+
"xs": 6,
|
|
125
|
+
"sm": 6,
|
|
126
|
+
"md": 4,
|
|
127
|
+
"lg": 2,
|
|
128
|
+
"xl": 1,
|
|
129
|
+
"newLine": true
|
|
130
|
+
},
|
|
131
|
+
"_donateTx": {
|
|
132
|
+
"type": "staticText",
|
|
133
|
+
"text": {
|
|
134
|
+
"en": "If you enjoyed this project — or just feeling generous, consider buying me a beer. Cheers! 🍻",
|
|
135
|
+
"de": "Wenn Ihnen dieses Projekt gefallen hat – oder Sie einfach großzügig sind, überlegen Sie, mir ein Bier zu spendieren. Prost! 🍻",
|
|
136
|
+
"ru": "Если вам понравился этот проект — или вы просто чувствуете себя щедрым, подумайте о том, чтобы купить мне пиво. Ура! 🍻",
|
|
137
|
+
"pt": "Se você gostou deste projeto - ou está se sentindo generoso, considere me comprar uma cerveja. Saúde! 🍻",
|
|
138
|
+
"nl": "Als je genoten hebt van dit project — of gewoon gul bent, overweeg dan om me een biertje te kopen. Proost! 🍻",
|
|
139
|
+
"fr": "Si vous avez apprécié ce projet — ou si vous vous sentez généreux, envisagez de m'acheter une bière. Santé! 🍻",
|
|
140
|
+
"it": "Se ti è piaciuto questo progetto — o se ti senti generoso, considera di offrirmi una birra. Salute! 🍻",
|
|
141
|
+
"es": "Si disfrutaste de este proyecto — o simplemente te sientes generoso, considera comprarme una cerveza. ¡Salud! 🍻",
|
|
142
|
+
"pl": "Jeśli spodobał ci się ten projekt — lub po prostu czujesz się hojny, rozważ kupienie mi piwa. Na zdrowie! 🍻",
|
|
143
|
+
"uk": "Якщо вам сподобався цей проект — або ви просто хочете зробити приємне, подумайте про те, щоб купити мені пиво. Ура! 🍻",
|
|
144
|
+
"zh-cn": "如果你喜欢这个项目,或者只是觉得慷慨,请考虑请我喝一杯啤酒。干杯!🍻"
|
|
145
|
+
},
|
|
146
|
+
"xs": 12,
|
|
103
147
|
"sm": 12,
|
|
104
148
|
"md": 12,
|
|
105
|
-
"lg": 12
|
|
149
|
+
"lg": 12,
|
|
150
|
+
"xl": 12
|
|
106
151
|
}
|
|
107
152
|
}
|
|
108
153
|
}
|
|
@@ -33,7 +33,7 @@ class TeslaFiAPICaller extends teslafiHelper_1.TeslaFiHelper {
|
|
|
33
33
|
const result = JSON.parse(response.data);
|
|
34
34
|
// Check if the response indicates an unauthorized access {"response":{"reason":"","result":"unauthorized"}}
|
|
35
35
|
if (result.response?.result === "unauthorized") {
|
|
36
|
-
this.adapter.log.warn(`TeslaFI data read - unauthorized access detected - please verify your API
|
|
36
|
+
this.adapter.log.warn(`TeslaFI data read - unauthorized access detected - please verify your API Token`);
|
|
37
37
|
return false;
|
|
38
38
|
}
|
|
39
39
|
else {
|
|
@@ -558,22 +558,22 @@ class TeslaFiAPICaller extends teslafiHelper_1.TeslaFiHelper {
|
|
|
558
558
|
switch (stError.code) {
|
|
559
559
|
case "ETIMEDOUT":
|
|
560
560
|
this.adapter.log.warn(`Connection timeout error when calling ${sOccasion}`);
|
|
561
|
-
this.adapter.log.warn(`Please verify the API Token or adapt
|
|
561
|
+
this.adapter.log.warn(`Please verify the API Token or adapt your poll interval, (e${sErrorOccInt}.2)`);
|
|
562
562
|
break;
|
|
563
563
|
case "EHOSTUNREACH":
|
|
564
564
|
this.adapter.log.warn(`TeslaFi not reachable error when calling ${sOccasion}`);
|
|
565
|
-
this.adapter.log.warn(`Please verify
|
|
565
|
+
this.adapter.log.warn(`Please verify your network environment, (e${sErrorOccInt}.2)`);
|
|
566
566
|
break;
|
|
567
567
|
case "ENETUNREACH":
|
|
568
568
|
this.adapter.log.warn(`Inverter network not reachable error when calling ${sOccasion}`);
|
|
569
|
-
this.adapter.log.warn(`Please verify
|
|
569
|
+
this.adapter.log.warn(`Please verify your network environment, (e${sErrorOccInt}.2)`);
|
|
570
570
|
break;
|
|
571
571
|
}
|
|
572
572
|
// errors: 'Unexpected end of JSON input' 'read ECONNRESET' 'connect ECONNREFUSED 192.168.0.1:80'
|
|
573
573
|
}
|
|
574
574
|
else {
|
|
575
575
|
this.adapter.log.error(`Unknown error when calling ${sOccasion}: ${stError.message}`);
|
|
576
|
-
this.adapter.log.error(`Please verify the API Token or adapt
|
|
576
|
+
this.adapter.log.error(`Please verify the API Token or adapt your poll interval, (e${sErrorOccInt}.3)`);
|
|
577
577
|
if (this.adapter.supportsFeature && this.adapter.supportsFeature("PLUGINS")) {
|
|
578
578
|
// send Sentry error
|
|
579
579
|
const sentryInstance = this.adapter.getPluginInstance("sentry");
|
package/io-package.json
CHANGED
|
@@ -1,8 +1,34 @@
|
|
|
1
1
|
{
|
|
2
2
|
"common": {
|
|
3
3
|
"name": "teslafi",
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.3",
|
|
5
5
|
"news": {
|
|
6
|
+
"0.1.3": {
|
|
7
|
+
"en": "Fix typo in error text\nOptimize responsive design\nBump dependencies",
|
|
8
|
+
"de": "Tippfehler im Fehlermeldungstext korrigieren\nResponsives Design optimieren\nAbhängigkeiten aktualisieren",
|
|
9
|
+
"ru": "Исправить опечатку в тексте ошибки\nОптимизировать адаптивный дизайн\nОбновить зависимости",
|
|
10
|
+
"pt": "Corrigir erro de digitação no texto de erro\nOtimizar design responsivo\nAtualizar dependências",
|
|
11
|
+
"nl": "Typfout in fouttekst corrigeren\nResponsief ontwerp optimaliseren\nAfhankelijkheden bijwerken",
|
|
12
|
+
"fr": "Corriger la faute de frappe dans le texte d'erreur\nOptimiser le design adaptatif\nMettre à jour les dépendances",
|
|
13
|
+
"it": "Correggi errore di battitura nel testo di errore\nOttimizza il design responsivo\nAggiorna le dipendenze",
|
|
14
|
+
"es": "Corregir error tipográfico en el texto de error\nOptimizar diseño responsivo\nActualizar dependencias",
|
|
15
|
+
"pl": "Popraw błąd w tekście błędu\nOptymalizuj responsywny design\nAktualizuj zależności",
|
|
16
|
+
"uk": "Виправити помилку у тексті помилки\nОптимізувати адаптивний дизайн\nОновити залежності",
|
|
17
|
+
"zh-cn": "修正错误文本中的拼写错误\n优化响应式设计\n更新依赖项"
|
|
18
|
+
},
|
|
19
|
+
"0.1.2": {
|
|
20
|
+
"en": "Introduce to ioBroker latest repo\nBump dependencies",
|
|
21
|
+
"de": "In ioBroker-Latest-Repo einführen\nAbhängigkeiten aktualisieren",
|
|
22
|
+
"ru": "Введение в последний репозиторий ioBroker\nОбновлены зависимости",
|
|
23
|
+
"pt": "Introduzir ao repositório mais recente do ioBroker\nAtualizar dependências",
|
|
24
|
+
"nl": "Introductie in ioBroker nieuwste repo\nAfhankelijkheden bijwerken",
|
|
25
|
+
"fr": "Introduction dans le dernier dépôt ioBroker\nMettre à jour les dépendances",
|
|
26
|
+
"it": "Introduzione al repository più recente di ioBroker\nAggiorna le dipendenze",
|
|
27
|
+
"es": "Introducir en el repositorio más reciente de ioBroker\nActualizar dependencias",
|
|
28
|
+
"pl": "Wprowadzenie do najnowszego repozytorium ioBroker\nZaktualizuj zależności",
|
|
29
|
+
"uk": "Введення в останнє репозиторій ioBroker\nОновити залежності",
|
|
30
|
+
"zh-cn": "引入到 ioBroker 最新仓库\n更新依赖项"
|
|
31
|
+
},
|
|
6
32
|
"0.1.1": {
|
|
7
33
|
"en": "Fix npm error",
|
|
8
34
|
"de": "NPM-Fehler behoben",
|
|
@@ -15,32 +41,6 @@
|
|
|
15
41
|
"pl": "Napraw błąd npm",
|
|
16
42
|
"uk": "Виправити помилку npm",
|
|
17
43
|
"zh-cn": "修复 npm 错误"
|
|
18
|
-
},
|
|
19
|
-
"0.1.0": {
|
|
20
|
-
"en": "First working version",
|
|
21
|
-
"de": "Erste funktionsfähige Version",
|
|
22
|
-
"ru": "Первая рабочая версия",
|
|
23
|
-
"pt": "Primeira versão funcional",
|
|
24
|
-
"nl": "Eerste werkende versie",
|
|
25
|
-
"fr": "Première version fonctionnelle",
|
|
26
|
-
"it": "Prima versione funzionante",
|
|
27
|
-
"es": "Primera versión funcional",
|
|
28
|
-
"pl": "Pierwsza działająca wersja",
|
|
29
|
-
"uk": "Перша робоча версія",
|
|
30
|
-
"zh-cn": "第一个工作版本"
|
|
31
|
-
},
|
|
32
|
-
"0.0.1": {
|
|
33
|
-
"en": "initial release",
|
|
34
|
-
"de": "Erstveröffentlichung",
|
|
35
|
-
"ru": "Начальная версия",
|
|
36
|
-
"pt": "lançamento inicial",
|
|
37
|
-
"nl": "Eerste uitgave",
|
|
38
|
-
"fr": "Première version",
|
|
39
|
-
"it": "Versione iniziale",
|
|
40
|
-
"es": "Versión inicial",
|
|
41
|
-
"pl": "Pierwsze wydanie",
|
|
42
|
-
"uk": "Початковий випуск",
|
|
43
|
-
"zh-cn": "首次出版"
|
|
44
44
|
}
|
|
45
45
|
},
|
|
46
46
|
"titleLang": {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "iobroker.teslafi",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "Adapter to poll TeslaFi data of your car",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Hombach",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@iobroker/adapter-core": "^3.2.2",
|
|
27
27
|
"axios": "^1.7.7",
|
|
28
|
-
"cron": "^3.1.
|
|
28
|
+
"cron": "^3.1.8"
|
|
29
29
|
},
|
|
30
30
|
"devDependencies": {
|
|
31
31
|
"@alcalzone/pak": "^0.11.0",
|
|
@@ -38,25 +38,25 @@
|
|
|
38
38
|
"@types/eslint__eslintrc": "^2.1.2",
|
|
39
39
|
"@types/eslint__js": "^8.42.3",
|
|
40
40
|
"@types/mocha": "^10.0.9",
|
|
41
|
-
"@types/node": "^22.8.
|
|
41
|
+
"@types/node": "^22.8.4",
|
|
42
42
|
"@types/proxyquire": "^1.3.31",
|
|
43
43
|
"@types/sinon": "^17.0.3",
|
|
44
44
|
"@types/sinon-chai": "^3.2.12",
|
|
45
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
46
|
-
"@typescript-eslint/parser": "^8.
|
|
45
|
+
"@typescript-eslint/eslint-plugin": "^8.12.2",
|
|
46
|
+
"@typescript-eslint/parser": "^8.12.0",
|
|
47
47
|
"chai": "^4.5.0",
|
|
48
48
|
"chai-as-promised": "^7.1.2",
|
|
49
49
|
"eslint": "^9.13.0",
|
|
50
50
|
"eslint-config-prettier": "^9.1.0",
|
|
51
51
|
"eslint-plugin-prettier": "^5.2.1",
|
|
52
|
-
"mocha": "^10.
|
|
52
|
+
"mocha": "^10.8.1",
|
|
53
53
|
"prettier": "^3.3.3",
|
|
54
54
|
"proxyquire": "^2.1.3",
|
|
55
55
|
"sinon": "^19.0.2",
|
|
56
56
|
"sinon-chai": "^3.7.0",
|
|
57
57
|
"ts-node": "^10.9.2",
|
|
58
58
|
"typescript": "~5.6.3",
|
|
59
|
-
"typescript-eslint": "^8.
|
|
59
|
+
"typescript-eslint": "^8.12.2"
|
|
60
60
|
},
|
|
61
61
|
"main": "build/main.js",
|
|
62
62
|
"files": [
|