Skip to content
Français

StandardWebhookOptions

import type { StandardWebhookOptions } from "@elie-laloum/outpost";
  • secretRequired
    TriggerSecret
    whsec_ secret verifying webhook-signature, or a callback returning every currently accepted secret (old and new during a rotation). An empty string throws at creation; a callback that fails or returns nothing, or a secret without the whsec_ prefix, denies requests.
  • toleranceMsOptional
    number | undefined
    Accepted clock difference for the request timestamp, in milliseconds; defaults to 300000 (5 minutes). A value that is not a positive integer throws at creation.
  • sourceOptional
    string | undefined
    Name reported in TriggerEvent.source; defaults to standard.
export interface StandardWebhookOptions {
  /** `whsec_` secret verifying Standard Webhooks signatures. */
  readonly secret: TriggerSecret;
  readonly toleranceMs?: number;
  /** Event source name; defaults to `standard`. */
  readonly source?: string;
}