ClawKit Logo
ClawKitReliability Toolkit
Back to Registry
Official Verified

kosmi-dj

This skill should be used when the user asks to "play a video in Kosmi", "queue a video", "DJ in Kosmi", "start the video DJ", "loop videos in Kosmi", "connect to Kosmi room", "play YouTube in Kosmi", "stop the DJ loop", "add a video to the queue", "be my video DJ", or needs guidance on controlling a Kosmi watch party room via agent-browser automation.

skill-install — Terminal

Install via CLI (Recommended)

clawhub install openclaw/skills/skills/rmasciarella/kosmi-dj
Or

Kosmi Video DJ — agent-browser Automation Skill

This skill turns the agent into a video DJ for Kosmi watch party rooms. It uses agent-browser (Chromium automation via accessibility-tree snapshots) to navigate to a Kosmi room, queue videos by URL, and auto-loop playback.

Prerequisites

  • agent-browser CLI installed and on PATH (npm install -g agent-browser or available in the environment)
  • A .env file at ${CLAUDE_PLUGIN_ROOT}/.env containing room URL and credentials
  • Persistent session support via AGENT_BROWSER_SESSION_NAME env var (keeps cookies/localStorage between runs)

Environment Variables

Load from ${CLAUDE_PLUGIN_ROOT}/.env before any agent-browser calls:

VariableRequiredDescription
KOSMI_ROOM_URLYesFull URL to the Kosmi room (e.g. https://app.kosmi.io/room/XXXXX)
KOSMI_EMAILNoLogin email (skip if using persistent session)
KOSMI_PASSWORDNoLogin password (skip if using persistent session)
KOSMI_BOT_NAMENoDisplay name in room (default: clawdbot)
AGENT_BROWSER_SESSION_NAMEYesSession persistence key (default: kosmi-dj-session)
AGENT_BROWSER_ENCRYPTION_KEYNoHex key to encrypt stored session data

Core Workflow

1. Connect to Room

Execute ${CLAUDE_PLUGIN_ROOT}/skills/kosmi-dj/scripts/kosmi-connect.sh to:

  1. Open the Kosmi room URL in agent-browser
  2. Wait for page load (800ms settle)
  3. Take an accessibility snapshot to detect the current UI state
  4. If a nickname/name prompt appears → fill with KOSMI_BOT_NAME and click Join
  5. If a login prompt appears and credentials exist → fill email/password and submit
  6. Verify connection by confirming room UI elements are present

2. Play a Video by URL

Execute ${CLAUDE_PLUGIN_ROOT}/skills/kosmi-dj/scripts/kosmi-play.sh <VIDEO_URL> to:

  1. Ensure connected (runs connect idempotently)
  2. Open the Apps/media modal in Kosmi
  3. Select the URL/link input mode
  4. Fill the URL textbox with the provided video URL
  5. Click Play (or press Enter as fallback)
  6. Verify playback started by checking for player UI elements

3. Auto-Loop DJ Mode

Execute ${CLAUDE_PLUGIN_ROOT}/skills/kosmi-dj/scripts/kosmi-loop.sh to:

  1. Connect to the room
  2. Enter a fetch→play→wait→repeat cycle: a. Retrieve a video URL (from a provided list, or agent finds one) b. Play the video c. Poll the room periodically to detect when the video ends (snapshot the player state) d. When ended, play the next video
  3. Continue until interrupted or a stop signal is received

The loop script writes a PID file at /tmp/kosmi-dj-loop.pid for stop/status commands.

agent-browser CLI Reference (Quick)

All browser automation goes through the agent-browser CLI. Key commands:

Metadata

Stars1171
Views1
Updated2026-02-19
View Author Profile
AI Skill Finder

Not sure this is the right skill?

Describe what you want to build — we'll match you to the best skill from 16,000+ options.

Find the right skill
Add to Configuration

Paste this into your clawhub.json to enable this plugin.

{
  "plugins": {
    "official-rmasciarella-kosmi-dj": {
      "enabled": true,
      "auto_update": true
    }
  }
}
Safety NoteClawKit audits metadata but not runtime behavior. Use with caution.