How acronymuz/cpotify works
Cpotify is an Android Spotify client combining a Vue interface, Spotify authentication/catalog access, and Web Playback SDK streaming with native Android background playback controls. The main user flow is login and callback, authenticated navigation to listening and discovery views, then playback through the SDK with state reflected in the player UI and native media session. Android also hosts Spotify’s web player and handles ad-resume/accessibility behavior. The source index and README support the major feature branches; unsampled implementation details and some native/plugin wiring are not asserted beyond documented or indexed relationships.
Main entry points: index.ts Route Guard · auth.ts Auth Store · spotifyApi.ts Spotify API · usePlaybackSDK.ts Web Playback SDK
Components 27
Web Experience
- App Shell
src/App.vue - Route Guard
src/router/index.ts - Login View
src/views/LoginView.vue - OAuth Callback
src/views/CallbackView.vue - Home View
src/views/HomeView.vue - Search View
src/views/SearchView.vue - Library View
src/views/LibraryView.vue - Media Details
src/views - Settings View
src/views/SettingsView.vue - Player Bar
src/components/PlayerBar.vue
Spotify Access
- Auth Store
src/stores/auth.ts - Spotify API
src/services/spotifyApi.ts - Spotify Models
src/types/spotify.ts
Playback
- Player Store
src/stores/player.ts - Web Playback SDK
src/composables/usePlaybackSDK.ts - Native Controls Hook
src/composables/useNativeMediaControls.ts
Android Runtime
- Main Activity
android/app/src/main/java/com/cpotify/app/MainActivity.java - Android Web Host
android/app/src/main/java/com/cpotify/app/myspoti/WebPlayerHost.java - Ad Block Rules
android/app/src/main/java/com/cpotify/app/myspoti/AdBlockRules.java - Playback Service
android/app/src/main/java/com/cpotify/app/MediaPlaybackService.java - Resume Accessibility
android/app/src/main/java/com/cpotify/app/ResumeAccessibilityService.java
Native Bridge
- Bridge Plugin
plugins/myspoti-bridge/src/android/main/java/com/cpotify/app/myspoti/MyspotiBridgePlugin.java - Plugin Web Host
plugins/myspoti-bridge/src/android/main/java/com/cpotify/app/myspoti/WebPlayerHost.java - Bridge API
plugins/myspoti-bridge/src/definitions.ts
Other components
- Listener
- Spotify Platform
- Preferences
Connections 41
- Listener → App Shell: uses
README.md - App Shell → Route Guard: renders routes
src/App.vue - Route Guard → Login View: routes to
src/router/index.ts - Route Guard → OAuth Callback: routes to
src/router/index.ts - Route Guard → Home View: routes to
src/router/index.ts - Route Guard → Search View: routes to
src/router/index.ts - Route Guard → Library View: routes to
src/router/index.ts - Route Guard → Media Details: routes to
src/router/index.ts - Route Guard → Settings View: routes to
src/router/index.ts - Login View → Auth Store: starts login
src/views/LoginView.vue - OAuth Callback → Auth Store: completes login
src/views/CallbackView.vue - Auth Store → Spotify Platform: authenticates
README.md - Auth Store → Preferences: persists tokens
src/stores/auth.ts - Auth Store → Spotify Models: uses models
src/stores/auth.ts - Home View → Spotify API: fetches content
src/views/HomeView.vue - Search View → Spotify API: searches catalog
src/views/SearchView.vue - Library View → Spotify API: loads library
src/views/LibraryView.vue - Media Details → Spotify API: loads details
src/views/AlbumView.vue - Spotify API → Auth Store: gets token
src/services/spotifyApi.ts - Spotify API → Spotify Platform: calls API
README.md - Spotify API → Spotify Models: uses models
src/services/spotifyApi.ts - App Shell → Web Playback SDK: initializes playback
src/App.vue - App Shell → Player Store: reads playback state
src/App.vue - App Shell → Player Bar: renders controls
src/App.vue - Web Playback SDK → Auth Store: gets credentials
src/composables/usePlaybackSDK.ts - Web Playback SDK → Player Store: syncs playback
src/composables/usePlaybackSDK.ts - Web Playback SDK → Spotify Platform: streams audio
README.md - Player Bar → Player Store: reads state
src/components/PlayerBar.vue - Player Bar → Web Playback SDK: controls playback
src/components/PlayerBar.vue - Native Controls Hook → Player Store: reads state
src/composables/useNativeMediaControls.ts - Native Controls Hook → Web Playback SDK: invokes controls
src/composables/useNativeMediaControls.ts - Player Store → Preferences: stores settings
src/stores/player.ts - Main Activity → Android Web Host: creates host
android/app/src/main/java/com/cpotify/app/MainActivity.java - Main Activity → Playback Service: updates media
android/app/src/main/java/com/cpotify/app/MainActivity.java - Main Activity → Resume Accessibility: requests resume
android/app/src/main/java/com/cpotify/app/MainActivity.java - Android Web Host → Ad Block Rules: uses rules
android/app/src/main/java/com/cpotify/app/myspoti/WebPlayerHost.java - Playback Service → Spotify Platform: downloads artwork
README.md - Playback Service → Listener: shows media controls
README.md - Main Activity → Bridge Plugin: integrates bridge
- Bridge Plugin → Plugin Web Host: uses host
plugins/myspoti-bridge/src/android/main/java/com/cpotify/app/myspoti/WebPlayerHost.java - Bridge Plugin → Bridge API: implements API