Giter Site home page Giter Site logo

docusign / docusign-esign-csharp-client Goto Github PK

View Code? Open in Web Editor NEW
129.0 45.0 159.0 65.83 MB

The Official DocuSign C# Client Library used to interact with the eSignature REST API. Send, sign, and approve documents using this client.

Home Page: https://developers.docusign.com/

License: MIT License

C# 99.99% Shell 0.01% PowerShell 0.01%
docusign docusign-api esign esignature rest electronic-signatures

docusign-esign-csharp-client's Introduction

The Official Docusign eSignature C# Client SDK

Nuget version Nuget downloads

The Docusign SDK makes integrating Docusign into your apps and websites a seamless experience.

Table of Contents

Introduction

Integrate eSignatures into your application in minutes. The secure and award-winning Docusign eSignature API makes requesting signatures, automating forms, and tracking documents directly from your app easy.

Installation

This client SDK is provided as open source, which enables you to customize its functionality to suit your particular use case. To do so, download or clone the repository. If the SDK’s given functionality meets your integration needs, or if you’re working through our code examples from the Docusign Developer Center, you merely need to install it by following the instructions below.

Version Information

  • API version: v2.1
  • Latest SDK version (Including prerelease): 8.0.0-rc1

Requirements

Compatibility

  • .NET Standard 2.0. See .NET Standard Selector for details on versioning for the individual components in .NET Standard.
  • .NET Core 2.0 or above.
  • Microsoft .NET version 4.6.2+.
  • TLS 1.2

NuGet Package Manager:

  1. Create a new C# project, or open an existing one.
  2. Select Tools -> NuGet Package Manager -> Manage NuGet Packages for Solution.
  3. Search for Docusign.
  4. Select DocuSign.eSign.dll.
  5. Select the check box next to your project name.
  6. Click Install.

Package Manager Console:

  1. Create a new C# project, or open an existing one.
  2. Open the Package Manager Console by either method:
    1. Clicking Package Manager Console along the bottom of Visual Studio
    2. Clicking Tools -> NuGet Package Manager -> Package Manager Console
  3. In the Package Manager Console, type: Install-Package DocuSign.eSign.dll

SDK Dependencies

This client has the following external dependencies:

.NET Standard v2 and .NET Core:

  • Newtonsoft.Json v13.0.3
  • BouncyCastle.Cryptography v2.3.1
  • System.ComponentModel.Annotations v5.0.0
  • Microsoft.IdentityModel.JsonWebTokens v7.5.2

.NET Framework, version 4.6.2:

  • Newtonsoft.Json v13.0.3
  • BouncyCastle.Cryptography v2.3.1
  • System.ComponentModel.Annotations v5.0.0
  • Microsoft.IdentityModel.JsonWebTokens v7.5.2

API Reference

You can refer to the API reference here.

Code Examples

Explore our GitHub repository for the Launcher, a self-executing package housing code examples for the eSignature C# SDK. This package showcases several common use cases and their respective source files. Additionally, you can download a version preconfigured for your Docusign developer account from Quickstart. These examples support both the Authorization Code Grant and JSON Web Token (JWT) authentication workflows.

OAuth Implementations

For details regarding which type of OAuth grant will work best for your Docusign integration, see Choose OAuth Type in the Docusign Developer Center.

For security purposes, Docusign recommends using the Authorization Code Grant flow.

Changelog

You can refer to the complete changelog here.

Support

Log issues against this client SDK through GitHub. You can also reach out to us through Docusign Community and Stack Overflow.

License

The Docusign eSignature C# Client SDK is licensed under the MIT License.

Additional resources

docusign-esign-csharp-client's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

docusign-esign-csharp-client's Issues

Docusign-Rest client - preview the envelope

