IRCWebHooks
Barry Renaming README file c75b43d (2 years, 4 months ago)diff --git a/README.md b/README.md new file mode 100644 index 0000000..e07e314 --- /dev/null +++ b/README.md @@ -0,0 +1,37 @@ +# IRC Web Hook Bot +This is a simple IRC bot that posts the content of POST requests it receives. + +It runs a small webserver, and connects to an IRC server. + +## How to install +Download the code, then run `make`, `sudo ./bot`. + +Root access is required to make use of low port numbers, but you can run the webserver on any port. + +If you want to change any settings, edit `src/config.h`, then run `make clean install` + +## How to use +By default the bot will join the channels specified in the config. +To get it to join more channels, private message the bot in the server and send `JOIN #channel`. + +You can also use `LEAVE #channel` to get it to leave. + +It will by default send notifications to all channels it is joined to. + +Only allowed users can control the bot from IRC. +You can specify users by an ident or a vhost in the config. +You may specify as many as you like by separating them with a comma + + + +Only want it to message one channel, or a specific user? + +Send the webhook to the channel name, e.g. `https://webhook.barryserver.net/channel`, or `https://webhook.barryserver.net/@Barry`. + +`@` specified that you want to message a user. + +## How to call a webhook +The bot reads from POST data, specifically the data sent in `content`. +This content is plaintext, not URL encoded. + +So, assuming your WEB_AUTH is set to "user:password", `curl -k -X POST -u user:password -d 'content=Hello, World!' https://webhook.barryserver.net/@Barry` will send `Hello, World!` directly to the user with the nick `Barry`.