Account
I am a
Développeur
Product(s)
Earned badges
Achievement: Latest Unlocked
TID Sandbox
Approved Answers
Code Shares
Replies
Code Share Comments
Preferences
Profile Completion
Topic Started
This user has not created any forum posts.
Replies Created
Reply to: How to update package status to expired
Wednesday, December 16, 2015 at 08:02amHi Alan,
Yes it definitely possible to set the package status to EXPIRED. The first thing you need to do is retrieve your document package. Once you have it, you can manually set the status to EXPIRED and update the package using the eSignLive client. The sample code below shows you how its done:
Let me know if you run into any issues.Reply to: Web Application using in IPad with Esign signing techniques
Thursday, December 17, 2015 at 03:17amWould you be able to post your code?
Reply to: Web Application using in IPad with Esign signing techniques
Friday, December 18, 2015 at 04:54amI don't see anything wrong from the snippet you provided. Can you post the code where you create you session token and possibly a screenshot of what you see on your iPad?
Reply to: What changes are needed in code to allow for upload of multiple documents/pdf
Monday, December 21, 2015 at 03:35amHi Maddy,
Below you will find a sample code on how to create and send a package with multiple documents with REST in Java. From the link you provided, only a few extra lines of code are needed.
package com.esignlive.example;
import java.io.BufferedReader;
import java.io.File;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.io.OutputStreamWriter;
import java.io.PrintWriter;
import java.net.HttpURLConnection;
import java.net.MalformedURLException;
import java.net.URL;
import java.net.URLConnection;
import java.nio.file.Files;
public class createWithMultipleDocumentsREST {
public static void main(String[] args) throws MalformedURLException, IOException {
String requestURL = "https://sandbox.esignlive.com/api";
String apiKey = "your_api_key";
String charset = "UTF-8";
File uploadFile1 = new File("DOCUMENT_FILE_PATH"); //first pdf
File uploadFile2 = new File("DOCUMENT_FILE_PATH"); //second pdf
String boundary = Long.toHexString(System.currentTimeMillis()); // Generate a random value for the form boundary
String CRLF = "\r\n"; // Line separator used in multipart/form-data.
String jsonContent = "{ \"roles\":[ { \"locked\":false, \"emailMessage\": { \"content\":\"\" }, \"attachmentRequirements\":[], \"reassign\":false, \"specialTypes\":[], \"id\":\"Sender\", \"data\":null, \"type\":\"SIGNER\", \"index\":0, \"signers\":[ { \"auth\": { \"challenges\":[], \"scheme\":\"NONE\" }, \"company\":\"Silanis\", \"firstName\":\"YOUR_FIRST_NAME\", \"lastName\":\"YOUR_LAST_NAME\", \"phone\":\"\", \"email\":\"[email protected]\", \"knowledgeBasedAuthentication\":null, \"language\":\"en\", \"title\":\"\", \"external\":null, \"professionalIdentityFields\":[], \"userCustomFields\":[], \"delivery\": { \"email\":true, \"provider\":false, \"download\":true }, \"group\":null, \"signature\":null, \"address\":null, \"data\":null, \"name\":\"\", \"specialTypes\":[] }], \"name\":\"Sender\" }, { \"locked\":false, \"emailMessage\": { \"content\":\"\" }, \"attachmentRequirements\":[], \"reassign\":false, \"specialTypes\":[], \"id\":\"Signer\", \"data\":null, \"type\":\"SIGNER\", \"index\":0, \"signers\":[ { \"auth\": { \"challenges\":[], \"scheme\":\"NONE\" }, \"company\":\"\", \"firstName\":\"SIGNER_FIRST_NAME\", \"lastName\":\"SIGNER_LAST_NAME\", \"phone\":\"\", \"email\":\"[email protected]\", \"knowledgeBasedAuthentication\":null, \"language\":\"en\", \"title\":\"\", \"external\":null, \"professionalIdentityFields\":[], \"userCustomFields\":[], \"delivery\": { \"email\":false, \"provider\":false, \"download\":false }, \"group\":null, \"id\":\"Signer\", \"signature\":null, \"address\":null, \"data\":null, \"name\":\"\", \"specialTypes\":[] }], \"name\":\"Signer\" }], \"documents\":[ { \"approvals\":[ { \"role\":\"Signer\", \"signed\":null, \"accepted\":null, \"data\":null, \"fields\":[ { \"page\":0, \"subtype\":\"FULLNAME\", \"width\":200, \"binding\":null, \"extract\":false, \"extractAnchor\":null, \"left\":175, \"top\":165, \"validation\":null, \"height\":50, \"data\":null, \"type\":\"SIGNATURE\", \"value\":\"\" }], \"name\":\"\" }, { \"role\":\"Sender\", \"signed\":null, \"accepted\":null, \"data\":null, \"fields\":[ { \"page\":0, \"subtype\":\"FULLNAME\", \"width\":200, \"binding\":null, \"extract\":false, \"extractAnchor\":null, \"left\":550, \"top\":165, \"validation\":null, \"height\":50, \"data\":null, \"type\":\"SIGNATURE\", \"value\":\"\" }], \"name\":\"\" }], \"name\": \"sampleAgreement\" }, { \"approvals\":[ { \"role\":\"Signer\", \"signed\":null, \"accepted\":null, \"data\":null, \"fields\":[ { \"page\":0, \"subtype\":\"FULLNAME\", \"width\":200, \"binding\":null, \"extract\":false, \"extractAnchor\":null, \"left\":175, \"top\":165, \"validation\":null, \"height\":50, \"data\":null, \"type\":\"SIGNATURE\", \"value\":\"\" }], \"name\":\"\" }, { \"role\":\"Sender\", \"signed\":null, \"accepted\":null, \"data\":null, \"fields\":[ { \"page\":0, \"subtype\":\"FULLNAME\", \"width\":200, \"binding\":null, \"extract\":false, \"extractAnchor\":null, \"left\":550, \"top\":165, \"validation\":null, \"height\":50, \"data\":null, \"type\":\"SIGNATURE\", \"value\":\"\" }], \"name\":\"\" }], \"name\": \"myDocument\" }], \"name\": \"Test Package REST\", \"type\":\"PACKAGE\", \"language\":\"en\", \"emailMessage\":\"\", \"description\":\"New Package\", \"autoComplete\":true, \"status\":\"SENT\" }";
URLConnection connection = new URL(requestURL + "/packages/").openConnection();
connection.setDoOutput(true);
connection.setRequestProperty("Content-Type", "multipart/form-data; boundary=" + boundary);
connection.setRequestProperty("Authorization", "Basic " + apiKey);
connection.setRequestProperty("Accept", "application/json");
OutputStream output = connection.getOutputStream();
PrintWriter writer = new PrintWriter(new OutputStreamWriter(output, charset), true);
try {
// Add first pdf file.
writer.append("--" + boundary).append(CRLF);
writer.append("Content-Disposition: form-data; name=\"file\"; filename=\"" + uploadFile1.getName() + "\"").append(CRLF);
writer.append("Content-Type: " + URLConnection.guessContentTypeFromName(uploadFile1.getName())).append(CRLF);
writer.append("Content-Transfer-Encoding: application/pdf").append(CRLF);
writer.append(CRLF).flush();
Files.copy(uploadFile1.toPath(), output);
output.flush();
writer.append(CRLF).flush();
// Add second file.
writer.append("--" + boundary).append(CRLF);
writer.append("Content-Disposition: form-data; name=\"file\"; filename=\"" + uploadFile2.getName() + "\"").append(CRLF);
writer.append("Content-Type: " + URLConnection.guessContentTypeFromName(uploadFile2.getName())).append(CRLF);
writer.append("Content-Transfer-Encoding: application/pdf").append(CRLF);
writer.append(CRLF).flush();
Files.copy(uploadFile2.toPath(), output);
output.flush();
writer.append(CRLF).flush();
// add json payload
writer.append("--" + boundary).append(CRLF);
writer.append("Content-Disposition: form-data; name=\"payload\"").append(CRLF);
writer.append("Content-Type: application/json; charset=" + charset).append(CRLF);
writer.append(CRLF).append(jsonContent).append(CRLF).flush();
// End of multipart/form-data.
writer.append("--" + boundary + "--").append(CRLF).flush();
}
catch (IOException ex) {
System.err.println(ex);
}
//get and write out response code
int responseCode = ((HttpURLConnection) connection).getResponseCode();
System.out.println(responseCode);
//get and write out response
BufferedReader in = new BufferedReader(new InputStreamReader(connection.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
//print result
System.out.println(response.toString());
}
}
As for JSON payload, you only need to modify the "documents" property:
\"documents\":[
{
\"approvals\":[
{
\"role\":\"Signer\",
\"signed\":null,
\"accepted\":null,
\"data\":null,
\"fields\":[
{
\"page\":0,
\"subtype\":\"FULLNAME\",
\"width\":200,
\"binding\":null,
\"extract\":false,
\"extractAnchor\":null,
\"left\":175,
\"top\":165,
\"validation\":null,
\"height\":50,
\"data\":null,
\"type\":\"SIGNATURE\",
\"value\":\"\"
}],
\"name\":\"\"
},
{
\"role\":\"Sender\",
\"signed\":null,
\"accepted\":null,
\"data\":null,
\"fields\":[
{
\"page\":0,
\"subtype\":\"FULLNAME\",
\"width\":200,
\"binding\":null,
\"extract\":false,
\"extractAnchor\":null,
\"left\":550,
\"top\":165,
\"validation\":null,
\"height\":50,
\"data\":null,
\"type\":\"SIGNATURE\",
\"value\":\"\"
}],
\"name\":\"\"
}],
\"name\": \"sampleAgreement\"
},
{
\"approvals\":[
{
\"role\":\"Signer\",
\"signed\":null,
\"accepted\":null,
\"data\":null,
\"fields\":[
{
\"page\":0,
\"subtype\":\"FULLNAME\",
\"width\":200,
\"binding\":null,
\"extract\":false,
\"extractAnchor\":null,
\"left\":175,
\"top\":165,
\"validation\":null,
\"height\":50,
\"data\":null,
\"type\":\"SIGNATURE\",
\"value\":\"\"
}],
\"name\":\"\"
},
{
\"role\":\"Sender\",
\"signed\":null,
\"accepted\":null,
\"data\":null,
\"fields\":[
{
\"page\":0,
\"subtype\":\"FULLNAME\",
\"width\":200,
\"binding\":null,
\"extract\":false,
\"extractAnchor\":null,
\"left\":550,
\"top\":165,
\"validation\":null,
\"height\":50,
\"data\":null,
\"type\":\"SIGNATURE\",
\"value\":\"\"
}],
\"name\":\"\"
}],
\"name\": \"myDocument\"
}]
Reply to: What changes are needed in code to allow for upload of multiple documents/pdf
Tuesday, December 22, 2015 at 03:50amHey Madhavi,
Unfortunately, in-person signing is on an account level. Therefore, you can't set in-person signing to a specific signer. With regards to "mapping" signers to different documents, the JSON would look something like this:
"{
\"roles\":[
{
\"locked\":false,
\"emailMessage\":
{
\"content\":\"\"
},
\"attachmentRequirements\":[],
\"reassign\":false,
\"specialTypes\":[],
\"id\":\"Signer1\",
\"data\":null,
\"type\":\"SIGNER\",
\"index\":0,
\"signers\":[
{
\"auth\":
{
\"challenges\":[],
\"scheme\":\"NONE\"
},
\"company\":\"\",
\"firstName\":\"John\",
\"lastName\":\"Doe\",
\"phone\":\"\",
\"email\":\"[email protected]\",
\"knowledgeBasedAuthentication\":null,
\"language\":\"en\",
\"title\":\"\",
\"external\":null,
\"professionalIdentityFields\":[],
\"userCustomFields\":[],
\"delivery\":
{
\"email\":true,
\"provider\":false,
\"download\":true
},
\"group\":null,
\"signature\":null,
\"address\":null,
\"data\":null,
\"name\":\"\",
\"specialTypes\":[]
}],
\"name\":\"\"
},
{
\"locked\":false,
\"emailMessage\":
{
\"content\":\"\"
},
\"attachmentRequirements\":[],
\"reassign\":false,
\"specialTypes\":[],
\"id\":\"Signer2\",
\"data\":null,
\"type\":\"SIGNER\",
\"index\":0,
\"signers\":[
{
\"auth\":
{
\"challenges\":[],
\"scheme\":\"NONE\"
},
\"company\":\"\",
\"firstName\":\"Mary\",
\"lastName\":\"Doe\",
\"phone\":\"\",
\"email\":\"[email protected]\",
\"knowledgeBasedAuthentication\":null,
\"language\":\"en\",
\"title\":\"\",
\"external\":null,
\"professionalIdentityFields\":[],
\"userCustomFields\":[],
\"delivery\":
{
\"email\":false,
\"provider\":false,
\"download\":false
},
\"group\":null,
\"id\":\"Signer\",
\"signature\":null,
\"address\":null,
\"data\":null,
\"name\":\"\",
\"specialTypes\":[]
}],
\"name\":\"\"
}],
\"documents\":[
{
\"approvals\":[
{
\"role\":\"Signer1\",
\"signed\":null,
\"accepted\":null,
\"data\":null,
\"fields\":[
{
\"page\":0,
\"subtype\":\"FULLNAME\",
\"width\":200,
\"binding\":null,
\"extract\":false,
\"extractAnchor\":null,
\"left\":175,
\"top\":165,
\"validation\":null,
\"height\":50,
\"data\":null,
\"type\":\"SIGNATURE\",
\"value\":\"\"
}],
\"name\":\"\"
}],
\"name\": \"sampleAgreement\"
},
{
\"approvals\":[
{
\"role\":\"Signer2\",
\"signed\":null,
\"accepted\":null,
\"data\":null,
\"fields\":[
{
\"page\":0,
\"subtype\":\"FULLNAME\",
\"width\":200,
\"binding\":null,
\"extract\":false,
\"extractAnchor\":null,
\"left\":175,
\"top\":165,
\"validation\":null,
\"height\":50,
\"data\":null,
\"type\":\"SIGNATURE\",
\"value\":\"\"
}],
\"name\":\"\"
}],
\"name\": \"myDocument\"
}],
\"name\": \"Test Package REST\",
\"type\":\"PACKAGE\",
\"language\":\"en\",
\"emailMessage\":\"\",
\"description\":\"New Package\",
\"autoComplete\":true,
\"status\":\"SENT\"
}"
In this case, John Doe's signature is required for the "sampleAgreement" document and Mary Doe's signature is required for the "myDocument" document. Hope this helps. Let me know if you run into any issues.Subscriptions
Topics | Replies | Freshness | Views | Users |
---|---|---|---|---|
I'm referencing the custom signing ceremony settings, in an attempt to customize the Thank You dialog content.
|
1 | 5 years 11 months ago | 15 | |
Hi,
One of our testers performed below use case:
a) Signed the document using eSignLive
b) The digital signatures were captured in the signature block
c) Downloaded the signed copy from eSignLive &am
|
3 | 5 years 11 months ago | 479 | |
When we have a package that has two signers and one signer has completed signing and the other is still pending, when we perform a check status, we are getting the following error.
Could not get sign
|
3 | 5 years 11 months ago | 121 | |
I am also finding it difficult to set the correct href. When I use the example 'www.google.com' when the button is clicked it has a query string attached.
|
9 | 5 years 11 months ago | 119 | |
I hear from Account Reps at my Company that DocuSign has a feature that sends them an Email if the Signer has opened the Email sent to them by DocuSign.
|
1 | 6 years ago | 104 |
Subscriptions Release Notes
This user is not subscribed to any release notes.