Free n8n template

NDA generation from a request form n8n template

What it does

A webhook receives an NDA request, Claude extracts the counterparty's legal name, signer and any non-standard asks as strict JSON, and review rules in code decide the route. Standard requests get a copy of your approved Google Docs template with only the variable fields filled. You need n8n, an Anthropic API key, Google Drive and Docs, and Slack.

What this workflow does

  1. NDA request form (Webhook) receives the form fields: requester, counterparty company, contact, purpose, mutual or one-way, whether they want to use their own paper, and free-text notes.
  2. Validate request and build prompt (Code) checks the required fields, picks the template for the NDA type and builds a Messages API request with a strict JSON schema.
  3. Claude: extract NDA fields (HTTP Request) calls the Anthropic Messages API with structured outputs. It returns the legal entity name, signer, country, requested governing law and term, a one-sentence purpose and any requested changes. It returns null rather than guessing.
  4. Apply review rules (Code) parses the response, handles refusal and max_tokens stop reasons, and applies your rules: approved governing law list, maximum term, US entities only, no counterparty paper, no requested edits, no missing legal name.
  5. Standard request? (If) splits standard requests from ones that need a lawyer.
  6. Copy NDA template (Google Drive) copies the approved mutual or one-way template into a drafts folder.
  7. Fill template fields (Google Docs) replaces the bracketed tags with the extracted values. The legal text is never sent to or written by the model.
  8. Slack: draft ready posts the doc link to the requesters’ channel. Slack: legal review needed gets every non-standard request, and any failed API call, with the reasons listed.

Before you import

  • n8n 1.x, cloud or self-hosted.
  • An Anthropic API key, added as n8n’s built-in Anthropic credential.
  • Google Drive and Google Docs OAuth2 credentials with access to your template folder.
  • A Slack app with chat:write, invited to both channels.
  • Counsel-approved mutual and one-way NDA templates in Google Docs.

Setup

  1. Import the JSON file into n8n and open each node with a warning icon to attach credentials.
  2. In Validate request and build prompt, replace REPLACE_WITH_MUTUAL_TEMPLATE_DOC_ID and REPLACE_WITH_ONE_WAY_TEMPLATE_DOC_ID. In Apply review rules, edit ALLOWED_GOVERNING_LAW, DEFAULT_TERM_YEARS and MAX_TERM_YEARS to match what counsel approved.
  3. Add these tags to your templates: [[COUNTERPARTY_LEGAL_NAME]], [[COUNTERPARTY_SIGNER_NAME]], [[COUNTERPARTY_SIGNER_TITLE]], [[EFFECTIVE_DATE]], [[PURPOSE]], [[TERM_YEARS]], [[GOVERNING_LAW]].
  4. On Copy NDA template, replace REPLACE_WITH_NDA_DRAFTS_FOLDER_ID.
  5. Set REPLACE_WITH_SLACK_CHANNEL_ID_FOR_REQUESTERS and REPLACE_WITH_SLACK_CHANNEL_ID_FOR_LEGAL.
  6. Point your form’s submit action at the production webhook URL.

Test it

Send a test POST with a clean US request and confirm a filled draft appears in the folder. Then send one that names a German parent company and a five-year term. It should land in the legal channel with both reasons. Check the draft for any tag that was not replaced.

Make it production-ready

  • Set an error workflow in the workflow settings so a failed Google or Slack call alerts someone.
  • Add a CRM lookup before generation so the stored legal entity name wins over the extracted one, and check for an NDA already on file.
  • Keep a log row per request (requester, route, reasons, doc ID) in a sheet or database for audit.
  • The Claude node tries up to three times, five seconds apart. Watch Google Docs API quotas if requests arrive in bursts.
  • Have legal review the first few weeks of standard drafts before you add the e-signature step. claude-haiku-5-5 is a cheaper option once volume grows.

Read the full guide at How to automate NDA generation, or talk to us if you want help wiring in e-signature and your CRM.

Next steps