Open dskillin opened 9 months ago
curl -d "Somebody: This is a whisper." http://ntfy.*********.org/xyz123abc435
{"id":"Emlhav773eJW","time":1695575324,"expires":1695618524,"event":"message","topic":"xyz123abc435","message":"Somebody: This is a whisper."}
Plugin Description
Offers the ability to send to NTFY. This is a free service (which can be self hosted) that will send notifications to a desktop/phone/watch.
More info
The process is simple. There are public servers, private can be stood up as well with docker or bare metal. A curl is sent to the server (unauthenticated) that is used to send a subscribed device a notification.
Suggest the following:
Create a unique ID -- this would be used to subscribe devices and make false notifications difficult. Offer a default to a public or hosted NTFY service, and the ability to set your own server.
Use regex matching, and/or default options to send the ping.
Received Tell, Linkshell activity, etc.
Similar to the Discord plugin, this would then take the message, or user defined string -- and send it to the NTFY service.
Command line the send looks like this:
curl -d "This is my message." http://ntfy.server.com/subscribed-topic-here
in PHP:
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,"http://ntfy.server.com/subscribed-topic-here"); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, "This is my message.");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$server_output = curl_exec($ch);
curl_close($ch);
The applications for this are broad. Recieve notifications on certain types of chat, when a FC member logs in. Ready checks. Duty pops (how many of us alt-tab). Messaging can be generic (user defined) or the string from the game.
An additional item might be allow an alternate ID to be sent to. IE all members of a FC or group subscribe to a particular ID. Multiple people would get the alert. Certain strings, or a message from the "leader" could trigger the event to send to that ID.
Original Requestor
No response
Request Terms