telegraph-md2node

n8n custom node to convert Markdown into Telegraph Node JSON

Package Information

Released: 10 mo ago
Downloads: 5 weekly / 31 monthly
Latest Version: 0.1.5

Documentation

n8n-nodes-telegraph-md2node

Custom n8n node that takes Markdown and returns a telegra.ph API-compatible node JSON structure.

Features

  • Converts Markdown into a Telegraph Node array (strings and tag objects).
  • Maps headings (h1..h4) into Telegraph-allowed tags (h3, h4).
  • Supports links, lists, blockquotes, inline and block code, images, and separators.
  • Ready to publish as an n8n custom node repository.

Installation

npm install
npm run build

Usage in n8n

  1. Copy the repository contents into your n8n custom nodes directory.
  2. Run npm install && npm run build.
  3. Restart n8n — the Telegraph MD → Node node will appear in the palette.
  4. Provide Markdown via the Markdown parameter (expressions like {{$json["markdown"]}} work).
  5. The output returns { "content": [...] }, compatible with Telegraph createPage/editPage.

Output example

Example for input Emphasis with *asterisks*:

[
  {
    "tag": "p",
    "children": [
      "Emphasis with ",
      { "tag": "em", "children": ["asterisks"] }
    ]
  }
]

Tests

npm test

License

MIT

Discussion