167 Commits

Author SHA1 Message Date
jango-blockchained
d7f127af4d Merge remote changes and resolve conflicts 2025-02-01 13:55:07 +01:00
jango-blockchained
8f0b9eb909 Enhance Jest Configuration and Resolver for ESM and TypeScript Support
- Updated Jest configuration to handle .mts and .mjs file extensions
- Improved Jest resolver to better support ESM modules and @digital-alchemy packages
- Added comprehensive test coverage for AI router, Home Assistant integration, and WebSocket client
- Expanded test scenarios for error handling, event subscriptions, and service interactions
2025-02-01 13:53:55 +01:00
Tevon Strand-Brown
99c66099c6 Update package.json with project name, dependencies, and package manager
- Corrected package name from `jango-blockchained/homeassistant-mcp` to `homeassistant-mcp`
- Added `@types/supertest` and `supertest` for testing
- Updated package manager specification to Yarn 1.22.22
2025-02-01 12:41:00 +01:00
jango-blockchained
675f6e3942 Add OpenAI-powered Home Assistant Analysis Tool
- Implemented comprehensive AI-driven system analysis using OpenAI's GPT-4
- Created interactive CLI tool for Home Assistant device and system insights
- Added support for standard and custom prompt-based analysis
- Integrated MCP server data collection with intelligent AI processing
- Updated package.json with new OpenAI and XML dependencies
- Enhanced README with detailed OpenAI integration documentation
2025-02-01 12:35:13 +01:00
jango-blockchained
9037cffcfe Add MCP Execute Endpoint with Secure Authentication and Tool Execution
- Implemented `/mcp/execute` endpoint for tool execution
- Added token-based authentication using HASS_TOKEN
- Supports dynamic tool selection and parameter passing
- Includes comprehensive error handling for unauthorized access and tool not found scenarios
- Provides flexible execution workflow with detailed response handling
2025-02-01 12:29:42 +01:00
jango-blockchained
431a68d690 Refactor SSE Endpoint with Enhanced Token Validation and Client Management
- Replaced direct token comparison with TokenManager validation
- Implemented robust SSE client connection and event subscription workflow
- Added detailed client authentication and connection status reporting
- Improved SSE endpoint with flexible event, entity, and domain subscription
- Enhanced error handling and client disconnect management
2025-02-01 07:50:54 +01:00
jango-blockchained
d3da46d5d5 Enhance Claude Desktop MCP Setup Script with Robust Installation and Configuration Management
- Added comprehensive error handling and validation functions
- Implemented backup and upgrade/clean install workflow
- Enhanced system requirements and dependency checks
- Improved configuration management with secure token and URL validation
- Added detailed user interaction and informative console output
- Implemented flexible installation modes with existing configuration preservation
2025-02-01 06:45:57 +01:00
jango-blockchained
155a6ea5ba Add MCP Schema Endpoint for API Discovery
- Implemented `/mcp` endpoint to expose server capabilities
- Created `src/mcp/schema.ts` with comprehensive tool and resource definitions
- Updated README.md with MCP Schema documentation
- Modified security middleware to allow unauthenticated access to schema endpoint
- Included detailed tool descriptions for list_devices, control, and event subscription
2025-02-01 06:42:16 +01:00
Tevon Strand-Brown
281cf29158 Update README.md with Claude use 2025-01-31 20:56:35 -08:00
Tevon Strand-Brown
61d4af5a06 Yarn refuses to illegal characters in package name 2025-01-31 20:43:09 -08:00
Tevon Strand-Brown
9682642733 Merge pull request #5 from jango-blockchained/main
Comprehensive Home Assistant MCP Enhancement
2025-01-31 20:38:01 -08:00
jango-blockchained
aa911c179d Merge branch 'main' of https://github.com/jango-blockchained/homeassistant-mcp 2025-02-01 04:23:30 +01:00
jango-blockchained
13773d2977 Add Docker support and enhance server configuration
- Created Dockerfile for containerized deployment
- Added .dockerignore to optimize Docker build context
- Updated README with comprehensive Docker setup instructions
- Implemented new server endpoints:
  * Health check endpoint
  * Device listing
  * Device control
  * SSE event subscription
