{
  "name": "Turn a Markdown report into a branded PDF + shareable link with Rendex",
  "nodes": [
    {
      "parameters": {
        "content": "## 📄 Markdown report → branded PDF + share link — Rendex Artifact\n\n**Who it's for:** anyone who generates recurring reports, digests, or summaries and wants a polished, on-brand PDF **plus a hosted share page** — in one call, no design tool.\n\n**What it does:** the **Rendex Artifact** node turns a Markdown (or HTML) document into a branded **PDF + PNG** and a hosted **share page**, returning signed URLs for each.\n\n**How it works:**\n1. A trigger supplies the report body (here Manual + sample **Report** — swap in your data source + an AI/summary step)\n2. **Rendex — Create Artifact** renders it branded and returns `{{ $json.pdfUrl }}`, `{{ $json.pngUrl }}`, `{{ $json.shareUrl }}`\n3. **Report Links** exposes those URLs — ready to email, Slack, or post anywhere\n\n**How to use:**\n1. Install `n8n-nodes-rendex` and add your **Rendex API** credential (free key at rendex.dev)\n2. Set your brand **Header**, **Accent Color**, and **Logo URL** on the Artifact node\n3. Click **Test workflow** — open the `shareUrl` to see the hosted page\n\n📚 Docs: https://rendex.dev/docs/n8n",
        "height": 480,
        "width": 440
      },
      "id": "sticky-overview",
      "name": "Overview",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [-380, 100]
    },
    {
      "parameters": {
        "content": "### 1 · Report content\nSwap this for your real report — a database query, an analytics digest, or an **AI Agent** that writes the summary. Just output Markdown in a `reportBody` field.",
        "height": 320,
        "width": 320,
        "color": 4
      },
      "id": "sticky-source",
      "name": "Source note",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [100, 100]
    },
    {
      "parameters": {},
      "id": "manual-trigger",
      "name": "When clicking Test",
      "type": "n8n-nodes-base.manualTrigger",
      "typeVersion": 1,
      "position": [160, 300]
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            { "id": "r1", "name": "title", "value": "Weekly Growth Report", "type": "string" },
            { "id": "r2", "name": "reportBody", "value": "# Weekly Growth Report\n\n**Week of July 21, 2026**\n\n## Highlights\n- Signups up **18%** week-over-week\n- 3 new enterprise trials started\n- Churn held flat at 1.2%\n\n## Next steps\n1. Follow up with the enterprise trials\n2. Ship the onboarding tweak\n3. Publish the case study\n\n> Rendered automatically with Rendex.", "type": "string" }
          ]
        },
        "options": {}
      },
      "id": "report-data",
      "name": "Report",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [360, 300]
    },
    {
      "parameters": {
        "content": "### 2 · Render the branded artifact\n**Content** is an expression, so `{{ $json.reportBody }}` (Markdown) is injected. Set **Output Formats** to PDF + PNG (each charges 1 credit). Brand it under **Additional Options** → Header / Accent Color / Logo URL. Returns `pdfUrl`, `pngUrl`, and a hosted `shareUrl`.",
        "height": 340,
        "width": 340,
        "color": 5
      },
      "id": "sticky-render",
      "name": "Render note",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [620, 90]
    },
    {
      "parameters": {
        "resource": "artifact",
        "operation": "create",
        "content": "={{ $json.reportBody }}",
        "inputFormat": "markdown",
        "formats": ["pdf", "png"],
        "artifactOptions": {
          "header": "={{ $json.title }}",
          "accentColor": "#EA580C",
          "footer": "Generated by your company · Confidential"
        }
      },
      "id": "rendex-artifact",
      "name": "Rendex — Create Artifact",
      "type": "n8n-nodes-rendex.rendex",
      "typeVersion": 1,
      "position": [700, 300]
    },
    {
      "parameters": {
        "content": "### 3 · Use the links\nThe artifact returns ready-to-share URLs. Wire **Report Links** into **Gmail** (attach the PDF), **Slack** (post the `shareUrl`), or a database. The `shareUrl` is a hosted preview page — no upload needed.",
        "height": 320,
        "width": 320,
        "color": 3
      },
      "id": "sticky-use",
      "name": "Use note",
      "type": "n8n-nodes-base.stickyNote",
      "typeVersion": 1,
      "position": [980, 100]
    },
    {
      "parameters": {
        "assignments": {
          "assignments": [
            { "id": "u1", "name": "shareUrl", "value": "={{ $json.shareUrl }}", "type": "string" },
            { "id": "u2", "name": "pdfUrl", "value": "={{ $json.pdfUrl }}", "type": "string" },
            { "id": "u3", "name": "pngUrl", "value": "={{ $json.pngUrl }}", "type": "string" }
          ]
        },
        "options": {}
      },
      "id": "report-links",
      "name": "Report Links",
      "type": "n8n-nodes-base.set",
      "typeVersion": 3.4,
      "position": [1040, 300]
    }
  ],
  "connections": {
    "When clicking Test": {
      "main": [[{ "node": "Report", "type": "main", "index": 0 }]]
    },
    "Report": {
      "main": [[{ "node": "Rendex — Create Artifact", "type": "main", "index": 0 }]]
    },
    "Rendex — Create Artifact": {
      "main": [[{ "node": "Report Links", "type": "main", "index": 0 }]]
    }
  },
  "pinData": {},
  "settings": {
    "executionOrder": "v1"
  },
  "meta": {
    "instanceId": ""
  }
}
