Account


Earned badges

Achievement: Latest Unlocked

Topic Started

Topics
I'm looking for more information on the expiration date. Can you tell me how the date and time is stored on your end?
I have some questions about creating the signing url in the .Net SDK and the REST API. Here is what I have so far. I've created a package called "Test". I've added documents to Test.
I already have created the package and now want to add documents to it. I have file data in a byte array from the database. How do I add a document to the package with the byte array? Thanks Colleen
Can I create packages programmatically using the same sender email address? And then show the designer view with that same sender email address in multiple browsers? Thanks Colleen

Replies Created

Reply to: Adding documents from database

0 votes
Haris, I'm getting an error message on the eslClient.UploadDocument line of code. The fileModel.data is the byte array. I see in the database that the content type is application/pdf for the TestingApprovals.pdf file. I'm able to manually add this pdf file through the website, so it's fine there. Thoughts? Here is my code:
 EslClient eslClient = getEslClient(companyId);
                PackageId pkgId = new PackageId(packageId);
                DocumentPackage pkg = eslClient.GetPackage(pkgId);

                Stream stream = new MemoryStream(fileModel.data);

                Document mydoc = DocumentBuilder.NewDocumentNamed(fileModel.displayName).FromStream(stream, DocumentType.PDF).Build();
                eslClient.UploadDocument(mydoc, pkg);
                return mydoc.Id;
Here is the error: Silanis.ESL.SDK.EslServerException was caught HResult=-2146233088 Message=Could not upload document to package. Exception: The remote server returned an error: (400) Bad Request. HTTP POST on URI https://sandbox.e-signlive.com/api/packages/e0ca4410-4637-450d-9b3d-5f1f08efdf0e/documents. Optional details: {"entity":null,"technical":"Unable to verify document fc4a3015ad9fd37e. Please make sure it is a valid document or save it as a different format. Error: PDF header signature not found.","packageId":null,"messageKey":"error.validation.verifyDocument.validDocument","message":"Unable to verify document. Please make sure it is a valid document or save it in a different format.","code":400,"name":"Validation Error"} Source=Silanis.ESL StackTrace: at Silanis.ESL.SDK.Services.PackageService.UploadDocument(DocumentPackage package, String fileName, Byte[] fileBytes, Document document) at Silanis.ESL.SDK.EslClient.UploadDocument(String fileName, Byte[] fileContent, Document document, DocumentPackage documentPackage) at Silanis.ESL.SDK.EslClient.UploadDocument(Document document, DocumentPackage documentPackage) at BoardBookitWebService.Repositories.SignatureRepository.addEslApprovalDocument(Int32 companyId, String packageId, FileModel fileModel) in c:\Projects\BoardBookit-Development_Branch\BoardBookitWebService\Repositories\SignatureRepository.cs:line 96 InnerException: Silanis.ESL.SDK.EslServerException HResult=-2146233088 Message=The remote server returned an error: (400) Bad Request. HTTP POST on URI https://sandbox.e-signlive.com/api/packages/e0ca4410-4637-450d-9b3d-5f1f08efdf0e/documents. Optional details: {"entity":null,"technical":"Unable to verify document fc4a3015ad9fd37e. Please make sure it is a valid document or save it as a different format. Error: PDF header signature not found.","packageId":null,"messageKey":"error.validation.verifyDocument.validDocument","message":"Unable to verify document. Please make sure it is a valid document or save it in a different format.","code":400,"name":"Validation Error"} Source=Silanis.ESL StackTrace: at Silanis.ESL.SDK.Internal.HttpMethods.MultipartPostHttp(String apiToken, String path, Byte[] content, String boundary, AuthHeaderGenerator authHeaderGen) at Silanis.ESL.SDK.RestClient.PostMultipartFile(String path, Byte[] fileBytes, String boundary, String json) at Silanis.ESL.SDK.Services.PackageService.UploadDocument(DocumentPackage package, String fileName, Byte[] fileBytes, Document document) InnerException: System.Net.WebException HResult=-2146233079 Message=The remote server returned an error: (400) Bad Request. Source=System StackTrace: at System.Net.HttpWebRequest.GetResponse() at Silanis.ESL.SDK.Internal.HttpMethods.MultipartPostHttp(String apiToken, String path, Byte[] content, String boundary, AuthHeaderGenerator authHeaderGen) InnerException: Thank you, Colleen

Reply to: Adding documents from database

