Skip to content

Models

All response models inherit from a base class with extra="allow" for forward-compatible parsing.

ATX

ATXState

ATX subsystem state.

Source code in src/aiopikvm/models/atx.py
class ATXState(_Base):
    """ATX subsystem state."""

    enabled: bool
    busy: bool
    leds: ATXLeds

ATXLeds

ATX LED indicators state.

Source code in src/aiopikvm/models/atx.py
class ATXLeds(_Base):
    """ATX LED indicators state."""

    power: bool
    hdd: bool

HID

HIDState

HID subsystem state.

Source code in src/aiopikvm/models/hid.py
class HIDState(_Base):
    """HID subsystem state."""

    online: bool
    busy: bool
    connected: bool | None = None
    keyboard: HIDKeyboard
    mouse: HIDMouse

HIDKeyboard

HID keyboard state.

Source code in src/aiopikvm/models/hid.py
class HIDKeyboard(_Base):
    """HID keyboard state."""

    connected: bool

HIDMouse

HID mouse state.

Source code in src/aiopikvm/models/hid.py
class HIDMouse(_Base):
    """HID mouse state."""

    absolute: bool
    connected: bool

HIDKeymap

Keyboard keymap entry.

Source code in src/aiopikvm/models/hid.py
class HIDKeymap(_Base):
    """Keyboard keymap entry."""

    name: str

MSD

MSDState

MSD subsystem state.

Source code in src/aiopikvm/models/msd.py
class MSDState(_Base):
    """MSD subsystem state."""

    enabled: bool
    online: bool
    busy: bool
    drive: MSDDrive
    storage: MSDStorage

MSDDrive

MSD virtual drive state.

Source code in src/aiopikvm/models/msd.py
class MSDDrive(_Base):
    """MSD virtual drive state."""

    image: str | None = None
    connected: bool
    cdrom: bool

MSDStorage

MSD storage information.

Source code in src/aiopikvm/models/msd.py
class MSDStorage(_Base):
    """MSD storage information."""

    size: int
    free: int
    images: dict[str, Any]

GPIO

GPIOState

GPIO subsystem state.

Source code in src/aiopikvm/models/gpio.py
class GPIOState(_Base):
    """GPIO subsystem state."""

    inputs: dict[str, GPIOInput]
    outputs: dict[str, GPIOChannel]

GPIOChannel

GPIO output channel state.

Source code in src/aiopikvm/models/gpio.py
class GPIOChannel(_Base):
    """GPIO output channel state."""

    online: bool
    state: bool
    busy: bool

GPIOInput

GPIO input channel state.

Source code in src/aiopikvm/models/gpio.py
class GPIOInput(_Base):
    """GPIO input channel state."""

    online: bool
    state: bool

Streamer

StreamerState

Streamer subsystem state.

Mirrors the shape returned by GET /api/streamer. The streamer field is None when no stream clients are connected — kvmd stops the streamer process to save resources.

Source code in src/aiopikvm/models/streamer.py
class StreamerState(_Base):
    """Streamer subsystem state.

    Mirrors the shape returned by ``GET /api/streamer``. The ``streamer``
    field is ``None`` when no stream clients are connected — kvmd stops the
    streamer process to save resources.
    """

    features: StreamerFeatures
    limits: StreamerLimits
    params: StreamerParams
    snapshot: StreamerSnapshot
    streamer: Streamer | None = None

Streamer

Running streamer process state.

Present only when the streamer is active. StreamerState.streamer is None when no clients are subscribed and kvmd has shut the streamer process down.

Source code in src/aiopikvm/models/streamer.py
class Streamer(_Base):
    """Running streamer process state.

    Present only when the streamer is active. ``StreamerState.streamer`` is
    ``None`` when no clients are subscribed and kvmd has shut the streamer
    process down.
    """

    encoder: StreamerEncoder
    h264: StreamerH264
    instance_id: str
    sinks: StreamerSinks
    source: StreamerSource
    stream: StreamerStream

StreamerSource

Streamer video source state.

Source code in src/aiopikvm/models/streamer.py
class StreamerSource(_Base):
    """Streamer video source state."""

    online: bool
    resolution: Resolution
    captured_fps: int
    desired_fps: int

Resolution

Video resolution.

Source code in src/aiopikvm/models/streamer.py
class Resolution(_Base):
    """Video resolution."""

    width: int
    height: int

OCRInfo

OCR capability metadata returned by GET /api/streamer/ocr.

Source code in src/aiopikvm/models/streamer.py
class OCRInfo(_Base):
    """OCR capability metadata returned by ``GET /api/streamer/ocr``."""

    enabled: bool
    langs: OCRLangs

OCRLangs

Available and default OCR languages.

Source code in src/aiopikvm/models/streamer.py
class OCRLangs(_Base):
    """Available and default OCR languages."""

    available: list[str]
    default: list[str]

Switch

SwitchState

KVM switch state.

Source code in src/aiopikvm/models/switch.py
class SwitchState(_Base):
    """KVM switch state."""

    active: str
    ports: dict[str, SwitchPort]

SwitchPort

KVM switch port.

Source code in src/aiopikvm/models/switch.py
6
7
8
9
class SwitchPort(_Base):
    """KVM switch port."""

    name: str

EDID

EDID profile.

Source code in src/aiopikvm/models/switch.py
class EDID(_Base):
    """EDID profile."""

    id: str
    data: str
    description: str | None = None