{"id":32301146,"url":"https://github.com/jackleemeta/al_downloader_flutter","last_synced_at":"2026-02-21T16:02:49.300Z","repository":{"id":46146223,"uuid":"371891799","full_name":"jackleemeta/al_downloader_flutter","owner":"jackleemeta","description":"A URL-based flutter downloader that supports to download any type of file and automatically manages a lot of things.","archived":false,"fork":false,"pushed_at":"2024-07-26T07:28:29.000Z","size":703,"stargazers_count":37,"open_issues_count":7,"forks_count":14,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-23T05:42:37.195Z","etag":null,"topics":["android","dart","download","downloader","flutter","ios","pub"],"latest_commit_sha":null,"homepage":"https://github.com/jackleemeta/al_downloader_flutter","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jackleemeta.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-05-29T05:50:54.000Z","updated_at":"2025-05-07T12:44:36.000Z","dependencies_parsed_at":"2023-02-17T19:01:15.393Z","dependency_job_id":"7ce13c7a-ab15-4fb5-aecd-ed88c0a0b077","html_url":"https://github.com/jackleemeta/al_downloader_flutter","commit_stats":{"total_commits":260,"total_committers":2,"mean_commits":130.0,"dds":"0.023076923076923106","last_synced_commit":"eadfbe309b4d19962b581b3d1f8b7d0b832c69e8"},"previous_names":[],"tags_count":85,"template":false,"template_full_name":null,"purl":"pkg:github/jackleemeta/al_downloader_flutter","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackleemeta%2Fal_downloader_flutter","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackleemeta%2Fal_downloader_flutter/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackleemeta%2Fal_downloader_flutter/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackleemeta%2Fal_downloader_flutter/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jackleemeta","download_url":"https://codeload.github.com/jackleemeta/al_downloader_flutter/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jackleemeta%2Fal_downloader_flutter/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29685044,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-21T15:51:39.154Z","status":"ssl_error","status_checked_at":"2026-02-21T15:49:03.425Z","response_time":107,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","dart","download","downloader","flutter","ios","pub"],"created_at":"2025-10-23T05:36:56.153Z","updated_at":"2026-02-21T16:02:49.295Z","avatar_url":"https://github.com/jackleemeta.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# al_downloader\n\n[![pub package](https://img.shields.io/pub/v/al_downloader.svg)](https://pub.dartlang.org/packages/al_downloader)\n\nA URL-based flutter downloader that supports to download any type of file and automatically manages a lot of things.\n\nIf you need Chinese Document, click [here](README_CN.md).\n\n## Features\n\n* manage download tasks by url\n* simple download status\n* I/O infrequently\n* provide convenient download handle\n* support batch download\n* manage automatically files without requiring to be specified a download path\n* based on [flutter_downloader](https://pub.dev/packages/flutter_downloader)\n\n## Integration\n\n\u003e Native Config: same as [flutter_downloader](https://pub.dev/packages/flutter_downloader) native config\n\nadd the following line to your pubspec.yaml\n```\ndependencies:\n  al_downloader: ^1.8.4\n```\n\nrun the following line with your command line\n```\nflutter packages get\n```\n\nimport the following line, then you can use al_downloader\n```\nimport 'package:al_downloader/al_downloader.dart';\n```\n\n## Usage\n\n### ALDownloader\n\n#### Initialize\n```\nALDownloader.initialize();\n```\n\n#### Configure print\n```\nALDownloader.configurePrint(true, frequentEnabled: false);\n```\n\n#### Download\n```\nALDownloader.download(url,\n    directoryPath: directoryPath,\n    fileName: fileName,\n    handlerInterface:\n        ALDownloaderHandlerInterface(progressHandler: (progress) {\n      debugPrint(\n          'ALDownloader | download progress = $progress, url = $url\\n');\n    }, succeededHandler: () {\n      debugPrint('ALDownloader | download succeeded, url = $url\\n');\n    }, failedHandler: () {\n      debugPrint('ALDownloader | download failed, url = $url\\n');\n    }, pausedHandler: () {\n      debugPrint('ALDownloader | download paused, url = $url\\n');\n    }));\n```\n\n#### Add a handler interface\n```\nALDownloader.addHandlerInterface(\n    ALDownloaderHandlerInterface(progressHandler: (progress) {\n      debugPrint(\n          'ALDownloader | download progress = $progress, url = $url\\n');\n    }, succeededHandler: () {\n      debugPrint('ALDownloader | download succeeded, url = $url\\n');\n    }, failedHandler: () {\n      debugPrint('ALDownloader | download failed, url = $url\\n');\n    }, pausedHandler: () {\n      debugPrint('ALDownloader | download paused, url = $url\\n');\n    }),\n    url);\n```\n\n#### Add a forever handler interface\n```\nALDownloader.addForeverHandlerInterface(\n    ALDownloaderHandlerInterface(progressHandler: (progress) {\n      debugPrint(\n          'ALDownloader | download progress = $progress, url = $url\\n');\n    }, succeededHandler: () {\n      debugPrint('ALDownloader | download succeeded, url = $url\\n');\n    }, failedHandler: () {\n      debugPrint('ALDownloader | download failed, url = $url\\n');\n    }, pausedHandler: () {\n      debugPrint('ALDownloader | download paused, url = $url\\n');\n    }),\n    url);\n```\n\n#### Remove handler interface\n```\nALDownloader.removeHandlerInterfaceForUrl(url);\n```\n\n#### Pause download\n```\n/// Stop download, but the incomplete data will not be deleted.\nALDownloader.pause(url);\n```\n\n#### Cancel download\n```\n/// Stop download, and the incomplete data will be deleted.\nALDownloader.cancel(url);\n```\n\n#### Remove download\n```\n/// Remove download, and all the data will be deleted.\nALDownloader.remove(url);\n```\n\n#### Get download status\n```\nfinal status = await ALDownloader.getStatusForUrl(url);\n```\n\n#### Get download progress\n```\nfinal progress = await ALDownloader.getProgressForUrl(url);\n```\n\n#### Get task\n```\nfinal task = await ALDownloader.getTaskForUrl(url);\n```\n\n#### Get all tasks\n```\nfinal tasks = await ALDownloader.tasks;\n```\n\n### ALDownloaderBatcher\n\n#### Batch download\n```\nALDownloaderBatcher.download(urls,\n    handlerInterface:\n        ALDownloaderHandlerInterface(progressHandler: (progress) {\n      debugPrint('ALDownloader | batch | download progress = $progress\\n');\n    }, succeededHandler: () {\n      debugPrint('ALDownloader | batch | download succeeded\\n');\n    }, failedHandler: () {\n      debugPrint('ALDownloader | batch | download failed\\n');\n    }, pausedHandler: () {\n      debugPrint('ALDownloader | batch | download paused\\n');\n    }));\n```\n\n#### Add a handler interface for batch\n```\nALDownloaderBatcher.addHandlerInterface(\n    ALDownloaderHandlerInterface(progressHandler: (progress) {\n      debugPrint('ALDownloader | batch | download progress = $progress\\n');\n    }, succeededHandler: () {\n      debugPrint('ALDownloader | batch | download succeeded\\n');\n    }, failedHandler: () {\n      debugPrint('ALDownloader | batch | download failed\\n');\n    }, pausedHandler: () {\n      debugPrint('ALDownloader | batch | download paused\\n');\n    }),\n    urls);\n```\n\n#### Get download status for a set of urls\n```\nfinal status = await ALDownloaderBatcher.getStatusForUrls(urls);\n```\n\n#### Get tasks\n```\nfinal tasks = await ALDownloaderBatcher.getTasksForUrls(urls);\n```\n\n### ALDownloaderFileManager - A manager that manages file by url\n\n```\nfinal physicalFilePath =\n    await ALDownloaderFileManager.getPhysicalFilePathForUrl(url);\ndebugPrint(\n    'ALDownloader | get physical file path for [url], url = $url, path = $physicalFilePath\\n');\n```\n\n## *Note*:\n\n*1. If the persistent file was removed by exceptional means, such as the cache folder being deleted by some business code, call [remove] and then call [download] to re-download for fixing the problem.*\n\n## Key File Of Example\n\n### iOS\n\n- [main.dart](https://github.com/jackleemeta/al_downloader_flutter/blob/master/example/lib/main.dart)\n- [AppDelegate.swift](https://github.com/jackleemeta/al_downloader_flutter/blob/master/example/ios/Runner/AppDelegate.swift)\n- [Info.plist](https://github.com/jackleemeta/al_downloader_flutter/blob/master/example/ios/Runner/Info.plist)\n\n### Android\n\n- [main.dart](https://github.com/jackleemeta/al_downloader_flutter/blob/master/example/lib/main.dart)\n- [AndroidManifest.xml](https://github.com/jackleemeta/al_downloader_flutter/blob/master/example/android/app/src/main/AndroidManifest.xml)\n\n## Contributing\n\nWelcome contribution!\n\nWelcome to open issue or PR for any problem, suggestion and idea!\n\n\u003e Maintainer: jackleemeta (jackleemeta@outlook.com)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjackleemeta%2Fal_downloader_flutter","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjackleemeta%2Fal_downloader_flutter","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjackleemeta%2Fal_downloader_flutter/lists"}