talk2bks | Posts: 35

eOriginal Coding Questions

0 votes

We need to push our signed documents into an eOriginal vault. The instructions say to push it through a "data" field in the API.

Question #1: Location and Procedure

There are data fields in the root and in a few different. I'm assuming that this data is going in the root. The sdk also doesn't seem to support the root data field, so I'm assuming I'm going to have to send that using a manual post. 

Question #2: Formatting

The manual API post looks to be something like:

~~~

"data":{
    "vaulting_data":"InRyYW5zYWN0aW9udHlwZ..."
}

~~~

in which the vaulting_data is a base64 ecrypted string of the json looking something like:

~~~

{
    "postRegisterOption":"watermark_doc",
    "vaultTransactionTypeName":"OneSpan Sign eTest",
    "vaultCredentials":{
        "username":"SampleUsername",
        "orgName":"SampleOrganization",
        "apiKey":"ok0Sample0ApiKey0Just0An0Example",
        "endpoint":"previewondemand"
    },
    "documentsToVault":[
        {
            "documentId":"DocumentName01",
            "loanId":"loanId_001",
            "loanAmount":"99999",
            "lender":"ABC Corporation",
            "type":"Loan Contract"
        }
    ]
}

~~~

I just want to make sure I'm headed in the right direction.

Question #3: Account Setup

Is there anything special that OneSpan needs to do in order to active this on the Sandbox and Production? The instructions say to open a case, which I have done but haven't heard back on.

 

Question #4: uploading to eOriginal after completion.

We have 2 documents that will need to go to eOriginal The first are the credit apps which are signed about 30 minutes prior to the contracts. IF the contracts are signed, we need to send the contracts and the credit apps both to eOriginal in the same Envelope. What's the best process of doing this?


Duo_Liang | Posts: 3776

Reply to: eOriginal Coding Questions

0 votes

Hi Brian,

 

Thanks for your post!

To answer your questions:
 

Q1: Apex SDK by default doesn't support e-vault features, thus you'd extend the SDK modelling like below:

class OneSpanAPIObjects > Data > Add a new field "vaulting_data":

    public class Data
    {
        public String origin;
        public String sdk;
        public String vaulting_data;
        ......

    }

In this case, e-vaulting can be set up in the creation API and doesn't need additional calls.

Q2: I believe you are referring to the feature guide "Transaction Settings for Digital Lending", this should be the correct direction.

Q3: Yes, please fill in a support ticket and have our support agents set up your account settings.

Q4: Could you elaborate a bit about how many signers you have and who will sign which document? Because when using eOriginal, documents are vaulted as soon as the last signature has been signed by the last signer, specifying document order and signer order could help to design the workflow.

 

Duo


talk2bks | Posts: 35

Reply to: eOriginal Coding Questions

0 votes

Thanks Duo,

I'm working through all the answers. As far as question #4, we have 2 different documents signed at two different times.

1. The Credit application. We first see if the customer is eligible for credit to see what payment options they may have. Once the credit application is signed, then our team will run credit to see what payment options we can provide the customer. This takes about 15 minutes.

2. The Contract. If we can make the package affordable to the member, then they will sign a contract.

 

If they sign the credit application (#1) but don't sign the contract (#2) then nothing needs to go to eOriginal.

If they sign both the credit application and the contract, then both documents need to go to eOriginal in the same envelope.


talk2bks | Posts: 35

Reply to: eOriginal Coding Questions

0 votes

Duo, I have added the variable to the Data object and have passed a base64encryped string into that variable. When I use postman to get the package, I'm seeing

 

{

   documents:{

      data{

         vaulting_info:"{{{encrypted string}}}"

   }

}

 

I've decrypted the string and it looks good. I don't know what to do next to troubleshoot the issue between OneSpan and eOriginal. The first test didn't get pushed to eOriginal. What do I need to do to help troubleshoot this?


talk2bks | Posts: 35

Reply to: eOriginal Coding Questions

0 votes

Okay, so I have some initial success. 

Adding the "public String vaulting_data;" adds the vaulting_data on the documents:{ vaulting_data which will not work. You need to add it to the root vaulting data.

Without editing the Object class, you first need to save the package as a draft. Then use a custom post to add the vaulting_data to the root of the package. Once that's done, then you can send the package.


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