netdev

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 12, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Obfuscate = true

Obfuscate controls whether sensitive values are replaced with hashes in tool output. Enabled by default; set to false via --no-obfuscate.

Functions

func GetConfig

GetConfig retrieves the running or startup configuration from a network device.

func RunShowCommand

func RunShowCommand(ctx context.Context, req *mcp.CallToolRequest, args RunShowCommandInput) (*mcp.CallToolResult, any, error)

RunShowCommand executes an arbitrary show command on a network device.

Types

type GetConfigInput

type GetConfigInput struct {
	Host       string `json:"host"        jsonschema:"hostname or IP address of the network device"`
	Username   string `json:"username"    jsonschema:"SSH username"`
	Port       int    `json:"port"        jsonschema:"SSH port, defaults to 22"`
	ConfigType string `json:"config_type" jsonschema:"configuration type: running (default) or startup"`
}

GetConfigInput defines the input parameters for the get_config tool.

type RunShowCommandInput

type RunShowCommandInput struct {
	Host     string `json:"host"     jsonschema:"hostname or IP address of the network device"`
	Command  string `json:"command"  jsonschema:"show command to execute, e.g. 'show bgp summary | json' or 'show interfaces status | json'"`
	Username string `json:"username" jsonschema:"SSH username"`
	Port     int    `json:"port"     jsonschema:"SSH port, defaults to 22"`
}

RunShowCommandInput defines the input parameters for the run_show_command tool.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL