Metadata-Version: 2.4
Name: argus-netbox
Version: 0.1.2
Summary: NetBox-backed network source-of-truth automation server for MCP coding agents
Author: Jon Freed
License-Expression: Apache-2.0
Requires-Python: >=3.12
Description-Content-Type: text/markdown
Requires-Dist: mcp>=1.28.0
Requires-Dist: pynetbox>=7.3
Requires-Dist: httpx>=0.28.1
Requires-Dist: fastapi>=0.137.1
Requires-Dist: uvicorn>=0.34
Requires-Dist: pydantic>=2.13.4
Requires-Dist: pydantic-settings>=2.3
Provides-Extra: discovery
Requires-Dist: napalm>=5.1.0; extra == "discovery"
Requires-Dist: netmiko>=4.3; extra == "discovery"
Requires-Dist: pysnmp>=7.1.27; extra == "discovery"
Provides-Extra: dev
Requires-Dist: pytest>=8.0; extra == "dev"
Requires-Dist: pytest-asyncio>=1.4.0; extra == "dev"
Requires-Dist: pytest-cov>=7.1.0; extra == "dev"
Requires-Dist: respx>=0.23.1; extra == "dev"
Requires-Dist: ruff>=0.15.17; extra == "dev"
Requires-Dist: mypy>=2.1.0; extra == "dev"

# Argus server

Python MCP + FastAPI server. NetBox source-of-truth tools for coding agents and the
Argus web dashboard. See the [top-level README](../README.md) and
[docs/ARCHITECTURE.md](../docs/ARCHITECTURE.md).

## Install

```bash
python -m venv .venv && source .venv/bin/activate
pip install -e ".[dev]"
```

## Configure

Copy `.env.example` to `.env` (or export the vars):

```bash
NETBOX_URL=https://netbox.lan
NETBOX_TOKEN=<netbox api token>
NETBOX_VERIFY_SSL=true
HTTP_HOST=0.0.0.0
HTTP_PORT=8080
```

If unset, tools return a clear "NetBox not configured" message instead of erroring.

## Run

```bash
argus-mcp     # MCP server over stdio (for Claude Code etc.)
argus-http    # FastAPI HTTP server on :8080 (for the web app + webhooks)
```

## Develop

```bash
ruff check src tests
mypy src
pytest -v          # offline — NetBox is mocked
```

## Tools

| Tool | Kind | Status |
| --- | --- | --- |
| `list_devices`, `get_device`, `list_prefixes`, `list_ip_addresses`, `search` | read | real (needs NetBox) |
| `list_collectors`, `discovery_scan`, `network_topology` | discovery | UniFi real — devices + clients + uplink topology (needs `UNIFI_*`); SNMP/LLDP real for non-UniFi gear (needs `SNMP_TARGETS` + `argus[discovery]`) |
| `drift_report`, `reconcile_apply` | reconcile | real — diffs and (on confirm) persists, auto-creating supporting NetBox objects |
| `health` | meta | real |
