π Publish HTML content with GitHub Gist and HTML preview
β‘ 176 views Β· π File Management
Description
π Whoβs it for
This subworkflow is designed for developers, AI engineers, or automation builders who generate dynamic HTML content in their workflows (e.g. reports, dashboards, emails) and want a simple way to host and share it via a clean URL, without spinning up infrastructure or uploading to a CMS.
Itβs especially useful when combined with AI agents that generate HTML content as part of a larger automated pipeline.
βοΈ What it does
This subworkflow:
- Accepts raw HTML content as input.
- Creates a new GitHub Gist with that content.
- Returns the shareable Gist URL, which can then be sent via Slack, Telegram, email, etc.
The result is a lightweight, fast, and free way to publish AI-generated HTML (such as reports, articles, or formatted data outputs) to the web.
π οΈ How to set it up
- Add this subworkflow to any parent workflow where HTML is generated.
- Pass in a string of valid HTML via the
htmlinput parameter. - Configure the GitHub credentials in the HTTP node using an access token with
gistscope.
β Requirements
- GitHub account and personal access token with
gistpermissions
π§ How to customize
- Change the filename (
report.html) if your use case needs a different format or extension. - Add metadata to the Gist (e.g., description, tags).
π Nodes Used
HTTP Request, Execute Workflow Trigger
π₯ Import
Download workflow.json and import into n8n:
Workflow menu β Import from File