janderedev 2b488ca15a | ||
---|---|---|
assets | ||
.gitignore | ||
README.md | ||
index.js | ||
package-lock.json | ||
package.json |
README.md
Cloudflare Firewall Discord Webhook
yes.
Setup
Step 1: Read source code because I'm too lazy to write proper instructions
Step 2: Get an API key
Go to https://dash.cloudflare.com/profile/api-tokens and create a new token, with the following permissions:
Step 3: Set environment variables
Create a file called .env
in the project root:
CF_TOKEN=The previously created token
WEBHOOK_ID=The ID of the Discord Webhook
WEBHOOK_SECRET=The Webhook's token
CF_ZONES_BLACKLIST=(Optional) Comma-seperated list of domains (Zone IDs!) that should not be monitored.
Note that I have no idea if CF_ZONES_BLACKLIST
even works simply because I'm too lazy to test it.
Step 4: Run it
npm install
and node .
yada yada ya