npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

n8n-nodes-notion-overlimit-writer

v2.13.8

Published

Enhanced n8n node for unlimited Notion content with professional markdown-to-rich-text conversion, robust property management, comprehensive file support, full-featured page read/export capabilities, and fast content erasure with backup functionality

Readme

n8n-nodes-notion-overlimit-writer

npm version License: MIT

A powerful n8n community node that enables writing unlimited content to Notion properties with advanced multi-mapping capabilities, dynamic page selection, and intelligent allocation strategies.

🚀 Enhanced Features (v2.0+)

Multi-Input/Output Mapping

  • Multiple Content Fields: Process multiple input fields in a single execution
  • Independent Settings: Each mapping can have its own chunk size and allocation strategy
  • Property Isolation: No conflicts between different content mappings
  • Parallel Processing: All mappings process simultaneously for maximum speed

Dynamic Page Selection

  • Manual Entry: Enter page ID or URL directly
  • Database Selection: Choose from databases, then select specific pages
  • Global Search: Search and select from all accessible pages
  • Smart Validation: Pre-execution validation of page access and properties

Advanced Content Processing

  • Unlimited Content: Write text of any size to Notion properties
  • Intelligent Chunking: Automatically splits content into optimal chunks (1900 chars by default)
  • Greedy Allocation: Fills one property completely before moving to the next (maximizes efficiency)
  • Balanced Allocation: Distributes content evenly across all available properties
  • Global + Override Settings: Set defaults globally, override per mapping as needed

Enhanced User Experience

  • Pre-Execution Validation: Validate all configurations before processing any content
  • Fail-Fast Error Handling: Stop on first error with detailed diagnostics
  • Rich Text Support: Maintains proper Notion rich text formatting
  • Comprehensive Logging: Detailed execution metrics and error reporting

📦 Installation

Install via n8n Community Nodes

  1. Go to SettingsCommunity Nodes in your n8n instance
  2. Click Install a community node
  3. Enter: n8n-nodes-notion-overlimit-writer
  4. Click Install

Install via npm (for self-hosted n8n)

npm install n8n-nodes-notion-overlimit-writer

Then restart your n8n instance.

🔧 Configuration

Prerequisites

  1. Notion Integration: Create a Notion integration and get your API key

  2. Page Access: Share your target page with the integration

    • Open your Notion page
    • Click "Share" → "Invite" → Select your integration
  3. Property Setup: Ensure your page has the required text properties

    • Add properties like "Text", "Text 2", "Text 3" to your page/database

Node Parameters

Required Parameters

  • Page ID: The Notion page ID (32-character hex string)

    • Example: 29e81e6b477081aeab51f7a4a8a89642
    • Can be found in the page URL
  • Content Field: The input field containing your large text content

    • Default: content
    • Must contain string data
  • Output Properties: Comma-separated list of Notion property names

    • Example: Text, Text 2, Text 3
    • Properties must exist on the target page

Advanced Options

  • Chunk Size: Characters per chunk (100-2000)

    • Default: 1900 (recommended for safety margin)
    • Lower values = more chunks, higher values = fewer chunks
  • Allocation Strategy: How to distribute content

    • greedy (default): Fill Property 1 → Property 2 → Property 3
    • balanced: Distribute evenly across all properties
  • Parallel Requests: Update multiple properties simultaneously

    • Default: true (faster execution)
    • Set to false for sequential updates
  • Validate Properties: Check property existence before processing

    • Default: true (recommended)
    • Validates page access and property names
  • Max Retries: Maximum API request retries

    • Default: 3
    • Helps handle temporary API issues

📋 Usage Examples

Basic Usage

{
  "pageId": "29e81e6b477081aeab51f7a4a8a89642",
  "contentField": "transcript",
  "outputProperties": {
    "propertyNames": "Text, Text 2, Text 3"
  }
}

Input Data:

{
  "transcript": "Your very long content here... (252,000 characters)",
  "title": "Meeting Notes",
  "date": "2024-01-15"
}

Result: Content automatically split and written to Text, Text 2, and Text 3 properties.

Advanced Configuration

{
  "pageId": "29e81e6b477081aeab51f7a4a8a89642",
  "contentField": "articleContent",
  "outputProperties": {
    "propertyNames": "Article Text, Article Text 2, Article Text 3, Article Text 4"
  },
  "advancedOptions": {
    "chunkSize": 1800,
    "allocationStrategy": "balanced",
    "parallelRequests": true,
    "validateProperties": true,
    "maxRetries": 5
  }
}

📊 Allocation Strategies

Greedy Allocation (Default)

Fills properties sequentially, maximizing content per property:

Content: 380,000 characters
├── Text: 190,000 chars (100% full)
├── Text 2: 190,000 chars (100% full)
└── Text 3: 0 chars (unused)

Best for: Most content types, minimizes property usage

Balanced Allocation

Distributes content evenly across all properties:

Content: 380,000 characters
├── Text: 126,667 chars (~67% full)
├── Text 2: 126,667 chars (~67% full)
└── Text 3: 126,666 chars (~67% full)

Best for: Visual balance, specific formatting requirements

📁 File Support & Limitations

