api_manager_plus library
The main entry point for the api_manager_plus package.
This package provides a structured and reusable approach to API integration in Flutter and Dart applications, including:
- Safe API calling with connectivity checks
- Request and response logging
- Unified header management
- Error handling
- Support for standard and multipart requests
Usage:
import 'package:api_manager_plus/api_manager_plus.dart';
final response = await ApiManagerPlusBase.get('https://api.example.com/data');
See the README for detailed usage instructions.
Classes
- ApiHeaders
- A utility class to manage and merge HTTP headers for API requests.
- ApiLogger
- A utility class for logging API requests and responses to the console.
- ApiRequestHelper
- A helper class for executing HTTP requests with standardized logging, headers merging, timeout control, and error handling.
- ApiResponseHandler
- A utility class for handling HTTP responses in a consistent manner.
- SafeApiCall
- A utility class that wraps API calls with internet connectivity checks and exception handling.