MCP tools with array / items and google model
# support
c
Hello, I have issue with MCP tools that uses array:
Copy code
"tools": [
    {
      "name": "note-create",
      "title": "Create Note",
      "description": "...",
      "inputSchema": {
        "type": "object",
        "properties": {
          "content": {
            "type": "string",
            "minLength": 1,
            "maxLength": 10000,
            "description": "Note content"
          },
          "relations": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "targetEntityId": {
                  "type": "string",
                  "description": "ID of the target entity to relate to"
                },
                "targetEntityType": {
                  "type": "string",
                  "enum": [
                    "customer",
                    "listing",
                    "task",
                    "event",
                  ],
                  "description": "Type of the target entity"
                }
              },
              "required": [
                "targetEntityId",
                "targetEntityType"
              ],
              "additionalProperties": false
            },
            "description": "Relationships to create with the note"
          }
        },
        "required": [
          "content"
        ],
        "additionalProperties": false,
        "$schema": "http://json-schema.org/draft-07/schema#"
      }
    }
]
But after VAPI conversion to tools for Google, we have this:
Copy code
{
  "name": "pinggy-note-create",
  "description": "...",
  "parameters": {
    "type": "object",
    "properties": {
      "content": {
        "type": "string",
        "description": "Note content"
      },
      "relations": {
        "type": "array",
        "description": "Relationships to create with the note"
      }
    },
    "required": [
      "content"
    ]
  }
}
Section with item is missing and that leads to fail.
v
To resolve the missing
items
property in your Google tool schema, manually add the
items
definition to the
relations
array before sending it to Google.
For example:
Copy code
json
"relations": {
  "type": "array",
  "description": "Relationships to create with the note",
  "items": {
    "type": "object",
    "properties": {
      "targetEntityId": { "type": "string" },
      "targetEntityType": { "type": "string", "enum": ["customer", "listing", "task", "event"] }
    },
    "required": ["targetEntityId", "targetEntityType"],
    "additionalProperties": false
  }
}
Patch your conversion logic to ensure this structure is preserved when generating the Google tool schema. Source: - [Custom LLM Tool Calling Integration](https://docs.vapi.ai/customization/tool-calling-integration)
c
Well, I am using MCP server as tool defined in VAPI and I do not handle that logic, that is automatic by VAPI. MCP server provides answer that I have shared, but then tool "pinggy-note-create" is created by VAPI.
Copy code
{
  "id": "d4aa532b-e3c4-49b4-a219-526625bd0611",
  "createdAt": "2025-10-14T18:56:49.573Z",
  "updatedAt": "2025-10-14T19:44:38.434Z",
  "type": "mcp",
  "function": {
    "name": "mcp_tool_local",
    "description": "Provide tools for all operations",
    "parameters": {
      "type": "object",
      "properties": {},
      "required": []
    }
  },
  "messages": [
    {
      "type": "request-start",
      "content": "",
      "blocking": false
    }
  ],
  "metadata": {
    "protocol": "shttp"
  },
  "orgId": "bc95c463-efaf-42e4-965f-c08cf335cc73",
  "server": {
    "url": "https://nbnienpsbg.a.pinggy.link/mcp/streamable-http",
    "timeoutSeconds": 5,
    "headers": {...}
  }
}
c
Hey, Could you provide the call ID where you experienced this issue? We want to review the logs to identify the cause. Also, please share: - The exact timestamp of when this happened - The response you expected to get - The response you actually received This information will help us figure out what went wrong.
2 Views