I am using rest api for docusign integration.
I am creating the envelope with multiple templates ( using composite template)and trying to preview it in readonly mode.
In my case, the the work flow goes like this... Rep ( Creates envelope and previews it in readonly mode). If everything looks good in preview, then click sent button in my App UI, which will actually sent the envelope to 3 remote recipients ( signer 1, signer2, signer3 -these are actual signers).
I am able to create and sent but not able to preview the envelope in read only mode.

  1. Tried downloading the document as byte[].. but the prefill field data is missing
  2. Tried by adding a previewer role to the templates and then make him as embedded user. Then created recipients view.. this again is missing the prefill data.
    How to preview a created envelope in non editable mode with prefill field data?

How to achieve Signer Attachment in embedded signing?

I have a requirement in which I need to send recipient an option to upload docs and after it is completed and signed, I should receive an email with those docs.

I have been working with class SignerAttachment but not sure how do I attach them to envelope as Envelope docs only take a list of Document?

Kindly suggest

Add support for Title tab with Templates

It seems like it should be possible to populate the Title field when using a template. I see it commented out in Envelope.json.cs - maybe it just needs to be finished out?

MOB_rotateToLandscapeToDraw not hiding on iPhone

So on the mobile embedded iframe if I rotate the screen to draw a signature on android everything works fine. I can draw or accept a template signature and move on with the rest of the form.

However, on the iPhone the div MOB_rotateToLandscapeToDraw never removes itself on landscape mode, almost like it never detects it that it is in landscape mode. The options are hidden only because of the div and using dev tools if I make it hidden everything looks great.

image

Due to cross domain securities I can't use something like jquery to remove this on my own and the client does not want an app, so I can't use a webview to solve this like suggested on the docusign site, so any suggestions?

Add a document to an envelope using a Stream

Right now Envelope.Create() has overloads that take a path or a byte array. There should be an overload that takes a Stream.

If I have a Stream I don't want to have to write the file to disk just so I can get a path and I may not want to load the whole thing into memory to get a byte array either.

Login Authentication failure

Hello,

I have used this dll to login, create and envelope, attaché several "SignHere" tabs, date tabs, and attached the document to sign. The control works great with my demo account. But when I point the BaseURL to our production account ( we have went through the API certification ) we are unable to login. Working with the Docusign support staff, we have verified that the username and password are indeed valid, and I can log into the site directly using those same credentials.

Using the sample code below, I am able to login to my site:

string strDOCUSIGNURL = ConfigurationManager.AppSettings["DOCUSIGNURL"];
string strDOCUSIGNAPIKEY = ConfigurationManager.AppSettings["DOCUSIGNAPIKEY"];
string strDOCUSIGNPASSWORD = ConfigurationManager.AppSettings["DOCUSIGNPASSWORD"];
string strDOCUSIGNEMAIL = ConfigurationManager.AppSettings["DOCUSIGNEMAIL"];

DocuSign.Integrations.Client.Account account = new DocuSign.Integrations.Client.Account();

account.BaseUrl = strDOCUSIGNURL;
account.Email = strDOCUSIGNEMAIL;
account.Password = strDOCUSIGNPASSWORD;

DocuSign.Integrations.Client.RestSettings RestSettings = DocuSign.Integrations.Client.RestSettings.Instance;
RestSettings.IntegratorKey = strDOCUSIGNAPIKEY;

bool result = account.Login();

This all works great using my Sandbox account, however, when I change to use the production account, I am getting a USER_AUTHENTICATION_FAILED response in the account object, and a false returned from the Login() function.

Any help would be greatly appreciated.

Thanks,

Brian

Send On Behalf Of isn't sent in some methods

I noticed the part where the accounts SOBOUserID field is attached to the request is only in some but not all methods. Is there a reason for this? For example the basic Envelope.Create method that accepts a filepath does not do it, but the other versions do. Same with the Account.LoginDirect method.

GetRecipientView: REST API Error ACCOUNT_NOT_AUTHORIZED_FOR_ENVELOPE

I am trying to get recipient url but getting "GetRecipientView REST Error ACCOUNT_NOT_AUTHORIZED_FOR_ENVELOPE #44".

First I am creating the envelope to get sender url. And then I calling GetRecipientView() to get recipient view url. Below is the code I am using

