This workflow follows the Agent → Chainllm recipe pattern — see all workflows that pair these two integrations.
The workflow JSON
Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →
{
"name": "opencode-llm-proxy demo",
"nodes": [
{
"parameters": {},
"id": "5f1a2b3c-0001-4a00-8000-000000000001",
"name": "When clicking 'Test workflow'",
"type": "n8n-nodes-base.manualTrigger",
"typeVersion": 1,
"position": [
-40,
300
]
},
{
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "github-copilot/claude-sonnet-4.6",
"cachedResultName": "github-copilot/claude-sonnet-4.6"
},
"options": {}
},
"id": "5f1a2b3c-0002-4a00-8000-000000000002",
"name": "OpenCode Chat Model",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"typeVersion": 1.2,
"position": [
220,
520
],
"credentials": {
"openAiApi": {
"name": "<your credential>"
}
}
},
{
"parameters": {
"promptType": "define",
"text": "Explain what an n8n workflow is in two sentences.",
"messages": {}
},
"id": "5f1a2b3c-0003-4a00-8000-000000000003",
"name": "Basic LLM Chain",
"type": "@n8n/n8n-nodes-langchain.chainLlm",
"typeVersion": 1.5,
"position": [
300,
180
]
},
{
"parameters": {
"promptType": "define",
"text": "What is 47 * 89? Use the calculator tool to be sure, then state the result.",
"options": {}
},
"id": "5f1a2b3c-0004-4a00-8000-000000000004",
"name": "AI Agent",
"type": "@n8n/n8n-nodes-langchain.agent",
"typeVersion": 1.7,
"position": [
640,
300
]
},
{
"parameters": {},
"id": "5f1a2b3c-0005-4a00-8000-000000000005",
"name": "Calculator",
"type": "@n8n/n8n-nodes-langchain.toolCalculator",
"typeVersion": 1,
"position": [
640,
540
]
},
{
"parameters": {
"content": "## opencode-llm-proxy demo\n\nBefore running:\n\n1. Start OpenCode with the proxy bound for network access:\n `OPENCODE_LLM_PROXY_HOST=0.0.0.0 OPENCODE_LLM_PROXY_TOKEN=your-token opencode`\n2. Create an **OpenAI** credential named \"OpenCode Proxy\":\n - Base URL: `http://<opencode-host-ip>:4010/v1`\n - API Key: your token\n3. Open the **OpenCode Chat Model** node and pick a model from the dropdown\n (it auto-populates from `GET /v1/models`).\n\nThe **Basic LLM Chain** shows simple prompt/response.\nThe **AI Agent** + **Calculator** shows real tool/function calling.",
"height": 300,
"width": 420
},
"id": "5f1a2b3c-0006-4a00-8000-000000000006",
"name": "Read me",
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
-560,
160
]
}
],
"connections": {
"When clicking 'Test workflow'": {
"main": [
[
{
"node": "Basic LLM Chain",
"type": "main",
"index": 0
},
{
"node": "AI Agent",
"type": "main",
"index": 0
}
]
]
},
"OpenCode Chat Model": {
"ai_languageModel": [
[
{
"node": "Basic LLM Chain",
"type": "ai_languageModel",
"index": 0
},
{
"node": "AI Agent",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Calculator": {
"ai_tool": [
[
{
"node": "AI Agent",
"type": "ai_tool",
"index": 0
}
]
]
}
},
"settings": {
"executionOrder": "v1"
},
"meta": {
"templateCredsSetupCompleted": false
}
}
Credentials you'll need
Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.
openAiApi
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
opencode-llm-proxy demo. Uses lmChatOpenAi, chainLlm, agent, toolCalculator. Event-driven trigger; 6 nodes.
Source: https://github.com/KochC/opencode-llm-proxy/blob/main/docs/examples/n8n/opencode-llm-proxy-demo.workflow.json — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
This workflow is for users who want to turn Telegram into a personal AI-powered assistant capable of handling everyday tasks through natural language. It's ideal for solo founders, operators, or profe
Monthly Invoice Summarizer. Uses googleDriveTrigger, googleDrive, lmChatOpenAi, outputParserStructured. Event-driven trigger; 28 nodes.
telegramAssistant. Uses telegramTrigger, agent, lmChatOpenAi, memoryBufferWindow. Event-driven trigger; 17 nodes.
Jarwis. Uses telegramTrigger, agent, lmChatOpenAi, memoryBufferWindow. Event-driven trigger; 17 nodes.
QuantumDefender AI is a next-generation intelligent cybersecurity assistant designed to harness the symbolic strength of quantum computing’s promise alongside cutting-edge AI capabilities. This sophis