Skip to content

Latest commit

 

History

History
266 lines (212 loc) · 7.03 KB

README.md

File metadata and controls

266 lines (212 loc) · 7.03 KB

SignNow

SignNow .NET SDK

About SignNow

SignNow is a powerful web-based e-signature solution that streamlines the signing process and overall document flow for businesses of any size. SignNow offers SaaS as well as public and private cloud deployment options using the same underlying API. With SignNow you can easily sign, share and manage documents in compliance with international data laws and industry-specific regulations. SignNow enables you to collect signatures from partners, employees and customers from any device within minutes.

API Contact Information

If you have questions about the SignNow API, please visit https://help.signnow.com/docs or email [email protected].

See additional contact information at the bottom.

Installation

PM> Install-Package SignNow

Note. You will need Newtonsoft.Json to work with the results returned by each method as you will see in the Examples.

PM> Install-Package Newtonsoft.Json

Setup

using SignNow;
using Newtonsoft.Json.Linq;
using System.IO;

SignNow.Config.init("YOUR CLIENT ID", "YOUR CLIENT SECRET", "https://api-eval.signnow.com");

Examples

To run the examples you will need an API key. You can get one here https://www.signnow.com/api. For a full list of accepted parameters, refer to the SignNow REST Endpoints API guide: https://help.signnow.com/docs.

#OAuth2

Request OAuth Token

JObject OAuthRes = SignNow.OAuth2.RequestToken("YOUR USERNAME", "YOUR PASSWORD");

Verify OAuth Token

JObject OAuthVRes = SignNow.OAuth2.Verify(AccessToken);

User

Create New User

JObject newAccountRes = SignNow.User.Create("[email protected]", "(123) 123-1234", "Firstname", "Lastname");

Retreive User Account Information

JObject accountRes = SignNow.User.Get(AccessToken);

Document

Get Document

//without annotations
JObject docRes = SignNow.Document.Get(AccessToken, "YOUR DOCUMENT ID");

//with annotations
JObject docRes = SignNow.Document.Get(AccessToken, "YOUR DOCUMENT ID", true);

Create New Document

JObject newDocRes = SignNow.Document.Create(AccessToken, "pdf-sample.pdf");

Create New Document and Extract the Fields

JObject newDocExtRes = SignNow.Document.Create(AccessToken, "Example Fields.docx", true);

Update Document

dynamic dataObj = new
{
  fields = new[]
  {
    new
    {
      x = 10,
      y = 10,
      width = 122,
      height = 34,
      page_number = 0,
      role = "Buyer",
      required = true,
      type = "signature"
    }
  }
};

JObject updateDocRes = SignNow.Document.Update(AccessToken, "YOUR DOCUMENT ID", dataObj);

Delete Document

JObject deleteDocRes = SignNow.Document.Delete(AccessToken, "YOUR DOCUMENT ID");

Download Document

JObject downloadDocRes = SignNow.Document.Download(AccessToken, "YOUR DOCUMENT ID", "/", "sample");

Send Free Form Invite

dynamic inviteDataObj = new
{
  from = "[email protected]",
  to = "[email protected]"
};

JObject sendFreeFormInviteRes = SignNow.Document.Invite(AccessToken, "YOUR DOCUMENT ID", inviteDataObj);

Send Role-based Invite

dynamic inviteDataObj = new {
  to = new [] {
    new {
      email = "[email protected]",
      role_id = "",
      role = "Role 1",
      order = 1,
      authentication_type = "password",
      password = "SOME PASSWORD",
      expiration_days = 15,
      reminder = 5
    },
    new {
      email = "[email protected]",
      role_id = "",
      role = "Role 2",
      order = 2,
      authentication_type = "password",
      password = "SOME PASSWORD",
      expiration_days = 30,
      reminder = 10
    }
  },
  from = "[email protected]",
  cc = new [] {
    "[email protected]"
  },
  subject = "YOUR SUBJECT",
  message = "YOUR MESSAGE"
};

JObject sendRoleBasedInviteRes = SignNow.Document.Invite(AccessToken, DocumentId, inviteDataObj);

Cancel Invite

JObject cancelInviteRes = SignNow.Document.CancelInvite(AccessToken, "YOUR DOCUMENT ID");

Merge Existing Documents

dynamic mergeDocsObj = new
{
  name = "My New Merged Doc",
  document_ids = new[] { "YOUR DOCUMENT ID", "YOUR DOCUMENT ID" }
};

JObject mergeDocsRes = SignNow.Document.Merge(AccessToken, mergeDocsObj, "/", "sample-merge");

Document History

JArray docHistoryRes = SignNow.Document.History(AccessToken, "YOUR DOCUMENT ID");

Template

Create Template

JObject newTemplateRes = SignNow.Template.Create(AccessToken, "YOUR DOCUMENT ID", "My New Template");

Copy Template

JObject copyTemplateRes = SignNow.Template.Copy(AccessToken, "YOUR TEMPLATE ID", "My Copy Template Doc");

Folder

Filters Values
signing-status waiting-for-me, waiting-for-others, signed, pending
document-updated new Date()
document-created new Date()
Sort Values
document-name asc/desc
updated asc/desc
created asc/desc

List Folders

JObject listFoldersRes = SignNow.Folder.List(AccessToken);

Get Folder

JObject getFolderRes = SignNow.Folder.Get(AccessToken, "YOUR FOLDER ID");

Webhook

Create Webhook

Events Description
document.create Webhook is triggered when a document is uploaded to users account in SignNow
document.update Webhook is triggered when a document is updated (fields added, text added, signature added, etc.)
document.delete Webhook is triggered when a document is deleted from
invite.create Webhook is triggered when an invitation to a SignNow document is created.
invite.update Webhook is triggered when an invite to Signnow document is updated. Ex. A signer has signed the document.
JObject createWebhookRes = SignNow.Webhook.Create(AccessToken, "document.create", "YOUR URL");

List Webhooks

JObject listWebhooksRes = SignNow.Webhook.List(AccessToken);

Delete Webhook

JObject deleteWebhookRes = SignNow.Webhook.Delete(AccessToken, "YOUR WEBHOOK ID");

Link

Create Link

JObject createLinkRes = SignNow.Link.Create(AccessToken, "YOUR DOCUMENT ID");

Updates

  • 1/21/2016 - Every method now contains an additional ResultFormat argument that allows you to specify JSON (default) or XML.
  • 2/10/2016 - SignNow.Document.Invite now has an optional send email argument, updated documentation with new Role-based invite example.

Additional Contact Information

SUPPORT

https://university.signnow.com/. To contact SignNow support, please email [email protected].

SALES

For pricing information, please call (800) 831-2050 or email [email protected].