public void SignDocuments(PackageId packageId, string signerId, CapturedSignature capturedSignature) { string bulkSigningKey = "Bulk Signing on behalf of"; IDictionary <string, string> signerSessionFields = new Dictionary <string, string>(); signerSessionFields.Add(bulkSigningKey, signerId); string signerAuthenticationToken = authenticationTokenService.CreateSignerAuthenticationToken(packageId, signerId, signerSessionFields); string signerSessionId = authenticationService.GetSessionIdForSignerAuthenticationToken(signerAuthenticationToken); SignedDocuments signedDocuments = new SignedDocuments(); signedDocuments.Handdrawn = capturedSignature.Handdrawn; Package package = packageService.GetPackage(packageId); foreach (OneSpanSign.API.Document document in package.Documents) { document.Approvals.Clear(); signedDocuments.AddDocument(document); } signingService.SignDocuments(packageId, signedDocuments, signerSessionId); }
public void SignDocuments(PackageId packageId) { SignedDocuments signedDocuments = new SignedDocuments(); Package package = packageService.GetPackage(packageId); foreach (Silanis.ESL.API.Document document in package.Documents) { document.Approvals.Clear(); signedDocuments.AddDocument(document); } signingService.SignDocuments(packageId, signedDocuments); }
public void SignDocuments(PackageId packageId, CapturedSignature capturedSignature) { SignedDocuments signedDocuments = new SignedDocuments(); signedDocuments.Handdrawn = capturedSignature.Handdrawn; Package package = packageService.GetPackage(packageId); foreach (OneSpanSign.API.Document document in package.Documents) { document.Approvals.Clear(); signedDocuments.AddDocument(document); } signingService.SignDocuments(packageId, signedDocuments); }