{"id":35013611,"url":"https://github.com/mozanunal/mqtt_decorator","last_synced_at":"2026-04-24T15:31:57.139Z","repository":{"id":45562933,"uuid":"264707171","full_name":"mozanunal/mqtt_decorator","owner":"mozanunal","description":"mqtt_decorator is a decorator module that converts MQTT subscriptions and messages to a flask like API.","archived":false,"fork":false,"pushed_at":"2021-12-08T14:10:27.000Z","size":51,"stargazers_count":2,"open_issues_count":8,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-28T18:53:40.506Z","etag":null,"topics":["converts-mqtt-subscriptions","flask","mqtt-decorator"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mozanunal.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-05-17T16:14:25.000Z","updated_at":"2025-12-26T22:30:21.000Z","dependencies_parsed_at":"2022-09-05T10:00:42.111Z","dependency_job_id":null,"html_url":"https://github.com/mozanunal/mqtt_decorator","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/mozanunal/mqtt_decorator","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mozanunal%2Fmqtt_decorator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mozanunal%2Fmqtt_decorator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mozanunal%2Fmqtt_decorator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mozanunal%2Fmqtt_decorator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mozanunal","download_url":"https://codeload.github.com/mozanunal/mqtt_decorator/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mozanunal%2Fmqtt_decorator/sbom","scorecard":{"id":661907,"data":{"date":"2025-08-11","repo":{"name":"github.com/mozanunal/mqtt_decorator","commit":"5905e31776b17b808ec1cc10502ac61b9c2daa25"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.4,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/8 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/autopep8.yml:1","Warn: no topLevel permission defined: .github/workflows/pylint.yml:1","Warn: no topLevel permission defined: .github/workflows/pytest.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/autopep8.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/mozanunal/mqtt_decorator/autopep8.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/autopep8.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/mozanunal/mqtt_decorator/autopep8.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pylint.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/mozanunal/mqtt_decorator/pylint.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pylint.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/mozanunal/mqtt_decorator/pylint.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pytest.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/mozanunal/mqtt_decorator/pytest.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pytest.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/mozanunal/mqtt_decorator/pytest.yml/master?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/autopep8.yml:19","Warn: pipCommand not pinned by hash: .github/workflows/autopep8.yml:20","Warn: pipCommand not pinned by hash: .github/workflows/autopep8.yml:21","Warn: pipCommand not pinned by hash: .github/workflows/pylint.yml:19","Warn: pipCommand not pinned by hash: .github/workflows/pylint.yml:20","Warn: pipCommand not pinned by hash: .github/workflows/pylint.yml:21","Warn: pipCommand not pinned by hash: .github/workflows/pytest.yml:19","Warn: pipCommand not pinned by hash: .github/workflows/pytest.yml:20","Warn: pipCommand not pinned by hash: .github/workflows/pytest.yml:21","Info:   0 out of   6 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   9 pipCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: GNU General Public License v3.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 27 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-21T16:27:43.885Z","repository_id":45562933,"created_at":"2025-08-21T16:27:43.885Z","updated_at":"2025-08-21T16:27:43.885Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32228958,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-24T13:21:15.438Z","status":"ssl_error","status_checked_at":"2026-04-24T13:21:15.005Z","response_time":64,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["converts-mqtt-subscriptions","flask","mqtt-decorator"],"created_at":"2025-12-27T05:07:56.523Z","updated_at":"2026-04-24T15:31:57.121Z","avatar_url":"https://github.com/mozanunal.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# mqtt_decorator\n[![autopep8](https://github.com/mozanunal/mqtt_decorator/actions/workflows/autopep8.yml/badge.svg)](https://github.com/mozanunal/mqtt_decorator/actions/workflows/autopep8.yml)\n[![pylint](https://github.com/mozanunal/mqtt_decorator/actions/workflows/pylint.yml/badge.svg)](https://github.com/mozanunal/mqtt_decorator/actions/workflows/pylint.yml)\n[![pytest](https://github.com/mozanunal/mqtt_decorator/actions/workflows/pytest.yml/badge.svg)](https://github.com/mozanunal/mqtt_decorator/actions/workflows/pytest.yml)\n\nmqtt_decorator is a decorator module which converts mqtt subscriptions and messages to a [Flask](https://flask.palletsprojects.com/en/1.1.x/) like api.\n\n### Installing\n\nThe package can be installed via pip\n```\npip install mqtt_decorator\n```\n\n### Demo\n\n```python\nfrom mqtt_decorator import MqttDecorator\nimport paho.mqtt.client as mqtt\n\n# you can specify all \n# paho mqtt client options\n# such as websocket connections or\n# tls connections\nmqttc = mqtt.Client(clean_session=True)\napp = MqttDecorator(mqttc)\n\n@app.route(\"$SYS/\u003cbroker\u003e/\u003ctype\u003e\")\ndef broker_url_params(msg, broker, type):\n    print(\"---broker_url_params\", msg.topic, msg.payload)\n    print(\"--broker\", broker)\n    print(\"--type\", type)\n\n@app.route(\"$SYS/broker/version\")\ndef version(msg):\n    print(\"---version\", msg.topic, msg.payload)\n\n@app.route(\"$SYS/broker/uptime\")\ndef uptime(msg):\n    print(\"---uptime\", msg.topic, msg.payload)\n\n\nif __name__ == \"__main__\":\n    app.run( \"mqtt.eclipse.org\", 1883 )\n\n```\n\n\n### Development\n\nIn this repo issue based development is active. For any problems or new enhancements please open a issue.\n\nCreate virtual environment (It should be done only for first installation)\n\n```\nconda create -n mqtt_decorator python=3.8\n```\n\nActivate virtual environment\n```\nconda activate mqtt_decorator\n```\n\nInstall this package\n```\npip install -e .\n```\n\nAutopep8 is used for formatting.\n\n```\nautopep8 -r -i mqtt_decorator test\n```\n\nPylint is used for linting.\n```\npylint mqtt_decorator\n```\n\n### Docs\n\nfor the first time\n```\nsphinx-apidoc -F mqtt_decorator -o docs/source\n```\n\njust update the auto docs\n```\nsphinx-apidoc -f mqtt_decorator -o docs/source\n```\n\n### Deployment\n\nThe following 2 commands are required to deploy over pypi.\n```\npython setup.py sdist bdist_wheel\ntwine upload --repository-url https://upload.pypi.org/legacy/ dist/*\n```\n\n### Licence\nGPL\n\n### Acknowledges\nThis package is developed using\n- Python \u003c3\n- Paho-Mqtt\nHeavily inspired from\n- [Flask](https://flask.palletsprojects.com/en/1.1.x/)\n\n### Contributors\n- [mozanunal](https://github.com/mozanunal)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmozanunal%2Fmqtt_decorator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmozanunal%2Fmqtt_decorator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmozanunal%2Fmqtt_decorator/lists"}