A sophisticated n8n workflow that dynamically updates form dropdowns with available AI models using the n8n node for self-configuration, enabling compliant AI chat interfaces.
Download this n8n workflow template and start using it instantly.
This dynamic n8n workflow provides a robust solution for environments where AI model availability frequently changes or where strict data governance (like GDPR) requires routing through a secure proxy. The core innovation of this n8n template lies in its two-phase operation: a Configuration Phase and an Execution Phase.
The Configuration Phase runs manually (or on a schedule) to fetch the latest list of available models from an external API (Requesty.ai). It then uses the powerful n8n node for self-modification, updating the options available in the primary ‘Model Selection Form’ n8n trigger. This ensures users always see the most current models.
The Execution Phase provides a user-friendly chat interface. When activated, the n8n workflow reads the user's stored model preference from Google Sheets and routes the prompt through the compliant Requesty.ai service, returning the AI generation directly to the user's chat window. This approach ensures maximum flexibility and adherence to corporate compliance standards within a single, powerful n8n workflow.
The process is divided into two distinct logical branches within this n8n workflow:
Extract Model IDs n8n node isolates just the model identifier strings.Get Current Workflow n8n node fetches the running n8n workflow's JSON definition.Merge Data and Update Dropdown Options (Code n8n node) combine the workflow definition and the new model IDs. The code intelligently parses the JSON, locates the specific formTrigger n8n node, and overwrites its dropdown choices.Update Workflow n8n node saves the modified JSON back to the n8n instance, instantly updating the model selection form.Current_Model) after clearing the previous entry, providing a persistent state for subsequent AI queries.Read Current Model n8n node.Chat Interface n8n trigger.To set up this dynamic n8n workflow, follow these steps:
AI API Request n8n node.YOURGOOGLESHEETID in the Save Model Selection, Clear Previous Selection, and Read Current Model n8n node parameters with the ID of your target spreadsheet.CurrentModel where the workflow can store the selected AI model.Initialize Workflow n8n trigger to run the Configuration Phase. This action will update the Model Selection Form with the available AI models fetched via Requesty.ai.Model Selection Form and Chat Interface n8n trigger nodes are now ready for interaction via their respective webhooks. Initialize Workflow (Manual Trigger): The starting point for the workflow configuration process.
Fetch Available Models (HTTP Request n8n node): Calls the external AI routing API (Requesty.ai) to gather a list of potential models, a critical first step for this dynamic n8n workflow.
Get Current Workflow (n8n node): Reads the current state and structure of the running n8n workflow, necessary for self-modification.
Update Dropdown Options (Code n8n node): Contains the core logic for parsing the workflow JSON and injecting the newly fetched model IDs into the settings of the Model Selection Form n8n trigger. This is a key piece of core logic flow control.
Update Workflow (n8n node): Saves the modified workflow definition, finalizing the dynamic configuration update.
Model Selection Form (Form Trigger n8n trigger): The user interface where the dynamic dropdown (updated in Phase 1) is displayed, allowing selection of the preferred AI model.
Google Sheets Nodes (Clear Previous Selection, Save Model Selection, Read Current Model): Used to manage and persist the user's current AI model choice across execution runs of this n8n workflow.
Chat Interface (LangChain Chat Trigger n8n trigger): Serves as the interactive endpoint where users submit prompts.
Chat Interface n8n trigger.Implement smart AI routing with this advanced n8n workflow. Automatically select the best LLM via OpenRouter based on query complexity and type for optimized results. Import this n8n template now.

Automate error alerts for your n8n workflows using WhatsApp and Gmail simultaneously. Use this robust n8n template for immediate incident response and better DevOps monitoring.

Automate lead generation using an n8n workflow that checks for duplicates, assigns unique coupons from Google Sheets, and synchronizes new leads directly into SuiteCRM for efficient follow-up.

Generate highly structured research data and export to CSV using this advanced n8n workflow. Utilizes GPT-4/5 for dynamic planning and Linkup for deep web extraction.

Use this advanced n8n workflow to automate lead routing based on AI qualification. Triggered by HubSpot, it uses GPT-4 and Airtable capacity data to assign leads and send instant notifications via Slack and Gmail.

Use this advanced n8n workflow to dynamically select and rank Model Context Protocol (MCP) servers using an OpenAI LLM for initial decision making and Contextual AI for highly relevant reranking. Explore n8n templates for tool calling.









































