Skip to content

SDK Overview

Official SDK libraries for smolvm. Create and manage microVM machinees for secure code execution.

Available SDKs

SDKLanguageInstall
smolvm-nodeTypeScript / JavaScriptnpm install smolvm
smolvm-pythonPythonpip install smolvm

Features

  • Machine Management - Create, start, stop, delete machinees
  • Command Execution - Run commands directly in the microVM
  • Container Support - Run OCI containers (Docker images) inside machinees
  • Volume Mounts - Mount host directories into machinees
  • Resource Control - Configure CPU and memory limits
  • GPU Acceleration - Vulkan access to host GPU for rendering and ML
  • Language Presets - Quick helpers for Python, Node.js

Requirements

  • smolvm server running (default: http://127.0.0.1:8080)
  • macOS with Apple Silicon (M1/M2/M3), or
  • Linux with KVM support (/dev/kvm accessible)

Quick Example

typescript
import { Machine } from 'smolvm';

const machine = await Machine.create({ name: 'my-machine' });

const result = await machine.exec(['echo', 'Hello!']);
console.log(result.stdout);

await machine.stop();
await machine.delete();
python
from smolvm import Machine, MachineConfig

async with Machine(MachineConfig(name="my-machine")) as machine:
    await machine.start()
    result = await machine.exec(["echo", "Hello!"])
    print(result.stdout)

Next Steps