verify-trello-webhook

1.0.0 • Public • Published

verify-trello-webhook NPM version

Safely verify that a received webhook originated from Trello.

Uses crypto.timingSafeEqual(), so Node.js v6.6.0 (or newer) is required.

Installation

Install the package with NPM:

$ npm install verify-trello-webhook

Usage

Example:

import verifyTrelloWebhook from "verify-trello-webhook";
 
let signature = "LeCJzA5aHiwh4zcxLhY25TJSNg=";
let payload = JSON.stringify({ hello: "world" });
let secret = "secret";
let callbackUrl = "https://example.com/webhooks";
 
verifyTrelloWebhook(signature, payload, secret, callbackUrl); // Returns true if verification succeeds; otherwise, false.

Related

You may also be interested in verify-github-webhook, a similar package for GitHub webhook verification.

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 1.0.0
    0
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 1.0.0
    0

Package Sidebar

Install

npm i verify-trello-webhook

Weekly Downloads

0

Version

1.0.0

License

MIT

Last publish

Collaborators

  • lukehorvat