Skip to content
This repository has been archived by the owner on Oct 17, 2023. It is now read-only.

Signer Attachments #49

Open
alexmac05 opened this issue May 4, 2018 · 1 comment
Open

Signer Attachments #49

alexmac05 opened this issue May 4, 2018 · 1 comment
Labels
enhancement legacy Related to legacy, non-OpenAPI SDK

Comments

@alexmac05
Copy link
Contributor

Add attachment parameters when sending a signature request

@Framinus
Copy link

This is a workaround using the RestSharp request library:

static void RestsharpSignatureRequestAttachments(string apiKey)
{
var key = apiKey;
var httpClient = new RestClient("https://:@api.hellosign.com/v3");
httpClient.Authenticator = new RestSharp.Authenticators.HttpBasicAuthenticator(key, "");
var request = new RestRequest("signature_request/create_embedded");
request.AddParameter("title", "Our agreement");
request.AddFile("testing", "testing.pdf");
string prefix = String.Format("signers[{0}]", "0");
request.AddParameter(prefix + "[email_address]", "james@example.com");
request.AddParameter(prefix + "[name]", "James");
string attachments_prefix = String.Format("attachments[{0}]", "0");
request.AddParameter(attachments_prefix + "[name]", "Driver's License");
request.AddParameter(attachments_prefix + "[instructions]", "Must not be expired");
request.AddParameter(attachments_prefix + "[signer_index]", 0);
request.AddParameter(attachments_prefix + "[required]", true);
IRestResponse response = httpClient.Execute(request);
var content = response.Content;
Console.WriteLine(content);
}

@jtreminio-dropbox jtreminio-dropbox added the legacy Related to legacy, non-OpenAPI SDK label Jun 29, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement legacy Related to legacy, non-OpenAPI SDK
Projects
None yet
Development

No branches or pull requests

4 participants