Javascript Event Listener

If you display the actionURL over your web app (<iframe>), Tap&Sign can send a message to your Javascript through Javascript Event Listener when a recipient performs an action.

First, you need to set callbackEvent while creating the envelope:


    "callbackEvent": "myCustomEvent",

Here is an example code that you can leverage for your own frontend (Javascript etc) code:

window.addEventListener("message", function (event) {
  //Let's assume that you set "callbackEvent" as "myCustomEvent"
  if ( && === "myCustomEvent") { "xyzz" //The value of "callbackData" you sent via API {id: "0000-000-000", ...} //Details of envelope object "closeIFrame" // The value of callbackEvent you sent via API "ENVELOPE_SENT" // "ENVELOPE_SENT" or "RECIPIENT_VIEWED" or "RECIPIENT_SIGNED" or "ENVELOPE_COMPLETED" or "ENVELOPE_REJECTED" or "ENVELOPE_DELETED"

Last updated