aev-web 0.1.0

Aev lios-web plugin for local web-controlled terminal sessions.
Documentation
# aev-web

`lios-web` plugin crate for local web-controlled terminal sessions.

This provides a future `aev.plugin.v1` entrypoint named `aev_plugin_init` plus a standalone local HTTP server that can be run today.

## Run

```bash
cargo run
```

Or install the published binary:

```bash
cargo install aev-web
```

By default the server binds to `127.0.0.1:8765`, generates a bearer token, and prints a local URL containing that token.

Use explicit settings when needed:

```bash
LIOS_WEB_TOKEN=replace-with-a-secret cargo run -- --bind 127.0.0.1:8765
```

## API

- `GET /health` is public and returns server health.
- `GET /api/manifest` returns the `lios-web` plugin manifest.
- `POST /api/sessions` creates a PTY-backed terminal session.
- `GET /api/sessions` lists active sessions.
- `GET /api/sessions/{id}/output?since={cursor}` reads terminal output.
- `POST /api/sessions/{id}/input` writes terminal input.
- `DELETE /api/sessions/{id}` terminates a session.

All `/api/*` routes require `Authorization: Bearer <token>`.

## Register With Aev

The current Aev plugin board validates descriptors; it does not load plugin code yet. Register the descriptor with:

```text
/plugins add lios-web git https://github.com/Tknott95/AevWeb.git aev_plugin_init tool,terminal,web,local-http,bearer-auth
/plugins validate all
```

See `examples/plugins.json` for the equivalent `.aev/plugins.json` entry.

## Security Notes

- Keep the bind address on loopback unless you intentionally expose it.
- Treat the bearer token as terminal access.
- The web UI stores the token in browser local storage for local convenience.