Embedding sign link in an Iframe

You can generate the embedded signing link by referring to this article Get embedded signing link and embed that link into your application using Iframe.

Please refer to the below example code snippet to embed the signing link into an Iframe.


<iframe src="https://app.boldsign.com/document/sign/?documentId=17882f5a-xxxx-xxxx-xxxx-ce5737756339s_dyU07s_hkU07;dfeab145-xxxx-xxxx-xxxx-d705b85823c8" style="width:100%;height:100%"/>

Client side events

Client side events are special events that are triggered from the embedded sign page to host/parent (Your website).

There are currently 6 events available and they are listed below.

onDocumentSignedThis event will be triggered after the signer successfully completes the signing process of the document.
onDocumentSigningFailedThis event will be triggered if any failure occurs while the signer completes the signing process of the document.
onDocumentReassignedThis event will be triggered after the signer successfully completes the reassigning process of the document.
onDocumentReassigningFailedThis event will be triggered if any failure occurs while the signer completes the reassigning process of the document.
onDocumentDeclinedThis event will be triggered after the signer successfully completes the declining process of the document.
onDocumentDecliningFailedThis event will be triggered if any failure occurs while the signer completes the declining process of the document.

Please refer to the below code snippet for handling this event in your application.

Usage

<script>
    window.addEventListener("message", function (params) {
        if (params.origin !== "https://app.boldsign.com") {
            return;
        }

        switch (params.data.action) {
            case "onDocumentSigned":
                // handle document signing success 
                break;
            case "onDocumentSigningFailed":
                // handle document signing failure
                break;
            case "onDocumentReassigned":
                // handle document reassigning success
                break;
            case "onDocumentReassigningFailed":
                // handle document reassigning failure
                break;
            case "onDocumentDeclined":
                // handle document declining success
                break;
            case "onDocumentDecliningFailed":
                // handle document declining failure
                break;
            default:
                break;
        }
    });
</script>

Webhooks

If you've subscribed to the Document Signed, your URL will receive a webhook request once the signer completes the signing process of the document. You can synchronize the document status, signer's signing status, and any document configuration changes made within the embedded sign in your application/DB.

Once your signer has signed the document, you can expect to download the completed document at your end. But the final PDF generation will take some time. So, you can subscribe to our Document Completed event, which will be triggered after everyone has signed the document and final PDF file has been generated.