Skip to main content

Generate branded word documents with Claude AI and Json2Doc (up to 20 pages)

Workflow preview

Workflow preview
100%
Generate branded word documents with Claude AI and Json2Doc (up to 20 pages) preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

This n8n workflow automatically generates professionally formatted Word documents (DOCX) with consistent company branding using AI. It leverages Json2Doc and the Json2Doc MCP server to ...

Best for

  • Document Extraction automation workflows
  • Multimodal AI automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

@n8n/n8n-nodes-langchain.lmchatanthropic, @n8n/n8n-nodes-langchain.outputparserstructured, @n8n/n8n-nodes-langchain.lmchatopenrouter, @n8n/n8n-nodes-langchain.mcpclienttool, n8n-nodes-base.set, @n8n/n8n-nodes-langchain.agent, n8n-nodes-base.formtrigger, n8n-nodes-base.httprequest

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by 8Automator.

Original n8n.io source

1.1 Workflow description

Title
Generate branded word documents with Claude AI and Json2Doc (up to 20 pages)
Workflow name
Generate branded word documents with Claude AI and Json2Doc (up to 20 pages)

Overview

This n8n workflow automatically generates professionally formatted Word documents (DOCX) with consistent company branding using AI. It leverages Json2Doc and the Json2Doc MCP server to transform simple text prompts into complete, multi-page documents.

Get your free API key at: app.json2doc.com

Use Cases

Generate first drafts of:

  • Contracts and legal agreements
  • Internal forms and templates
  • Company announcements and notices
  • Internal documentation and policies
  • Business reports and presentations
  • Guidelines and procedures
  • and much more ...

Key Features

Consistent Company Branding

  • Custom fonts, colors, and typography
  • Company logo in headers
  • Page numbers in footers
  • Controlled spacing and layout
  • Professional heading styles

Multi-Page Document Support

  • Page-based sections (new page)
  • Flow sections (continuous across pages)
  • Automatic pagination
  • Consistent headers and footers throughout

Rich Content Types

  • Multiple heading levels
  • Formatted text and paragraphs
  • Tables with custom styling
  • Ordered and unordered lists
  • Images and logos
  • Auto Generated QR Codes

AI-Driven Generation

Uses Claude Sonnet 4.5 to:

  • Generate appropriate document structure
  • Apply correct formatting
  • Create professional, coherent content

How It Works

1. Input Form

Users provide:

  • Prompt - Description of the desired document (e.g., "Generate an employment contract template")
  • Logo URL - Web-accessible URL to company logo

2. Company Styling

Pre-configured branding is applied (See workflow for Description on how to Update):

  • Font, font Styles (for H1,H2, ...)
  • Header: Company name + logo
  • Footer: Page numbers ("Page X of Y")
  • Spacing rules for all content types
  • Table Styles

3. AI Document Generation

The AI agent:

  1. Retrieves the Json2Doc section schema
  2. Generates JSON configuration for the document
  3. Validates the configuration
  4. Creates a document generation job
  5. Returns the Job ID

4. Processing & Download

  • Waits for document completion (3 seconds initially)
  • Polls job status via API
  • Retries if not complete
  • Downloads the final DOCX file when ready

Setup Requirements

Authentication

You need a Json2Doc API key from app.json2doc.com (Permanently free version available).

Processing Times

Configuration Generation (Model-dependent)

The AI model generates the JSON configuration:

  • Simple documents (1-2 pages): 10-30 seconds
  • Medium documents (3-5 pages): 30-60 seconds
  • Complex documents (10-20 pages): 60-120 seconds

Time varies based on the selected AI model and document complexity.

Json2Doc Processing

Once the configuration is created, Json2Doc generates the DOCX file in 2-6 seconds regardless of document size.

Extensions

This workflow can be integrated with:

  • Cloud storage (Google Drive, Dropbox)
  • Email services for automated delivery
  • Approval workflows
  • Document management systems

Important Limitation

This workflow is only suitable for documents up to 20 pages, as larger documents will exceed the AI model's context window. For longer documents, use the Builder Mode instead: DocumentBuilder Docs

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - Anthropic Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatAnthropic - lmChatAnthropic
Config choices
Version 1.3

Block 2 - Structured Output Parser

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.3

Block 3 - OpenRouter Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenRouter - lmChatOpenRouter
Config choices
Version 1

Block 4 - Json2Doc MCP

Type / Role
@n8n/n8n-nodes-langchain.mcpClientTool - mcpClientTool
Config choices
Version 1.2

Block 5 - Add Company styleguide

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 6 - Generate Sections

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 3

Block 7 - On form submission

Type / Role
n8n-nodes-base.formTrigger - formTrigger
Config choices
Version 2.3

Block 8 - Download Docx

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.3

Block 9 - Wait for Document Generation

Type / Role
n8n-nodes-base.wait - wait
Config choices
Version 1.1

Block 10 - HTTP Request

Type / Role
n8n-nodes-base.httpRequest - httpRequest
Config choices
Version 4.3

Block 11 - is Completed?

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

Block 12 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 13 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 14 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 15 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

3. Summary Table

Workflow Generate branded word documents with Claude AI and Json2Doc (up to 20 pages)
Complexity advanced
Nodes 15
Categories Document Extraction, Multimodal AI
Author 8Automator
Published 30 Nov 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/11370/11370.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Generate branded word documents with Claude AI and Json2Doc (up to 20 pages) do?

This n8n workflow automatically generates professionally formatted Word documents (DOCX) with consistent company branding using AI. It leverages Json2Doc and the Json2Doc MCP server to ...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Document Extraction, Multimodal AI use case.