{"id":15095822,"url":"https://github.com/islandcontroller/euc2mqtt","last_synced_at":"2026-01-05T07:05:50.052Z","repository":{"id":236798861,"uuid":"789502961","full_name":"islandcontroller/euc2mqtt","owner":"islandcontroller","description":"MQTT Publisher for Eaton UPS Companion status messages to Home Assistant","archived":false,"fork":false,"pushed_at":"2024-05-20T13:46:19.000Z","size":134,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-26T16:32:56.857Z","etag":null,"topics":["eaton-ups","homeassistant","mqtt","python3"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/euc2mqtt/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/islandcontroller.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-04-20T18:24:21.000Z","updated_at":"2024-05-20T13:43:44.000Z","dependencies_parsed_at":null,"dependency_job_id":"3f77593a-86ce-4c53-ac98-6164ca2dcf39","html_url":"https://github.com/islandcontroller/euc2mqtt","commit_stats":null,"previous_names":["islandcontroller/euc2mqtt"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/islandcontroller%2Feuc2mqtt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/islandcontroller%2Feuc2mqtt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/islandcontroller%2Feuc2mqtt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/islandcontroller%2Feuc2mqtt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/islandcontroller","download_url":"https://codeload.github.com/islandcontroller/euc2mqtt/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244875046,"owners_count":20524591,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["eaton-ups","homeassistant","mqtt","python3"],"created_at":"2024-09-25T15:42:21.846Z","updated_at":"2026-01-05T07:05:50.045Z","avatar_url":"https://github.com/islandcontroller.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# euc2mqtt\n\n[![License](https://img.shields.io/github/license/islandcontroller/euc2mqtt)](LICENSE) ![PyPI - Version](https://img.shields.io/pypi/v/euc2mqtt)\n\nA tool for publishing status data from a local Eaton UPS Companion service to Homeassistant.\n\n\u003cp align=\"center\"\u003e\u003cimg src=\"https://raw.githubusercontent.com/islandcontroller/euc2mqtt/master/scr.png\"/\u003e\u003c/p\u003e\n\n## Quick Start\n\nThe following quick start guide should get you up and running from a blank Homeassistant installation. Feel free to skip a step if your system is already configured.\n\n### Install mosquitto\n\n1. In Homeassistant, navigate to *Settings*, *Add-ons*\n2. Click the *Add-on store* button\n3. Search for *Mosquitto broker* and select the result\n4. Click on *Install*\n\n\u003e [!NOTE]\n\u003e When using the *Mosquitto broker* Add-on, your MQTT broker hostname will be the same as your Homeassistant's, e.g. \"`homeassistant.local`\".\n\n### Create a new Homeassistant user for data ingest\n\nAs mosquitto requires authentication, I heavily suggest creating a new user for data ingest.\n\n1. In Homeassistant, navigate to *Settings*, *People*\n2. Click on *Add person*, input a user name\n3. Check *Allow person to log in*\n4. Enter all required fields\n5. Check *Can only log in from local network*\n\n### Get the application\n\nWindows binaries are provided on the [GitHub Releases](https://github.com/islandcontroller/euc2mqtt/releases) page.\n\nIf you prefer to use your own Python insallation, a pre-built package is hosted on [PyPI](https://pypi.org/project/euc2mqtt/) and can be installed and updated using the [`pip`](https://pip.pypa.io/en/stable/getting-started/) utility:\n\n    pip install -U euc2mqtt\n\n### Run it!\n\n\u003e [!NOTE]\n\u003e This tool needs to run on the same host as Eaton UPS Companion, as EUC in its default configuration only accepts connections on `localhost:4679`.\n\nOpen a terminal and run the tool, providing the broker hostname (your Homeassistant hostname), username and the password!\n\n*Option 1: Standalone application*\n\n    .\\euc2mqtt --mqtt \u003cbroker hostname\u003e --username \u003cuser\u003e --password \u003cpassword\u003e\n\n*Option 2: Run as Python module*\n\n    python -m euc2mqtt --mqtt \u003cbroker hostname\u003e --username \u003cuser\u003e --password \u003cpassword\u003e\n\n### More info\n\nA more in-depth description of available command line parameters can be viewed by appending `-h` at the end of your input. For example:\n\n```\n\u003e .\\euc2mqtt -h\n\nusage: euc2mqtt [-h] [--name NAME] [--mqtt MQTT] [--euc EUC] [--username USERNAME] [--password PASSWORD] [--interval INTERVAL] [--full-update FULL_UPDATE] [--logfile LOGFILE] [--verbose]\n\nMQTT Publisher for Eaton UPS Companion status messages to Home Assistant. See https://github.com/islandcontroller/euc2mqtt for more info!\n\noptions:\n  -h, --help            show this help message and exit\n  --name NAME           Device name\n  --mqtt MQTT           MQTT broker hostname and port (hostname[:port])\n  --euc EUC             Eaton UPS Companion hostname and port (hostname[:port])\n  --username USERNAME   Username for MQTT broker authentication\n  --password PASSWORD   Password for MQTT broker authentication\n  --interval INTERVAL   Update interval in seconds\n  --full-update FULL_UPDATE\n                        Number of incremental dataset fetches between full updates\n  --logfile LOGFILE     Output log messages to a file\n  --verbose             Enable verbose logging\n```\n\n## Running as a Windows Task\n\n1. Open *Task Scheduler* and select *Create New Task...*\n2. Select the following options on the *General* tab:\n    - Check *Run whether user is logged in or not*\n    - Uncheck *Do not store password*\n3. On the *Triggers* tab, create a \"At startup\" trigger\n4. On the *Actions* tab, add the standalone application as a program to run:\n    - Action: *Start a program*\n    - Program/Script: (Navigate to your `euc2mqtt.exe` here)\n    - Add arguments: `--mqtt \u003cbroker hostname\u003e --username \u003cuser\u003e --password \u003cpassword\u003e`\n5. On the *Settings* tab, select the following options:\n    - Check *Allow task to be run on demand*\n    - Select *If task fails, restart every: 1 minute*\n    - Uncheck *Stop the task if it runs longer than: ...*\n    - Select *If the task is already running: Do not start a new instance*\n6. Click *OK*. You will be prompted for a username and password to run the task as.\n\n## Configuring bind address for Eaton UPS Companion\n\n\u003e [!WARNING]\n\u003e Exposing the EUC service may pose a security risk.\n\n\u003e [!NOTE]\n\u003e When euc2mqtt is run on the same host as EUC, it is not required to expose the EUC service.\n\n1. Start a `notepad` instance with Admin privileges\n2. Open `C:\\Program Files (x86)\\Eaton\\UPSCompanion\\configs\\config.js`\n3. Edit the \"`httpServers`\" line to listen on all interfaces:\n\n        \"httpServers\": {\"http\": {\"port\": 4679, \"hostname\": \"0.0.0.0\"}}, \n\n## Legal Information\n\nThe contents of this repository are licensed under the MIT License. The full license text is provided in the [`LICENSE`](LICENSE) file.\n\n    SPDX-License-Identifier: MIT\n\n\"Eaton\" is a trademark of Eaton Corporation. \"Windows\" is a trademark of Microsoft Corporation. All trademarks are property of their respective owners.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fislandcontroller%2Feuc2mqtt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fislandcontroller%2Feuc2mqtt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fislandcontroller%2Feuc2mqtt/lists"}