{"id":19715058,"url":"https://github.com/georgeherby/madevice","last_synced_at":"2025-11-03T13:03:52.915Z","repository":{"id":49215509,"uuid":"171683934","full_name":"georgeherby/MADevice","owner":"georgeherby","description":"Provides a way to monitor devices being used in MAD.","archived":false,"fork":false,"pushed_at":"2025-09-01T04:45:44.000Z","size":229,"stargazers_count":9,"open_issues_count":9,"forks_count":14,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-09-01T07:01:01.771Z","etag":null,"topics":["discord","hacktoberfest"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/georgeherby.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null}},"created_at":"2019-02-20T14:03:59.000Z","updated_at":"2023-04-11T16:32:00.000Z","dependencies_parsed_at":"2024-11-11T22:37:11.964Z","dependency_job_id":"067edf6c-f5c7-4ff6-a809-269f197ba836","html_url":"https://github.com/georgeherby/MADevice","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/georgeherby/MADevice","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/georgeherby%2FMADevice","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/georgeherby%2FMADevice/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/georgeherby%2FMADevice/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/georgeherby%2FMADevice/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/georgeherby","download_url":"https://codeload.github.com/georgeherby/MADevice/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/georgeherby%2FMADevice/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":282461069,"owners_count":26672904,"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","status":"online","status_checked_at":"2025-11-03T02:00:05.676Z","response_time":108,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["discord","hacktoberfest"],"created_at":"2024-11-11T22:37:04.307Z","updated_at":"2025-11-03T13:03:52.869Z","avatar_url":"https://github.com/georgeherby.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MADevice\n\n[![Python 3.7](https://img.shields.io/badge/python-3.7-blue.svg)](https://www.python.org/downloads/release/python-370/)\n\nProvides a way to monitor devices being used in MAD without needing a browser. Get alerts in Discord when they have not updated for a set amount of time. As well as a way to get the status of your devices on demand without leaving Discord.\ngit \n## Requirements\n* Python 3.7 (Only tested on 3.7, other Python 3 versions may work)\n\n\u003e WHERE IT SAYS `python[3[.7]]` or  `pip[3[.7]]` DON'T JUST COPY AND PASTE. EITHER RUN:\n\u003e * `pip` if you only have python 3 installed\n\u003e * `pip3` if you only have one python 3 installed\n\u003e * `pip3.7` if you have multiple python 3 installs.\n\n## Setup\n* Clone this repo\n* You **MUST** create a virtual environment as this and MAD use different websocket versions.\n   * Go to the folder containing MADevice. Within this folder run `python[3[.7]] -m venv py3`. This will create a folder within called `py3`\n   * Within this there is a `bin` folder and in this there is the pip and python installs for this envrionment.\n* Once you have a venv run from in the MADevice folder `\u003cPATH_TO_VENV_BIN\u003e/pip[3[.7]] install -r requirements.txt`\n* Ensure you have entered your server details and name into `servers.json` (take a copy from `servers.json.example`)\n    * This should be the `IP` and the `port`.\n    * If you have set authentication for MADmin, ensure you add `username` and `password` to each of the servers in `servers.json`\n* Create `config.ini` from `config.ini.example` and populate the value which says `REQUIRED`\n    * Optional config\n        * `duration_before_alert` this is the number of minutes that MAD has not received any proto data for, before it raises an alert (Default: 20 minutes)\n        * `delay_between_checks` this is the amount of time that MADevice does to sleep before checking the status of the devices again (Default: 20 minutes)\n\n## Run\n\n```\n\u003cPATH_TO_VENV_BIN\u003e/python[3[.7]] main.py\n```\n\n### No Data Alert\nWhen running it will check the last received time for data and then if it is more than 20 minutes (or the values set in `alert_recheck_time`) in the past it will post a message to the channel set by `webhook` in `servers.json`\n\n![alert image](images/alert.png)\n\n### On-Demand Status (`!status`)\n\nIf you type `!status` in the channel set by `status_channel_id` in servers.json  You get an on-demand update across all servers (set in servers.json) and posted into Discord rather than opening up multiple browsers to see the data.\n\n![status image](images/status.png)\n\n\n\n## FAQ\n\n### - How to get `status_channel_id`?\n\nEnable developer mode -\u003e https://support.discordapp.com/hc/en-us/articles/206346498-Where-can-I-find-my-User-Server-Message-ID-\n\nThen go to the channel you want the messages to be posted in. Right-click and select `Copy ID` and paste in `servers.json`\n\n### - How to create Discord token?\n\nhttps://github.com/reactiflux/discord-irc/wiki/Creating-a-discord-bot-\u0026-getting-a-token\n\n### -  How do I add my Discord token to my server?\n\nhttps://www.techjunkie.com/add-bots-discord-server/\n\n### - Why do i not get notifications for new alerts\n\nIf a server has over 2500 members this limits the notifications and you won't get a push notification. To resolve this create a role (assign the relevant users to this role) and add the role id to the corresponding server in servers.json - see the example json. \n\n\u003e Make sure the role has \"Allow anyone to @mention this role\" enabled otherwise it wont trigger a notification\n\n### - `Ctrl + C` does not stop MADevice\nAs of Python 3.6, the interpreter handles SIGINT generated by Ctrl+C differently for Linux and Windows.\n\nSee the below examples for how to stop the processes:\n#### Mac OS and Linux\n\n`Ctrl + Shift + \\` or `Ctrl + \\`\n\n#### Windows\n\nGeneral: `Ctrl+Break`\n\nDell: `Ctrl+Fn+F6` or `Ctrl+Fn+S`\n\nLenovo: `Ctrl+Fn+F11` or `Ctrl+Fn+B`\n\nHP: `Ctrl+Fn+Shift`\n\nSamsung: `Fn+Esc`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeorgeherby%2Fmadevice","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgeorgeherby%2Fmadevice","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgeorgeherby%2Fmadevice/lists"}