dart-info
Retrieve information about the Dart SDK installation, including version details and available components, to verify setup and compatibility for development workflows.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "dart-info"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| options | No | Additional info options |
Implementation Reference
- src/tools/info.ts:8-19 (handler)The main handler function for the 'dart-info' tool. It executes the 'dart info' command using executeDartCommand with provided options and formats the stdout/stderr output as MCP content.
export async function info({ options = [] }: z.infer<typeof infoSchema>) { const { stdout, stderr } = await executeDartCommand('info', options); return { content: [ { type: "text" as const, text: stdout || stderr } ], isError: !!stderr }; } - src/tools/info.ts:4-6 (schema)Zod input schema for the 'dart-info' tool, allowing optional array of additional command options.
export const infoSchema = z.object({ options: z.array(z.string()).optional().describe('Additional info options') }); - src/index.ts:39-39 (registration)Registers the 'dart-info' tool on the MCP server, associating it with the infoSchema and info handler function.
server.tool('dart-info', infoSchema.shape, info); - src/index.ts:21-21 (registration)Imports the info handler and schema from src/tools/info.ts for use in tool registration.
import { info, infoSchema } from './tools/info.js';