Apple Music API (MusicKit)
Provides access to Apple Music's catalog of over 100 million songs, artist metadata, curated playlists, and user library management for Apple Music subscribers via JWT-authenticated REST requests.
Score Breakdown
⚙ Agent Friendliness
🔒 Security
JWT-based developer tokens with short-lived signing keys provide strong authentication. The two-token model (developer + user) cleanly separates service-level and user-level authorization. Private key management requires careful handling — the MusicKit key cannot be rotated automatically and compromise requires manual revocation in Apple Developer portal.
⚡ Reliability
Best When
Building iOS/macOS native apps or Apple-ecosystem-focused tools where users are Apple Music subscribers and you need deep catalog integration with Apple's curation data.
Avoid When
Your user base is cross-platform or primarily non-Apple users, or you need raw audio access — Spotify or SoundCloud are better fits for platform-agnostic music tools.
Use Cases
- • Search Apple Music's catalog for tracks, albums, and artists to enrich a music knowledge base or power a music recommendation agent
- • Fetch storefront-specific catalog data to surface region-appropriate music recommendations for a localized content agent
- • Manage a subscriber's personal library — add albums, create playlists, and sync favorites — as part of a music organization automation
- • Retrieve Apple-curated playlists (New Music Daily, Top Charts) to build trend-tracking and music discovery reports
- • Cross-reference track ISRCs and Apple Music IDs to identify the same song across multiple streaming platforms in a metadata sync pipeline
Not For
- • Non-Apple-ecosystem users — the API requires an Apple Music subscription for user library operations and Apple Developer enrollment for any access
- • Audio streaming or download — the API provides metadata and playback initiation but not raw audio streams accessible outside MusicKit clients
- • Bulk catalog mirroring or competitive music service construction — Apple's ToS prohibits aggregating catalog data at scale
Interface
Authentication
Two-layer authentication: (1) Developer Token — a JWT signed with an Apple MusicKit private key from your Apple Developer account, used for all catalog requests; (2) Music-User-Token — a user-specific token obtained via MusicKit JS or native MusicKit SDK, required for accessing or modifying a user's personal library. Catalog access (no user data) requires only the Developer Token. Developer keys are obtained from Apple Developer portal and require an active paid developer membership ($99/year).
Pricing
The $99/year Apple Developer Program fee is required to generate MusicKit keys. There are no per-call API charges. End users must have active Apple Music subscriptions ($10.99/month) for any personal library features to function.
Agent Metadata
Known Gotchas
- ⚠ Developer Tokens (JWTs) expire in up to 6 months maximum — agents running long-term must track token expiry and rotate keys, which requires the private key to be securely stored server-side
- ⚠ Music-User-Tokens have shorter expiry windows and can only be obtained through interactive MusicKit SDK flows — there is no server-side refresh mechanism, making headless agent flows difficult for user library operations
- ⚠ Catalog content availability is storefront-specific — a track available in the US storefront may not exist in other storefronts, causing 404s if the storefront is not explicitly managed
- ⚠ The API does not support audio feature data (tempo, energy, acousticness) — unlike Spotify, Apple Music provides no acoustic analysis metadata
- ⚠ Apple Developer key generation requires manual steps in the Apple Developer portal — it cannot be automated, creating a manual prerequisite for any agent deployment pipeline
Alternatives
Full Evaluation Report
Detailed scoring breakdown, competitive positioning, security analysis, and improvement recommendations for Apple Music API (MusicKit).
Scores are editorial opinions as of 2026-03-06.