@shortcut/client
    Preparing search index...

    Function verifyShortcutWebhookSignature

    • Verifies a Shortcut webhook signature in constant time using WebCrypto, which is available on Node.js 20+, Cloudflare Workers, Deno, and Bun.

      Parameters

      • secret: string

        The agent app's webhook signing secret.

      • rawBody: string | Uint8Array<ArrayBufferLike>

        The exact request bytes. Passing a re-serialized string only works when it matches the original bytes, so prefer the raw body.

      • signature: string | null | undefined

        The Payload-Signature header value.

      Returns Promise<boolean>

      false for a missing, malformed, or mismatched signature.