mqtt-restifier
v0.1.0-alpha.0
Published
Access MQTT messages through HTTP calls
Downloads
3
Readme
MQTT Restifier
Access MQTT messages through HTTP calls.
┌─────────────────────────────────────────────────────┐
│ mqtt-restifier │
│ │
┌─┴──────────────────────┐ ┌──────────────────────┴─┐
┌─────────┐ │ │ │ │ ┌─────────┐
│ │ │ │ │ │ │ │
│ MQTT │ │ │ │ │ │ HTTP │
│ Client │────────▶│ MQTT Broker │──────▶│ WebServer │───────▶│ Client │
│ │ │ │ │ │ │ │
└─────────┘ │ │ │ │ └─────────┘
│ │ │ │
└─┬──────────────────────┘ └──────────────────────┬─┘
└─────────────────────────────────────────────────────┘
publish({ GET:
topic: "/my/awesome/topic", http://host:port/my/awesome/topic
payload: { Response:
"timestamp": 1617800660341, {
"value": "OPEN" "timestamp": 1617800660341,
} "value": "OPEN"
}) }
Requirements
Node.js v14 LTS (14.15.1) or later.
Install & Usage
$ npm install -g mqtt-restifier
$ mqtt-restifier -c <PATH_TO_CONF_FILE>
Contributing
Contributions are very welcome and wanted.
To submit your custom hook, please make sure your read our CONTRIBUTING guidelines.
Before submitting a new merge request, please make sure:
- You have updated the package.json version and reported your changes into the CHANGELOG file
- make sure you run
npm test
andnpm build
before submitting your merge request.
Credits
This library is provided and sponsored by:
As part of our commitment to support and contribute to the open source community.
License
Licensed under MIT.