onRequest method
Future<void>
onRequest(
- Uri url,
- HttpMethod method,
- Map<
String, String> headers, - dynamic body,
override
Called before a request is sent
Implementation
@override
Future<void> onRequest(
Uri url,
HttpMethod method,
Map<String, String> headers,
dynamic body,
) async {
_logger.i('🚀 ${method.name.toUpperCase()} Request to: $url');
if (headers.isNotEmpty) {
_logger.d('📋 Headers: $headers');
}
if (body != null) {
_logger.d('📦 Body: $body');
}
}