sudhangi | Posts: 59

List of Error codes, Error Messages, Error Name

0 votes
Hi, I have noticed that there are a bunch of different error messages under the EslServerException. Where can I find a list of all these error messages with their corresponding error codes and error names. Example: com.silanis.esl.sdk.internal.EslServerException: Could not create a new package Exception: HTTP POST on URI https://sandbox.e-signlive.com/api/packages resulted in response with status code: [403, Forbidden]. Optional details: {"messageKey":"error.forbidden.accountNotAccessible","entity":null,"technical":null,"packageId":null,"code":403,"message":"The operation requested cannot be done by the user requesting it because there is an account access mismatch","name":"Access Denied"} As seen above the message details have: "code":403," message":"The operation requested cannot be done by the user requesting it because there is an account access mismatch", "name":"Access Denied" I would like to know a list of all these possible different messages. Thanks a bunch.

Approved Answer
mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Take a look at this list. I couldn't upload it, here. I put it in the code share and linked it below: https://developer.esignlive.com/code-share/esignlive-error-messages/

mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
The error codes and messages will generally follow the standard http status codes; https://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html Or are you saying that for a given code, you've seen different messages and you want to know the different messages available for each code? Either way, I'll see if we have a complete list of all the codes and messages available to get to you.

sudhangi | Posts: 59

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Yes exactly I need the complete list of messages for each error code since that are generated by ESL. Thanks so much for your response. -Sudhangi

mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
I will see what I can find and let you know, next week!

mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
I have an unofficial list. Just checking to make sure I can release it publicly (not sure why I wouldn't be able to) and I'll post it.

sudhangi | Posts: 59

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Sounds good. Thank you. Waiting to see the list. -Sudhangi

mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Just got approval to attach it. However, I have to clean it up a bit, first. I will do that in the morning.

sudhangi | Posts: 59

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Thank you Michael. That is helpful. -Sudhangi

mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
You're very welcome! Let us know whenever you have questions! :)

TroyMunford | Posts: 6

Reply to: List of Error codes, Error Messages, Error Name

0 votes
How does the .NET SDK translate these errors? I mean, I tried to connect using a bad URL on purpose in the SDK, and am getting one of the errors below. How do I get the specific error code/reason it failed from the SDK when using a try...catch in C#? I mean, in the SDK, I have no idea what the "root cause" is, only that an error with a set of strings was thrown. Is there a special way to get this list from the SDK (Version 11.0.1.0 of the Silanis.ESL.dll)?
 try
            {
                PackageId packageId = eslClient.CreatePackage(documentPackage);
            }
            catch (Silanis.ESL.SDK.ServerError ex)
            {
                //What caused the error?
            }
Error returned as a string: Silanis.ESL.SDK.EslException: Could not create a new package. Exception: Object reference not set to an instance of an object. ---> System.NullReferenceException: Object reference not set to an instance of an object. at Silanis.ESL.SDK.Internal.HttpMethods.PostHttp(String apiToken, String path, Byte[] content) at Silanis.ESL.SDK.RestClient.Post(String path, String jsonPayload) at Silanis.ESL.SDK.Services.PackageService.CreatePackage(Package package) --- End of inner exception stack trace --- at Silanis.ESL.SDK.Services.PackageService.CreatePackage(Package package) at Silanis.ESL.SDK.EslClient.CreatePackage(DocumentPackage package) OR this one: Silanis.ESL.SDK.EslException: Could not get application version. Exception: Unexpected character encountered while parsing value: . Path '', line 1, position 1. ---> Newtonsoft.Json.JsonReaderException: Unexpected character encountered while parsing value: . Path '', line 1, position 1. at Newtonsoft.Json.JsonTextReader.ParseValue() at Newtonsoft.Json.JsonTextReader.ReadInternal() at Newtonsoft.Json.JsonTextReader.Read() at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.ReadForType(JsonReader reader, JsonContract contract, Boolean hasConverter) at Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader, Type objectType, Boolean checkAdditionalContent) at Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader, Type objectType) at Newtonsoft.Json.JsonConvert.DeserializeObject(String value, Type type, JsonSerializerSettings settings) at Newtonsoft.Json.JsonConvert.DeserializeObject[T](String value, JsonSerializerSettings settings) at Silanis.ESL.SDK.SystemService.GetApplicationVersion() --- End of inner exception stack trace --- at Silanis.ESL.SDK.SystemService.GetApplicationVersion() at SBA.ESign.ESignProvider.GetApplicationVersion() in C:\SBA\ela\Source\ESign\ESignProvider.cs:line 410 at SBA.PortalUI.Areas.SystemAdministration.Controllers.DiagnosticsController.ESignTests() in C:\SBA\ela\Source\PortalUI\Areas\SystemAdministration\Controllers\DiagnosticsController.cs:line 1062 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.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.AsyncControllerActionInvoker.EndInvokeActionMethod(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.b__3d() at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.>c__DisplayClass46.b__3f() at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.>c__DisplayClass46.b__3f() at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.>c__DisplayClass46.b__3f() at System.Web.Mvc.Async.AsyncControllerActionInvoker.AsyncInvocationWithFilters.>c__DisplayClass46.b__3f() at System.Web.Mvc.Async.AsyncControllerActionInvoker.>c__DisplayClass33.b__32(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`1.CallEndDelegate(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End() at System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeActionMethodWithFilters(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncControllerActionInvoker.>c__DisplayClass21.>c__DisplayClass2b.b__1c() at System.Web.Mvc.Async.AsyncControllerActionInvoker.>c__DisplayClass21.b__1e(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResult`1.CallEndDelegate(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End() at System.Web.Mvc.Async.AsyncControllerActionInvoker.EndInvokeAction(IAsyncResult asyncResult) at System.Web.Mvc.Controller.b__1d(IAsyncResult asyncResult, ExecuteCoreState innerState) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End() at System.Web.Mvc.Controller.EndExecuteCore(IAsyncResult asyncResult) at System.Web.Mvc.Controller.b__15(IAsyncResult asyncResult, Controller controller) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End() at System.Web.Mvc.Controller.EndExecute(IAsyncResult asyncResult) at System.Web.Mvc.Controller.System.Web.Mvc.Async.IAsyncController.EndExecute(IAsyncResult asyncResult) at System.Web.Mvc.MvcHandler.b__5(IAsyncResult asyncResult, ProcessRequestState innerState) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncVoid`1.CallEndDelegate(IAsyncResult asyncResult) at System.Web.Mvc.Async.AsyncResultWrapper.WrappedAsyncResultBase`1.End() at System.Web.Mvc.MvcHandler.EndProcessRequest(IAsyncResult asyncResult) at System.Web.Mvc.MvcHandler.System.Web.IHttpAsyncHandler.EndProcessRequest(IAsyncResult result) at System.Web.HttpApplication.CallHandlerExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute() at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)

mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
I would guess the .NET SDK has its own errors built in. I'll have to look further into what it does by asking our Engineering staff that works on the SDKs. Also, the SDK is open source, so we could also look into what it does to translate errors there. As for the specific errors you're getting, I want to say that the first error is when one of the signer, document or signature objects is built improperly, so the document package passed to eSignLive via the createPackage call has an issue and the SDK might mask the real error message returned. If you were to break things down and create the document package first, then add the documents and signers in separate calls after, you might have more insight into the issue. For the second error you're receiving, based on that it's with Newtonsoft, it would appear to be an issue with the resulting structure of the JSON payload. Though, I agree that the error is not particularly helpful. If you would like to send your code to me (either on here or to [email protected]) I'd gladly look it over to try to see if I notice any issues.

TroyMunford | Posts: 6

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Thank you for the offer to review the code, however we threw the errors on purpose to see if we can cleanly trap for each type and take the appropriate action.
For the second error you’re receiving, based on that it’s with Newtonsoft, it would appear to be an issue with the resulting structure of the JSON payload.
Yes, of course - but that is the connection we tried to make through the SDK, not Newtonsoft directly. In other words, the SDK called Newtonsoft in whatever the SDK used to connect, or when the error was returned from the connection. If we are getting "could not parse HTML" errors from Newtonsoft whenever a connectivity error occurs (remember, we triggered this with a bad URL on purpose), we can't be certain that it was actually a connectivity error when we are in Production mode. Why the real error is important: A connectivity error might mean we take action to notify the Operations group to ensure connectivity is up. A user account error might tell us to notify the account owner we have on record to take action. I'm looking forward to determining how the real errors can be found, without everyone who uses the SDK needing to rewrite it to get those real error codes.

mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Understood. I'll look into it with R&D and/or a Product Manager and let you know if the http error is accessible from the SDK.

mwilliams | Posts: 957

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Here was the reply that I got from R&D: "Unfortunately, the SDK does not expose the response itself. Though, if it’s a connectivity issue, they would get an exception like UnknownHostException or something." So, the short answer is that the errors given by the SDK are what they are currently and the http error codes are not exposed. If these are desired, it would be best to post about this in the Enhancement Ideas forum. Our product managers monitor this forum for ideas for new features from customers/prospects. I can see if there is an available list of exceptions that the SDKs pass and when. I will let you know.

TroyMunford | Posts: 6

Reply to: List of Error codes, Error Messages, Error Name

0 votes
Herein lies the rub:
Though, if it’s a connectivity issue, they would get an exception like UnknownHostException or something.
We explicitly tried to make it throw a "connection error" by providing a bad URL. When we tried to create a package with this URL, the JSON error I provided was thrown. The code we used is this:
using Silanis.ESL.SDK;
using Silanis.ESL.SDK.Builder;
using System;
using System.Collections.Generic;
using System.IO;

    public class ESignProvider
    {
        private EslClient eslClient = null;
        private ESignProviderPackageDefiner definer = new ESignProviderPackageDefiner();
        private string apiKey = string.Empty;
        public string BaseUrl {
            get { return eslClient.BaseUrl; }
        }

        public ESignProvider(string apiKey, string baseUrl)
        {
            eslClient = new EslClient(apiKey, baseUrl);
            this.apiKey = apiKey;
        }
        public string CreatePackage(string packageName, DateTime expiryDate, string senderEmail, HandOverLinkBE handOverLink, LogoImageBE logoImage, string[] optOutReasons)
        {
            Silanis.ESL.SDK.DocumentPackage documentPackage = definer.DefinePackage(packageName, expiryDate, senderEmail, handOverLink, logoImage, optOutReasons).Build();
            Silanis.ESL.SDK.PackageId packageId = eslClient.CreatePackage(documentPackage);

            return packageId.ToString();
        }
    }

    public class HandOverLinkBE
    {
        public string Url { get; set; } = string.Empty;
        public string Text { get; set; } = string.Empty;
        public string ToolTip { get; set; } = string.Empty;

        public HandOverLinkBE(string url, string text)
        {
            Url = url;
            Text = ToolTip = text;
        }
    }

    public class LogoImageBE
    {
        public string Link { get; set; } = string.Empty;
        public string Source { get; set; } = string.Empty;

        public LogoImageBE(string logoImageLink)
        {
            Link = Source = logoImageLink;
        }
    }

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