Follow these steps to sync your Claude sessions to this dashboard.
Set these environment variables on your Coolify server:
# Required for the dashboard API
SUPABASE_URL=https://supabase.starworx.nl
SUPABASE_SERVICE_KEY=your-supabase-service-key
# Sync authentication token (generate a secure random string)
CLAUDE_SYNC_TOKEN=your-secure-token-hereRun this SQL in your Supabase SQL editor at supabase.starworx.nl:
-- Create the sessions table
CREATE TABLE IF NOT EXISTS claude_sessions (
id UUID PRIMARY KEY DEFAULT gen_random_uuid(),
session_id TEXT NOT NULL,
device_id TEXT NOT NULL,
device_name TEXT,
device_type TEXT,
interface TEXT NOT NULL,
platforms TEXT[] DEFAULT '{}',
working_dir TEXT,
questions JSONB DEFAULT '[]'::jsonb,
created_at TIMESTAMPTZ DEFAULT NOW(),
updated_at TIMESTAMPTZ DEFAULT NOW(),
UNIQUE(device_id, session_id)
);
-- Create indexes
CREATE INDEX IF NOT EXISTS idx_sessions_updated ON claude_sessions(updated_at DESC);
-- Auto-update timestamp
CREATE OR REPLACE FUNCTION update_updated_at()
RETURNS TRIGGER AS $$ BEGIN NEW.updated_at = NOW(); RETURN NEW; END; $$ LANGUAGE plpgsql;
DROP TRIGGER IF EXISTS sessions_updated_at ON claude_sessions;
CREATE TRIGGER sessions_updated_at BEFORE UPDATE ON claude_sessions
FOR EACH ROW EXECUTE FUNCTION update_updated_at();Set environment variables on each device, then install the hook config:
# Add to ~/.bashrc or ~/.zshrc
export CLAUDE_SYNC_TOKEN="your-secure-token-here"
export CLAUDE_DEVICE_ID="$(hostname)"
export CLAUDE_DEVICE_TYPE="$(uname -s) ($(uname -s | tr '[:upper:]' '[:lower:]') $(uname -m))"
# Then install the hook (backup existing settings first!)
curl -fsSL https://apps.starworx.nl/claudedash/plugin/claude-sync.json > ~/.claude/settings.json# Set environment variables (run as Administrator for system-wide)
[Environment]::SetEnvironmentVariable("CLAUDE_SYNC_TOKEN", "your-secure-token-here", "User")
[Environment]::SetEnvironmentVariable("CLAUDE_DEVICE_ID", $env:COMPUTERNAME, "User")
[Environment]::SetEnvironmentVariable("CLAUDE_DEVICE_TYPE", "Windows (win32 x64)", "User")
# Download hook config
Invoke-WebRequest -Uri "https://apps.starworx.nl/claudedash/plugin/claude-sync.json" -OutFile "$env:USERPROFILE\.claude\settings.json"Download and run the file watcher script:
# Set token first
export CLAUDE_SYNC_TOKEN="your-secure-token-here"
# Download and run
curl -fsSL https://apps.starworx.nl/claudedash/plugin/claude-sync.mjs -o ~/claude-sync.mjs
node ~/claude-sync.mjs# Set token first
$env:CLAUDE_SYNC_TOKEN = "your-secure-token-here"
# Download and run
Invoke-WebRequest -Uri "https://apps.starworx.nl/claudedash/plugin/claude-sync.mjs" -OutFile "$env:USERPROFILE\claude-sync.mjs"
node $env:USERPROFILE\claude-sync.mjsTo run the watcher in the background, consider using a process manager like pm2 or creating a system service.
Send a test request to verify everything works:
curl -X POST https://apps.starworx.nl/claudedash/api/sync \
-H "Authorization: Bearer your-secure-token-here" \
-H "Content-Type: application/json" \
-H "X-Device-Id: test-device" \
-H "X-Device-Name: Test Machine" \
-H "X-Device-Type: Test (test test)" \
-H "X-Interface: claude-code" \
-d '{"session_id":"test-session-123","questions":["Test question"]}'If successful, you should see the test session appear on the dashboard.