Dynamically generate HTML page from user request using OpenAI Structured Output
Triggered by a webhook. Connects HTTP request, Html, Respond To Webhook, Webhook. Generate HTML from user query HTTP Request node - Send the user query to OpenAI, with a defined JSON response format - using HTTP Request node as it has not yet been implemented in the OpenAI nodes - The response format is inspired by the [Structured Output defined in OpenAI Introduction post]({{ $env.APIBASEURL }} -
Front matter
name: Dynamically generate HTML page from user request using OpenAI Structured Output
description: Triggered by a webhook. Connects HTTP request, Html, Respond To Webhook, Webhook. ## Generate HTML from user query **HTTP Request node** - Send the user query to OpenAI, with a defined JSON response format - *using HTTP Request node as it has not yet been implemented in the OpenAI nodes* - The response format is inspired by the [Structured Output defined in OpenAI Introduction post]({{ $env.API_BASE_URL }} - The output is a JSON containing HTML components and attributed **OpenAI node** - Format the response from the previous node from JSON format to HTML format ## Workflow
category: Automation
kind: Workflow
software: HTTP request|Html|Respond To Webhook|WebhookDynamically generate HTML page from user request using OpenAI Structured Output
Triggered by a webhook. Connects HTTP request, Html, Respond To Webhook, Webhook. ## Generate HTML from user query
HTTP Request node
- Send the user query to OpenAI, with a defined JSON response format - using HTTP Request node as it has not yet been implemented in the OpenAI nodes
- The response format is inspired by the [Structured Output defined in OpenAI Introduction post]({{ $env.API_BASE_URL }}
- The output is a JSON containing HTML components and attributed
OpenAI node
- Format the response from the previous node from JSON format to HTML format ## Workflow
Steps
- Respond to Webhook (respondToWebhook)
- Open AI - Using Structured Output (httpRequest)
- OpenAI - JSON to HTML (noOp)
- Format the HTML result (html)
- Sticky Note (stickyNote)
- Sticky Note1 (stickyNote)
- Webhook (webhook)
Import
Download the JSON from the GitHub source and import it in n8n (Workflows, Import from file).
Author: Zie619, n8n workflow collection. License: MIT.
Shown here with formatting for the web. Keep the author and license notice when you reuse it.
Related entries
There are more like this in the members library
The n8n workflow library holds 1,814 entries. Members can search all of them by meaning and read every one in full.