-->

如何设置电子邮件主题行和电子邮件消息从JSON中的DocuSign(How to Set Email

2019-09-28 15:57发布

谁能给我解释了如何设置电子邮件主题行和使用的DocuSign JSON电子邮件。

注:(JSON字符串有作为HTTP请求传递)。

谢谢你,Vignesh.B

Answer 1:

使用emailNotification属性设置单独的邮件主题和邮件正文每一单收件人。 该emailNotification属性应该每个收件人进行设置。

下面是一个样品的Json createEnvelope请求。

POST / V2 /帐号/ {}帐户ID /信封

{
  "recipients": {
    "signers": [
      {
        "email": "recipientone@acme.com",
        "name": "recipient one",
        "recipientId": "1",
        "routingOrder": "1",
        "emailNotification": {
              "emailSubject": "Please sign the  document Recipient One ",
              "emailBody": "Hello Recipient One,\r\n\r\nYour consultant has sent you a new document to view and sign.  Please click on the View Documents link below, review the content, and sign the document.  If you have any questions, please contact your consultant.\r\n\r\nThank you!",
              "supportedLanguage": "en"
         },
        "tabs": {"signHereTabs": [{"documentId": "1", "pageNumber": "1", "xPosition": "100", "yPosition": "100"}]}
      },
      {
        "email": "recipienttwo@acme.com",
        "name": "recipient two",
        "recipientId": "2",
        "routingOrder": "2",
        "emailNotification": {
              "emailSubject": "Please sign the  document Recipient Two ",
              "emailBody": "Hello Recipient Two,\r\n\r\nYour consultant has sent you a new document to view and sign.  Please click on the View Documents link below, review the content, and sign the document.  If you have any questions, please contact your consultant.\r\n\r\nThank you!",
              "supportedLanguage": "en"
         },        
        "tabs": {"signHereTabs": [{"documentId": "1", "pageNumber": "1", "xPosition": "100", "yPosition": "200"}]}
      }
    ]
  },
  "documents": [
    {
      "documentBase64": "RG9jIFRXTyBUV08gVFdP",
      "documentId": "1",
      "fileExtension": "txt",
      "name": "Simple Contract",
      "order": "1"
    }
  ],
  "status": "Sent"
}


Answer 2:

使用Emailsubject的emailBlurb属性设置为信封,收件人的主题和消息。 这些属性在你的JSON请求的根级别进行设置。

注意:您可以通过指定每个收件人的emailNotification属性来覆盖在信封级属性在此建议答案

下面是一个样品的Json createEnvelope请求。

POST / V2 /帐号/ {}帐户ID /信封

{
 "emailSubject": "Email subject for all recipients",
 "emailBlurb": "Email body for all recipients",
 "status": "Sent",
 "recipients": {
     "signers": [
         {
             "email": "recipientone@acme.com",
             "name": "recipientone",
             "recipientId": "1",
             "routingOrder": "1",
             "tabs": { "signHereTabs": [ { "documentId": "1", "pageNumber": "1", "xPosition": "100", "yPosition": "100" } ] }

         },
         {
             "email": "recipienttwo@acme.com",
             "name": "recipient two",
             "recipientId": "2",
             "routingOrder": "1",
             "tabs": { "signHereTabs": [ { "documentId": "1", "pageNumber": "1", "xPosition": "100", "yPosition": "200" } ] }
         }
     ]
 },
 "documents": [
     {
         "documentBase64": "RG9jIFRXTyBUV08gVFdP",
         "documentId": "1",
         "fileExtension": "txt",
         "name": "Simple Contract",
         "order": "1"
     }
 ]
}


文章来源: How to Set Email Subject Line and Email Message from JSON in Docusign
标签: docusignapi