Skip to content

Latest commit

 

History

History
89 lines (62 loc) · 1.96 KB

File metadata and controls

89 lines (62 loc) · 1.96 KB

Adding an App

Developers can extend Samaris OS by adding web applications via the VOLT app lifecycle.


App Manifest

Create a JSON manifest for your app:

{
  "name": "MyApp",
  "version": "1.0.0",
  "icon": "/opt/myapp/icon.svg",
  "entry": "/opt/myapp/index.html",
  "permissions": ["fs.read", "fs.write", "network.connect"],
  "window": {
    "width": 800,
    "height": 600,
    "resizable": true
  }
}

Directory Structure

/opt/myapp/
├── index.html      ← App entry point
├── icon.svg        ← App icon (SVG or PNG, 128×128 minimum)
├── manifest.json   ← Registration manifest
└── app.js          ← App logic

Registration

Place the manifest in /opt/volt/apps/ and restart the desktop session, or use the App Store to install from a URL. Apps registered in this directory are automatically loaded by the kernel's AppRegistry on boot.


Kernel Integration

Apps communicate with the kernel via WebSocket on ws://localhost:9999:

const ws = new WebSocket("ws://localhost:9999");

ws.send(JSON.stringify({
  type: "fs.list",
  data: { path: "/User/Desktop" },
  appId: "myapp"
}));

Permissions

Apps must declare required permissions in their manifest. The kernel enforces namespace-based access control:

Permission Access
fs.read Read any file the user can access
fs.write Write to user-writable paths
network.connect Make outbound network connections
audio.output Play audio through system output
clipboard.read Read system clipboard

See Security for details.


Related



← Back: Documentation Index