Imported from Divy13ansh/homelab_jarvis (
skills/spotify/SKILL.md). Install upstream withnpx skills add Divy13ansh/homelab_jarvis --skill spotify. Copyright stays with the author.
Spotify
HARD RULES: You CAN play music — the adapter below is a working playback remote.
NEVER say "I can't play music" or answer from knowledge. ALWAYS call the adapter.
There is NO openclaw spotify command and NO spotifyd/spotify_player/spogo binary — never try those; the adapter via exec is the ONLY playback path (a third-party plugin was removed).
NEVER use web_search/web_fetch for playback requests — search the Spotify catalog with the adapter's search, not the web.
For "play Radiohead", "queue X", "pause", "next", "volume 50%":
- Check first — Always run
statusbefore acting. Noteis_playing, current item, and active device. Known devices:jarvis-server(homelab speakers — prefer when asked "on the server/homelab"), user's MacBook/phone by name. - Don't hijack — If something is already playing and the user did NOT say "now", "interrupt", or "switch":
searchthe request, thenqueue --uriit (adds to up-next, current music keeps playing) and say it's queued. Onlyplay(replace) when idle or explicitly asked to switch. - Resolve — If track/artist ambiguous,
web_searchfor disambiguation, thenexec:python3 /app/voice/spotify_adapter.py search --query "<query>". Use the real URI from search results — never invent one. - Control — Call adapter:
python3 /app/voice/spotify_adapter.py devices(list;*= active)- If
playfails with NO_ACTIVE_DEVICE:python3 /app/voice/spotify_adapter.py transfer --device "<name>", then retry play. python3 /app/voice/spotify_adapter.py play --query "<query>" [--device <name>]python3 /app/voice/spotify_adapter.py queue --uri <spotify:track:...>python3 /app/voice/spotify_adapter.py pause|next|prev|volume --value 50python3 /app/voice/spotify_adapter.py status
- Auth — Adapter handles OAuth token refresh from
/home/node/.openclaw/spotify.json(refresh token). If not authenticated, instruct user to runpython3 /app/voice/spotify_adapter.py authand follow URL. - Verify (mandatory) — After
play, runstatusand check real state. Only say "playing X" if the player reportsis_playing:trueon that track. If NO_ACTIVE_DEVICE:transfer --device "<name>", retry play, re-check status. Ifplayreturns ok butstatusstill showsis_playing:false/item:nullafter one retry: stop, report honestly that the app accepted the command but isn't rendering audio — the desktop app is asleep and needs one manual play press in the Spotify app, then API control works. - Confirm — Report what started playing, device, and queue state. Do not build a music service; adapter is tiny wrapper over Web API.