MCP Toolbox is a web-based analytics and monitoring dashboard for Model Context Protocol servers, powered by agnost.ai. It provides real-time visualization of MCP server performance, usage patterns, and debugging capabilities.
Dashboard URL: http://localhost:8080 (default)
- Features
- Quick Start
- Configuration
- Dashboard Overview
- Analytics & Metrics
- Debugging
- Troubleshooting
- Security
- Live Tool Invocations: Watch MCP tools being called in real-time
- Performance Metrics: Track execution times, success rates, and error rates
- Resource Utilization: Monitor memory, CPU, and network usage
- Active Connections: See which clients are connected to the server
- Usage Patterns: Identify most/least used tools and resources
- Performance Trends: Historical data with time-series graphs
- Error Analysis: Track error types, frequencies, and patterns
- Client Statistics: Per-client usage and performance metrics
- Request/Response Inspection: View full request and response payloads
- Stack Traces: Detailed error stack traces with context
- Parameter Validation: See parameter validation errors
- Execution Timeline: Step-by-step execution flow visualization
- Performance Alerts: Get notified when response times exceed thresholds
- Error Rate Alerts: Alert on high error rates
- Custom Alerts: Define custom alerting rules
- Docker and Docker Compose installed
- UniFi API key from unifi.ui.com
- Agnost Organization ID from app.agnost.ai
# 1. Clone the repository (if not already done)
git clone https://github.com/enuno/unifi-mcp-server.git
cd unifi-mcp-server
# 2. Copy environment template
cp .env.docker.example .env
# 3. Edit .env file with your credentials
nano .env # or use your preferred editorRequired environment variables:
# UniFi API Configuration
UNIFI_API_KEY=your-unifi-api-key-here
# Agnost Configuration (required for Toolbox)
AGNOST_ENABLED=true
AGNOST_ORG_ID=your-organization-id-here# 4. Start all services
docker-compose up -d
# 5. Verify services are running
docker-compose ps
# 6. Access the Toolbox dashboard
open http://localhost:8080# Stop all services
docker-compose down
# Stop and remove volumes (includes Redis data)
docker-compose down -v| Variable | Required | Default | Description |
|---|---|---|---|
AGNOST_ENABLED |
Yes | false |
Enable agnost tracking |
AGNOST_ORG_ID |
Yes* | - | Your agnost organization ID |
AGNOST_ENDPOINT |
No | https://api.agnost.ai |
Agnost API endpoint |
*Required if AGNOST_ENABLED=true or using Toolbox
| Variable | Required | Default | Description |
|---|---|---|---|
TOOLBOX_PORT |
No | 8080 |
Dashboard web interface port |
TOOLBOX_AUTH_ENABLED |
No | false |
Enable authentication |
TOOLBOX_USERNAME |
No | admin |
Admin username (if auth enabled) |
TOOLBOX_PASSWORD |
No | - | Admin password (if auth enabled) |
| Variable | Default | Description |
|---|---|---|
AGNOST_DISABLE_INPUT |
false |
Set to true to disable input tracking |
AGNOST_DISABLE_OUTPUT |
false |
Set to true to disable output tracking |
By default, the Toolbox dashboard runs on port 8080. To change this:
# .env file
TOOLBOX_PORT=9090Then access the dashboard at http://localhost:9090.
To enable dashboard authentication:
# .env file
TOOLBOX_AUTH_ENABLED=true
TOOLBOX_USERNAME=admin
TOOLBOX_PASSWORD=your-secure-password-hereAfter enabling authentication, you'll be prompted for credentials when accessing the dashboard.
The home page provides an at-a-glance view of your MCP server:
- Server Status: Uptime, version, configuration
- Tool Statistics: Total tools, most used, success rate
- Resource Statistics: Resource types, access counts
- Recent Activity: Last 10 tool invocations with timing
View and analyze MCP tool usage:
- Tool List: All available tools with descriptions
- Usage Statistics: Call count, avg response time, error rate
- Performance Graphs: Response time distribution, success/failure trends
- Tool Details: Click any tool to see detailed analytics
Monitor MCP resource access:
- Resource URIs: All available resource endpoints
- Access Patterns: Most accessed resources, access frequency
- Performance: Response times, cache hit rates
- Resource Details: Click to see access history and performance
Track and debug errors:
- Error List: Recent errors with timestamps
- Error Types: Group by error type or tool
- Stack Traces: Full stack traces with code context
- Error Trends: Error frequency over time
- Quick Filters: Filter by tool, error type, or time range
Deep dive into performance and usage:
-
Performance Metrics:
- Average response time by tool
- P50, P95, P99 percentiles
- Throughput (requests per second)
- Error rates and types
-
Usage Metrics:
- Tool popularity (most/least used)
- Peak usage times
- Client distribution
- Request patterns
-
Time-series Graphs:
- Response time trends
- Request volume over time
- Error rate trends
- Resource utilization
- Average Response Time: Mean execution time across all tools
- Median (P50): 50th percentile response time
- P95: 95th percentile - 95% of requests faster than this
- P99: 99th percentile - 99% of requests faster than this
Interpreting Response Times:
- < 100ms: Excellent
- 100-500ms: Good
- 500ms-1s: Acceptable
- > 1s: Needs optimization
- Overall Success Rate: Percentage of successful tool invocations
- Per-Tool Success Rate: Success rate for individual tools
Healthy Ranges:
- > 99%: Excellent
- 95-99%: Good
- 90-95%: Needs attention
- < 90%: Critical
- Requests Per Second (RPS): Number of tool invocations per second
- Requests Per Minute (RPM): Number of tool invocations per minute
For each MCP tool, the dashboard tracks:
- Invocation Count: Total number of times called
- Avg Response Time: Average execution time
- Success Rate: Percentage of successful calls
- Error Count: Number of failed calls
- Last Used: Timestamp of most recent invocation
For each MCP resource:
- Access Count: Number of times accessed
- Cache Hit Rate: Percentage of cached responses
- Avg Response Size: Average size of responses
- Response Time: Average time to fetch resource
Click any tool invocation in the dashboard to see:
Request Details:
- Tool name
- Input parameters (if tracking enabled)
- Timestamp
- Client information
- Headers (if available)
Response Details:
- Output data (if tracking enabled)
- Response time
- Success/failure status
- Error message (if failed)
- Stack trace (if error occurred)
The Errors tab provides powerful debugging capabilities:
- Error Grouping: Errors grouped by type or tool
- Stack Traces: Full Python stack traces with line numbers
- Context: Request parameters that caused the error
- Frequency: How often each error occurs
- Recent Occurrences: Timeline of when errors happened
Identify slow operations:
- Slowest Tools: List of tools with highest avg response time
- Performance Timeline: Visual timeline of execution
- Bottleneck Identification: Pinpoint slow operations
- Comparison: Compare performance across time ranges
Watch your MCP server in real-time:
- Live Feed: Stream of tool invocations as they happen
- Active Requests: Currently executing tools
- Connection Status: Connected clients and their status
- Resource Usage: Live CPU, memory, and network stats
Problem: Cannot access http://localhost:8080
Solutions:
-
Check if Toolbox container is running:
docker-compose ps mcp-toolbox
-
Check Toolbox logs:
docker-compose logs mcp-toolbox
-
Verify port is not in use:
lsof -i :8080 # macOS/Linux netstat -ano | findstr :8080 # Windows
-
Try a different port:
TOOLBOX_PORT=9090
Problem: Dashboard loads but shows no data
Solutions:
-
Verify agnost tracking is enabled:
AGNOST_ENABLED=true AGNOST_ORG_ID=your-org-id-here
-
Check MCP server logs for tracking errors:
docker-compose logs unifi-mcp | grep -i agnost -
Verify MCP server is making tool calls:
docker-compose logs unifi-mcp | grep -i "tool"
-
Check Organization ID is correct in agnost.ai dashboard
Problem: Can't log in to dashboard
Solutions:
-
Verify credentials in
.env:TOOLBOX_AUTH_ENABLED=true TOOLBOX_USERNAME=admin TOOLBOX_PASSWORD=your-password
-
Restart Toolbox container:
docker-compose restart mcp-toolbox
-
Disable authentication temporarily for testing:
TOOLBOX_AUTH_ENABLED=false
Problem: Toolbox container using too much memory
Solutions:
-
Reduce data retention period (configure in agnost.ai dashboard)
-
Enable input/output tracking controls:
AGNOST_DISABLE_INPUT=true AGNOST_DISABLE_OUTPUT=true
-
Add memory limits to docker-compose.yml:
mcp-toolbox: mem_limit: 512m
-
Enable Authentication
TOOLBOX_AUTH_ENABLED=true TOOLBOX_PASSWORD=strong-random-password
-
Use Strong Passwords
- Minimum 16 characters
- Mix of uppercase, lowercase, numbers, and symbols
- Use a password manager
-
Restrict Network Access
# docker-compose.yml mcp-toolbox: ports: - "127.0.0.1:8080:8080" # Only localhost
-
Enable HTTPS (for production)
- Use a reverse proxy (nginx, Caddy, Traefik)
- Configure SSL certificates
- Redirect HTTP to HTTPS
-
Control Data Tracking
AGNOST_DISABLE_INPUT=true # Don't track input params AGNOST_DISABLE_OUTPUT=true # Don't track output data
What Gets Tracked:
- Tool names and execution times (always)
- Input parameters (if
AGNOST_DISABLE_INPUT=false) - Output results (if
AGNOST_DISABLE_OUTPUT=false) - Error messages and stack traces (always)
What Doesn't Get Tracked:
- UniFi API keys (always masked)
- Passwords (always masked)
- Authentication tokens (always masked)
- Personal data (unless explicitly in parameters)
Data Retention:
- Default: 30 days
- Configurable in agnost.ai dashboard
- Can be deleted manually at any time
Recommended Firewall Rules:
# Allow Toolbox only from local network
iptables -A INPUT -p tcp --dport 8080 -s 192.168.1.0/24 -j ACCEPT
iptables -A INPUT -p tcp --dport 8080 -j DROPProduction Deployment:
- Use VPN for remote access
- Deploy behind a firewall
- Use reverse proxy with SSL
- Enable rate limiting
- Monitor access logs
For self-hosted agnost deployments:
AGNOST_ENDPOINT=https://your-agnost-instance.comCreate docker-compose.override.yml for custom configuration:
version: '3.8'
services:
mcp-toolbox:
environment:
- CUSTOM_VAR=value
volumes:
- ./custom-config:/config
deploy:
resources:
limits:
memory: 512M
cpus: '0.5'Monitor service health:
# Check all services
docker-compose ps
# Check specific service health
docker inspect --format='{{.State.Health.Status}}' mcp-toolbox
# View health check logs
docker inspect --format='{{json .State.Health}}' mcp-toolbox | jq- Agnost.ai Documentation: https://docs.agnost.ai
- MCP Toolbox GitHub: https://github.com/googleapis/genai-toolbox
- UniFi MCP Server: https://github.com/enuno/unifi-mcp-server
- GitHub Issues: Report bugs or request features
- GitHub Discussions: Ask questions and share ideas
- Agnost Support: support@agnost.ai
Q: Do I need agnost.ai to use the UniFi MCP server? A: No, agnost.ai and MCP Toolbox are completely optional. The UniFi MCP server works without them.
Q: Is MCP Toolbox free? A: Check agnost.ai pricing at https://agnost.ai/pricing
Q: Can I run Toolbox without Docker? A: Yes, but Docker is recommended. See agnost.ai documentation for alternative deployment methods.
Q: How much data does Toolbox collect?
A: You control data collection with AGNOST_DISABLE_INPUT and AGNOST_DISABLE_OUTPUT flags. With both disabled, only metadata is collected (tool names, timing, errors).
Q: Can I use Toolbox with other MCP servers? A: Yes! MCP Toolbox works with any MCP server that implements agnost tracking.
Q: How do I update Toolbox to the latest version?
docker-compose pull mcp-toolbox
docker-compose up -d mcp-toolboxLast Updated: 2025-11-01 Version: 1.0.0 Maintainer: Elvis (@enuno)