- Enhanced security middleware with request validation and input sanitization
- Added error handling and token-based authentication for new endpoints
2025-02-01 04:21:45 +01:00
Tevon Strand-Brown
79f1418f6f Merge branch 'main' into main 2025-01-31 16:52:34 -08:00
jango-blockchained
b855b05dca Remove coverage directory and update .gitignore 2025-01-31 23:16:21 +01:00
jango-blockchained
3b2e9640db Refactor Home Assistant server initialization with Express and comprehensive endpoint management
- Added Express server with security middleware
- Implemented dynamic tool registration and API endpoint generation
- Enhanced logging with structured initialization messages
- Created centralized tools tracking for automatic endpoint discovery
- Added explicit Express server startup alongside MCP server
- Improved initialization logging with detailed endpoint information
2025-01-31 23:05:14 +01:00
jango-blockchained
662cb1b2fb Update get_hass function to use proper bootstrap initialization for consistent logging 2025-01-31 22:42:07 +01:00
jango-blockchained
59cbd2552b Add comprehensive Home Assistant WebSocket and API tests
- Created detailed test suite for Home Assistant WebSocket client
- Implemented tests for WebSocket connection, authentication, and error handling
- Added comprehensive test coverage for HassInstanceImpl API methods
- Mocked WebSocket and fetch to simulate various connection scenarios
- Covered authentication, state retrieval, service calls, and environment configuration
- Improved test infrastructure for Home Assistant integration
2025-01-31 20:29:24 +01:00
jango-blockchained
90cf0ca315 Enhance Context Manager test suite and improve test coverage
- Refactored and simplified Context Manager test cases
- Updated test scenarios for resource management, relationships, and event subscriptions
- Improved test readability and reduced test complexity
- Configured Jest to collect and report code coverage
- Added coverage thresholds and reporting options
2025-01-30 20:07:00 +01:00
jango-blockchained
96aaffd952 Update project configuration and testing infrastructure
- Refactored Jest configuration for improved ESM and TypeScript support
- Updated `jest.setup.ts` with comprehensive test environment configuration
- Enhanced mocking for WebSocket, console, and external dependencies
- Adjusted package.json dependencies and scripts
- Updated tsconfig.json with decorator and test exclusion settings
- Improved test coverage configuration and reporting
- Simplified test file structure and mocking strategies
2025-01-30 20:06:40 +01:00
jango-blockchained
e1e0a45acc Add Server-Sent Events (SSE) API documentation and README updates
- Created comprehensive SSE API documentation in `docs/SSE_API.md`
- Updated README.md with new features section highlighting SSE capabilities
- Added `.cursornotes` file for SSE subscription flow
- Provided detailed examples and usage guidelines for SSE integration
- Documented event types, authentication, and best practices for real-time updates
2025-01-30 12:21:25 +01:00
jango-blockchained
64e619252c Add Server-Sent Events (SSE) support for Home Assistant integration
- Implemented comprehensive SSE manager with advanced client management
- Added dynamic event subscription and broadcasting capabilities
- Created robust rate limiting and client connection tracking
- Enhanced Home Assistant event handling with new SSE endpoints
- Updated package.json with UUID dependency for client identification
- Expanded test coverage for SSE and WebSocket event handling
- Improved type definitions for Home Assistant events and entities
2025-01-30 11:42:19 +01:00
jango-blockchained
70c9287c68 Add comprehensive Home Assistant MCP API documentation
- Created detailed API documentation for Home Assistant Model Context Protocol (MCP)
- Documented authentication, rate limiting, and security best practices
- Included comprehensive endpoint descriptions for:
  * Natural Language Processing
  * Device Control
  * History
  * Scenes
  * Automations
  * Add-ons
  * Package Management