0 votes
Haris, I did what you suggested and opened the attached pdf in notepad. The first few characters are this: %PDF-1.5 I have tried this process with a few different pdf files that we use in testing that all work and load as a PDF in other parts of our application. We are uploading the file via HttpPostedFileBase and they saving the content and content type into the database. I just want to pass along the data to eSign Live and add the same file there. We never save the file to disk. Any other suggestions? Colleen

Attachments

Reply to: Adding documents from database

0 votes
Haris, I am using 10.13.0.0 of the SDK. I tried a couple of things on my end. It looks like I need the byte array from the database and not the byte array from the posted file. I saved the posted file to the database first. Then retrieved it and passed it to the uploaddocument call. The file uploaded successfully. I didn't realize that I couldn't just use the byte array from the posted file. Seems to be working fine now. Thank you for the help! Colleen

Reply to: Retrieving documentId

0 votes
Haris, What you gave me worked, after I realized that the uploadDocument call was stripping off the file extension. My filename was testing.pdf. So, I was searching for testing.pdf and not finding results. Removing the .pdf from the GetDocument call returned results. Maybe a note in the knowledgebase about that would be helpful. Thanks! Colleen

Reply to: Need help with getSigningUrl

0 votes
Michael, The information you provided helps. Our mobile developer would like to use the REST Get call and would like me to store the RoleId in the database it if possible. So, I would need to make a call to get roles and then associate the roleId to what object? (ie, package, signer, document) I just tried calling
eslClient.PackageService.GetSigningUrl(packageId, signerId)
on a sent package, and I get this an object reference error below. Silanis.ESL.SDK.EslException was unhandled by user code HResult=-2146233088 Message=Could not get a signing url. Exception: Object reference not set to an instance of an object. Source=Silanis.ESL StackTrace: at Silanis.ESL.SDK.Services.PackageService.GetSigningUrl(PackageId packageId, Role role) at Silanis.ESL.SDK.Services.PackageService.GetSigningUrl(PackageId packageId, String signerId) at TestESignLiveMVC.Controllers.HomeController.SignApproval() in c:\Users\Colleen\Documents\Visual Studio 2013\Projects\TestESignLiveMVC\TestESignLiveMVC\Controllers\HomeController.cs:line 71 at lambda_method(Closure , ControllerBase , Object[] ) at System.Web.Mvc.ActionMethodDispatcher.Execute(ControllerBase controller, Object[] parameters) at System.Web.Mvc.ReflectedActionDescriptor.Execute(ControllerContext controllerContext, IDictionary`2 parameters) at System.Web.Mvc.ControllerActionInvoker.InvokeActionMethod(ControllerContext controllerContext, ActionDescriptor actionDescriptor, IDictionary`2 parameters) at System.Web.Mvc.Async.AsyncControllerActionInvoker.ActionInvocation.InvokeSynchronousActionMethod() at System.Web.Mvc.Async.AsyncControllerActionInvoker.b__39(IAsyncResult asyncResult, ActionInvocation innerInvokeState) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`2.CallEndDelegate(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End() at System.Web.Mvc.Async.AsyncResultWrapper.End[TResult](IAsyncResult asyncResult, Object tag) at System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeActionMethod(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.b__3d() at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.c__DisplayClass46.b__3f() InnerException: System.NullReferenceException HResult=-2147467261 Message=Object reference not set to an instance of an object. Source=Silanis.ESL StackTrace: at Silanis.ESL.SDK.Services.PackageService.GetSigningUrl(PackageId packageId, Role role) InnerException Please advise. Thank you, Colleen

Subscriptions

Topics Replies Freshness Views Users
We have embedded the prepare iframe within our application and ran into a little hiccup.
10 7 years 10 months ago 29
Profile picture for user harishaidary
I'm looking for information on the declined process. When a signer declines a document, what happens in the system? Does the signer status get updated or is this at a package level?
3 7 years 10 months ago 105
Profile picture for user mwilliams
We have the thank you dialog box for signing ceremony disabled for our signers, and it doesn't show up when you finish signing on a desktop.
8 7 years 10 months ago 22
Profile picture for user mwilliams
Is there a way to customize what the user sees under the fields and types options in the designer?
3 7 years 10 months ago 24
I'm looking for more information on the expiration date. Can you tell me how the date and time is stored on your end?
24 7 years 9 months ago 193
Profile picture for user harishaidary
Profile picture for user mwilliams

Code Share

This user has not submitted any code shares.

Subscriptions Release Notes

This user is not subscribed to any release notes.