Recovering Deleted Apple Music Playlists with Claude Cowork

A detailed use case shows how Claude Cowork helped recover 20+ years of deleted Apple Music playlists after a user accidentally wiped their entire library while troubleshooting an iCloud sync issue. The recovery involved reconstructing 75 playlists and slotting 8,185 tracks back into them.
The Problem
The user deleted every playlist in their Apple Music library and the entire Apple Music cloud library in June 2025 while trying to fix an iCloud sync issue. This included roughly 20 years of curation, imports from Spotify, and 7 years of Apple Music preference building. The only remaining data was a damaged Favorites list and some Discovery playlists.
What Claude Cowork Did
After the user described the problem and pointed to an Apple data export folder, Claude Cowork:
- Found and parsed the
Apple Music Library Playlists.jsonandTracks.jsonfiles inside the export - Cross-referenced a 256,617-row Play Activity CSV to reconstruct deleted playlist contents (modification dates showed all deletions occurred on 2025-06-01)
- Recovered 31 of 34 deleted playlists from play history alone with full track lists
- Wrote Python scripts to generate a formatted Excel report with 4 sheets: Summary, Active Playlists, Deleted/Recovered, and Full Library sorted by play count
- Generated 14 AppleScript shell scripts split across active and deleted playlists that searched the Music.app library and automatically slotted tracks into recreated playlists
- Debugged multiple rounds of AppleScript syntax errors, encoding issues (em dashes and special characters causing Script Editor to misidentify files as Chinese), and iCloud permission errors
- Built a master
RUN_ALL.shscript to run all 14 restore scripts sequentially
The Tools Built On the Fly
After the AppleScript restore pass, 1,254 tracks remained unfound (either from Apple-curated playlists or with artist names stripped during ASCII conversion). Claude built three custom HTML tools:
- Apple Music Quick-Add.html – Looked up each NOT FOUND track against the iTunes Search API using JSONP (to bypass CORS from a local file), showed confidence badges (exact/close/title/partial), and created
music://deep links to open tracks directly in the desktop Music app - Apple Music Album Add List.html – Pivoted from individual tracks to whole albums once adding albums proved faster. Grouped the 1,254 missing tracks into 437 unique albums, looked up each via the iTunes API, and generated 'Open in Music' deep links that jumped straight to albums in the desktop app. Sorted by track count so the most impactful albums came first
- Both tools used localStorage for checkbox persistence so the user could work across multiple sessions without losing progress
The album tool was particularly effective – instead of clicking through 1,254 individual tracks, the user added whole albums in seconds each, completing 437 albums in a fraction of the time.
📖 Read the full source: r/ClaudeAI
👀 See Also

OpenClaw Personal Assistant Use Cases: Morning Briefings and Behavior Tracking
A Reddit user demonstrates using OpenClaw as a personal assistant for morning briefings with weather, calendar, and task integration, and built a custom smoke tracker skill that logs triggers to SQLite and combines data with calendar and sleep patterns.

Developer Builds Browser RPG in 9 Days Using Claude Code and Godot
A developer created 'Civic Nightmare,' a satirical browser RPG, in 9 days using Godot and Claude Code as part of a multi-tool AI workflow. This was their first time using the Godot engine.

Using Claude with MCP for Content Creation and Publishing Workflow
A developer describes using Claude as a publishing platform via MCP integration, enabling article creation, editing, and publishing without leaving the chat interface. The workflow includes drafting, adding links, scheduling publication, and updating existing content.

Building a LinkedIn lead qualification workflow with Claude and MCP
A developer used Claude with an MCP server integration to create an automated pipeline that extracts LinkedIn profile data, scores leads 1-10, filters based on score thresholds, and sends connection requests without manual review.