- Added WebSocket event handling and connection examples
- Provided error handling and response format guidelines
2025-01-30 11:04:21 +01:00
jango-blockchained
43cd320a92 Refactor Home Assistant WebSocket client and configuration management
- Completely rewrote HassWebSocketClient with enhanced event handling and connection management
- Added environment-specific configuration support for Home Assistant connection
- Implemented robust WebSocket connection, authentication, and event subscription methods
- Created more flexible HassInstance interface with improved type definitions
- Added support for dynamic environment configuration and error handling
2025-01-30 11:03:13 +01:00
jango-blockchained
8152313f52 Refactor Home Assistant API and schema validation
- Completely rewrote HassInstance class with fetch-based API methods
- Updated Home Assistant schemas to be more precise and flexible
- Removed deprecated test environment configuration file
- Enhanced WebSocket client implementation
- Improved test coverage for Home Assistant API and schema validation
- Simplified type definitions and error handling
2025-01-30 10:51:25 +01:00
jango-blockchained
732a727d27 Add comprehensive Home Assistant schema validation tests
- Created detailed test suite for Home Assistant schema validation
- Implemented schemas for entities, services, events, configurations, automations, and device controls
- Added robust validation for complex Home Assistant data structures
- Enhanced type safety and validation for Home Assistant-related interfaces
- Expanded schema definitions to support multiple use cases and edge scenarios
2025-01-30 10:42:39 +01:00
jango-blockchained
251dfa0a91 Add comprehensive Home Assistant API integration tests
- Created detailed test suite for Home Assistant API interactions
- Implemented tests for API connection, state management, service calls, and event handling
- Added robust error handling and edge case scenarios for HASS API integration
- Mocked fetch and WebSocket to simulate various API response conditions
- Covered authentication, state retrieval, service invocation, and event subscription scenarios
2025-01-30 10:11:10 +01:00
jango-blockchained
c904e4f188 Add comprehensive security middleware and token management tests
- Introduced detailed test suites for security middleware components
- Added robust test coverage for token encryption, decryption, and validation
- Implemented comprehensive tests for input sanitization and error handling
- Created test scenarios for rate limiting and security header configurations
- Enhanced test infrastructure for security-related modules with edge case handling
2025-01-30 10:10:15 +01:00
jango-blockchained
c64dc4334b Add AI NLP and router modules for advanced natural language processing
- Introduced comprehensive NLP processing modules for intent classification, entity extraction, and context analysis
- Created AI router with rate-limited endpoints for command interpretation and execution
- Added prompt templates for different AI models with configurable system and user prompts
- Implemented robust type definitions for AI-related interfaces and schemas
- Enhanced security and error handling in AI processing pipeline
2025-01-30 10:05:57 +01:00
jango-blockchained
3115c41e87 Add test environment configuration and update Jest setup
- Created `.env.test.example` with test environment variables
- Updated `jest.config.cjs` to simplify configuration and improve test setup
- Added `jest.setup.ts` to load and configure test environment variables
- Updated test files to use dynamic test environment configuration
- Enhanced README.md with additional configuration details for testing
2025-01-30 09:56:19 +01:00
jango-blockchained
b3fa5f729e Enhance test infrastructure and add comprehensive WebSocket and security mocking
- Updated test suite with more robust mocking for WebSocket and security modules
- Expanded test coverage for performance monitoring and optimization utilities
- Added detailed type definitions for WebSocket and test response interfaces
- Improved error handling and type safety in test scenarios
- Updated package dependencies to include WebSocket and security-related libraries
2025-01-30 09:43:19 +01:00
jango-blockchained
f5f756f71e Simplify security middleware configuration
- Replaced detailed Helmet configuration with default settings
- Added rate limiting middleware with standard configuration
- Streamlined security middleware chain for improved readability and maintainability
2025-01-30 09:27:35 +01:00
jango-blockchained
585b8d1f91 Enhance security middleware and package dependencies
- Updated security headers configuration with stricter settings
- Modified rate limiting and helmet middleware setup
- Added TypeScript type definitions for Express, rate-limit, and Helmet
- Refined referrer policy and HSTS configuration
- Improved security middleware chain for better protection
2025-01-30 09:27:22 +01:00
jango-blockchained
110f2a308c Add comprehensive WebSocket, context, performance, and security modules
- Introduced WebSocket client for real-time Home Assistant event streaming
- Created context management system for tracking resource relationships and state
- Implemented performance monitoring and optimization utilities
- Added security middleware with token validation, rate limiting, and input sanitization
- Extended tool registry with enhanced tool registration and execution capabilities
- Expanded test coverage for new modules and added comprehensive test scenarios
- Improved type safety and added robust error handling across new modules
2025-01-30 09:18:17 +01:00
jango-blockchained
d7e5fcf764 Enhance Jest configuration and testing infrastructure
- Updated Jest configuration to support ESM and improve test coverage
- Added comprehensive test files for helpers, index, context, and HASS integration
- Configured coverage reporting and added new test scripts
- Updated Jest resolver to handle module resolution for chalk and related packages
- Introduced new test setup files for mocking and environment configuration
2025-01-30 09:04:07 +01:00
Tevon Strand-Brown
87dc4ad66b Update README.md (added control) 2024-12-29 10:17:24 -08:00
Tevon Strand-Brown
f398e43f04 Merge pull request #1 from smithery-ai/add-smithery 2024-12-24 15:19:19 -08:00
Henry Mao
12a576b3eb Update README.md 2024-12-23 16:17:23 +08:00
Henry Mao
6f480f1c73 Add Smithery CLI installation instructions and badge 2024-12-23 15:16:51 +07:00
jango-blockchained
f908d83cbf Update README.md to improve Docker setup instructions
- Clarified Docker setup section, indicating that the setup is in progress and directing users to the `docker` branch for the latest changes.
- Added instructions to copy the `.env.example` file to `.env` for environment configuration.
- Enhanced clarity on configuring the environment variables in the `.env` file, emphasizing the need for user-specific values.
2024-12-17 17:01:28 +01:00
jango-blockchained
e1eb96a46d Update .env.example for development environment configuration
- Changed NODE_ENV from production to development for local testing.
- Updated HASS_HOST and HASS_SOCKET_URL to point to local Home Assistant instance.
- Added PORT and LOG_LEVEL variables for better control over application settings during development.
2024-12-17 16:49:08 +01:00
jango-blockchained
6df461bb78 Enhance README.md with new features and project updates
- Added sections for Docker containerization, Jest testing setup, TypeScript integration, and Home Assistant API integration.
- Improved organization of the "In Progress" and "Planned" sections, detailing ongoing and future enhancements.
- Expanded on custom prompt testing, macOS integration, type safety improvements, and testing coverage.
- Updated project documentation for better clarity and user guidance.
2024-12-17 16:42:15 +01:00
jango-blockchained
a69cdb1d22 Enhance README.md for clarity and organization
- Forked from tevonsb/homeassistant-mcp and added relevant badges for license, Node.js, Docker Compose, and NPM versions.
- Expanded the Table of Contents for easier navigation.
- Clarified prerequisites by specifying required tools and their versions.
- Improved installation instructions with formatted code blocks for better readability.
- Enhanced troubleshooting section with clearer issue descriptions and solutions.
- Updated command examples for consistency and added details for environment variable configuration.
2024-12-17 16:36:04 +01:00
jango-blockchained
a6fc9397db Add Jest configuration and update TypeScript dependency 2024-12-17 16:21:19 +01:00
jango-blockchained
26f6e155dd Add HassEntity interface and improve type safety in device handling 2024-12-17 16:12:12 +01:00
jango-blockchained
164e2a336c Refactor Claude Desktop setup for macOS integration
- Removed the old `claude_desktop_setup.sh` script and replaced it with a new `claude-desktop-macos-setup.sh` script for improved installation and configuration of MCP integration on macOS.
- Enhanced Node.js installation process using Homebrew, ensuring compatibility with version 20.10.0 or higher.
- Added checks for required tools (npm, jq) and streamlined the configuration process, including optional Brave Search integration.
- Improved configuration file generation with better handling of environment variables and permissions.
- Updated user prompts and installation messages for clarity and guidance.
2024-12-17 16:05:35 +01:00
jango-blockchained
c580f2faa8 Remove Docker-related files from dev branch 2024-12-17 15:25:40 +01:00
jango-blockchained
ada5ea4646 Enhance project structure and testing capabilities
- Updated .dockerignore to include additional logs and IDE files, improving Docker build efficiency.
- Added .eslintrc.json for TypeScript linting configuration, ensuring code quality and consistency.
- Refactored Dockerfile to streamline the build process and utilize a slimmer Node.js image.
- Introduced jest-resolver.cjs and jest.setup.js for improved Jest testing configuration and setup.
- Updated jest.config.js to support ESM and added new test patterns for better test organization.
- Enhanced TypeScript schemas to include new device types (media_player, fan, lock, vacuum, scene, script, camera) for comprehensive validation.
- Added unit tests for device schemas and Home Assistant connection, improving test coverage and reliability.
- Updated README.md with new testing instructions and device control examples, enhancing user guidance.
2024-12-17 15:07:40 +01:00
jango-blockchained
7610147a19 Update README.md to enhance clarity and organization
- Renamed "Sensors" to "Sensors & Contacts" for better accuracy.
- Changed section title from "Quick Start" to "Prerequisites" and refined the prerequisites list for clarity.
- Added an "Installation" section with detailed setup instructions.
- Updated "Usage Guide" to "Configuration" and included a new section for environment variable setup.
- Expanded command examples for light, climate, and cover controls to include additional parameters.
- Improved troubleshooting section with more detailed entity control issues.
- Consolidated resources section for better accessibility.
2024-12-17 12:09:19 +01:00
jango-blockchained
dd832a8011 Add .env.example file for environment variable configuration
- Created a new .env.example file to provide a template for required environment variables, including NODE_ENV, HASS_HOST, and HASS_TOKEN.
- This addition enhances configuration management by guiding users on necessary settings for the application.
2024-12-16 15:05:00 +01:00