Hacker News new | ask | show | jobs
by binwiederhier 1557 days ago
I am on my phone so I can't contribute a PR right now, but here are tons of PHP examples: https://ntfy.sh/docs/publish/

Also check the other pages on the docs.

Here's one example:

   file_get_contents('https://ntfy.sh/mytopic', false, stream_context_create([
    'http' => [
        'method' => 'POST', // PUT also works
        'header' => 'Content-Type: text/plain',
        'content' => 'Backup successful '
    ]
   ]));
1 comments

Someone contributed a PR that replaced the PHP output with libcurl