Skip to main content
Glama

update_ssh_connection

Modify SSH connection settings like host, port, username, password, or private key path for secure remote access to Windows systems through the Windows CLI MCP Server.

Instructions

Update an existing SSH connection

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
connectionIdNoID of the SSH connection to update
connectionConfigNo

Implementation Reference

  • Core implementation of the update_ssh_connection tool logic: loads the server config, updates the specified SSH connection if it exists, and saves the config back to file.
    const updateSSHConnection = (connectionId: string, connectionConfig: any): void => { const config = loadConfig(); if (config.ssh.connections[connectionId]) { config.ssh.connections[connectionId] = connectionConfig; saveConfig(config); } };
  • MCP tool dispatch handler for 'update_ssh_connection': parses and validates arguments using Zod schema, calls the updateSSHConnection helper function, and returns success response.
    case 'update_ssh_connection': { const args = z.object({ connectionId: z.string(), connectionConfig: z.object({ host: z.string(), port: z.number(), username: z.string(), password: z.string().optional(), privateKeyPath: z.string().optional(), }) }).parse(request.params.arguments); updateSSHConnection(args.connectionId, args.connectionConfig); return { content: [{ type: 'text', text: 'SSH connection updated successfully.' }] };
  • Declarative input schema definition for the update_ssh_connection tool, used by MCP clients to validate tool calls.
    inputSchema: { type: "object", properties: { connectionId: { type: "string", description: "ID of the SSH connection to update" }, connectionConfig: { type: "object", properties: { host: { type: "string", description: "Host of the SSH connection" }, port: { type: "number", description: "Port of the SSH connection" }, username: { type: "string", description: "Username for the SSH connection" }, password: { type: "string", description: "Password for the SSH connection" }, privateKeyPath: { type: "string", description: "Path to the private key for the SSH connection" } }, required: ["connectionId", "connectionConfig"] } }
  • src/index.ts:471-509 (registration)
    Tool registration in the MCP ListTools response, including name, description, and input schema for update_ssh_connection.
    { name: "update_ssh_connection", description: "Update an existing SSH connection", inputSchema: { type: "object", properties: { connectionId: { type: "string", description: "ID of the SSH connection to update" }, connectionConfig: { type: "object", properties: { host: { type: "string", description: "Host of the SSH connection" }, port: { type: "number", description: "Port of the SSH connection" }, username: { type: "string", description: "Username for the SSH connection" }, password: { type: "string", description: "Password for the SSH connection" }, privateKeyPath: { type: "string", description: "Path to the private key for the SSH connection" } }, required: ["connectionId", "connectionConfig"] } } } },

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/simon-ami/win-cli-mcp-server'

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