Webhook Notifications
Get notified on Slack, Discord, or any HTTPS endpoint when Vigil runs.
Configuration
Add a notifications section to your .vigil.yml in the repository root:
.vigil.yml
notifications:
on: failure # "failure" or "always"
urls:
- https://hooks.slack.com/services/T.../B.../xxx
- https://discord.com/api/webhooks/123/abcVigil sends a POST request to each URL with a JSON payload containing the repository name, PR number, confidence score, recommendation, and a link to the PR.
Trigger Modes
| Mode | When it fires |
|---|---|
failure | Only when the score indicates "Caution" or "Review needed" (score below 80). This is the default if you configure notifications without specifying a mode. |
always | Sends a notification on every PR analysis, regardless of score. |
Slack Setup
- Go to your Slack workspace and create an Incoming Webhook via the Slack API dashboard or by adding the Incoming Webhooks app to your workspace.
- Choose the channel where Vigil should post notifications and authorize the webhook.
- Copy the webhook URL. It will look like:
Slack webhook URL
https://hooks.slack.com/services/T00000000/B00000000/XXXXXXXXXXXXXXXXXXXXXXXX- Add the URL to your
.vigil.ymlundernotifications.urls.
Discord Setup
- Open your Discord server and go to Server Settings → Integrations → Webhooks.
- Click New Webhook, choose a name and channel, then click Copy Webhook URL.
- The URL will look like:
Discord webhook URL
https://discord.com/api/webhooks/123456789012345678/abcdefghijklmnop...- Add the URL to your
.vigil.ymlundernotifications.urls.
Limits
- Maximum 5 webhook URLs per repository.
- All URLs must start with
https://. Plain HTTP endpoints are rejected to protect your webhook secrets in transit. - Notifications are sent asynchronously after the PR comment is posted. A failed webhook delivery does not affect the Vigil run or the confidence score.