{"id":30869228,"url":"https://github.com/dbono711/cisco-nso-mcp-server","last_synced_at":"2026-01-14T07:46:06.173Z","repository":{"id":292390327,"uuid":"964583953","full_name":"dbono711/cisco-nso-mcp-server","owner":"dbono711","description":"A Model Context Protocol (MCP) server implementation for Cisco NSO that enables AI-powered network automation through natural language interactions.","archived":false,"fork":false,"pushed_at":"2025-12-21T21:20:48.000Z","size":6654,"stargazers_count":3,"open_issues_count":2,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-05T08:29:22.828Z","etag":null,"topics":["ai","cisco","mcp","model-context-protocol","network-automation","nso","openai"],"latest_commit_sha":null,"homepage":"https://github.com/dbono711/cisco-nso-mcp-server","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dbono711.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-04-11T12:56:14.000Z","updated_at":"2025-12-21T21:20:45.000Z","dependencies_parsed_at":"2025-05-09T17:55:55.835Z","dependency_job_id":"7211d4f9-3b4f-4d07-892b-793f7d2a4a11","html_url":"https://github.com/dbono711/cisco-nso-mcp-server","commit_stats":null,"previous_names":["dbono711/cisco-nso-mcp-server"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dbono711/cisco-nso-mcp-server","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbono711%2Fcisco-nso-mcp-server","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbono711%2Fcisco-nso-mcp-server/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbono711%2Fcisco-nso-mcp-server/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbono711%2Fcisco-nso-mcp-server/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dbono711","download_url":"https://codeload.github.com/dbono711/cisco-nso-mcp-server/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dbono711%2Fcisco-nso-mcp-server/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28413490,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-14T05:26:33.345Z","status":"ssl_error","status_checked_at":"2026-01-14T05:21:57.251Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","cisco","mcp","model-context-protocol","network-automation","nso","openai"],"created_at":"2025-09-07T22:04:03.458Z","updated_at":"2026-01-14T07:46:06.166Z","avatar_url":"https://github.com/dbono711.png","language":"Python","funding_links":[],"categories":["🤖 AI/ML"],"sub_categories":[],"readme":"# Cisco NSO MCP Server\n\nA Model Context Protocol (MCP) server implementation for [Cisco NSO (Network Services Orchestrator)](https://www.cisco.com/site/us/en/products/networking/software/crosswork-network-services-orchestrator/index.html) that exposes NSO data and operations as MCP primitives (Tools, Resources, etc.) that can be consumed by an [MCP-compatible client](#connecting-to-the-server-with-mcp-clients), enabling AI-powered network automation through natural language interactions.\n\n## Sample Custom Client\n\n![demo](./demos/client.gif)\n\n## What is MCP?\n\n[Model Context Protocol (MCP)](https://modelcontextprotocol.io/introduction) is an open protocol that standardizes how AI models interact with external tools and services. MCP enables:\n\n- **Tool Definition**: Structured way to define tools that AI models can use\n- **Tool Discovery**: Mechanism for models to discover available tools\n- **Tool Execution**: Standardized method for models to call tools and receive results\n- **Context Management**: Efficient passing of context between tools and models\n- **Framework Agnostic**: Works across multiple AI frameworks including OpenAI, Anthropic, Google Gemini, and others\n- **Interoperability**: Provides a common language for AI systems to communicate with external tools\n\n## Features\n\n- **Stdio Transport**: By default, this MCP server uses stdio transport for process-bound communication\n- **Tool-First Design**: Network operations are defined as discrete tools with clear interfaces\n- **Asynchronous Processing**: All network operations are implemented asynchronously for better performance\n- **Structured Responses**: Consistent response format with status, data, and metadata sections\n- **Environment Resources**: Provides contextual information about the NSO environment\n- **NSO Integration**: Uses [cisco-nso-restconf](https://github.com/dbono711/cisco-nso-restconf) library for a clean, Pythonic interface to NSO's RESTCONF API\n- **Flexible Logging**: Configurable logging to stdout and/or file via environment variables. When the `LOG_FILE` environment variable is set, logs are sent to both stdout and the specified file. If the log file cannot be created or written to, the server falls back to stdout-only logging with an error message\n- **Multiple Client Support**: Works with any MCP-compatible client including Windsurf Cascade and custom Python applications\n\n## Available Tools and Resources\n\n### Tools\n\n| Tool Name | Description | Inputs | Returns |\n| --- | --- | --- | --- |\n| `get_device_ned_ids` | Retrieves Network Element Driver (NED) IDs from Cisco NSO |  | A dictionary with a list of NED IDs |\n| `get_device_groups` | Retrieves device groups from Cisco NSO |  | A dictionary with a list of device groups |\n| `get_device_platform` | Gets platform information for a specific device in Cisco NSO | 'device_name' (string) | A dictionary with platform information for the specified device |\n| `get_device_config` | Gets full configuration for a specific device in Cisco NSO | 'device_name' (string) | A dictionary with configuration for the specified device |\n| `get_device_state` | Gets state for a specific device in Cisco NSO | 'device_name' (string) | A dictionary with state for the specified device |\n| `check_device_sync` | Checks sync status for a specific device in Cisco NSO | 'device_name' (string) | A dictionary with sync status for the specified device |\n| `sync_from_device` | Syncs from a specific device in Cisco NSO | 'device_name' (string) | A dictionary with sync status for the specified device |\n| `get_service_types` | Gets service types in Cisco NSO |  | A dictionary with service types |\n| `get_services` | Gets services for a specific service type in Cisco NSO | 'service_type' (string) | A dictionary with services for the specified service type |\n\n### Resources\n\n- `https://resources.cisco-nso-mcp.io/environment`: Provides a curated summary of the NSO environment:\n  - _Device count, Operating System Distribution, Unique Operating System Count, Unique Model Count, Model Distribution, Device Series Distribution, Device Groups and Members_\n\n## Requirements\n\n- Python 3.12+\n- Cisco NSO with RESTCONF API enabled\n- Network connectivity to NSO RESTCONF API\n\n## Configuration Options\n\nYou can configure the server using command-line arguments or environment variables:\n\n### NSO Connection Parameters\n\n| Command-line Argument | Environment Variable | Default | Description |\n|----------------------|---------------------|-----------|-------------|\n| `--nso-scheme`       | `NSO_SCHEME`        | http      | NSO connection scheme (http/https) |\n| `--nso-address`      | `NSO_ADDRESS`       | localhost | NSO server address |\n| `--nso-port`         | `NSO_PORT`          | 8080      | NSO server port |\n| `--nso-timeout`      | `NSO_TIMEOUT`       | 10        | Connection timeout in seconds |\n| `--nso-username`     | `NSO_USERNAME`      | admin     | NSO username |\n| `--nso-password`     | `NSO_PASSWORD`      | admin     | NSO password |\n| `--nso-verify`       | `NSO_VERIFY`        | True      | Verify NSO HTTPS certificate (default: True). Use `--no-nso-verify` for self-signed certs (dev only).      |\n| `--nso-ca-bundle`    | `NSO_CA_BUNDLE`     | None      | Path to a CA bundle file to trust for NSO HTTPS. Applicable when `-nso-verify` is `True`. |\n\n### MCP Server Parameters\n\n| Command-line Argument | Environment Variable | Default | Description |\n|----------------------|---------------------|---------|-------------|\n| `--transport`        | `MCP_TRANSPORT`     | stdio   | MCP transport type (stdio/http) |\n\n### HTTP Transport Options (only used when --transport=http)\n```FastMCP HTTP Server reference: https://gofastmcp.com/deployment/http#http-deployment```\n\n| Command-line Argument | Environment Variable | Default | Description |\n|----------------------|---------------------|---------|-------------|\n| `--host`             | `MCP_HOST`          | 0.0.0.0 | Host to bind to when using HTTP transport |\n| `--port`             | `MCP_PORT`          | 8000    | Port to bind to when using HTTP transport |\n\n### Logging Configuration\n\n| Environment Variable | Default | Description |\n|---------------------|---------|-------------|\n| `LOG_FILE`          | None    | Path to log file. If not set, logs will be sent to stdout only |\n\nEnvironment variables take precedence over default values but are overridden by command-line arguments.\n\n## Connecting to the Server with MCP Clients\n\nYou can connect to the server using any MCP client that supports the selected transport type. A few options are:\n\n### Windsurf Cascade\n\nWindsurf Cascade [supports MCP servers](https://docs.windsurf.com/windsurf/cascade/mcp#model-context-protocol-mcp) through a configuration file. To use the Cisco NSO MCP server with Windsurf, add it to your `mcp_config.json` file.\n\n#### Using uv (recommended)\n\nWhen using uv, no specific installation is needed. You can use `uvx` to directly run the package:\n\n```json\n{\n  \"mcpServers\": {\n    \"nso\": {\n      \"command\": \"uvx\",\n      \"args\": [\n        \"cisco-nso-mcp-server\",\n        \"--nso-address=127.0.0.1\",\n        \"--nso-port=8080\",\n        \"--nso-username=admin\",\n        \"--nso-password=admin\"\n      ],\n      \"env\": {\n        \"LOG_FILE\": \"/path/to/your/logs/nso-mcp.log\"\n      }\n    }\n  }\n}\n```\n\n#### Using with pip installation\n\nAlternatively, you can install `cisco-nso-mcp-server` via pip:\n\n```bash\npip install cisco-nso-mcp-server\n```\n\nNow you can use the direct path to the executable:\n\n```json\n{\n  \"mcpServers\": {\n    \"nso\": {\n      \"command\": \"/path/to/your/env/bin/cisco-nso-mcp-server\",\n      \"args\": [\n        \"--nso-address=127.0.0.1\",\n        \"--nso-port=8080\",\n        \"--nso-username=admin\",\n        \"--nso-password=admin\"\n      ],\n      \"env\": {\n        \"LOG_FILE\": \"/path/to/your/logs/nso-mcp.log\"\n      }\n    }\n  }\n}\n```\n\nReplace `/path/to/your/env/bin/cisco-nso-mcp-server` with the actual path where you [installed the package with pip](#using-with-pip-installation). You can find this by running `which cisco-nso-mcp-server` if you installed it in your main environment, or by locating it in your virtual environment's bin directory.\n\nIn either case, the `env` section is optional. If you include it, you can specify the `LOG_FILE` environment variable to enable file logging.\n\n### Using in a custom MCP client Python application with stdio transport\n\nA sample Python application is provided in [sample_stdio_client.py](./sample_stdio_client.py) that demonstrates how to connect to the MCP server locally and execute a tool.\n\n## Running the Server as Standalone\n\nWhile the server is typically used with an [MCP client](#connecting-to-the-server-with-mcp-clients), you can also run it directly as a standalone process:\n\n```bash\n# Run with default NSO connection and MCP settings (see Configuration Options above for details)\ncisco-nso-mcp-server\n\n# Run with custom NSO connection parameters\ncisco-nso-mcp-server --nso-scheme=http --nso-address=127.0.0.1 --nso-port=8080 --nso-username=admin --nso-password=admin\n```\n\nWhen running as a standalone process with stdio transport, you'll need to pipe input/output to the process or use it with an MCP client that supports stdio transport.\n\n## License\n\nThis project is licensed under the [MIT License](LICENSE). This means you can use, modify, and distribute the code, subject to the terms and conditions of the MIT License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdbono711%2Fcisco-nso-mcp-server","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdbono711%2Fcisco-nso-mcp-server","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdbono711%2Fcisco-nso-mcp-server/lists"}