//! WebSocket service — domain logic for real-time pipeline updates, chat, and
//! permission prompts.
//!
//! This module extracts the business logic from `http/ws.rs` into the service
//! layer following the conventions in `docs/architecture/service-modules.md`:
//! - `mod.rs` — public API, typed `Error`, orchestration
//! - `io.rs` — the only file that may perform side effects
//! - `message.rs` — pure message types and conversions
//! - `dispatch.rs` — pure request routing and permission resolution
//! - `error.rs` — typed error enum

/// Pure request routing and permission resolution.
pub mod dispatch;
/// Typed WebSocket error enum.
pub mod error;
pub(super) mod io;
/// Pure WebSocket message types and domain-event conversions.
pub mod message;

pub use dispatch::{
    DispatchResult, InnerDispatchResult, dispatch_inner, dispatch_outer, error_response,
    permission_request_response,
};
pub use io::{
    check_onboarding, load_initial_pipeline_state, load_recent_logs, load_wizard_state,
    subscribe_logs, subscribe_persona_pipeline_events, subscribe_reconciliation, subscribe_status,
    subscribe_watcher,
};
pub use message::{WizardStepInfo, WsResponse};
