@@ -8,10 +8,10 @@ Get notified when your Workers Builds complete, fail, or are cancelled. This tem
88
99## Features
1010
11- - 🔔 Real time notifications for build success, failure, and cancellation
11+ - 🔔 Real- time notifications for build success, failure, and cancellation
1212- 🔗 Works with any webhook (Slack, Discord, custom endpoints)
13- - 📋 Includes build details: project name, status, duration , and other metadata
14- - 📜 Optional build logs , preview URL, and live deployment URL fetched via Cloudflare API
13+ - 📋 Includes build details: project name, branch, commit , and author
14+ - 📜 Smart error extraction for failed builds , preview URL and live deployment URL for successful builds
1515
1616## How It Works
1717
@@ -112,8 +112,10 @@ Modify the payload format in `src/index.ts` to match your webhook's expected for
112112### 4. Create a Cloudflare API Token
113113
1141141 . Go to [ Cloudflare API Tokens] ( https://dash.cloudflare.com/profile/api-tokens )
115- 2 . Click ** Create Token**
116- 3 . Select ** Edit Cloudflare Workers** template
115+ 2 . Click ** Create Token** → ** Create Custom Token**
116+ 3 . Add the following permissions:
117+ - ** Workers Builds Configuration** : Read
118+ - ** Workers Scripts** : Read
1171194 . Click ** Continue to summary** → ** Create Token**
1181205 . Copy the token
119121
@@ -161,8 +163,8 @@ Subscribe your queue to Workers Builds events.
161163``` bash
162164wrangler queues subscription create builds-event-subscriptions \
163165 --source workersBuilds.worker \
164- --events build.started,build. succeeded,build.failed \
165- --worker-name [YOUR WORKER NAME HERE]
166+ --events build.succeeded,build.failed \
167+ --worker-name < YOUR_CONSUMER_WORKER_NAME >
166168```
167169
168170> For more details, see [ Event Subscriptions Documentation] ( https://developers.cloudflare.com/queues/event-subscriptions/ )
@@ -196,9 +198,10 @@ Trigger a build on any worker in your account. You should see a notification in
196198| ------------------------------- | ----------------- |
197199| ✅ Build succeeded (production) | Live Worker URL |
198200| ✅ Build succeeded (preview) | Preview URL |
199- | ❌ Build failed | Build logs inline |
200- | ⚠️ Build cancelled | Build logs inline |
201- | 🚀 Build started | Build started |
201+ | ❌ Build failed | Error message |
202+ | ⚠️ Build cancelled | Cancellation note |
203+
204+ > ** Note:** Build started/queued events are acknowledged but do not send notifications.
202205
203206---
204207
@@ -249,10 +252,10 @@ Trigger a build on any worker in your account. You should see a notification in
249252
250253### Environment Variables
251254
252- | Variable | Description |
253- | ---------------------- | ----------------------------------------------------- |
254- | ` SLACK_WEBHOOK_URL ` | Webhook URL (Slack, Discord, or custom) |
255- | ` CLOUDFLARE_API_TOKEN ` | API token with Workers Builds and Scripts read access |
255+ | Variable | Description |
256+ | ---------------------- | --------------------------------------------------------------------------- |
257+ | ` SLACK_WEBHOOK_URL ` | Webhook URL (Slack, Discord, or custom) |
258+ | ` CLOUDFLARE_API_TOKEN ` | API token with Workers Builds Configuration: Read and Workers Scripts: Read |
256259
257260### Queue Settings (wrangler.jsonc)
258261
@@ -279,7 +282,7 @@ The queue must be created before deploying. See [Step 1: Create a Queue](#1-crea
279282### "Invalid token" error in logs
280283
281284- Verify ` CLOUDFLARE_API_TOKEN ` is set in worker settings
282- - Ensure token has correct permissions (Edit Cloudflare Workers template )
285+ - Ensure token has correct permissions (Workers Builds Configuration: Read, Workers Scripts: Read )
283286
284287### URLs not appearing
285288
0 commit comments