public string EmbeddedSenderView(string docId)
{
Account account = InitializeDocSign();

        Envelope envelope = new Envelope();
        envelope.Login = account;
        envelope.EmailSubject = "Please sign document";
        envelope.Recipients = new Recipients()
        {
            signers = new Signer[]
            {
                new Signer()
                {
                    email = "[email protected]",
                    name = "AV Gmail 1",
                    routingOrder = "1",
                    recipientId = "1",
                    roleName="Signer",
                    clientUserId="101"
                },
            },
        };           
        envelope.Create("\FAQ_NMS.pdf");

        bool result = envelope.GetSenderView("my domain");          

        /*Saving document details into Database*/
        if (result)
        {                
            ObjDocumentSignRequest obj = new ObjDocumentSignRequest();
            obj.DocumentId = docId;
            obj.EnvelopeId = envelope.EnvelopeId;
            obj.SenderViewUrl = envelope.SenderViewUrl;
            eSignUtilities.SaveSignRequest(obj);           
        }
        return envelope.SenderViewUrl;
    }


    public void EmbeddedRecepientView(string docId)
    {
        Account account = InitializeDocSign();

        Envelope envelope = new Envelope();
        envelope.Login = account;
        envelope.EmailSubject = "Please sign document";
        envelope.Recipients = new Recipients()
        {
            signers = new Signer[]
            {
                new Signer()
                {
                    email = "[email protected]",
                    name = "AV Gmail 1",
                    routingOrder = "1",
                    recipientId = "1",
                    roleName="Signer",
                    clientUserId="101"
                },
            },
        };

        envelope.EnvelopeId = "xxxxxxxxxxx";
        envelope.UpdateStatus();

        bool result = envelope.GetRecipientView("my domain");     

Any help?

Thanks
AV

OAUTH?

Hello,
Does this library support OAUTH authentication?

Any guidance on adding OAuth Token Support?

We're about to incorporate OAuth tokens into our application. It appears that there's no support yet in this Library. We can think of a couple of approaches for adding it, but before we dig in, I wanted to first check and see if there are any existing discussions, any work in progress, or any preferred DocuSign approach that we should know about. We may be very late to the table on this issue....

We saw a thread about this over on the Node client, but it didn't seem heavily developed.
Alex
Dockyard

Async Calls Not Using Default Header

I recently started using the Async calls (specifically in the AuthenticationApi and EnvelopeApi) and it keeps throwing the following exception:

DocuSign.eSign.Client.ApiException: Error calling Login: {
"errorCode": "PARTNER_AUTHENTICATION_FAILED",
"message": "The specified Integrator Key was not found or is disabled. An Integrator key was not specified."
}
...

Looking at the source, and assuming that this repo is the current version of that (since the nuget pkg is v2.0.0 and this has the source at 1.7.2), it looks like the LoginAsyncWithHttpInfo method isn't initializing the headerParams dictionary with the Configuration.DefaultHeader like LoginWithHttpInfo is. This is only the first example, it looks like all of the subsequent async methods, (I'm assuming all of them throughout) are doing the same thing.

Send Request from Template and add extra Document?

I need to send a signature request from a Template (easy enough by adding a TemplateId and TemplateRoles)…but also add a document into the envelope. Basically standard template housed in DocuSign for signing, but need to be able to also add a document just for supporting documentation into the envelope (no signing needed on this..just appended to the end)….is this possible?

Thanks!

Get All Envelopes from Inbox (Completed)

Is there any method to retrieve all envelope guids from Completed folder ? It's possible to get list of envelopes using REST API search_folders method. Searching in .NET client by this method name brought only two lines: in retrieving drafts and in retrieving count of envelopes. But no method to retrieve guids. Please advise.

What are conditions for spawning a new Auth Token (Connected Applications)?

Hi!
As I'm moving our codebase to your new library I became a bit confused about your authentication mechanisms
I was wondering if you could explain me a few things, one of which is why my team is constantly spawning tokens in Connected Apps.
Currently we use an old version of your library, the one that had "DocuSign.Integration.Client" namespace.
Here is what we currently do:

  1. We prompt a user for credentials.
  2. Post credentials to https://demo.docusign.net/restapi/v2/oauth2/token and receive an auth token.
    Request looks something like like this:
