A simple Node.js script that forwards messages received from the OpenMHZ API to another endpoint.
git clone https://github.com/S1monlol/openmhzForward.git
cd openmhzForward
npm install
- Open the
index.js
file in a text editor. - Locate the
sendMessage
function. - Modify the
sendMessage
function according to your needs. You can customize the logic for processing and forwarding the received messages. - Save the changes to the
index.js
file.
Rename the config.example.json file to config.json. Open config.json and provide the following information:
{
"endpoint": "https://api.example.com",
"shortName": "phillytrs",
"Authorization": "Bearer wasd"
}