Modify Signature Timezone Based on Signer

0 votes

We are exploring a solution to display signature blocks utilizing the Apex SDK based on the Signer’s time zone.

We can find documentation on this for Java and .Net SDKs but nothing for Apex. I checked and do not see any “withTimeZoneId()” methods in the Apex SDK. We are currently using the Apex SDK to generate a signing URL in the community portal.

Here is a snippet of the code used to generate the Signing URL. 

ESignPackageCreator pkg = new ESignPackageCreator();

String signingUrl= pkg.createPackage()
                                        .withSigner(firstName, lastName, email)
                                        .withDocument(fileName, file.VersionData)

Please let me know if this Use Case is possible or if more information is needed.




Reply to: Modify Signature Timezone Based on Signer

0 votes

Hi nickd12,


Thanks for your post!

First of all, not sure if you've been aware that the most granular time zone setting is at the package level, namely you can only specify one time zone for all signers. It's determined by a package level attribute "timezoneId". 

On the other hand, we can definitely raise an enhancement request to add this feature to the APEX SDK, however, it will take some time before the next SDK release covers the code change. At the same time, since the APEX classes are open sourced and can be directly edited from Salesforce, you can modify it yourself to accommodate this requirement:
OneSpanAPIObjects.cls (it was once called "ESignLiveAPIObjects.cls") > line 587: public class Package_x > add an additional field: public String timezoneId; > (optional) modify the constructor as well > specify time zone ID when creating a transaction:

OneSpanSDK sdk = new OneSpanSDK();  
OneSpanAPIObjects.Package_x pkg = new OneSpanAPIObjects.Package_x(); = 'Example Transaction';   
pkg.timezoneId = 'EST'; 
String packageId = sdk.createPackage(pkg);   



Duo Liang OneSpan Evangelism and Partner Integrations Developer

Hello! Looks like you're enjoying the discussion, but haven't signed up for an account.

When you create an account, we remember exactly what you've read, so you always come right back where you left off