{"record":{"id":"76bbd587cac448f6","repo":"vercel/ai","slug":"server-requested-additional-input-but-multi-round","errorCode":null,"errorMessage":"Server requested additional input, but multi round-trip requests are not supported yet","messagePattern":"Server requested additional input, but multi round-trip requests are not supported yet","errorType":"exception","errorClass":"MCPClientError","httpStatus":null,"severity":"error","filePath":"packages/mcp/src/tool/mcp-client.ts","lineNumber":867,"sourceCode":"          cleanup();\n          return rejectWithAbortError();\n        }\n\n        if (response instanceof Error) {\n          return rejectAndCleanup(response);\n        }\n\n        try {\n          if (\n            this.protocolEra === 'modern' &&\n            response.result.resultType == null\n          ) {\n            throw new MCPClientError({\n              message: 'Modern MCP result is missing resultType',\n            });\n          }\n          if (response.result.resultType === 'input_required') {\n            throw new MCPClientError({\n              message:\n                'Server requested additional input, but multi round-trip requests are not supported yet',\n            });\n          }\n\n          const result = resultSchema.parse(response.result);\n          cleanup();\n          resolve(result);\n        } catch (error) {\n          const parseError = MCPClientError.isInstance(error)\n            ? error\n            : new MCPClientError({\n                message: 'Failed to parse server response',\n                cause: error,\n              });\n          rejectAndCleanup(parseError);\n        }\n      });","sourceCodeStart":849,"sourceCodeEnd":885,"githubUrl":"https://github.com/vercel/ai/blob/69428b1f8b037e4d118fb4853428d5c4e620493c/packages/mcp/src/tool/mcp-client.ts#L849-L885","documentation":"MCPClientError thrown inside DefaultMCPClient.request when a modern-protocol server responds with resultType 'input_required', meaning the server needs additional user input (elicitation) before it can complete the request. This SDK does not yet implement multi round-trip requests, so it throws instead of continuing the exchange.","triggerScenarios":"Calling a tool (or reading a resource/prompt) whose server-side implementation requests elicitation — e.g. a tool that asks for confirmation or missing parameters mid-execution — while connected via the modern protocol. Any request routed through DefaultMCPClient.request can hit this when the server returns resultType 'input_required'.","commonSituations":"Interactive tools (booking flows, approval workflows, tools that prompt for credentials) used through this client; server-side tools updated to use MCP elicitation while the client SDK is still on a version without multi round-trip support.","solutions":["Upgrade @ai-sdk/mcp to the latest version to check whether multi round-trip/elicitation support has shipped","Restructure the tool call to provide all required input up front so the server never needs to elicit more (pass all arguments in params)","Disable or avoid tools that rely on elicitation, or ask the server maintainer for a non-interactive variant","Handle the error explicitly in your app and surface the missing-input prompt in your own UI, then re-call with complete arguments"],"exampleFix":"// before: tool elicits missing parameter mid-run\nawait client.callTool({ name: 'bookFlight', arguments: { from: 'SFO' } });\n\n// after: supply everything up front\nawait client.callTool({\n  name: 'bookFlight',\n  arguments: { from: 'SFO', to: 'JFK', date: '2026-09-01', confirm: true },\n});","handlingStrategy":"try-catch","validationCode":"// pre-flight: ensure the tool's declared inputs are fully provided so the server never elicits\nconst missing = requiredToolInputs.filter(k => !(k in args));\nif (missing.length > 0) {\n  throw new Error(`Missing arguments required to avoid elicitation: ${missing.join(', ')}`);\n}","typeGuard":"function isElicitationUnsupported(error: unknown): error is MCPClientError {\n  return MCPClientError.isInstance(error) && error.message.includes('multi round-trip requests are not supported');\n}","tryCatchPattern":"try {\n  const result = await client.callTool({ name, arguments });\n} catch (error) {\n  if (isElicitationUnsupported(error)) {\n    // collect the missing input in your own UI, then re-call with complete arguments\n  } else {\n    throw error;\n  }\n}","preventionTips":["Pass all required tool arguments up front so servers never request elicitation","Upgrade @ai-sdk/mcp and check release notes for elicitation/multi round-trip support","Avoid tools that depend on interactive elicitation until support lands"],"tags":["mcp","elicitation","multi-round-trip","unsupported-feature"],"backgroundTag":"elicitation-unsupported","analyzedSha":"69428b1f8b037e4d118fb4853428d5c4e620493c","analyzedAt":"2026-08-30T12:32:21.016Z","schemaVersion":2},"datasetVersion":"2026-08-30T13:17:10.514Z"}