Help with openai assistant with custom n8n workflow tool

Having problems wiring up custom n8n workflow tool to openai assistant. The assistant shows that it is passing in {“query”:{“type”:“layout”}} which would be correct but I am not seeing that in the workflow. I execute the previous nodes but nothing shows up in the workflow tool node.

Open AI Assistant function schema

{
  "name": "getSchema",
  "description": "Returns an array of layout names if type is layouts or returns an array of objects representing fields on the specified layout if type is fields",
  "parameters": {
    "type": "object",
    "properties": {
      "type": {
        "type": "string",
        "enum": [
          "layouts",
          "fields"
        ],
        "description": "Specify 'layouts' to retrieve layout information or 'fields' for field information"
      },
      "layout": {
        "type": "string",
        "description": "Specify the layout name; required if 'type' is 'fields'"
      }
    },
    "required": [
      "type"
    ],
    "if": {
      "properties": {
        "type": {
          "const": "fields"
        }
      }
    },
    "then": {
      "required": [
        "layout"
      ]
    }
  }
}

Information on your n8n setup

  • 1.20.0
  • Database SQLite)
  • n8n EXECUTIONS_PROCESS setting (default: own, main)
  • Running n8n via Docker
  • Synology NAS

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Hi @Michael_Wallace, is your “Execute Workflow” node living in the same workflow as your “Execute Workflow Trigger” node or does it live in its own workflow? If it’s the latter you’d need to specify the static ID of your sub-workflow when calling it. This ID is part of the URL and appears at the very end:

I am not seeing that in the workflow

This is expected. Calling a sub-workflow is effectively a separate execution and the execution data for this will not show up on the canvas immediately. Instead you would need to check the execution list (and make sure to store execution data in the first place) to review the data processed during your sub-workflow execution.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.