コンテンツにスキップ

@himorishige/hatago-core

Core types and protocol definitions for Hatago MCP Hub.

This package provides pure type definitions with no side effects. All implementations should depend on these core types.

Terminal window
npm install @himorishige/hatago-core

The dependency flow must be strictly maintained:

core → runtime → transport → server → mcp-hub
  • Types: Core type definitions for connections, sessions, and registries
  • Errors: Error codes and severity levels
  • Events: Event contracts for server lifecycle, discovery, and sessions
  • Protocol: MCP protocol definitions and constants
import { ErrorCode, ConnectionType, EventName } from '@himorishige/hatago-core';
// Use types in your implementation
const connectionType: ConnectionType = 'local';

MIT