Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/node.js/34.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Node.js 收件人未收到Docusign复合模板,但该模板显示在DS收件箱中/已发送_Node.js_Docusignapi_Docusigncompositetmplts - Fatal编程技术网

Node.js 收件人未收到Docusign复合模板,但该模板显示在DS收件箱中/已发送

Node.js 收件人未收到Docusign复合模板,但该模板显示在DS收件箱中/已发送,node.js,docusignapi,docusigncompositetmplts,Node.js,Docusignapi,Docusigncompositetmplts,我遵循的食谱可以在这里找到: 但我发现,尽管信封显示为已在docusign收件箱中发送,但收件人不会收到,下面是代码 const tabs = getTabsMethodWorkingForStandaloneTemplates({ name: "name", email: "name@email.com" }); // Create a signer recipient for the signer role of the server template let signer1

我遵循的食谱可以在这里找到:

但我发现,尽管信封显示为已在docusign收件箱中发送,但收件人不会收到,下面是代码

const tabs = getTabsMethodWorkingForStandaloneTemplates({
    name: "name",
    email: "name@email.com"
});
// Create a signer recipient for the signer role of the server template
let signer1 = docusign.Signer.constructFromObject({
    email: args.signerEmail,
    name: args.signerName,
    roleName: "signer",
    recipientId: "1",
    // Adding clientUserId transforms the template recipient
    // into an embedded recipient:
    clientUserId: args.signerClientId,
    tabs
});

// Recipients object:
let recipientsServerTemplate = docusign.Recipients.constructFromObject({
    signers: [signer1],
});

// create a composite template for the Server Template
let compTemplate1 = docusign.CompositeTemplate.constructFromObject({
    compositeTemplateId: "1",
    serverTemplates: [
        docusign.ServerTemplate.constructFromObject({
            sequence: 1,
            templateId: args.templateId
        })
    ],
    // Add the roles via an inlineTemplate
    inlineTemplates: [
        docusign.InlineTemplate.constructFromObject({
            sequence: 1,
            recipients: recipientsServerTemplate
        })
    ]
});



//const compTemplate2 = getCompositeTemplateFromHTML(args);

const eventNotification = new docusign.EventNotification();
eventNotification.url = 'http://pj.pagekite.me';
eventNotification.includeDocuments = true;
eventNotification.loggingEnabled = true;
eventNotification.envelopeEvents = getEnvelopeEvents();

// create the envelope definition
let env = docusign.EnvelopeDefinition.constructFromObject({
    status: "sent",
    compositeTemplates: [
        compTemplate1,
    //  compTemplate2
    ],
    eventNotification
});

try {
    // Step 2. call Envelopes::create API method
    // Exceptions will be caught by the calling function
    let results = await envelopesApi.createEnvelope(
        args.accountId,
        {envelopeDefinition: env}
    );

    let envelopeId = results.envelopeId;
    console.log(`Envelope was created. EnvelopeId ${envelopeId}`);
} catch (e) {
    debugger
}

你有clientUserId在里面。这意味着嵌入式签名。删除该选项,将发送一封电子邮件进行远程签名。这两者是相互排斥的。不能两者兼得。

就是这样!谢谢