signWebhookPayload
function signWebhookPayload( payload: string, secret: string, timestamp?: string): WebhookSignature;Defined in: src/mft/webhooks.ts:82
Computes the HMAC-SHA256 signature for a webhook payload.
Parameters
Section titled “Parameters”| Parameter | Type | Description |
|---|---|---|
payload | string | Raw JSON string of the webhook body. |
secret | string | Shared secret. |
timestamp | string | Optional fixed timestamp. Defaults to new Date().toISOString(). |
Returns
Section titled “Returns”The signature parts that should be included on the request.