Skip to main content
Glama

Windows Automation MCP Server

copy_file

Copy files between locations on Windows systems using source and destination paths for file management and organization.

Instructions

复制文件

Input Schema

NameRequiredDescriptionDefault
sourceYes源文件路径
destinationYes目标文件路径

Input Schema (JSON Schema)

{ "properties": { "destination": { "description": "目标文件路径", "type": "string" }, "source": { "description": "源文件路径", "type": "string" } }, "required": [ "source", "destination" ], "type": "object" }

Implementation Reference

  • The `copyFile` method implements the core logic for the `copy_file` tool, using Node.js `fs.copyFile` to copy from source to destination, with success/error response.
    async copyFile(source, destination) { try { await fs.copyFile(source, destination); return { success: true, source, destination, message: '复制成功' }; } catch (error) { return { success: false, error: error.message }; } }
  • The tool definition including name, description, and input schema for `copy_file` in `getToolDefinitions()`.
    { name: 'copy_file', description: '复制文件', inputSchema: { type: 'object', properties: { source: { type: 'string', description: '源文件路径' }, destination: { type: 'string', description: '目标文件路径' }, }, required: ['source', 'destination'], }, },
  • Registration and dispatch logic in `executeTool` switch statement that routes `copy_file` calls to the handler.
    case 'copy_file': return await this.copyFile(args.source, args.destination);

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/eva-wanxin-git/windows-automation-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server