flutter_downloaded_audio_play_in_notification 1.0.0
flutter_downloaded_audio_play_in_notification: ^1.0.0 copied to clipboard
A Flutter plugin for playing downloaded audio files in notifications with background playback support and terminated state handling.
Changelog #
1.0.0 #
Initial Release #
Features:
- ✅ Play custom audio files from URLs in notifications
- ✅ Background audio playback support
- ✅ Audio playback when app is terminated
- ✅ Stop audio from notification tap
- ✅ Android native implementation with ExoPlayer
- ✅ Firebase Cloud Messaging integration
- ✅ Robust audio stopping from terminated state
- ✅ Comprehensive error handling and retry logic
Technical Details:
- Native Android implementation using Kotlin
- ExoPlayer for audio playback
- Foreground service for background playback
- Broadcast receivers for cross-component communication
- Singleton pattern for audio management
- Aggressive stopping mechanisms for terminated state
- Comprehensive logging for debugging
Platform Support:
- Android: Full support (API 21+)
- iOS: Not supported (Android only)
Dependencies:
- Flutter SDK: ^3.6.1
- Firebase Messaging: ^14.7.10
- Flutter Local Notifications: ^17.2.4
- ExoPlayer: 2.19.1 (Android native)
Setup Requirements:
- Firebase configuration with google-services.json
- Android Gradle Plugin 8.1.1+
- Compile SDK 34+
- Min SDK 21+
Example App #
- Complete working example with Firebase integration
- Test interface with stop button
- FCM token display
- Notification testing instructions
- Terminated state testing capabilities
Documentation #
- Comprehensive README with usage examples
- API reference documentation
- Setup instructions
- Troubleshooting guide
- Testing procedures