"grant_type":"password"
 "client_id":{our integrator key}
 "username":{username}
 "password":{password}
 "scope":"api",
 "token_type":"bearer" 
  1. Store user's email as a username and an acquired token as an ApiPassword (sic!) together and use it with your old library. Note that we use a token, which is supposed to be an oAuth token, as an ApiPassword. I'm not sure that this was intended, but it works.

Now I am moving our codebase to your new library. As I understand you have 2 authentication mechanism. One is "X-DocuSign-Authentication", and another one is oAuth.
In first case one has to add a username, a password and an integrator key to every request. And in case of oAuth you simply have to add an access token to request , like `"bearer":"{access_token}".
It seemed to me to that moving us to a genuine oAuth flow would be a good thing, so I started to work in this direction. But soon I realised, that I am confused. My whole team tends to use one DocuSign account for everyone and we run out of tokens from time to time. And I assume that your old library uses "X-DocuSign-Authentication" mechanism, since it requests both email and password.

Your documentation says about Connected Apps list that

"For example, if the client application were an iPad app and the user owned two iPads, then both might appear in the list"

So, my first question is:
Could you, please, shed light on what is hiding behind this "might appear"? What are conditions for spawning a new token in case of running a Web site?

My second question is:
Would using an oAuth authentication keep spawning new tokens?

Thank you!

Document prefill

Hello!
I use the latest 1.6 version of library.
I create envelope by template and define TemplateRole for each recipient. My question: Is there any way to set in code some of tab values for recipient?

Need support for Signer.tabs.listItems

I think it probably just needs to be added to the Signer class, and deserialization might just work. Not sure though, it may be more complicated than that.

Is there any other way to retrieve this info? I can see it in the raw JSON response, but don't see any way to access it through the recipients collection of an envelope.

Unable to add multiple documents to an envelope.

Hello,
I am unable to add documents to an envelope.
Example:
Byte[] file1 = File.ReadAllBytes(documentPath);
Byte[] file2 = File.ReadAllBytes(documentPath);
envelope.AddDocument(file1,"File1.docx",1);
envelope.AddDocument(file2, "File2.docx",2);

I can only add a single document when I use the Create method.
Example:
result = envelope.Create(documentPath);

Note: I am using the example code you provided via GitHub to connect to DocuSign.

Again Missing features

This client is mostly useless, I think?? There is NO support for adding signature tabs or any other tab except text tabs. Am I missing something?

Envelope.GetRecipientView method always return UNKNOWN_ENVELOPE_RECIPIENT

requestInfo.RequestBody = new List<RequestBody>()
        {
          new RequestBody()
          {
            Text = new RecipientView()
            {
              returnUrl = returnUrl,
              email = this.Login.Email,
              userName = this.Login.AccountName,
              authenticationMethod = "email"
            }.Serialize()
          }
        }.ToArray();

i think it's b/c in GetRecipientView method in req body email is account email but it should be recipient email.

Need SDK documentation

Hey, the library is great, but we need documentation. The Nuget package does not install any xml documentation for the classes.

Is there documentation anywhere for this library?

No feedback from rest API when SMS Authentication is not available on account

I'm currently working on adding SMS authentication to the ,NET client, it was very quick to implement however I was not aware that I had successfully implemented and have lost almost a whole day trying to discover what is wrong.

It turns out that the SMS authentication is only available on Buisiness accounts, however the REST API documentation does not mention this, the response from the API does not return an error or any feedback to say that the feature is not available.

Please consider adding the useful nugget of information to the docs and while I can understand DocuSign not wanting to incur the costs of sending lots of SMS it would be good if a mock SMS authentication page was displayed to show that the request was correct.

1.4 is not Strongly Named

In order to support a com interop project I needed to add the dll to a GAC. the assembly needs to be strongly named to do this. For my own project I simply pulled down the latest, added the necessary options, and it worked just fine. I just thought I'd bring it up so others don't have to go through that. Thanks.

Update Custom Field (textCustomField) in a Template

I have a textCustomfield named 'UserName' added to a document in a template:
image

I want to update UserName field value with "My Name" using .Net code, when I use below code to add custom field to envelope:
var fields = new Dictionary<string, object>();
fields.Add("UserName", "My Name");
bool added = envelope.AddCustomFields(fields);

then envelope.AddCustomFields(fields) returns true and in the envelope i can see error as 'CUSTOM_FIELD_ALREADY_EXISTS'

Below is actual resonse from enveloep object:
c-b17e-f67d938544ec/custom_fields

Headers:
Accept:application/json
Content-Type:application/json
X-DocuSign-Authentication:[email protected]tRYdgfjRsNZTLoHFa7aYGAyynAQ=MSCD-22068561-3fad-4f7d-b396-bb662b2c68e6
Host:demo.docusign.net
Content-Length:96
Expect:100-continue

Request Stream:
{"textCustomFields":[{"name":"UserName","show":"False","required":null,"value":"My Name"}]}

Response:
{
"textCustomFields": [
{
"fieldId": "76003325",
"name": "UserName",
"show": "false",
"value": "My Name",
"errorDetails": {
"errorCode": "CUSTOM_FIELD_ALREADY_EXISTS",
"message": "Field Name: UserName"
}
}
],
"listCustomFields": []
}

This error is correct as this field already exists in the envelope and i am trying to add custom field again with the same name, Instead I have to update 'UserName' custom field exists in template.
How can update text custom field 'UserName' using c# code?

Missing functionality

I've recently joined a team that was starting to interface with DocuSign, they had not discovered the .NET client and had been hand rolling their own Rest requests. I'm in the process of migrating what they have done to use the client but cannot find some features that they have been using and are not present:

  • SmsAuthentication
  • EmailNotification

Are they implemented and just not obvious or are they scheduled to be implemented?

Changing status to void

Hi,

I am having trouble changing status of an envelope to void using the ChangeStatus() method. The problem is that it does not include the required "voided_reason" in the body. It looks like including this within the body of the request if the new status is "void" would do the trick.

However, I am on a (very) tight deadline. Is there another way you can think of to void an already signed or partially signed envelope. The reason for wanting to void an envelope is in the situation where we need to change one of the signers after the document has been signed.

Thanks,

GetRecipientView REST Error ACCOUNT_NOT_AUTHORIZED_FOR_ENVELOPE

I am trying to integrate DocUSign embedded signing for my application, however, every time I try to execute the function GetRecipientView I get the REST error ACCOUNT_NOT_AUTHORIZED_FOR_ENVELOPE.

Everything is returning true for result up to the point where GetRecipientView is called and if I modify the code below to comment out the line where it calls GetRecipientView I get the SenderView just fine but I need a SignerView.

I am trying to work off an existing template that I made in the developer center.

// user credentials 
                Account account = new Account();
                account.Email = AccountEmail;
                account.Password = AccountPassword;

                // make the login call (retrieves your baseUrl and accountId)
                bool result = account.Login(); //result returns true
                if (!result)
                {                    
                    return BadRequest("Login API call failed for user" + account.Email + ".\nError Code:  " + account.RestError.errorCode + "\nMessage:  " + account.RestError.message);
                }

                // create envelope object and assign login info
                Envelope envelope = new Envelope();
                envelope.Login = account;
                envelope.Status = "sent";
                // use an existing server template
                envelope.TemplateId = TemplateId;

                // add one signer to a template role identified by roleName
                envelope.TemplateRoles = new TemplateRole[]
                {
                    new TemplateRole()
                    {
                        email = RecipientEmail,
                        name = RecipientName,
                        roleName = TemplateRoleName,
                        clientUserId = "101"
                    }
                };


                // create a new DocuSign envelope (i.e. server side)
                result = envelope.Create(); //result returns true

                // generate the recipient view token                
                result = envelope.GetRecipientView(); //returns false, Rest Error = ACCOUNT_NOT_AUTHORIZED_FOR_ENVELOPE

if (!result)
                {
                    if (envelope.RestError != null)
                    {
                        return BadRequest("Error code:  "+ envelope.RestError.errorCode + "\nMessage:  " + envelope.RestError.message);
                    }
                    else
                    {
                        Console.WriteLine();
                        return BadRequest("Error encountered retrieving signing token, please review your envelope and recipient data.");
                    }
                }
                else
                {
                    // open the recipient view (SenderViewUrl field is re-used for the recipient URL)
                    return Ok(envelope.SenderViewUrl);
                }

Is this a known issue or am I missing something?

Code consistency and exception exception checks

Envelope.Create() checks the null-value state of the key RestSettings members, but the other api methods do not. They should all make these null checks. Maybe a new private method to check these values should be added.

Furthermore, when you try to use “Evenlope.UpdateRecipients” without having completed an Account.Login() you will get a weird exception:

System.UriFormatException: Invalid URI: The format of the URI could not be determined.
at System.Uri.CreateThis(String uri, Boolean dontEscape, UriKind uriKind)
at System.Net.WebRequest.Create(String requestUriString)
at DocuSign.Integrations.Client.RequestBuilder.CreateWebRequest()
at DocuSign.Integrations.Client.RequestBuilder.MakeRESTRequest()
at DocuSign.Integrations.Client.Envelope.UpdateRecipients(Recipients recipients, Boolean resendEnvelope)

That should be changed so that a more informative exception, such as “You must login before accessing the service,” should be used. Otherwise, we will all think there is a bug in the API when there is not.

Tab Missing VALUE

It is not possible to pre-fill textFields without Value.

Should be added to Tab:

public class Tab
{
///

    /// Tab Value
    /// </summary>


    public string value { get; set; }

Adding Custom Fields to Documents on an Envelope

I have been looking through the API trying to find the following call:
[https://www.docusign.com/p/RESTAPIGuide/RESTAPIGuide.htm#REST%20API%20References/Add Custom Document Fields to an Envelope Document.htm](https://www.docusign.com/p/RESTAPIGuide/RESTAPIGuide.htm#REST%20API%20References/Add Custom Document Fields to an Envelope Document.htm)

I haven't been able to find it, so I'm assuming that I'm going to have to add it, unless I'm just looking in all the wrong places.

Missing TemplateName in Connect event payload

When connect sends an event, there is a node inside of EnvelopeStatus node, looking like this:

       <DocumentStatuses>
            <DocumentStatus>
                <ID>1</ID>
                <Name>medical_intake_form.pdf</Name>
                <TemplateName />
                <Sequence>1</Sequence>
            </DocumentStatus>
        </DocumentStatuses>

I'm pretty sure that TemplateName had always come up with a value.
I've tried different templates and different connect configurations - it's all the same, TemplateName is missing.

URI not properly formatted

I am trying to replicate your example and during bool result = account.Login(); I am getting a URI format error. Is there a input im missing? is anyone else encountering this issue?

Im doing

Account account = new Account();
account.Email = AccountEmail;
account.Password = AccountPassword;

Iv used prod and sandbox credentials for AccountEmail and AccountPassword to no luck.

I am not sure if this is an issue with the nugget or not thats why I posted here first until I go over to stacks. Which it might be because I get

An exception of type 'System.UriFormatException' occurred in DocuSign.Integration.Client.dll but was not handled in user code

Additional information: Invalid URI: The format of the URI could not be determined.
Any suggestions?

Enum for string status codes

Create an enumeration that contains the envelope and recipient status codes instead of relying upon the string codes from the server. The API should decode these values and provide an enumerated set of values.

Such as : enum EnvelopeStatus { Completed }, etc.

Getting key file import failure upon forking

We cloned this library a few days ago and were able to successfully build it, although we did have to manually copy "nuget.exe" into the .nuget folder.

We then tried, today, to fork the repo. We forked and cloned. When we tried to build from the new clone, we again got the nuget.exe error and again fixed it. Then, however, we got this error:

"Cannot import the following key file: DocuSignClient.pfx. The key file may be password protected. To correct this, try to import the certificate again or manually install the certificate to the Strong Name CSP with the following key container name: VS_KEY_6CA6AFBE065420C2 "

Based on SO, we used the sn command, but it wants a password:

c:\code\DocuSign-.NET-Client\DocuSign.Integrations.Client>sn -i DocuSignClient.p
fx VS_KEY_6CA6AFBE065420C2

Microsoft (R) .NET Framework Strong Name Utility Version 4.0.30319.33440
Copyright (c) Microsoft Corporation. All rights reserved.
Enter the password for the PKCS#12 key file:
Failed to parse the PKCS#12 blob in DocuSignClient.pfx -- The specified network
password is not correct.

These might be very stupid questions, but:

  1. Is this a new problem that we've stumbled on?
  2. Do we need to request a password from Docusign before we fork the repo? Or is forking not allowed at all?
  3. Are we just doing something dumb here?

cheers

unexpected character encountered while parsing value: <. Path ".line 0, position 0.

When executing below statements:
AccountEnvelopes allEnvelopes = env.GetAccountsEnvelopes(fromDate);
OR
Newtonsoft.Json.Linq.JObject allEnvelopes = tp.GetTemplate(TemplateId);
getting 'unexpected character encountered while parsing value: <. Path ".line 0, position 0.'
Detailed error:
ERROR : Newtonsoft.Json.JsonReaderException: Unexpected character encountered while parsing value: <. Path '', line 0, position 0.
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.JsonSerializer.Deserialize(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 Newtonsoft.Json.JsonConvert.DeserializeObject[T](String value)
at DocuSign.Integrations.Client.AccountEnvelopes.FromJson(String json)
at DocuSign.Integrations.Client.Envelope.GetAccountsEnvelopes(DateTime fromDate)
at DocuSignIntegration.DosuSignPOC.btnCreateEnvelope_Click(Object sender, EventArgs e) in c:\Users\f3hx333\Documents\Visual Studio 2013\Projects\DocuSignIntegration\DocuSignIntegration\DosuSignPOC.cs:line 234

NuGet Install - File Not Found

After installing the Nuget package in my Winforms VB.NET application and running the project I came across an issue. When it hit the following line of code I received an error:

Dim envDef As New EnvelopeDefinition() With {.EmailSubject = "DocuSign SDK - Please sign this doc"}

Error: EnvelopeDefinition.cs not found

I had to manually locate the file in the packages folder for my project.

More error info:
Locating source for 'y:\Docusign\Github\DevCenter\SDKs\csharp\sdk\src\main\csharp\DocuSign\eSign\Model\EnvelopeDefinition.cs'. Checksum: MD5 {de 2b ef 57 21 9f 2f 81 87 a2 42 8f 82 f1 a7 7c}
The file 'y:\Docusign\Github\DevCenter\SDKs\csharp\sdk\src\main\csharp\DocuSign\eSign\Model\EnvelopeDefinition.cs' does not exist.
Looking in script documents for 'y:\Docusign\Github\DevCenter\SDKs\csharp\sdk\src\main\csharp\DocuSign\eSign\Model\EnvelopeDefinition.cs'...
Looking in the Edit-and-Continue directory 'C:\Users\chris.EXPRESSCORP\ECH Applications\Express Housing Manager 2012 v2 - vs2015\enc_temp_folder'...
The file with the matching checksum was not found in the Edit-and-Continue directory.
Looking in the projects for 'y:\Docusign\Github\DevCenter\SDKs\csharp\sdk\src\main\csharp\DocuSign\eSign\Model\EnvelopeDefinition.cs'.
The file was not found in a project.
Looking in directory 'C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\crt\src'...
Looking in directory 'C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\atlmfc\src\mfc'...
Looking in directory 'C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\atlmfc\src\atl'...
Looking in directory 'C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\atlmfc\include'...
Looking in directory 'C:'...
The debug source files settings for the active solution indicate that the debugger will not ask the user to find the file: y:\Docusign\Github\DevCenter\SDKs\csharp\sdk\src\main\csharp\DocuSign\eSign\Model\EnvelopeDefinition.cs.
The debugger could not locate the source file 'y:\Docusign\Github\DevCenter\SDKs\csharp\sdk\src\main\csharp\DocuSign\eSign\Model\EnvelopeDefinition.cs'.

How to set the request timeout

I notice that the RequestInfo object has a Timeout property which gets applied to the WebRequest if it is set. However, I don't see a way to set the Timeout on RequestInfo. Am I missing something?

missing support for tab types, access code, brand ID

This page of the REST API Guide (https://www.docusign.com/p/RESTAPIGuide/RESTAPIGuide.htm#REST%20API%20References/Tab Parameters.htm) defines the following tabs that don't appear to be defined in this code (please correct me if I'm wrong):

Approve, Date, Decline, Email Address, Envelope ID, First Name, Formula, Last Name, List, Note, Number, SSN, and Zip

Envelopes don't have a parameter for Brand ID (should be as simple as adding Brand ID to Envelope and EnvelopeCreate, and then setting env.brandId = this.BrandId in the Envelope's CreateJson method)

Recipients don't have parameters for accessCode or addAccessCodeToEmail (https://www.docusign.com/p/RESTAPIGuide/RESTAPIGuide.htm#REST%20API%20References/Recipients/Signers Recipient.htm)

Great project, though!

Exceptions for UpdateStatus and SendReminder

I am getting the following error code when I call the UpdateStatus and SendReminder methods from Envelope.
Error code: INVALID_REQUEST_PARAMETER Message: The request contained at least one invalid parameter. Query parameter 'from_date' must be set to a valid DateTime, or 'envelope_ids' or 'transaction_ids' must be specified.
I have a valid envelope, and can use the GetStatus method to return the proper creation time, but the above methods are throwing the exception.

Tabs and Templates

Hello. I've been able to create a template and assign approvers from code. That part works great. The issue I'm having is that I added a Custom Field but can't populate the value.

I've tried adding a TabCollection with my TextTab populated with the field details to the template using template.AddTabs(); I've tried to use CustomFIelds and that doesn't work either.

What is the trick to add values to Custom Fields on a Template.

Thank you,
dave

NumberTabs and DateTabs Aren't Actually Tabs

The NumberTabs and DateTabs collections aren't actually tabs like all other tab collections on the Tabs class are. They are just a list of nullable doubles and a list of nullable datetimes. This means there is no way to specify the positioning of the tabs via the library. This doesn't make sense based on the REST API documentation. I tried including links but they didn't format correctly.

default PurgeState for requested Envelope

            EnvelopeSummary envelopeSummary = envelopesApi.CreateEnvelope(accountID, envDef);
            var envelope = envelopesApi.GetEnvelope(accountID, envelopeSummary.EnvelopeId);
            envelope.Status = "sent";
            envelope.PurgeState = "";
            envelopesApi.Update(accountID, envelope.EnvelopeId, envelope);

PurgeState property had "unpurged" value. I had to clear PurgeState property, since otherwise I was getting

"errorCode": "INVALID_REQUEST_PARAMETER",

"message": "The request contained at least one invalid parameter. Value for 'purgeState' must be 'documents_queued' or 'documents_and_metadata_queued'."

DeleteRecipient functionality missing (was: 'Mark envelope as completed or void' )

Hello again!
My question is quite specific.
For example recipient get an envelope created by template and want to sign it in old style (just print it and sign it by his hand), for our system it's ok. As the result envelope isn't completed and this recipient will receive reminders to complete envelope with some frequency. I want to prevent it. My question: Is there any way to mark envelope as completed or void it or just delete it by using client?

I tried to use UpdateRecipients method, here it's my simple code. It returns true all them time but there's no any effect.

public bool CompleteEnvelope(string envelopeId)
{
var envelope = new Envelope() { EnvelopeId = envelopeId, Login = _account };
envelope.GetRecipients();
var signers = envelope.Recipients.signers;
for (int i = 0; i < signers.Length; i++)
{
signers[i].status = "completed";
}
return envelope.UpdateRecipients(envelope.Recipients);
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.