liveblocks-webhooks
БесплатноЗапускает вложенные скриптыНе проверенReceive and verify Liveblocks webhooks, which follow the Standard Webhooks specification. Use when setting up a Liveblocks webhook endpoint, getting the…
от hookdeck★ 104 звезды на GitHubОб этом скилле
Liveblocks Webhooks
Liveblocks is realtime collaboration infrastructure: rooms, Storage, Yjs, Comments and notifications. It POSTs a signed JSON event to each endpoint you add in the project's Webhooks dashboard, for all events or a filtered subset. Signatures follow Standard Webhooks, so each delivery carries webhook-id, webhook-timestamp and webhook-signature headers.
When to Use This Skill
- How do I receive Liveblocks webhooks?
- How do I verify a Liveblocks webhook signature (
webhook-signature)? - Where do I find my Liveblocks webhook secret (
whsec_...)? - How do I handle
userEntered,storageUpdated,ydocUpdated,commentCreatedorthreadCreatedevents? - How do I send emails from Liveblocks
notificationevents? - Why is my Liveblocks webhook verification failing, or failing only on retries and replays?
Verification (core)
| Header | Value |
|---|---|
webhook-id |
Identifies the message and is signed. The body has no event id, and the docs don't say whether a retry reuses this one |
webhook-timestamp |
Unix seconds |
webhook-signature |
One or more space-separated v1,<base64> entries |
Signed content is {webhook-id}.{webhook-timestamp}.{raw body}, HMAC-SHA256, base64 output. The key is the base64-decoded part of the whsec_... secret after the prefix. Compare against every v1, entry; ignore other versions. If webhook-id is absent, read svix-id, svix-timestamp and svix-signature instead. The examples use the standardwebhooks library (npm and PyPI):
const { Webhook } = require('standardwebhooks');
// rawBody: exact request body (Buffer or string), NOT re-serialised JSON
function verifyLiveblocks(rawBody, headers, secret = process.env.LIVEBLOCKS_WEBHOOK_SECRET) {
const p = headers['webhook-id'] ? 'webhook' : 'svix'; // fall back to the svix-* names
new Webhook(secret).verify(rawBody, {
'webhook-id': headers[`${p}-id`],
'webhook-timestamp': headers[`${p}-timestamp`],
'webhook-signature': headers[`${p}-signature`],
}, { jsonParse: false }); // throws on a bad signature or stale timestamp → respond 401
}
The library always enforces a fixed 5-minute timestamp window. Hookdeck retries and replays resend the original webhook-timestamp, so the library rejects them once they are more than 5 minutes old. If you receive through Hookdeck and need late retries to pass, use the manual verifier in references/verification.md, which can drop or widen the window. In Express, read the body with express.raw({ type: '*/*' }) so any content type verifies, and parse JSON only after the check.
Liveblocks' own @liveblocks/node package offers new WebhookHandler(secret).verifyRequest({ headers, rawBody }), which verifies and returns a typed event. See references/verification.md for when to pick it.
For complete handlers with tests, see examples/express/, examples/nextjs/, examples/fastapi/.
Event Type and Payload
Every body is the same { type, data } envelope. The event name is the camelCase top-level type, and the event fields sit under data:
{
"type": "commentCreated",
"data": {
"projectId": "my-project-id",
"roomId": "my-room-id",
"threadId": "my-thread-id",
"commentId": "my-comment-id",
"createdAt": "2021-10-06T01:45:56.558Z",
"createdBy": "my-user-id"
}
}
The notification event is refined by data.kind: thread, textMention, or a custom $-prefixed kind you trigger from your server.
Common Event Types
| Event | Fired when |
|---|---|
userEntered / userLeft |
A user connects to or disconnects from a room (numActiveUsers is the count after the change; not throttled) |
storageUpdated |
A user writes to Storage (throttled at 60 s, so not sent for every write) |
ydocUpdated |
A user changes a Yjs document in a room (throttled at 60 s) |
roomCreated / roomDeleted |
A room is created (by API or by a user connecting to a missing room) or deleted |
commentCreated / commentEdited / commentDeleted |
A comment changes |
commentReactionAdded / commentReactionRemoved |
An emoji reaction is added to or removed from a comment |
commentMetadataUpdated |
A comment's metadata is updated |
threadCreated / threadDeleted |
A thread is created, or deleted (all comments removed or deleted manually) |
threadMetadataUpdated |
A thread's metadata is updated |
threadMarkedAsResolved / threadMarkedAsUnresolved |
A thread's resolved state changes |
notification |
A user was mentioned or replied to and hasn't seen it; sent 30 minutes after the activity by default (configurable in project settings), once per enabled channel (data.channel) |
These 18 are
Установить liveblocks-webhooks в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл liveblocks-webhooks?
Receive and verify Liveblocks webhooks, which follow the Standard Webhooks specification. Use when setting up a Liveblocks webhook endpoint, getting the whsec_ signing secret, debugging webhook-id / webhook-timestamp / webhook-signature verification, or handling events like userEntered, storageUpdated, ydocUpdated, commentCreated, threadCreated and notification.
Как установить скилл liveblocks-webhooks?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл liveblocks-webhooks запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic