shadcn-ui/ui · error
No tool arguments provided.
Error message
No tool arguments provided.
What it means
The MCP CallTool handler requires request.params.arguments to be present — even an empty object for no-arg tools. Some clients send null/undefined for tools taking no arguments; this guard rejects that before dispatching into the tool switch.
Source
Thrown at packages/shadcn/src/mcp/index.ts:176
"Array of items to get the add command for prefixed with the registry name (e.g., ['@shadcn/button', '@shadcn/card'])"
),
})
),
},
{
name: "get_audit_checklist",
description:
"After creating new components or generating new code files, use this tool for a quick checklist to verify that everything is working as expected. Make sure to run the tool after all required steps have been completed.",
inputSchema: zodToJsonSchema(z.object({})),
},
],
}
})
server.setRequestHandler(CallToolRequestSchema, async (request) => {
try {
if (!request.params.arguments) {
throw new Error("No tool arguments provided.")
}
switch (request.params.name) {
case "get_project_registries": {
const config = await getMcpConfig(process.cwd())
if (!config?.registries) {
return {
content: [
{
type: "text",
text: dedent`No components.json found or no registries configured.
To fix this:
1. Use the \`init\` command to create a components.json file
2. Or manually create components.json with a registries section`,
},
],View on GitHub (pinned to efac598707)
Solutions
- Update the MCP client to always send arguments ({} for no-arg tools).
- If you control the client, ensure params.arguments is an object before sending the request.
Example fix
// before (client call)
client.callTool({ name: 'get_audit_checklist', arguments: null })
// after
client.callTool({ name: 'get_audit_checklist', arguments: {} }) Defensive patterns
Strategy: validation
Validate before calling
// On the client side: always pass an arguments object, even for no-arg tools.
await client.callTool({
name: "get_audit_checklist",
arguments: {},
}) Type guard
type CallToolRequest = { params: { name: string; arguments?: Record<string, unknown> | null } }
function hasMcpArgs(req: CallToolRequest): req is { params: { name: string; arguments: Record<string, unknown> } } {
return req?.params?.arguments != null && typeof req.params.arguments === "object"
} Prevention
- Always pass an arguments object (even {}), never null/undefined, in MCP calls.
- Keep the MCP client library up to date with the protocol spec.
When it happens
Trigger: An MCP client (Claude Code, Cursor, VS Code, Codex, OpenCode) calls a shadcn MCP tool but omits the arguments field or sends null — common for get_audit_checklist whose schema is z.object({}).
Common situations: Client bug, older client spec version, a client that treats 'no parameters' as 'no arguments key' rather than arguments:{}.
Related errors
- Tool ${request.params.name} not found
- Unknown client: ${client}. Available clients: ${CLIENTS.map(
- Base color "${baseColorName}" or theme "${themeName}" not fo
- Unknown item: "${designSystemConfig.item}".
- Font "${designSystemConfig.font}" not found
AI-assisted analysis of shadcn-ui/ui@efac598707 (2026-08-12).
Data as JSON: /api/errors/c4bb846898c8cb90.
Report an issue: GitHub.