Webhooks
Webhooks let Fluger tell your server when something happens on your account, for example when a video is ready, a schedule changes or a VOD item expires. Fluger sends an HTTPS POST with a JSON body to an address you choose, usually within about 30 seconds.
Webhooks are included in every paid plan.
Add an endpoint
- Open the profile menu and choose API & Integrations.
- In Webhooks, click New Endpoint.
- Enter the Endpoint URL (https). It must be a public https address.
- Under Events, keep All events or untick it and choose the events you want.
- Click Add Endpoint.
The endpoint's Signing secret is shown once. Copy it and store it with your server's settings; you need it to check that messages really come from Fluger.
Each endpoint is listed with its events, its status (On or Off) and its last delivery. From there you can see its Deliveries (the history of messages sent), Send Test to send a webhook.test event, Turn Off or Turn On, and delete it. Payload Format shows the exact fields of each message.
You can have up to 10 endpoints. You can also manage them through the API (/v1/webhooks).
What a message looks like
Each message is a JSON object with the event's id, its type, when it was created (UTC) and the event details in data. For example, the test event:
{
"id": "evt_aa84e62657434508959976da9365163d",
"type": "webhook.test",
"created": "2026-11-24T14:48:17Z",
"data": { "message": "Test event from Fluger", "endpointId": "…" }
}
Messages also carry the headers Fluger-Event-Type, Fluger-Event-Id, Fluger-Delivery-Id and Fluger-Signature. Use the event id to recognise an event you've already handled. Click Payload Format on the dashboard to see the fields of every event.
Events
| Event | Sent when |
|---|---|
video.created | a video is added |
video.ready | a video is ready to play |
video.failed | a video couldn't be processed |
video.broken | a video link that used to work stopped working (Fluger checks links regularly) |
video.deleted | a video is deleted |
schedule.item.created | a programme is added to a schedule |
schedule.item.deleted | a programme is removed from a schedule |
schedule.updated | a schedule changes |
vod.item.added | a video is added to a VOD category |
vod.item.removed | a video is removed from a VOD category |
vod.item.expired | a VOD item reached the end of its availability and was removed |
playback.error | a viewer's web player (your public channel page or an embed) couldn't play a video |
bandwidth.threshold | you reach 80, 90 or 100% of your monthly delivery limit |
webhook.test | you click Send Test |
Check the signature
Every message has a Fluger-Signature header:
Fluger-Signature: t=1795527600,v1=5f2b…
t is the time it was sent (Unix seconds). v1 is an HMAC-SHA256, in hex, of the text {t}.{raw request body}, using your endpoint's signing secret as the key. To check it:
- compute the HMAC over the raw body exactly as received, before parsing the JSON
- compare it with
v1using a constant-time comparison - reject messages whose timestamp is more than 5 minutes old
Node.js example
const crypto = require('crypto');
// rawBody: the request body as a Buffer or string, before JSON.parse
function isFromFluger(rawBody, header, secret) {
const parts = Object.fromEntries(header.split(',').map(p => p.split('=')));
const t = Number(parts.t);
if (!t || Math.abs(Date.now() / 1000 - t) > 300) return false;
const expected = crypto.createHmac('sha256', secret)
.update(`${t}.${rawBody}`).digest('hex');
const a = Buffer.from(expected), b = Buffer.from(parts.v1 || '');
return a.length === b.length && crypto.timingSafeEqual(a, b);
}
Python example
import hmac, hashlib, time
def is_from_fluger(raw_body: bytes, header: str, secret: str) -> bool:
parts = dict(p.split("=", 1) for p in header.split(","))
t = int(parts.get("t", "0"))
if abs(time.time() - t) > 300:
return False
expected = hmac.new(secret.encode(), f"{t}.".encode() + raw_body,
hashlib.sha256).hexdigest()
return hmac.compare_digest(expected, parts.get("v1", ""))
Retries and turning off
- Answer with a 2xx status quickly, then do any slow work afterwards. A response that isn't 2xx, or no response within 10 seconds, counts as a failure.
- Failed messages are retried after 1 minute, 5 minutes, 30 minutes, 2 hours, 6 hours and 12 hours.
- Redirects aren't followed, so use the final address of your endpoint.
- After 50 failures in a row the endpoint is turned off and you get an email. Fix your server, then click Turn On.
- The same event can arrive more than once. Keep track of the events you've already handled and skip duplicates.