Skip to content
This repository was archived by the owner on Apr 13, 2026. It is now read-only.
This repository was archived by the owner on Apr 13, 2026. It is now read-only.

Missing required parameter: 'messages[1].tool_calls[1].function.arguments' #117

Description

@dmingolla

Hello,
when I run some prompts I get the following error:

Missing required parameter: 'messages[1].tool_calls[1].function.arguments'

This error is not always happening, I think it depends on how the model pass the value of the arguments of the tool that can be empty

I tried to:

  • test the same prompt on gpt4o-mini and gpt4o but it doesn't work
  • test the same prompt and model on Warp and it works perfectly, so there is no issue in my mcp server code and the issue is not due to the model's intelligence

My mcphost config file:

{
  "mcpServers": {
    "mcp-server": {
      "type": "local",
      "command": [
        "uv",
        "run",
        "-p",
        "/home/demo/mcp/.venv/bin/python",
        "--",
        "/home/demo/mcp/main.py",
        "--allow-write"
      ],
      "cwd": "/home/demo/mcp"
    }
  },
  "model": "${env://MODEL:-openai:gpt-4o-mini}",
  "provider-api-key": "${env://OPENAI_API_KEY}",
  "max-tokens": 16000
}

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions