Control Spotify playback and manage playlists via MCP server. Use when user requests playing music, controlling Spotify, creating playlists, searching songs, or managing their Spotify library.
npx skills add https://github.com/oaustegard/claude-skills --skill controlling-spotify
Control Spotify playback, search for music, and manage playlists using the Spotify MCP Server with full user account access.
Invoke this skill when users request:
CRITICAL: This skill requires user-provided credentials. The user must complete a one-time setup:
http://127.0.0.1:8888/callbackreferences/setup-guide.md)SPOTIFY_CLIENT_ID: From Spotify Developer DashboardSPOTIFY_CLIENT_SECRET: From Spotify Developer DashboardSPOTIFY_REFRESH_TOKEN: From helper script outputAlternative: Credentials can also be provided via a Project Knowledge file. Ensure the file contains a .env style block with the keys above.
Without these credentials, the skill cannot function. If credentials are missing, guide the user through the setup process detailed in references/setup-guide.md.
The Spotify MCP Server must be installed in the compute environment. Use the provided installation script which handles cloning, patching, and building the server.
# Run the installation script
bash scripts/install-mcp-server.sh
Configure the MCP client to connect to the Spotify MCP server. Note the logic to support credentials from Project Knowledge.
from mcp import Client
import asyncio
import re
# 1. Try to get credentials from skill configuration
env_vars = {
"SPOTIFY_CLIENT_ID": credentials.get("SPOTIFY_CLIENT_ID"),
"SPOTIFY_CLIENT_SECRET": credentials.get("SPOTIFY_CLIENT_SECRET"),
"SPOTIFY_REFRESH_TOKEN": credentials.get("SPOTIFY_REFRESH_TOKEN")
}
# 2. If missing, look in Project Knowledge / Context for .env style block
if not all(env_vars.values()):
# Heuristic: Scan context/files for VAR=VALUE patterns
# (Pseudo-code: Implement based on available context access)
pass
# Server configuration
mcp_config = {
"command": "node",
"args": ["/home/claude/spotify-mcp-server/build/index.js"],
"env": env_vars
}
# Initialize client
async def initialize_spotify_mcp():
client = Client()
await client.connect_stdio(
mcp_config["command"],
mcp_config["args"],
mcp_config["env"]
)
return client
result = await client.call_tool("searchSpotify", {
"query": "bohemian rhapsody",
"type": "track",
"limit": 10
})
result = await client.call_tool("getNowPlaying", {})
result = await client.call_tool("getMyPlaylists", {
"limit": 20,
"offset": 0
})
result = await client.call_tool("getPlaylistTracks", {
"playlistId": "37i9dQZEVXcJZyENOWUFo7"
})
result = await client.call_tool("getRecentlyPlayed", {
"limit": 10
})
result = await client.call_tool("getUsersSavedTracks", {
"limit": 50,
"offset": 0
})
# Play by URI
result = await client.call_tool("playMusic", {
"uri": "spotify:track:6rqhFgbbKwnb9MLmUQDhG6"
})
# Or by type and ID
result = await client.call_tool("playMusic", {
"type": "track",
"id": "6rqhFgbbKwnb9MLmUQDhG6"
})
result = await client.call_tool("pausePlayback", {})
result = await client.call_tool("skipToNext", {})
result = await client.call_tool("skipToPrevious", {})
result = await client.call_tool("addToQueue", {
"uri": "spotify:track:6rqhFgbbKwnb9MLmUQDhG6"
})
result = await client.call_tool("createPlaylist", {
"name": "My Workout Mix",
"description": "High energy tracks",
"public": False
})
result = await client.call_tool("addTracksToPlaylist", {
"playlistId": "3cEYpjA9oz9GiPac4AsH4n",
"trackUris": [
"spotify:track:4iV5W9uYEdYUVa79Axb7Rh",
"spotify:track:6rqhFgbbKwnb9MLmUQDhG6"
]
})
result = await client.call_tool("getAlbums", {
"albumIds": ["4aawyAB9vmqN3uQ7FjRGTy"]
})
result = await client.call_tool("getAlbumTracks", {
"albumId": "4aawyAB9vmqN3uQ7FjRGTy"
})
result = await client.call_tool("saveOrRemoveAlbumForUser", {
"albumIds": ["4aawyAB9vmqN3uQ7FjRGTy"],
"action": "save"
})
# 1. Search for the song
search_result = await client.call_tool("searchSpotify", {
"query": "user's favorite song name",
"type": "track",
"limit": 1
})
# 2. Extract track URI from results
track_uri = search_result["tracks"][0]["uri"]
# 3. Play the track
await client.call_tool("playMusic", {
"uri": track_uri
})
# 1. Search for tracks in genre
search_result = await client.call_tool("searchSpotify", {
"query": "genre:rock year:2020-2024",
"type": "track",
"limit": 20
})
# 2. Create new playlist
playlist_result = await client.call_tool("createPlaylist", {
"name": "Modern Rock Mix",
"description": "Recent rock tracks",
"public": False
})
# 3. Extract track URIs
track_uris = [track["uri"] for track in search_result["tracks"]]
# 4. Add tracks to playlist
await client.call_tool("addTracksToPlaylist", {
"playlistId": playlist_result["id"],
"trackUris": track_uris
})
# Get current playback state
now_playing = await client.call_tool("getNowPlaying", {})
# Format and display
print(f"Now Playing: {now_playing['track']['name']}")
print(f"Artist: {now_playing['track']['artists'][0]['name']}")
print(f"Album: {now_playing['track']['album']['name']}")
print(f"Progress: {now_playing['progress_ms']} / {now_playing['duration_ms']} ms")
Playback control operations (play, pause, skip, queue) require Spotify Premium. Read operations (search, get playlists, view tracks) work with free accounts.
For playback commands to work, the user must have an active Spotify session (web player, desktop app, mobile app) with a device available. If no active device, playback commands will fail.
Spotify API has rate limits (typically 180 requests per minute). For bulk operations, implement appropriate delays or batching.
Spotify uses URIs in the format:
spotify:track:IDspotify:album:IDspotify:artist:IDspotify:playlist:IDMost tools accept either URIs or separate type + id parameters.
Cause: Missing environment variables
Solution: Verify credentials are properly configured:
import os
print(os.getenv("SPOTIFY_CLIENT_ID")) # Should not be None
print(os.getenv("SPOTIFY_CLIENT_SECRET")) # Should not be None
print(os.getenv("SPOTIFY_REFRESH_TOKEN")) # Should not be None
Cause: No Spotify client is currently running/active
Solution: Guide user to:
Cause: User has Spotify Free account
Solution: Playback control requires Spotify Premium. Only search and read operations available for free accounts.
Cause: Missing dependencies or incorrect installation
Solution:
# Re-run installation script
bash scripts/install-mcp-server.sh
getNowPlaying to verify device availabilityreferences/setup-guide.mdThis skill requires sensitive credentials. Ensure:
See references/setup-guide.md for detailed security best practices.
agent-im 会话技能 - 通过 liblib.tv 的 AI 能力生成和编辑图片/视频。覆盖场景包括:生成(文生图、文生视频、图生视频、做动画、画一个xxx、来段xxx)、编辑修改(把xxx换成yyy、去掉xxx、加上xxx、改成xxx、调整xxx、局部修改、改镜头)、风格转换(风格迁移、转绘、换风格)、视频续写延长、复刻视频/TVC/宣传片、短剧/短漫剧生成、音乐MV生成、产品广告/展示片制作、分镜/故事板设计、教育视频/短视频制作。当用户提到 liblib、libtv、上传参考图/视频、查看生成进度时也应触发。关键判断:只要用户的请求涉及 AI 图片或视频的创作、生成、编辑、修改,无论措辞如何(如"画只猫"、"做个海报"、"把纸船换成爱心"、"这个视频帮我改一下"、"帮我复刻这段视频"、"用这首歌做个MV"、"一句话生成短剧"),都必须触发此技能。
This skill should be used when the user asks to "generate video prompts", "create Seedance prompts", "write video descriptions", mentions "Seedance", "seedance", "即梦", "即梦平台", "视频提示词", "视频生成", "AI视频", "短剧", "广告视频", "视频延长", or discusses video prompt engineering, AI video generation, or Seedance 2.0 workflows.
Best practices and techniques for writing effective AI video generation prompts. Covers: Veo, Seedance, Wan, Grok, Kling, Runway, Pika, Sora prompting strategies. Learn: shot types, camera movements, lighting, pacing, style keywords, negative prompts. Use for: improving video quality, getting consistent results, professional video prompts. Triggers: video prompt, how to prompt video, veo prompts, video generation tips, better ai video, video prompt engineering, video prompt guide, video prompt template, ai video tips, video prompt best practices, video prompt examples, cinematography prompts
This skill is a practical, 'use-it-while-debugging' reference for getting a LiveKit + Letta voice agent working reliably.
Download screenshot baselines from the latest CI run and commit them. Use when asked to update, accept, or refresh component screenshot baselines from CI, or after the screenshot-test GitHub Action reports differences. This skill should be run as a subagent.
| Turn vague taste, screenshots, URLs, product notes, or "make it feel like this" references into a grounded DESIGN.md plus an implementation handoff. Use it before prototypes, decks, redesigns, or image remix work when the user needs a reusable visual direction rather than a one-off prompt.
>- Upload local assets (images, mockups, extracted HTML, design markdown) to a Stitch project. ALWAYS use this skill when you need to upload visual assets, HTML pages, or design docs to Stitch, particularly when direct MCP tool calls fail or truncate due to base64 token limits.
This skill helps users automatically extract channel-level and video detail data from a specific YouTube channel via BrowserAct API. Agent should proactively apply this skill when users express needs like extracting channel video data, getting latest or popular videos from a YouTube channel, tracking competitor channel content, extracting video metrics such as views likes comments, retrieving subscriber count and channel info, monitoring posting cadence of a YouTube channel, gathering video data for content strategy analysis, getting earliest videos of a YouTube creator, analyzing engagement signals across a full channel, and downloading structured YouTube video details without manual scraping.
Take oaustegard/controlling-spotify from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.