Comprehensive Instana MCP wrapper with all 46+ tools - WatsonX compatible
Project description
Instana Comprehensive Wrapper
A comprehensive MCP (Model Context Protocol) wrapper for all 46+ Instana monitoring tools, designed for seamless integration with WatsonX Orchestrator Cloud.
🎯 Key Features
- Complete Coverage: All 46+ tools from official
mcp-instana==0.7.1server - WXO Cloud Compatible: Designed to work with WatsonX Orchestrator connections
- No Hardcoded Credentials: Relies on environment variables from WXO Cloud
- Simple Pass-Through: Direct mapping to official Instana tools
- Production Ready: Clean architecture, proper error handling
📦 Installation
For WatsonX Orchestrator Cloud
# Import as toolkit
Package: instana-comprehensive-wrapper==1.0.1
Command: uvx instana-comprehensive-wrapper==1.0.1 --transport stdio
Connection: Select your Instana connection (with INSTANA_API_TOKEN and INSTANA_BASE_URL)
For Local Development
pip install instana-comprehensive-wrapper
🛠️ Available Tools (46+ Tools)
Infrastructure Monitoring (1 tool)
analyze_infrastructure_elicitation- Two-pass infrastructure analysis for any entity type
Event Monitoring (8 tools)
get_event- Get specific event details by IDget_kubernetes_info_events- Kubernetes events with analysisget_agent_monitoring_events- Agent monitoring eventsget_issues- Warning and issue eventsget_incidents- Critical incident eventsget_changes- Deployment and configuration changesget_events_by_ids- Batch event retrieval
Automation/Actions (9 tools)
get_action_matches- Find matching actions for scenariosget_actions- List all available actionsget_action_details- Get action details by IDget_action_types- List action typesget_action_tags- List action tagssubmit_automation_action- Execute automation actionget_action_instance_details- Get action run detailslist_action_instances- List action run historydelete_action_instance- Delete action run result
Dashboard Management (1 tool)
manage_custom_dashboards- Complete dashboard CRUD operations
Application Resources (1 tool)
manage_instana_resources- Unified resource manager for metrics, alerts, settings, catalog
Website Monitoring (26 tools)
get_website_beacon_groups- Grouped website metricsget_website_beacons- All website beaconsget_website_catalog_metrics- Metrics catalogget_website_catalog_tags- Tags catalogget_website_tag_catalog- Tag catalog for beacon typeget_websites- List all websitesget_website- Get website by IDcreate_website- Create new websitedelete_website- Delete websiterename_website- Rename websiteget_website_geo_location_configuration- Get geo-location configupdate_website_geo_location_configuration- Update geo-location configget_website_ip_masking_configuration- Get IP masking configupdate_website_ip_masking_configuration- Update IP masking configget_website_geo_mapping_rules- Get geo mapping rulesset_website_geo_mapping_rules- Set geo mapping rulesupload_source_map_file- Upload source mapclear_source_map_upload_configuration- Clear source map configget_website_page_load- Get page load detailsget_website_beacon_metrics_v2- Get beacon metrics (v2 API)
🚀 Usage Examples
Infrastructure Monitoring
# Query host metrics
{
"tool": "analyze_infrastructure_elicitation",
"arguments": {
"selections": {
"entity_type": "host",
"metrics": ["cpu.used", "memory.used"],
"aggregation": "mean",
"filters": [{"name": "host.name", "value": "my-server"}],
"timeRange": "6h"
}
}
}
Database Discovery
# List all databases on a host
{
"tool": "analyze_infrastructure_elicitation",
"arguments": {
"selections": {
"entity_type": "db2Database",
"metrics": ["db2.database.name"],
"aggregation": "mean",
"filters": [{"name": "host.name", "value": "db-server"}],
"timeRange": "1h",
"groupBy": ["db2.database.name"]
}
}
}
Event Monitoring
# Get incidents from last 24 hours
{
"tool": "get_incidents",
"arguments": {
"time_range": "last 24 hours",
"max_events": 50
}
}
Application Monitoring
# Get application metrics
{
"tool": "manage_instana_resources",
"arguments": {
"resource_type": "metrics",
"operation": "application",
"params": {
"tag_filter_expression": {
"type": "TAG_FILTER",
"name": "application.name",
"operator": "EQUALS",
"entity": "DESTINATION",
"value": "my-app"
},
"metrics": ["calls", "latency"],
"time_frame": {"windowSize": 3600000}
}
}
}
🔧 Configuration
Environment Variables
The wrapper expects these environment variables (provided by WXO Cloud connection):
INSTANA_API_TOKEN=your_api_token_here
INSTANA_BASE_URL=https://your-instance.instana.io
WatsonX Orchestrator Setup
-
Create Connection:
- Go to WXO Cloud → Connections
- Create new connection named "instana"
- Add Key-Value Pairs:
INSTANA_API_TOKEN: Your Instana API tokenINSTANA_BASE_URL: Your Instana instance URL
-
Import Toolkit:
- Go to WXO Cloud → Toolkits
- Click "Import Toolkit"
- Package:
instana-comprehensive-wrapper==1.0.1 - Command:
uvx instana-comprehensive-wrapper==1.0.1 --transport stdio - Connection: Select "instana"
-
Test:
- Create or open an agent
- Try query: "Get CPU usage for [hostname] for the last 6 hours"
🏗️ Architecture
WXO Cloud Agent
↓
instana-comprehensive-wrapper (reads env vars from WXO connection)
↓
Spawns: uvx mcp-instana==0.7.1 (with credentials)
↓
Official Instana MCP Server
↓
Instana API
Key Design Principles
- No Hardcoded Credentials: All credentials from environment
- Simple Pass-Through: Direct mapping to official tools
- Minimal Transformation: Only JSON parsing for WXO compatibility
- Error Transparency: Errors passed through from official server
📚 Documentation
Tool Categories
- Infrastructure: Host, database, container, Kubernetes monitoring
- Events: Incidents, issues, changes, Kubernetes events
- Automation: Action catalog, execution, history
- Dashboards: Custom dashboard management
- Applications: Metrics, alerts, settings, catalog
- Websites: Beacon monitoring, configuration, source maps
Common Patterns
Two-Pass Infrastructure Analysis:
- Pass 1: Provide
intentandentityto get schema - Pass 2: Provide
selectionswith exact parameters
Time Ranges:
- Natural language: "last 24 hours", "last 2 days"
- Milliseconds: 3600000 (1 hour), 86400000 (1 day)
- String format: "1h", "24h", "7d"
Filtering:
{
"filters": [
{"name": "host.name", "value": "my-server"},
{"name": "db2.database.name", "value": "MYDB"}
]
}
🔍 Troubleshooting
"Environment variables not set" Error
Cause: WXO Cloud connection not properly configured Solution:
- Verify connection has
INSTANA_API_TOKENandINSTANA_BASE_URL - Ensure connection is selected when importing toolkit
- Check connection status (should show green checkmarks)
"401 Unauthorized" Error
Cause: Invalid or expired API token Solution: Update API token in WXO Cloud connection
"Host not found" Error
Cause: Hostname doesn't match Instana records Solution: Use exact hostname from Instana (case-sensitive)
Empty Results
Cause: Time range too narrow or filters too restrictive Solution: Increase time range or broaden filters
🤝 Contributing
This wrapper is designed for the DB2 DBA team's Slack bot automation project. For issues or enhancements, please contact the team.
📄 License
MIT License
🔗 Related Projects
- Official Instana MCP: https://github.com/instana/mcp-instana
- MCP Protocol: https://modelcontextprotocol.io/
- WatsonX Orchestrator: https://www.ibm.com/docs/en/watsonx/watson-orchestrate
📊 Version History
1.0.1 (2026-04-14)
- CRITICAL FIX: Corrected tool name from
analyze_infrastructuretoanalyze_infrastructure_elicitation - Fixed infrastructure analysis tool to match official mcp-instana server
- All infrastructure queries now work correctly
1.0.0 (2026-04-14)
- Initial release (had critical bug with wrong tool name)
- All 46+ tools from official mcp-instana server
- WXO Cloud compatible (no hardcoded credentials)
- Simple pass-through architecture
- Comprehensive documentation
Built for: DB2 DBA Team Slack Bot Automation Status: Production Ready Support: Internal Team Support
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file instana_comprehensive_wrapper-1.0.1.tar.gz.
File metadata
- Download URL: instana_comprehensive_wrapper-1.0.1.tar.gz
- Upload date:
- Size: 12.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.0b1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d03ee174d250006bd78b3f1974e8e6cc4ee00b061649c2dc37413a6a84b0e204
|
|
| MD5 |
91a6a3bfcd3d24b2da2df60f2c2d2e56
|
|
| BLAKE2b-256 |
f05bb5b138117d341ab21843d7c840e18698325ddc62ffe1e3e29939b019c384
|
File details
Details for the file instana_comprehensive_wrapper-1.0.1-py3-none-any.whl.
File metadata
- Download URL: instana_comprehensive_wrapper-1.0.1-py3-none-any.whl
- Upload date:
- Size: 10.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.0b1
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f211e0bcec33f6b5824f5cf96edbf60286d4e9d95792c340ff4e5203aeb117c4
|
|
| MD5 |
de2970667953c0541901a6491dac68a5
|
|
| BLAKE2b-256 |
111a4f1a5732108c19f0baa292a923ac3c0d85d16d82871a7caf1aeaed6ff654
|