Webhook deliveries log — Table block
Protable-webhook-deliveries-log · for app, settings, developers pages
Webhook deliveries log
An endpoint’s page in developer settings: a dense table of deliveries (status, event, HTTP code, time, duration), each row opening in place on its request, its response and "Retry" when it failed.
Documentation
Installation
One command copies the block into your project with the shadcn CLI (the registry is set once: Installation).
pnpm dlx shadcn-vue@latest add @trame/table-webhook-deliveries-logUsage
Its demo data, shortened (Using blocks).
<script setup lang="ts">
import TableWebhookDeliveriesLog from '@/components/trame/blocks/table/table-webhook-deliveries-log.vue'
const props = {
endpoint: {
url: "https://api.harbor-lane.example/hooks/billing",
description: "Billing sync for the ledger",
status: "active"
},
deliveries: [
{
id: "dl_0c41",
event: "invoice.paid",
status: "failed",
code: 500,
at: "Mar 4, 10:22:07",
duration: "2.4 s",
attempt: 3,
request: "{\n \"id\": \"evt_0c41\",\n \"type\": \"invoice.paid\",\n \"created\": 1772619727,\n \"data\": {\n \"object\": {\n \"id\": \"inv_0c41\",\n \"customer\": \"cus_8QwL2m\",\n \"amount_paid\": 48000,\n \"currency\": \"usd\",\n \"status\": \"paid\"\n }\n }\n}",
response: "HTTP/1.1 500 Internal Server Error\ncontent-type: text/html\n\n<html><body><h1>500</h1><p>Upstream ledger service unavailable.</p></body></html>"
},
{
id: "dl_0c40",
event: "invoice.created",
status: "succeeded",
code: 200,
at: "Mar 4, 10:21:55",
duration: "182 ms",
attempt: 1,
request: "{\n \"id\": \"evt_0c40\",\n \"type\": \"invoice.created\",\n \"created\": 1772619727,\n \"data\": {\n \"object\": {\n \"id\": \"inv_0c40\",\n \"customer\": \"cus_8QwL2m\",\n \"amount_paid\": 48000,\n \"currency\": \"usd\",\n \"status\": \"paid\"\n }\n }\n}",
response: "{\n \"received\": true\n}"
}
],
filters: [
{
label: "All",
action: "deliveriesAll",
current: true,
count: 128
},
{
label: "Succeeded",
action: "deliveriesSucceeded",
current: false,
count: 119
}
],
retry: {
label: "Retry",
action: "retryDelivery"
},
more: {
label: "Older deliveries",
action: "olderDeliveries"
},
title: "Recent deliveries"
}
</script>
<template>
<TableWebhookDeliveriesLog v-bind="props" />
</template>Props
Each prop says who changes it: Words, Picture, Action, Design, Data.* required.
| Prop | Type | Description |
|---|---|---|
| endpoint* | Endpoint | the endpoint whose deliveries these are |
| deliveries* | Delivery[] | the deliveries to that endpoint, newest first, one page as the host answers it |
| filters | Filter[] | the host’s own filter links, e.g. "All", "Succeeded", "Failed"; the host answers each address with the matching page |
| retry | Retry | the retry offered on failed deliveries only; absent, the log is read-only |
| more | More | a link to older deliveries, e.g. "Older deliveries" |
| title | string | Wordsthe block’s heading, e.g. "Recent deliveries"; absent, the blocks’ own word for deliveries |
| options | Options | the block’s settings, read by every variant |
Endpoint endpoint · 3 props
| Prop | Type | Description |
|---|---|---|
| url* | string | Datathe endpoint’s address, without credentials, e.g. "https://api.example/hooks/billing" |
| description | string | Wordswhat the endpoint is for, in the host’s words, e.g. "Billing sync" |
| status | 'active' | 'disabled' | whether the host still sends events there: "active" or "disabled"; absent: not shown |
Delivery deliveries[] · 10 props
| Prop | Type | Description |
|---|---|---|
| id* | string | number | Datathe record’s id in the tool that answers it |
| event* | string | Wordsthe event that was sent, as the host names it, e.g. "invoice.paid" |
| status* | 'succeeded' | 'failed' | 'pending' | 'retrying' | how the delivery stands: "succeeded" the endpoint answered 2xx, "failed" it gave up or the last attempt failed, "pending" not sent yet, "retrying" a later attempt is scheduled |
| code | number | the HTTP status the endpoint answered, e.g. 500; absent: no answer (a timeout, a refused connection, not sent yet) |
| at* | string | Wordswhen it was sent, in the host’s words, e.g. "Mar 4, 10:22:07" |
| duration | string | Wordshow long the endpoint took to answer, in the host’s words, e.g. "182 ms" |
| attempt | number | which attempt this is, counting from 1 |
| nextRetry | string | Wordswhen the host tries again, in its words, e.g. "in 4 minutes" |
| request | string | Datathe body that was sent, as the host stored it (usually JSON), shown whole in monospace |
| response | string | Datathe body the endpoint answered, as the host stored it, shown whole in monospace |
Filter filters[] · 6 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordsthe link’s words, e.g. "See the collection" |
| action | string | Actiona named action of the page |
| record | Record<string, unknown> | Datathe record the action applies to, passed to the host with it, if any |
| url | string | Designan address outside the app |
| current | boolean | true: the filter shown now |
| count | number | how many deliveries the filter holds, as the host counts them |
Retry retry · 2 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordsthe retry button, e.g. "Retry" |
| action* | string | Actionsends a failed delivery again: posts `id`, the delivery’s id; hidden when the page lacks it |
More more · 4 props
| Prop | Type | Description |
|---|---|---|
| label* | string | Wordsthe link’s words, e.g. "See the collection" |
| action | string | Actiona named action of the page |
| record | Record<string, unknown> | Datathe record the action applies to, passed to the host with it, if any |
| url | string | Designan address outside the app |
Options options · 1 props
| Prop | Type | Description |
|---|---|---|
| mood | 'inverse' | 'brand' | 'warm' | 'tint' | string | a band of the page that redefines the theme surfaces inside it |
What it asks your app for
The block never knows your app: it asks it, through one context provided once, where its links lead, what its actions do, how a price reads and which words to say (The host context).
| Member | What it is for |
|---|---|
| href | the address an action leads to, or null to hide what leads there |
| act | runs a change (subscribe, add to cart, save) and answers { ok } or { ok: false, error } |
| can | whether the page has this action |
| Link | your router’s link component |
| cartCount | the cart badge’s number |
| cartDrawer | whether your app has a cart drawer |
| cartOpen | whether the cart drawer is open |
| label | your word for an interface key, or undefined to keep the block’s own |
The words it says itself, in English and French; label(key) replaces any of them:
| Key | English | French |
|---|---|---|
| newsletter.already | You are already subscribed. | Vous êtes déjà inscrit. |
| newsletter.done | Done: you are subscribed. | C’est noté : vous êtes inscrit. |
| newsletter.invalid | Check the email address. | Vérifiez l’adresse e-mail. |
| newsletter.tooMany | Too many attempts, try again in a moment. | Trop de tentatives, réessayez dans un moment. |
Features
- Every word in the server HTML
- Same markup in Vue and React
- Theme tokens only: every theme, light and dark
- Shows what you give it, invents nothing
- No motion; still under reduced motion
- Real buttons and links, a visible focus
- Asks your app through actions:
filters[],delivery.retry,more - Reads
webhookDeliveriesfrom your app
A table section, for app, settings, developers pages; it uses @lucide/vue, class-variance-authority, clsx, reka-ui, tailwind-merge.
Built with
The components this block is made of; each one installs on its own too.
More table blocks
- Resource totals: records whose amounts matter together: a footer with the selection count and the list’s own totals.
- Spreadsheet grid: Edit a dense table with a frozen first column and row selection, then save the edits in one go.
- Spreadsheet summary bar: Keep the selection count and numeric sum prominent above the editable grid, saved in one go.
- Stage rows track cards: fewer records each needing a next step: one card per record with a status sentence, the labelled track full width and the action beside it, filters in a rail.
- Stage rows track: many records followed at a glance (shipments, sales orders): a table whose progress column is a row of joined dots, an exception named in words.
- Stock levels filter rail: a long inventory narrowed often: filters in a left rail beside dense rows (a "Filters" sheet on a phone).
- Stock levels meter cards: a small catalogue checked by its pictures: a grid of compact cards, prices in two figures and the stock bar at the foot.
- Stock levels meter: a merchant scanning many lines at once: a table whose stock column is a short bar against the reorder point, with the state in words.