Skip to content
SMS SDK
Esc
↑↓navigate↵open⌘Jpreview

Free tool · runs in your browser

SMS webhook signature verifier

Paste a delivery status or inbound SMS webhook from Twilio, Telnyx, Plivo or Vonage with your secret, and see whether the signature verifies and which check fails. Most failures come from a URL that differs from the one the provider signed, a body that was parsed and re-serialized, or the wrong secret.

Verifier

Provider

HMAC-SHA1 of the URL plus the sorted POST parameters, base64

Checked with verifyTwilioSignature(), verifyTelnyxSignature(), verifyPlivoSignatureV2() and verifyVonageSignature() from SMS SDK, in this tab. Your secret and the request never leave the page. Use a test secret or rotate a live one afterwards if you prefer. A text box turns CRLF line breaks into LF, so a raw body with CRLF line breaks can fail here and pass on your server.

How each provider signs SMS webhooks

Each provider proves a webhook came from it in a different way. The tool runs the same checks SMS SDK runs on your server.

ProviderHeaderWhat is signedSecret
TwilioX-Twilio-SignatureBase64 HMAC-SHA1 of the full URL plus every POST parameter, sorted by name. A JSON body is covered by bodySHA256 in the URL instead.Auth Token
Telnyxtelnyx-signature-ed25519, telnyx-timestampEd25519 signature of timestamp|body.Account public key
PlivoX-Plivo-Signature-V2 (or -Ma-V2), X-Plivo-Signature-V2-NonceBase64 HMAC-SHA256 of the URL without its query string, plus the nonce. The body is not covered.Auth Token (main account's for -Ma-V2)
Vonage Messages APIAuthorization: BearerAn HS256 JWT with an iat time and, when present, a payload_hash, the SHA-256 of the body.Signature secret

For Bandwidth, SMS SDK checks the Basic auth credentials on your callback. For Sinch, it checks Basic auth or an HMAC secret your Sinch account manager sets up. The tool doesn't cover them, and Webhook security covers them.

Why a webhook signature fails

The URL differs. Twilio and Plivo sign the URL they called. Behind a proxy or load balancer, your app can see http://, another host or another port. Verify against the public URL from the provider console, including Twilio's query string. In SMS SDK, pass it as publicUrl.

The body was parsed first. Telnyx and Vonage sign the exact bytes they sent. If a framework parses JSON and you re-serialize it, spacing and key order can change and the check fails. Read the raw body before anything parses it.

The secret is the wrong one. Twilio signs with the account's primary Auth Token, not an API key secret. Vonage signs with the signature secret from the dashboard, not the API secret. Telnyx needs the public key from the same account that owns the number.

The request is old. SMS SDK rejects a Telnyx timestamp or Vonage iat more than 300 seconds from now, so a captured request can't be replayed later. Turn the age check off above to test a saved request. Twilio and Plivo sign no timestamp, so deduplicate events instead, as Receive webhooks shows.

Verify webhooks in your code

Install SMS SDK with npm install @opencoredev/sms-sdk. Each provider has a parser that verifies the signature, then returns a normalized event, and throws WebhookSignatureError with a reason when the check fails:

import { parseTwilioWebhook, WebhookSignatureError } from "@opencoredev/sms-sdk/webhooks";

export async function POST(request: Request): Promise<Response> {
  try {
    const event = await parseTwilioWebhook({
      request,
      credentials: { authToken: process.env.TWILIO_AUTH_TOKEN! },
      publicUrl: "https://example.com/webhooks/sms",
    });
    console.log(event.type, event.dedupeKey);
    // Empty TwiML answers both status callbacks and inbound messages without a reply.
    return new Response("<Response></Response>", { headers: { "content-type": "text/xml" } });
  } catch (error) {
    if (error instanceof WebhookSignatureError) {
      console.warn("Rejected webhook:", error.reason);
      return new Response("Invalid signature", { status: 401 });
    }
    throw error;
  }
}

parseTelnyxWebhook(), parsePlivoWebhook() and parseVonageWebhook() work the same way with each provider's credentials. The Twilio, Telnyx, Plivo and Vonage guides show a full route with offline tests, and SMS delivery reports shows what to store from each event.