Skip to content

This is a client library in c# to demonstrate the usage of the signhost api using .net

Notifications You must be signed in to change notification settings

hyperworkxdevteam/SignhostClientLibrary

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Signhost client library

join gitter chat Build status Nuget package Quality Gate

This is a client library in c# to demonstrate the usage of the signhost api using .net. You will need a valid APPKey and APIKey. You can request a APPKey for signhost at ondertekenen.nl.

Install

Get it on NuGet:

PM> Install-Package SignhostClientLibrary

Example code

The following code is an example of how to create and start a sign transaction with two documents.

var client = new SignHostApiClient(new SignHostApiClientSettings("AppName appkey", "apikey or usertoken"));

var transaction = await client.CreateTransactionAsync(new Transaction
{
	Signers = new List<Signer>
	{
		new Signer
		{
			Email = "john.doe@example.com",
			SignRequestMessage = "Could you please sign this document?",
			SendSignRequest = true,
			/*
			 * The verifications listed here are executed in order.
			 * Your last verification _must_ be one of the following:
			 * - PhoneNumberVerification
			 * - ScribbleVerification
			 * - ConsentVerification
			 */
			Verifications = new List<IVerification> {
				new PhoneNumberVerification {
					Number = "+3161234567890"
				},
				new ScribbleVerification {
					ScribbleName = "John Doe",
					RequireHandsignature = true,
				},
			}
		}
	}
});

await client.AddOrReplaceFileToTransactionAsync("PathToFile",    transaction.Id, "First document",    new FileUploadOptions());
await client.AddOrReplaceFileToTransactionAsync("PathOtherFile", transaction.Id, "General agreement", new FileUploadOptions());

/* When everything is setup we can start the transaction flow */
await client.StartTransactionAsync(transaction.Id);

About

This is a client library in c# to demonstrate the usage of the signhost api using .net

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • C# 100.0%