This topic contains 6 replies, has 2 voices, and was last updated by  Sudipta 3 months, 3 weeks ago.

  • Author
    Posts
  • Participant
    Sudipta
    Member
    Member since: 10.01.2018
    Number of posts: 20

    Hello

    Can anybody please help is finding a way to specify a callback endpoint while creating eSignLive package using Java SDK?

    Thanks
    Sudipta

    Keymaster
    Haris
    Jedi Master
    Member since: 05.11.2015
    Number of posts: 1419

    Score

    0

    Hi Sudipta,

    What would be the reason for this? Callback notifications are on an account level and if you change the endpoint for every package, then you run the risk of missing a big chunk of them.


    Haris Haidary
    eSignLive Technical Evangelist
    Participant
    Sudipta
    Member
    Member since: 10.01.2018
    Number of posts: 20

    Score

    0

    We wanted to set the callback at package level so that we can setup custom query parameter (say, <callbackUrl?id=<Guid>) which will be unique for a package. We need this parameter (id) to be appended to the callback url so that we can uniquely identify the package in the response. We do not save the packageid in our DB. So, only way we can identify a package in callback is by the unique value of the parameter appended to callback url.

    We are using the following code to generate the package. We are expecting PackageBuilder to provide us a way to set the callback url while creating the package.

    Document document = new Document();
    document.addSignatures(signs);
    document.setContent(DatatypeConverter.parseBase64Binary(<base64filebytestream>);
    document.setName(“TestDocument”);
    document.setFileName(“TestDocument.pdf”);

    DocumentPackageSettings settings = DocumentPackageSettingsBuilder
    .newDocumentPackageSettings()
    .hideOwnerInPersonDropDown()
    .withoutDocumentToolbarDownloadButton()
    .withoutDialogOnComplete()
    .withoutCaptureText()
    .withDecline()
    .withoutInPerson()
    .withoutOptOut()
    .withoutOptOutOther()
    .withoutWatermark()
    .withoutDialogOnComplete()
    .withoutLanguageDropDown()
    .withCeremonyLayoutSettings(CeremonyLayoutSettingsBuilder.newCeremonyLayoutSettings()
    .withoutNavigator()
    .withoutGlobalNavigation()
    .withoutBreadCrumbs()
    .withoutSessionBar()
    .withoutTitle()
    .withoutIFrame()
    .withoutGlobalConfirmButton()
    .withoutGlobalDownloadButton()
    .withoutGlobalSaveAsLayoutButton()
    .withLogoSource(null))
    .build();

    PackageBuilder packageBuilder = newPackageNamed(“uSign Transaction ” + format.format(new Date()))
    .withSigner(newSignerWithEmail(email)
    .withCustomId(uSignId.toString())
    .withFirstName(signerFirstName)
    .withLastName(signerLastName));

    final DocumentPackage documentPackage = packageBuilder.withDocument(document).withSettings
    (settings).build();

    Keymaster
    Haris
    Jedi Master
    Member since: 05.11.2015
    Number of posts: 1419

    Score

    1

    The callback notification feature is on an account level. That cannot be changed. However, what you can do is store the parameter in the package as attributes. Hence, when you receive the callback notification, you simply use the package id returned by esignlive to retrieve the package attribute and match it with your application. Here’s a guide on how to add package attributes: https://developer.esignlive.com/guides/feature-guides/package-attributes/


    Haris Haidary
    eSignLive Technical Evangelist
    Participant
    Sudipta
    Member
    Member since: 10.01.2018
    Number of posts: 20

    Score

    0

    Thanks for the information Haris. It was really helpful. Can you also share an example of setting the callback url at account level?

    Regards
    Sudipta

    Keymaster
    Haris
    Jedi Master
    Member since: 05.11.2015
    Number of posts: 1419

    Score

    0

    Sure 🙂

    https://developer.esignlive.com/guides/feature-guides/callback-notifications/


    Haris Haidary
    eSignLive Technical Evangelist
    Participant
    Sudipta
    Member
    Member since: 10.01.2018
    Number of posts: 20

    Score

    0

    Thanks Haris. I got all my questions around callback answered.

    Regards
    Sudipta

You must be logged in to reply to this topic.