Skip to main content

Module web

Module web 

Source
Expand description

HTTP and WebSocket server built on Axum.

Routes:

  • GET /ws — WebSocket endpoint (terminal I/O)
  • GET /api/v1/ping — health check
  • GET / and GET /*path — embedded static frontend

Modules§

health
Health-check endpoint (GET /api/v1/ping).
static_files
Static file serving with compile-time embedded frontend assets.
ws
WebSocket handler implementing the tty-web binary protocol.

Structs§

AppState
Shared state passed to all request handlers.

Functions§

router
Build the Axum router with all routes and shared state.