[ { "id": "5a11adb1d1ac4ea9", "type": "comment", "z": "ea42da07.f8c51", "name": "Prix EDF (tempo pas dispo)", "info": "", "x": 1840, "y": 420, "wires": [] }, { "id": "f47b652b7409ee87", "type": "comment", "z": "ea42da07.f8c51", "name": "Source: https://www.data.gouv.fr/fr/datasets/historique-des-tarifs-reglementes-de-vente-delectricite-pour-les-consommateurs-residentiels/", "info": "BASE\nhttps://www.cre.fr/content/download/21061/269176\nhttps://www.data.gouv.fr/fr/datasets/r/c13d05e5-9e55-4d03-bf7e-042a2ade7e49\n\nHPHC\nhttps://www.cre.fr/content/download/21062/269182\nhttps://www.data.gouv.fr/fr/datasets/r/f7303b3a-93c7-4242-813d-84919034c416\n\n\nNotice\nhttps://www.cre.fr/content/download/21059/269167\nhttps://www.data.gouv.fr/fr/datasets/r/82756653-3ae3-4ae4-a256-77fe0ab0800f\n\n", "x": 2270, "y": 260, "wires": [] }, { "id": "613bbea787afcf7f", "type": "change", "z": "ea42da07.f8c51", "name": "ID Option BASE", "rules": [ { "t": "set", "p": "topic", "pt": "msg", "to": "BASE", "tot": "str" }, { "t": "set", "p": "payload", "pt": "msg", "to": "c13d05e5-9e55-4d03-bf7e-042a2ade7e49", "tot": "str" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1980, "y": 320, "wires": [ [ "a65391e849e1a74f" ] ] }, { "id": "3f8b9cf383fb5f21", "type": "debug", "z": "ea42da07.f8c51", "name": "Sortie Methode 1", "active": true, "tosidebar": true, "console": false, "tostatus": false, "complete": "payload", "targetType": "msg", "statusVal": "", "statusType": "auto", "x": 2970, "y": 420, "wires": [] }, { "id": "a65391e849e1a74f", "type": "http request", "z": "ea42da07.f8c51", "name": "https://www.data.gouv.fr/fr/datasets/r/", "method": "GET", "ret": "txt", "paytoqs": "ignore", "url": "https://www.data.gouv.fr/fr/datasets/r/{{payload}}", "tls": "", "persist": false, "proxy": "", "insecureHTTPParser": false, "authType": "", "senderr": false, "headers": [], "x": 2300, "y": 340, "wires": [ [ "a6940d2c6213bfeb", "d0b0f2d72385b099" ] ] }, { "id": "e8fa747365f2bce4", "type": "change", "z": "ea42da07.f8c51", "name": "ID Option HPHC", "rules": [ { "t": "set", "p": "topic", "pt": "msg", "to": "HPHC", "tot": "str" }, { "t": "set", "p": "payload", "pt": "msg", "to": "f7303b3a-93c7-4242-813d-84919034c416", "tot": "str" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 1980, "y": 360, "wires": [ [ "a65391e849e1a74f" ] ] }, { "id": "4e8a87f0587be17b", "type": "inject", "z": "ea42da07.f8c51", "name": "Tous les jours à 0h30", "props": [ { "p": "payload" } ], "repeat": "", "crontab": "30 00 * * *", "once": false, "onceDelay": 0.1, "topic": "", "payload": "", "payloadType": "date", "x": 1740, "y": 320, "wires": [ [ "613bbea787afcf7f" ] ] }, { "id": "83d870e45ff5febd", "type": "csv", "z": "ea42da07.f8c51", "name": "", "sep": ";", "hdrin": true, "hdrout": "none", "multi": "one", "ret": "\\n", "temp": "", "skip": "0", "strings": true, "include_empty_strings": "", "include_null_values": "", "x": 2170, "y": 440, "wires": [ [ "ac9ad90859f6630c", "c85ef1af522bfad1" ] ] }, { "id": "a6940d2c6213bfeb", "type": "switch", "z": "ea42da07.f8c51", "name": "Verification de l'entête CSV", "property": "payload", "propertyType": "msg", "rules": [ { "t": "cont", "v": "DATE_DEBUT;", "vt": "str" }, { "t": "else" } ], "checkall": "true", "repair": false, "outputs": 2, "x": 2660, "y": 340, "wires": [ [ "1d97d40e9d6e211c" ], [] ] }, { "id": "d0b0f2d72385b099", "type": "debug", "z": "ea42da07.f8c51", "name": "Debug URL", "active": false, "tosidebar": true, "console": false, "tostatus": false, "complete": "payload", "targetType": "msg", "statusVal": "", "statusType": "auto", "x": 2610, "y": 300, "wires": [] }, { "id": "cb23ac92d330ad30", "type": "switch", "z": "ea42da07.f8c51", "name": "DATE_DEBUT = 01/08/2023 ?", "property": "payload.DATE_DEBUT", "propertyType": "msg", "rules": [ { "t": "eq", "v": "01/08/2023", "vt": "str" }, { "t": "else" } ], "checkall": "true", "repair": false, "outputs": 2, "x": 2690, "y": 420, "wires": [ [ "3f8b9cf383fb5f21" ], [] ] }, { "id": "11a24f80127fa476", "type": "inject", "z": "ea42da07.f8c51", "name": "Tous les jours à 0h31", "props": [ { "p": "payload" } ], "repeat": "", "crontab": "31 00 * * *", "once": false, "onceDelay": 0.1, "topic": "", "payload": "", "payloadType": "date", "x": 1740, "y": 360, "wires": [ [ "e8fa747365f2bce4" ] ] }, { "id": "ac9ad90859f6630c", "type": "debug", "z": "ea42da07.f8c51", "name": "Debug CSV", "active": false, "tosidebar": true, "console": false, "tostatus": false, "complete": "payload", "targetType": "msg", "statusVal": "", "statusType": "auto", "x": 2350, "y": 480, "wires": [] }, { "id": "1d97d40e9d6e211c", "type": "change", "z": "ea42da07.f8c51", "name": ", -> .", "rules": [ { "t": "change", "p": "payload", "pt": "msg", "from": ",", "fromt": "str", "to": ".", "tot": "str" } ], "action": "", "property": "", "from": "", "to": "", "reg": false, "x": 2890, "y": 340, "wires": [ [ "83d870e45ff5febd" ] ] }, { "id": "993d4f0c14105ad4", "type": "switch", "z": "ea42da07.f8c51", "name": "DATE_FIN ?", "property": "payload.DATE_FIN", "propertyType": "msg", "rules": [ { "t": "nnull" }, { "t": "else" } ], "checkall": "true", "repair": false, "outputs": 2, "x": 2630, "y": 460, "wires": [ [], [ "4b2cc8dcce710131" ] ] }, { "id": "4b2cc8dcce710131", "type": "debug", "z": "ea42da07.f8c51", "name": "Sortie Methode 2", "active": true, "tosidebar": true, "console": false, "tostatus": false, "complete": "payload", "targetType": "msg", "statusVal": "", "statusType": "auto", "x": 2970, "y": 460, "wires": [] }, { "id": "c85ef1af522bfad1", "type": "switch", "z": "ea42da07.f8c51", "name": "P_SOUSCRITE = 6 ?", "property": "payload.P_SOUSCRITE", "propertyType": "msg", "rules": [ { "t": "eq", "v": "6", "vt": "num" }, { "t": "else" } ], "checkall": "true", "repair": false, "outputs": 2, "x": 2380, "y": 440, "wires": [ [ "993d4f0c14105ad4", "cb23ac92d330ad30" ], [] ] } ]