david.walker

Retrieving field values

0 votes

Is there a way to configure OneSpan Sign to email field values from packages created from a template?


Approved Answer

Reply to: Retrieving field values

0 votes

Hi David,

 

I think this is because the email replacing "DBE_EDGE_Signer" happened to be API Key holder / transaction sender. Is this your requirement that sender will be part of the signing process or is it possible that you can test with another email?

 

Duo

Duo Liang OneSpan Evangelism and Partner Integrations Developer


Reply to: Retrieving field values

0 votes

Hi David,

 

The "Lists of Email Templates" guide has covered all the email templates along with the available placeholder variables, such as “$RECIPIENT_NAME;”, “$RECIPIENT_ROLE;”, “$PACKAGE_NAME;”, “$LINK_URL;”, “$PACKAGE_MESSAGE;”, etc, which values will be dynamically determined during the runtime.

Normally, the package message variable allows you to inject custom data to the email, like signer's reference ID. However, I don't think it's possible to inject a field value entered by signer to the email template.

 

Duo

Duo Liang OneSpan Evangelism and Partner Integrations Developer


Reply to: Retrieving field values

0 votes

Thanks--could it be done using the .NET SDK? The only example of retrieving field values I was able to locate on this site showed how to write the field values to the debugger.


Reply to: Retrieving field values

0 votes

Hi David,

 

Could you elaborate a bit about your use case? How many signers involved in your transaction? Are they in a particular signing order? What data you want to collect and present it in which email template? We can brainstorm together and figure it out if it's possible to achieve the goal.

 

Duo

Duo Liang OneSpan Evangelism and Partner Integrations Developer


Reply to: Retrieving field values

0 votes

Great--thanks. For this particular transaction, there would only be one signer. It's a quarterly report form template using Fast Track. We want to be able to retrieve the field values so they can be used elsewhere.


Reply to: Retrieving field values

0 votes

If you simply want to retrieve the field value, use the get field summary function is the easiest way:


List<FieldSummary> fieldSummaries = eslClient.FieldSummaryService.GetFieldSummary( packageId );
 
Console.WriteLine( "SignerId || DocumentId || FieldId: Value" );
foreach ( FieldSummary fieldSummary in fieldSummaries ) 
{
    Console.WriteLine( fieldSummary.SignerId + " || " + fieldSummary.DocumentId + " || " + 
        fieldSummary.FieldId + ": " + fieldSummary.FieldValue );
}
 

Duo

Duo Liang OneSpan Evangelism and Partner Integrations Developer


Reply to: Retrieving field values

0 votes

What about retrieving the field values into a SharePoint list? Is this doable?


Reply to: Retrieving field values

0 votes

I figured out how to get the values into a SharePoint list, but now I'm running into a new issue. The output from the Retrieve Field Values code (attached) always has a string of characters in place of the first of two SignerID's in my document. 

This is the pattern I'm seeing:

SignerId || DocumentId || FieldID || FieldName: Value
zuZFXmILjscX || doc1 || d5I9Am5rMh8E || subdt: 2022-03-04T19:48:19Z
Prime_Signer || doc1 || bFFnWgyLDJc5 || primedt: 2022-03-04T19:03:06Z

When I was expecting this:

SignerId || DocumentId || FieldID || FieldName: Value
DBE_EDGE_Signer || doc1 || d5I9Am5rMh8E || subdt: 2022-03-04T19:48:19Z
Prime_Signer || doc1 || bFFnWgyLDJc5 || primedt: 2022-03-04T19:03:06Z

This matters if I am going to be successful in using the ApprovalService to get the signatory names and emails. Or is there another way to reference those fields?


Reply to: Retrieving field values

0 votes

Hi David,

 

Do you mean zuZFXmILjscX  vs DBE_EDGE_Signer?

"zuZFXmILjscX" is actually the auto-generated signer ID for sender. If you want to customize the sender's ID, you can explicitly add sender as a signer when creating the transaction:

            OssClient ossClient = new OssClient(apiKey, apiUrl);
            DocumentPackage superDuperPackage = PackageBuilder.NewPackageNamed("Test Package .NET")
                    .WithSigner(SignerBuilder.NewSignerWithEmail("[email protected]")
                                    .WithFirstName("sender First Name")
                                    .WithLastName("sender Last Name")
                                    .WithCustomId("DBE_EDGE_Signer"))

                    ......
                    .Build();

            PackageId packageId = ossClient.CreatePackageOneStep(superDuperPackage);

 

Duo

Duo Liang OneSpan Evangelism and Partner Integrations Developer


Reply to: Retrieving field values

0 votes

Thanks--I tried your solution but it didn't help. Could it be because I am using placeholders?

                .WithSigner(SignerBuilder.NewSignerPlaceholder(new Placeholder("Prime_Signer"))
                    .WithCustomId("Prime_Signer")
                    .SigningOrder(0)
                    .DeliverSignedDocumentsByEmail())
                .WithSigner(SignerBuilder.NewSignerPlaceholder(new Placeholder("DBE_EDGE_Signer"))
                    .WithCustomId("DBE_EDGE_Signer")
                    .DeliverSignedDocumentsByEmail()
                    .SigningOrder(1))


Reply to: Retrieving field values

0 votes

I was just thinking the same thing! I tried it with an alternative email address and it works now. 


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