BoldSign Site Logo

Embed send document within your app

Fill in for the Demo
Info-icon Try filling out the below form details, sending the document, and signing it. This will provide you with a better understanding of how the signing process works.
ID of a template created in BoldSign Web App
Code Reference The embedded sign request allows the signers to sign the document within your website or mobile app using an iFrame, popup window, or new tab.
Code flow:
Step 1
On the form submission, create the new document from the template using Send document from Template API. It will return the document Id which we can use to generate the embedded signing link.
curl -X 'POST' \ 'https://api.boldsign.com/v1/template/createEmbeddedRequestUrl?templateId=9506074e-fe2d-4328-a03e-be1cea9bc6ad' \
        -H 'accept: application/json' \
        -H 'X-API-KEY: { your API key }' \
        -H 'Content-Type: application/json;odata.metadata=minimal;odata.streaming=true' \
        -F 'DisableEmails=true'
        -d '{}` 
                    
Step 2
Use the following code by updating the received document ID from the previous step to generate the embedded signing URL.
curl -X GET 'https://api.boldsign.com/v1/document/getEmbeddedSignLink?documentId={ document Id }&signerEmail={ Enter Signer Email }&redirectUrl={ redirect URL to app once signed }' \ 
         -H 'X-API-KEY: { your API key }' \
                    
Step 3
Once the embedded signing URL is generated, load the URL in iFrame inside your App using the following code.
<iframe src="https://app.boldsign.com/document/embed/?documentId=17882f5a-xxxx-xxxx-xxxx-ce5737756339s_dyU07s_hkU07;dfeab145-xxxx-xxxx-xxxx-d705b85823c8" style="width:100%;height:100%"/>