AvaloniaUI.MCP Documentation
Welcome to the AvaloniaUI.MCP server documentation. This comprehensive Model Context Protocol (MCP) server provides extensive AvaloniaUI development assistance, code generation, and best practices guidance.
๐ Table of Contents
๐ฏ Overview
AvaloniaUI.MCP is a professional-grade MCP server built on .NET 9.0 that provides:
- 15+ Development Tools for project generation, validation, and code assistance
- Comprehensive Knowledge Base with 500+ controls, patterns, and examples
- Enterprise Features including telemetry, caching, and error handling
- Migration Support for WPF to AvaloniaUI transitions
- Security Patterns and best practices guidance
๐ Quick Start
Prerequisites
- .NET 9.0 SDK
- MCP-compatible client (Claude Desktop, VS Code with MCP extension)
Installation
1
2
3
4
5
6
7
8
9
# Clone the repository
git clone https://github.com/decriptor/AvaloniaUI.MCP.git
cd AvaloniaUI.MCP
# Build the project
dotnet build
# Run the MCP server
dotnet run --project src/AvaloniaUI.MCP/AvaloniaUI.MCP.csproj
Configuration
Configure your MCP client to connect to the server via STDIO transport:
1
2
3
4
5
6
7
8
9
{
"mcpServers": {
"avalonia": {
"command": "dotnet",
"args": ["run", "--project", "path/to/AvaloniaUI.MCP/src/AvaloniaUI.MCP/AvaloniaUI.MCP.csproj"],
"cwd": "path/to/AvaloniaUI.MCP"
}
}
}
๐ ๏ธ Core Features
Project Generation
Create production-ready AvaloniaUI projects with various templates:
- MVVM architecture with ReactiveUI
- Basic applications
- Cross-platform projects
Code Validation
- XAML syntax validation
- Property validation
- Best practices enforcement
Migration Assistance
- WPF to AvaloniaUI conversion
- Control mapping guidance
- Namespace updates
Performance Optimization
- Caching system for faster responses
- Async file operations
- Memory-efficient resource loading
๐ Telemetry & Monitoring
Built-in observability features:
- Real-time performance metrics
- Health monitoring
- Distributed tracing
- Error tracking
๐ Security
Enterprise-grade security features:
- Input validation
- Secure pattern generation
- Error handling
- Audit logging
๐งช Testing
Comprehensive test suite with 150+ tests covering:
- Tool functionality
- Resource management
- Telemetry systems
- Error scenarios
๐ Performance
Optimized for production use:
- Sub-100ms response times
- 80%+ cache hit rates
- Minimal memory footprint
- Concurrent request handling
๐ค Community
๐ License
This project is licensed under the MIT License - see the LICENSE file for details.