快来看,n8n更新了!从 n8n 发送合同进行电子签名,使用 TurboDocx、Slack 审批和 SharePoint 归档

内容来源:https://blog.n8n.io/spotlight-turbodocx/
内容总结:
【新闻稿】TurboDocx推出n8n签名节点,打通合同自动化“最后一公里”
近日,TurboDocx首席执行官Nicolas Fry撰文介绍,n8n工作流自动化平台此前已能完成合同数据处理、文档生成、审批流转与归档等大部分环节,但唯独缺少合同生效的关键一步——电子签名,导致流程被迫中断、需人工收尾。为此,TurboDocx推出经过验证的原生签名节点,填补这一空白。
据介绍,借助该节点,用户可搭建覆盖合同全生命周期的自动化工作流:Excel表格中标记为“待发送”的合同行将自动触发生成合同文档,经Slack频道由管理人员审批后发送签署,客户完成签名后,已签署的PDF文件自动归档至SharePoint,并同步更新表格状态。整个流程分为“发送”与“归档”两部分,前者按计划定时运行,后者由签名事件触发。
文章详细说明了搭建步骤,包括在Excel中建立合同队列表格、准备含合并变量的Word合同模板、配置TurboDocx文档生成与签名发送节点、设置Slack审批消息、配置SharePoint归档以及端到端测试等,并针对签名文件未归档、表格行未被读取、Slack消息未送达、签名位置错误及自建n8n实例HTTPS回调等常见问题给出排查建议。
文章指出,该方案的核心优势在于:合同条款固定于模板之中,避免法律语言出现偏差;每份合同均须经Slack人工审批,审批记录可追溯;签署完成的PDF统一归档至指定文件夹,状态一目了然。目前TurboDocx免费账户每月提供5次文档生成和5次签名额度,足以支持搭建与测试。用户还可进一步扩展该流程,例如改由Salesforce或HubSpot的商机阶段变更触发、引入AI起草变量段落、按合同金额分流审批人等。
中文翻译:
本篇“认证节点聚焦”客座文章由TurboDocx首席执行官Nicolas Fry撰写。
交易已成交,合同已就绪。它却在某个人的收件箱里躺了三天,等着那句“好,发出去”。等到终于签完字,PDF却跑进了“下载”文件夹,而不是共享网盘。
n8n已经能处理其中大部分环节。它可以提取交易数据、生成文档、走审批流程,并归档到你指定的任何位置。但唯独缺了一个原生节点来处理让合同之所以成为合同的那一步:签名。于是工作流到此为止,剩下的事只能靠人工完成。
在本文中,你将搭建一个工作流来补上这个缺口。Excel中一行标记为“待发送”的记录会变成一份生成的合同。经理在Slack中审批。合同发出等待签署。客户签字后,已签署的PDF归档到SharePoint,该行状态自动更新。签名环节运行在经过认证的TurboDocx节点上。
你将搭建什么
画布分为两部分。一部分负责发送合同,另一部分负责等待签名。
A部分:发送。每15分钟运行一次。
- 定时触发器启动运行。
- Microsoft Excel读取合同表格,仅保留标记为“待发送”的行。
- 循环处理逐条处理合同。
- TurboDocx根据你的模板生成协议并转换为PDF。
- Slack发送“批准并发送/拒绝”消息并等待响应。
- If节点根据回答进行分支。
- TurboDocx将已批准的合同发送签署。
- Microsoft Excel将该行标记为“已发送”或“已拒绝”,Slack通知团队。
B部分:归档。在有人签署时运行。
- TurboDocx触发器在签名时触发并下载已签署的PDF。
- Microsoft SharePoint将其上传到你的合同文件夹。
- Microsoft Excel将该行标记为“已签署”,Slack发布好消息。
开始之前
- 一个n8n实例。云端或自托管均可。如果还没有,可以开始免费试用。
- TurboDocx节点。在n8n中通过节点面板直接从画布安装TurboDocx节点。如果你导入了下方的模板,系统会提示你进行安装。
- 一个TurboDocx账户。免费套餐每月包含5次文档生成和5次签名。用于搭建和测试绰绰有余。
- Microsoft 365(含Excel和SharePoint),并已在n8n中配置好两者的凭据。
- 一个Slack工作区和审批频道,例如#contract-approvals。
在TurboDocx.com创建免费TurboDocx账户,直接从n8n工作流生成文档并发送电子签名。你的账户拥有完整走通本教程所需的一切。如果你正在搭建报价到合同的流程,我们的CPQ产品TurboQuote将配置-定价-报价带入同一套文档和签名引擎。
导入模板以跟随操作。
第1步:在Excel中设置合同队列
每一行代表一份合同,“状态”列就是队列。工作流会拾取所有标记为“待发送”的记录,并随着合同推进更新状态。你的团队有了一个统一的地方来查看每份合同的进展。
在存储在SharePoint或OneDrive中的Excel工作簿里创建一张表,包含以下列:
- 状态:待发送 → 已发送/已拒绝 → 已签署
- 客户名称、公司、邮箱(签署人)
- 金额、开始日期,以及文档ID和签署时间(由工作流填写)
在Microsoft Excel节点中,选择你的工作簿、工作表和表格,然后将操作设置为“查找”,查找列设置为“状态”,查找值设置为“待发送”,并开启“返回所有匹配项”。
第2步:准备合同模板
从法务已批准的合同开始,使用普通的Word .docx文件。将需要变化的部分替换为合并变量,如{clientName}、{amount}和{startDate}。
然后添加两个签名锚点:
- {client_sig}标记签署人签名的位置。
- {client_date}标记签署日期的盖章位置。
将文件上传到TurboDocx并复制模板ID。变量之外的所有内容保持法务原文不变。
第3步:生成合同
打开“生成协议Docx”节点,选择你的凭据,粘贴模板ID。然后将每个变量映射到对应的Excel列:
clientName → {{ $json["Client Name"] }}amount → {{ $json["Amount"] }}startDate → {{ $json["Start Date"] }}
在一行测试数据上运行该节点。几秒钟内你就会得到一份完整的合同,格式与模板完全一致。
第4步:在Slack中审批
这一步由人来把关。Slack节点使用“发送并等待响应”将合同发布到审批频道,附带“批准并发送”和“拒绝”按钮。工作流会等待直到有人点击其中一个。
编辑消息内容,让审批人拥有做出决定所需的信息:客户、金额以及文档链接。If节点将批准的合同送入签名流程。被拒绝的合同在Excel中标记为“已拒绝”,并通知团队。
第5步:发送签署
这一步以前在n8n中比较棘手。合同批准后,工作流将PDF传递给“发送协议进行电子签名”节点(TurboSign:发送签名)。从Excel行中映射签署人的姓名和邮箱。
TurboSign会将签名字段和日期字段放置在{client_sig}和{client_date}锚点处,你无需手动拖拽字段。签署人会收到邮件,并可在任何设备上签字。与此同时,该行状态翻转为“已发送”。
第6步:将已签署的合同归档到SharePoint
B部分从TurboDocx触发器开始。其webhook在你激活工作流时会自动注册,无需复制URL。
在Microsoft SharePoint节点中,选择你的站点和已签署合同文件夹。客户签字后,已签署的PDF被上传,该行标记为“已签署”,Slack通知所有人。
第7步:端到端测试
在将其用于真实客户之前,先用一份合同自己走一遍:
- 激活工作流。
- 在Excel中添加一行,以你自己的邮箱作为签署人,并设置为“待发送”。
- 等待下一次定时运行,或手动运行工作流。
- 在Slack中点击“批准并发送”。
- 从收件箱中签署合同。
- 检查PDF是否在SharePoint中,且该行显示为“已签署”。
如果六个步骤全部走通,你就完成了。从此以后,标记“待发送”和点击“批准”是仅剩的手动步骤。
故障排除
- 已签署的合同未被归档。确保工作流已激活。签名webhook仅在激活时注册。
- 行未被拾取。状态筛选是精确文本匹配,请检查“待发送”中是否有拼写错误和多余空格。
- 没有Slack消息。检查你的Slack应用是否已添加到审批频道。
- 签名位置不对。检查模板中锚点的拼写。必须精确为{client_sig}和{client_date}。
- 在自托管n8n上测试失败,报错“TurboDocx webhooks require an HTTPS callback URL”。签名触发器需要一个公开的HTTPS地址,n8n Cloud开箱即用。在自托管实例上,将n8n置于HTTPS(或隧道)之后,并将WEBHOOK_URL设置为该地址。
为什么这套方案有效
法律语言不能走样。条款固定在模板中。工作流只负责填空。
未经批准的内容不会发出。每份合同都等待Slack中的一次点击,且该审批有记录可查。
签名后不会丢失。每份已签署的PDF都归档到同一个SharePoint文件夹,Excel行一目了然地显示其状态。
下一步方向
- 更换记录系统。改为在Salesforce或HubSpot中交易阶段变化时触发,而非定时触发。
- 让AI起草可变部分。在生成之前添加OpenAI或Anthropic节点,根据通话记录撰写业务概述。条款保持固定。
- 按金额路由。将超过设定金额的合同发送给不同的审批人或频道。
- 签署的是报价而非合同?同样的签名步骤也适用于销售报价。参见CPQ报价模板。
总结
合同不需要在边缘环节增加更多自动化。它们需要的是最后一步被处理好:拿到签名。有了这一步,n8n就能把合同从一行表格一路送到正确文件夹中的已签署PDF,同时仍然由人来做发送的决定。
下载模板,今天就用一个免费的TurboDocx账户发送你的第一份合同。
我们迫不及待想看到你的作品。
实用资源
英文来源:
This Verified Node Spotlight is a guest post written by Nicolas Fry, CEO of TurboDocx.
The deal is closed and the contract is ready. It's been sitting in someone's inbox for three days, waiting for an "OK, send it." Once it's finally signed, the PDF ends up in a Downloads folder instead of the shared drive.
n8n can already handle most of that. It can pull the deal data, generate the document, route it for approval, and file it wherever you like. But there hasn't been a native node for the one step that makes a contract a contract: the signature. So the workflow stops there, and someone finishes the job by hand.
In this post, you'll build a workflow that closes that gap. A row in Excel marked Ready to send becomes a generated contract. A manager approves it in Slack. It goes out for signature. When the client signs, the executed PDF is filed in SharePoint and the row updates itself. The signature step runs on the verified TurboDocx node.
What you'll build
The canvas has two parts. One sends contracts, and the other waits for signatures.
Part A: send. This part runs every 15 minutes.
- Schedule Trigger starts the run.
- Microsoft Excel reads the contract table and keeps only rows marked Ready to send.
- Loop Over Items handles one contract at a time.
- TurboDocx generates the agreement from your template and converts it to PDF.
- Slack posts an Approve & send / Reject message and waits.
- If branches on the answer.
- TurboDocx sends approved contracts for signature.
- Microsoft Excel marks the row Sent or Rejected, and Slack lets the team know.
Part B: file. This part runs when someone signs. - TurboDocx Trigger fires on signature and downloads the executed PDF.
- Microsoft SharePoint uploads it to your contracts folder.
- Microsoft Excel marks the row Signed, and Slack posts the good news.
Before you start - An n8n instance. Cloud or self-hosted both work. Start a free trial if you don't have one yet.
- The TurboDocx node. Install the TurboDocx node directly from the canvas via the Node panel in n8n. You will be prompted to do this if you import the template below.
- A TurboDocx account. The free tier includes 5 document generations and 5 signatures a month. That's plenty for building and testing.
- Microsoft 365 with Excel and SharePoint, and credentials for both set up in n8n.
- A Slack workspace and an approvals channel, such as #contract-approvals.
Create a free TurboDocx account at TurboDocx.com and start generating documents and sending them for e-signature straight from your n8n workflows. Your account has everything you need to follow this walkthrough end to end. And if you're building quote-to-contract flows, TurboQuote, our CPQ product, brings configure-price-quote into the same document and signature engine.
Import the template to follow along.
Step 1: Set up your contract queue in Excel
Each row is one contract, and the Status column is the queue. The workflow picks up anything marked Ready to send and updates the status as the contract moves along. Your team gets one place to see where every contract stands.
Create a table in an Excel workbook stored in SharePoint or OneDrive, with these columns: - Status: Ready to send → Sent / Rejected → Signed
- Client Name, Company, Email (the signer)
- Amount, Start Date, plus Document ID and Signed At, which the workflow fills in
In the Microsoft Excel node, pick your workbook, worksheet, and table, then set Operation to Lookup, Lookup Column to Status, Lookup Value to Ready to send, and turn on Return All Matches.
Step 2: Prepare the contract template
Start with the contract legal has already approved, as a regular Word .docx file. Replace the parts that change with merge variables like {clientName}, {amount}, and {startDate}.
Then add two anchors for the signature: - {client_sig} marks where the signer's signature goes.
- {client_date} marks where the signing date is stamped.
Upload the file to TurboDocx and copy the template ID. Everything outside the variables stays exactly as legal wrote it.
Step 3: Generate the contract
Open the Generate Agreement Docx node, select your credential, and paste in the template ID. Then map each variable to its Excel column:
clientName → {{ $json["Client Name"] }}amount → {{ $json["Amount"] }}startDate → {{ $json["Start Date"] }}
Run the node on a test row. You'll get a finished contract back in a few seconds, formatted exactly like your template.
Step 4: Approve it in Slack
This step is where a person weighs in. The Slack node uses Send and Wait for Response to post the contract to your approvals channel with Approve & send and Reject buttons. The workflow waits until someone clicks one.
Edit the message so the approver has what they need to decide: the client, the value, and a link to the document. The If node sends approvals on to signature. Rejections get marked Rejected in Excel, and the team gets a heads-up.
Step 5: Send it for signature
This is the step that used to be tricky in n8n before. Once the contract is approved, the workflow passes the PDF to the Send Agreement for E-Signature node (TurboSign: Send Signature). Map the signer's name and email from the Excel row.
TurboSign places the signature and date fields at the {client_sig} and {client_date} anchors, so you never drag fields into place by hand. The signer gets an email and signs from any device. Meanwhile, the row flips to Sent.
Step 6: File the signed contract in SharePoint
Part B starts with the TurboDocx Trigger. Its webhook registers itself when you activate the workflow, so there's no URL to copy.
In the Microsoft SharePoint node, pick your site and your signed-contracts folder. When the client signs, the executed PDF is uploaded, the row is marked Signed, and Slack lets everyone know.
Step 7: Test it end to end
Before you point this at real clients, run one contract through yourself: - Activate the workflow.
- Add a row to Excel with your own email as the signer and set it to Ready to send.
- Wait for the next scheduled run, or run the workflow manually.
- Click Approve & send in Slack.
- Sign the contract from your inbox.
- Check that the PDF is in SharePoint and the row says Signed.
If all six steps work, you're done. From here on, marking a row Ready to send and clicking Approve are the only manual steps left.
Troubleshooting - Signed contracts aren't being filed. Make sure the workflow is activated. The signature webhook only registers on activation.
- Rows aren't being picked up. The status filter matches the text exactly, so check for typos and extra spaces in Ready to send.
- No Slack message. Check that your Slack app has been added to the approvals channel.
- Signature lands in the wrong spot. Check the anchor spelling in your template. It must be exactly {client_sig} and {client_date}.
- Testing on self-hosted n8n fails with “TurboDocx webhooks require an HTTPS callback URL”. The signature trigger needs a public HTTPS address, which n8n Cloud provides out of the box. On a self-hosted instance, put n8n behind HTTPS (or a tunnel) and set WEBHOOK_URL to that address.
Why this works
Legal language can't drift. The clauses live in the template. The workflow only fills in the blanks.
Nothing goes out unapproved. Every contract waits for a click in Slack, and that approval is on record.
Nothing gets lost after signing. Every executed PDF lands in the same SharePoint folder, and the Excel row shows its status at a glance.
Where to go from here - Swap the system of record. Trigger on a deal stage change in Salesforce or HubSpot instead of a schedule.
- Let AI draft the variable sections. Add an OpenAI or Anthropic node before generation to write the business overview from your call notes. The clauses stay fixed.
- Route by value. Send contracts over a set amount to a different approver or channel.
- Signing quotes, not contracts? The same signature step works for sales quotes. See the CPQ quote template.
Wrap up
Contracts don't need more automation around the edges. They need the last step handled: getting the signature. With that in place, n8n can take a contract all the way from a spreadsheet row to a signed PDF in the right folder, with a person still making the call to send it.
Download the template and send your first contract today with a free TurboDocx account.
We can't wait to see what you build.
Useful resources
文章标题:快来看,n8n更新了!从 n8n 发送合同进行电子签名,使用 TurboDocx、Slack 审批和 SharePoint 归档
文章链接:https://news.qimuai.cn/?post=5512
本站文章均为原创,未经授权请勿用于任何商业用途