impak_retro 2.0.2
impak_retro: ^2.0.2 copied to clipboard
ImpakRetro is a Dart library built on Dio, offering a type-safe, configurable, and user-friendly interface for handling HTTP requests and interacting with APIs.
Changelog #
2.0.2 - 2025-07-14 #
Added #
-
HTTP Request Handling:
- Ability to make HTTP requests (GET, POST, etc.) with or without authentication.
- Support for file uploads with progress tracking.
- Configurable timeout settings with
TimeUnit.
-
Logging:
- Integrated
PrettyDioLoggerfor detailed request and response logging. - Custom logging interceptor support.
- Integrated
-
Singleton Instance:
- Introduced a singleton instance (
ImpakRetro.instance) for consistent usage across the application.
- Introduced a singleton instance (
-
Authorization:
- Support for a global authorization token for API requests.
- Methods to set and use custom or default tokens per request.
-
Error Handling:
- Comprehensive exception handling with detailed error messages.
- Specific error types for mapping, timeout, connection, and server errors.
-
Type-Safe Responses:
typeSafeCallandtypeSafeFormDataCallmethods for parsing API responses into specific data models.
-
Raw Response Handling:
-
Includes
callandformDataCallmethods for making HTTP requests and directly retrieving raw responses without additional transformations. -
Form Data Support:
- Support for making requests with
ImpakRetroFormData.
- Support for making requests with
-
Customizability:
- Ability to pass custom headers, query parameters, and body data for requests.
- Configurable base URL for each request.
-
Extensibility:
- Flexible initialization with optional configuration for base URL, timeout, and logging.
Notes #
- Initial release with core HTTP request capabilities, error handling, and type safety.