Page tree
Skip to end of metadata
Go to start of metadata

If you want to take a look at the source code of a webapp displaying individual and bulk signature integration with Blobfish Signer immediately, download from Downloads.

See Bulk signature integration too.

To complete the most basic individual signature integration with Blobfish Signer in your web application (for bulk signature go to Bulk signature integration), you need to review the following steps. It is worth noting that you are not constrained to any programming language or server technology, but code examples are shown in Java JSP.

1. Prepare download and upload URLs

Blobfish Signer takes a very simplistic approach related the URLs it will use for downloading the PDF to be signed, as well as the one it will use for uploading the signed PDF after the signature procedure gets completed. Blobfish Signer is not aware of any session cookies managed by the browser, because of that, you will maybe require to pass access tokens as request parameters in the URL.

Blobfish Signer expects to receive absolute URLs for downloading and uploading the PDF document, these are examples of these URLs. 

  • Download URL:
  • Upload URL:

In Java JSP these URLs could be composed with the following code:

    String requestURL = request.getRequestURL().toString();
    String baseURL = requestURL.substring(0, requestURL.lastIndexOf("/"));
    String downloadURL = baseURL + "/";    
    String uploadURL = baseURL + "/";    

As indicated in Standards based, Blobfish Signer works on the basis of an URI Scheme, namely, the bsign URI Scheme. What you need to configure a bsign action is a regular HTML hyperlink like the following where the downloadURL and uploadURL both need to be URL encoded:

<a href="bsign:?from=<downloadURL>&to=<uploadURL>">Sign</a>

For the URLs shown in the previous step, the resulting HTML would be:

<a href="bsign:?">Sign</a>

In Java JSP, this hyperlink could be composed like this:

<a href="<c:url value="bsign:">
               <c:param name="from" value="<%=downloadURL%>"/>
               <c:param name="to" value="<%=uploadURL%>"/>

On this page:

Full JSP example

Note that this example requires JSTL, which you may need to add to your project dependencies.

<%@ taglib prefix="c" uri="" %>
<!DOCTYPE html>
    String requestURL = request.getRequestURL().toString();
    String baseUrl = requestURL.substring(0, requestURL.lastIndexOf("/"));
    String downloadURL = baseUrl + "/";
    String uploadURL = baseUrl + "/";
<a href="<c:url value="bsign:">
                   <c:param name="from" value="<%=downloadURL%>"/>
                   <c:param name="to" value="<%=uploadURL%>"/>
Write a comment…