Documentation menu

Automation

Send managed email and Telegram notifications.

Notification channels subscribe to workspace events without requiring your own webhook receiver. Availability is controlled by the plan’s configured channel allocation.

Routes

GET/notificationsNotification access required
POST/notificationsWorkspace channel limit applies
PATCH/notifications/:id
DELETE/notifications/:id
typescript
import { veritas } from "@/lib/veritas";

const created = await veritas<{ channel: { id: string } }>(
  "/notifications",
  {
    method: "POST",
    body: JSON.stringify({
      type: "TELEGRAM",
      label: "Operations",
      destination: "@operations_channel",
      events: ["payment_link.paid"],
    }),
  },
);

const channelId = created.channel.id;
const channels = await veritas("/notifications");

await veritas(`/notifications/${channelId}`, {
  method: "PATCH",
  body: JSON.stringify({
    events: ["payment_link.paid", "product.sold_out"],
  }),
});

await veritas(`/notifications/${channelId}`, {
  method: "DELETE",
});

Create a Telegram channel

json
{
  "type": "TELEGRAM",
  "label": "Operations",
  "destination": "@operations_channel",
  "events": ["payment_link.paid"]
}

Channel behavior

TypeConfiguration
EMAILRecipient address and subscribed events.
TELEGRAMChat identifier and subscribed events.

Only active channels count toward the configured limit. Existing records are preserved when a limit is lowered.