PackageTrack
Sign in Get early access

advanced_api_client

Production-ready Flutter/Dart API client built on Dio with authentication, automatic token refresh, retry interceptor, file uploads, global error handling, and clean architecture.

1.0.2 yourusername/advanced_api_client

What this package is like to depend on

Last release 5 months ago

06 Mar 2026

Too new to tell

only 2 release windows

Nearly every release is documented

notes for 4 of 4 stable releases

Nothing withdrawn

no release was ever pulled

6 months old

4 releases · first in 2026

4 releases in the last 12 months

see the full history below

Release timeline

4 releases · Feb 2026 to Mar 2026
Release Pre-release

Releases

latest 4
  1. 1.0.2 06 Mar 2026
    Release notes

    🚀 Improvements

    • Improved global session expiration handling without requiring BuildContext.
    • Improved retry safety for multipart uploads after token refresh.
    • Enhanced FormData rebuilding logic to prevent finalized stream reuse issues.
    • Improved logging clarity for refresh flow, retries, and upload progress.
    • Refactored internal _request() logic for better readability and maintainability.

    🛠 Bug Fixes

    • Fixed rare race condition when multiple requests attempted token refresh simultaneously.
    • Fixed edge case where CancelToken was not passed correctly to retried upload requests.
    • Fixed retry request headers not preserving original request headers.

    Added

    • Better production-safe retry mechanism for requests with FormData.
    • Improved upload task cancellation support using CancelToken.
    • Support for dynamic body rebuild for retried multipart requests.
    • Additional debug logs for retry attempts and token refresh flow.

    Open source →
  2. 1.0.1 05 Mar 2026
    Release notes

    🛠 Bug Fixes

    • Fixed _FormData already finalized error when retrying uploads after token refresh.
    • Resolved bodyBuilder missing issue in RefreshConfig for dynamic refresh API bodies.
    • Corrected named parameter mismatches in _request() and Dio request options.
    • Prevented token refresh infinite loops on concurrent requests.

    Added

    • Support for bodyBuilder in RefreshConfig for dynamic refresh request bodies.
    • Ability to fetch user_id or other dynamic data from SharedPreferences during token refresh.
    • Optional CancelToken support per upload task for better upload management.
    • Improved logging for upload progress and retry actions.
    • Dynamic handling of multiple file uploads with different field names.
    • Added SharedPrefsTokenStorage example for storing token and extra data separately.

    Improved

    • Safer retry mechanism for POST/PUT requests using FormData after token refresh.
    • Cleaner interceptor logs and separation between auth and upload flows.
    • More robust _request() core function with error parsing improvements.
    • Improved production safety and scalability of AdvancedApiClient.

    Open source →
  3. 1.0.0 27 Feb 2026
    Release notes

    🚀 Production Release

    Added

    • Production-ready architecture
    • Centralized AdvancedApiClient
    • Robust _request() core handler
    • Global error handling via ApiConfig.onError
    • Automatic token refresh mechanism
    • Retry interceptor with timeout & connection retry support
    • Session termination with request cancellation
    • Single file upload support
    • Multiple file upload support (same field)
    • Multiple file upload support (dynamic field names)
    • Improved error parsing with ApiException
    • Debug logging (enabled in debug mode only)
    • Custom Dio interceptor support
    • Safe singleton initialization
    • Lazy initialization option

    Improved

    • Cleaner internal request handling
    • Stronger error mapping for DioException
    • Better file existence validation
    • More stable cancel token management
    • Improved production safety & scalability

    Open source →
  4. 0.0.1 19 Feb 2026
    Release notes

    Added

    • Initial release
    • GET, POST, PUT, PATCH, DELETE requests
    • Token-based authentication
    • Token refresh support
    • File upload support
    • Pagination support
    • Custom interceptors
    • Example Flutter app demonstrating usage
    Open source →

Every package, every release, already written down.

The archive is open and free. Watching your own project is what we are building next.

Browse the archive