C# 为每个签名者创建私有消息

C# 为每个签名者创建私有消息,c#,docusignapi,C#,Docusignapi,根据DocuSign,可以发送一个信封,信封中的每个签名者都会收到一条私人消息。我查看了docusignrestapi文档,找不到任何私人消息的引用,也找不到有关如何创建私人消息的详细信息 有人能提供有关私有消息功能的RESTAPI实现的详细信息吗?另外一个例子也很好。您可以为每个收件人指定emailNotification属性。文件 这是一个示例请求 POST/v2/accounts/{accountId}/信封 使用C SDK 完整代码 谢谢你的回复。是的,我相信这个方法,连同收件人便笺属性

根据DocuSign,可以发送一个信封,信封中的每个签名者都会收到一条私人消息。我查看了docusignrestapi文档,找不到任何私人消息的引用,也找不到有关如何创建私人消息的详细信息

有人能提供有关私有消息功能的RESTAPI实现的详细信息吗?另外一个例子也很好。

您可以为每个收件人指定emailNotification属性。文件

这是一个示例请求

POST/v2/accounts/{accountId}/信封

使用C SDK 完整代码


谢谢你的回复。是的,我相信这个方法,连同收件人便笺属性应该给我们提供我们需要的功能。我们正在使用c SDK,我需要检查它并确保它受支持。用代码更新了答案以使用c SDK创建信封。
{
  "status": "sent",
  "recipients": {
      "signers": [
          {
             "email": "janedoe@acme.com",
             "name": "jane doe",
             "recipientId": 1,
             "emailNotification": {
                "emailSubject": "Please sign the  document(s) (jane doe)",
                "emailBody": "Hello Jane Doe,\r\n\r\nYour have a new document to view and sign.  Please click on the View Documents link below, review the content, and sign the document.  ",
                "supportedLanguage": "en"
              },
              "tabs": {"signHereTabs": [ { "documentId": "1", "pageNumber": "1", "xPosition": "80", "yPosition": "80"}]}
          },
          {
             "email": "johnsmith@acme.com",
             "name": "john smith",
             "recipientId": 2,
             "emailNotification": {
                "emailSubject": "Please sign the  document(s) (john smith)",
                "emailBody": "Hello john smith,\r\n\r\nYour have a new document to view and sign.  Please click on the View Documents link below, review the content, and sign the document.  ",
                "supportedLanguage": "en"
              },
              "tabs": {"signHereTabs": [ { "documentId": "1", "pageNumber": "1", "xPosition": "80", "yPosition": "180"}]}
          }
      ]
  },
  "documents": [
      {
          "documentId": "1", "name": "Contract", "fileExtension": "txt", "documentBase64": "RG9jIFRXTyBUV08gVFdP"
      }
  ]
}
    public void CreateEnvelopeSeparateEmailNotificationForRecipients()
    {
        string accountID = Init();

        byte[] fileBytes = System.IO.File.ReadAllBytes(@"C:\temp\test.pdf");
        var envDef = new EnvelopeDefinition()
        {
            Status = "sent",
            Recipients = new Recipients()
            {
                Signers = new List<Signer>() 
                {
                    new Signer()
                    {
                        Email = "janedoe@acme.com",
                        Name = "jane doe",
                        RecipientId = "1",
                        RoutingOrder = "1",
                        EmailNotification = new RecipientEmailNotification()
                        {
                            EmailSubject = "Please sign the  document(s) (jane doe)",
                            EmailBody = "This is email body for Jane Doe"
                        },
                        Tabs = new Tabs() { SignHereTabs =  new List<SignHere>(){ new SignHere() { DocumentId = "1", XPosition = "100",YPosition = "300", PageNumber = "1" } } }
                    },
                    new Signer()
                    {
                        Email = "johnsmith@acme.com",
                        Name = "JohnSmith",
                        RecipientId = "2",
                        RoutingOrder = "1",
                        EmailNotification = new RecipientEmailNotification()
                        {
                            EmailSubject = "Please sign the  document(s) (John Smith)",
                            EmailBody = "This is email body for John Smith"
                        },
                        Tabs = new Tabs() { SignHereTabs =  new List<SignHere>(){ new SignHere() { DocumentId = "1", XPosition = "200",YPosition = "300", PageNumber = "1" } } }
                    }
                }
            },
            Documents = new List<Document>()
            {
                new Document()
                {
                    DocumentBase64 = System.Convert.ToBase64String(fileBytes),
                    Name = "Contract",
                    DocumentId = "1"
                }
            }               
        };

        EnvelopesApi envelopesApi = new EnvelopesApi();
        EnvelopeSummary envelopeSummary = envelopesApi.CreateEnvelope(accountID, envDef);
    }