Skip to main content
New protocol version released: This page may contain outdated information.
Complete reference documentation for all HAIP SDK classes, interfaces, and functions.

Core Exports

createHAIPClient()

Factory function to create a HAIP client instance.
config
HAIPClientConfig
required
Client configuration object.
Returns: HAIPClient - Configured client instance Example:

Types

HAIPClientConfig

Configuration for creating a HAIP client.

HAIPFlowControlConfig

Flow control configuration.

HAIPMessage

Core message interface for all HAI Protocol messages.

HAIPEnvelope

Message envelope containing metadata.

HAIPEventType

All supported HAIP event types.

HAIPChannel

Supported message channels.

Client Interface

HAIPClient

Main client interface for HAI Protocol communication.

Transport Interfaces

HAIPTransport

Base transport interface.

WebSocketTransport

WebSocket transport implementation.

SSETransport

Server-Sent Events transport implementation.

HTTPStreamingTransport

HTTP streaming transport implementation.

Utility Functions

HAIPUtils

Utility functions for HAI Protocol operations.

State Interfaces

HAIPConnectionState

Current connection state information.

HAIPPerformanceMetrics

Performance and usage metrics.

HAIPRun

Run session information.

Tool Interfaces

HAIPTool

Tool definition for MCP integration.

HAIPToolCall

Tool call information.

HAIPToolResult

Tool execution result.

Error Types

HAIPError

Base error class for HAIP SDK errors.

HAIPConnectionError

Connection-related errors.

HAIPAuthenticationError

Authentication-related errors.

HAIPFlowControlError

Flow control-related errors.

Configuration Types

WebSocketTransportOptions

WebSocket-specific configuration options.

SSETransportOptions

SSE-specific configuration options.

HTTPStreamingTransportOptions

HTTP streaming-specific configuration options.

Event Types

HAIPClientEvents

Events emitted by the HAIP client.

HAIPTransportEvents

Events emitted by transport implementations.

Constants

HAIPConstants

Protocol constants and default values.

Next Steps

Client API

Learn about the client interface and methods.

Examples

See practical examples of API usage.

Types

Explore detailed type definitions.

Utilities

Learn about utility functions and helpers.