✅ Supported File Input Types

  • URLs: Public file URLs from any web service

    "https://example.com/document.pdf"
    "https://drive.google.com/uc?id=FILE_ID&export=download"
  • Notion File IDs: Files already uploaded to Notion

    "abc123def-456-789-ghi012jkl"

❌ NOT Supported: Binary Data

Important: Notion's API does NOT accept binary data directly. This is a Notion API limitation, not a node limitation.

❌ Binary data from "Convert to File" node
❌ File buffers from HTTP Request node  
❌ Direct file uploads from file system

🔄 Workarounds for Binary Files

If you have binary file data, use one of these approaches:

Option 1: Google Drive Upload

1. HTTP Request → Upload to Google Drive
2. Get public sharing URL
3. Use URL in this node

Option 2: AWS S3 Upload

1. AWS S3 → Upload file
2. Get public URL or signed URL
3. Use URL in this node

Option 3: External File Hosting

1. Upload to: Dropbox, OneDrive, CloudFlare R2, etc.
2. Get public URL
3. Use URL in this node

Option 4: Manual Notion Upload

1. Upload file directly in Notion interface
2. Get the file ID from the property
3. Use file ID in this node

File Handling Modes

  • Replace All Files: Overwrites all existing files in the property (default)
  • Append to Existing Files: Adds new files while keeping existing ones

🎨 Enhanced Markdown Support (v2.2+)

Rich Text Processing

The node now supports comprehensive markdown-to-rich-text conversion using @tryfabric/martian:

Supported Markdown Features

  • Headers: # H1, ## H2, ### H3
  • Bold: **bold text**
  • Italic: *italic text*
  • Code: `inline code`
  • Strikethrough: ~~strikethrough~~
  • Links: [text](url)
  • Lists: Ordered and unordered lists
  • Code blocks: ` language
  • Blockquotes: > quote text

Usage Example

{
  "contentFormat": "rich",
  "inputField": "# My Document\n\nThis is **bold** and *italic* text with `code`."
}

Result in Notion

The text will appear in Notion with proper formatting:

  • Headers as actual headers
  • Bold text rendered bold
  • Italic text rendered italic
  • Code with proper code formatting

Fallback Behavior

If markdown parsing fails, the node gracefully falls back to plain text mode.

🏗️ Technical Details

Notion API Limits

  • Max Rich Text Blocks: 100 per property
  • Max Characters per Block: 2000
  • Max Characters per Property: ~190,000 (100 × 1900)
  • Safe Chunk Size: 1900 characters (safety margin)

Content Processing Pipeline

  1. Content Extraction: Get content from specified input field
  2. Sanitization: Remove invalid characters and control codes
  3. Chunking: Split into optimal-sized chunks
  4. Allocation: Assign chunks to properties using chosen strategy
  5. Rich Text Building: Convert chunks to Notion rich text blocks
  6. Validation: Verify all limits are respected
  7. API Updates: Send parallel/sequential PATCH requests
  8. Result Aggregation: Combine all update results

Error Handling

The node provides detailed error messages for common issues:

  • Invalid Page ID: Format validation and suggestions
  • Missing Properties: Lists available properties
  • Content Too Large: Calculates required properties
  • API Errors: Notion-specific error handling
  • Network Issues: Automatic retries with backoff

🔄 Migration from Workflow

If you're migrating from the manual workflow approach:

Old Workflow (5 nodes)

Trigger → Settings → Chunking → Allocation → HTTP Updates

New Node (1 node)

Trigger → Notion Overlimit Writer

Configuration Mapping

| Workflow Setting | Node Parameter | |------------------|----------------| | input_field | Content Field | | output_field | Output Properties | | page_id | Page ID | | Hardcoded chunks | Chunk Size | | Greedy logic | Allocation Strategy |

🧪 Testing

# Run tests
npm test

# Run tests with coverage
npm run test:coverage

# Run tests in watch mode
npm run test:watch

🛠️ Development

# Clone repository
git clone https://github.com/yourusername/n8n-nodes-notion-overlimit-writer.git
cd n8n-nodes-notion-overlimit-writer

# Install dependencies
npm install

# Build the node
npm run build

# Run in development mode
npm run dev

# Lint code
npm run lint

# Format code
npm run format

📈 Performance

  • Small Content (<10K chars): ~200ms execution time
  • Medium Content (50K chars): ~500ms execution time
  • Large Content (200K+ chars): ~1-2s execution time
  • Parallel Updates: 2-3x faster than sequential
  • Memory Usage: Minimal, processes content in chunks

🤝 Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/amazing-feature
  3. Make your changes and add tests
  4. Ensure tests pass: npm test
  5. Commit changes: git commit -m 'Add amazing feature'
  6. Push to branch: git push origin feature/amazing-feature
  7. Open a Pull Request

📜 License

This project is licensed under the MIT License - see the LICENSE file for details.

🆘 Support

🎯 Roadmap

  • [ ] Support for markdown formatting preservation
  • [ ] HTML to rich text conversion
  • [ ] Custom allocation rules
  • [ ] Batch processing for multiple pages
  • [ ] Database property support
  • [ ] Block content support (not just properties)

🙏 Acknowledgments

  • n8n - The amazing workflow automation platform
  • Notion - For their comprehensive API
  • Original workflow concept from the n8n community

Made with ❤️ for the n8n community