chucker 0.0.1 copy "chucker: ^0.0.1" to clipboard
chucker: ^0.0.1 copied to clipboard

A Chucker - like HTTP logger for Flutter using Dio, GetIt, and local notifications.

chucker_flutter #

A lightweight Chucker-like HTTP inspector for Flutter using Dio, GetIt, and flutter_local_notifications.

This package helps developers monitor and debug network requests in real-time within their apps.


Features #

  • ✅ Logs all HTTP requests/responses using Dio interceptor
  • ✅ View full request/response details (headers, body, status, duration)
  • ✅ Show local notifications for each request
  • ✅ Uses GetIt for dependency injection
  • ✅ Built with clean architecture
  • ✅ Easy integration with plug-and-play setup

Installation #

Add to your pubspec.yaml:

dependencies:
  chucker_flutter:
    git:
      url: https://github.com/mohamedgamal95/chucker_flutter.git

Make sure your project also includes these dependencies:

dependencies:
  dio: ^5.8.0+1
  get_it: ^8.0.3
  flutter_local_notifications: ^19.2.1

🚀 Getting Started #

Initialize Chucker in main.dart #

import 'package:flutter/material.dart';
import 'package:chucker_flutter/chucker_flutter.dart';

void main() async {
  WidgetsFlutterBinding.ensureInitialized();
  await initChuckerFlutter(); // setup Dio, GetIt, notifications
  runApp(MyApp());
}

Use Dio (already configured via GetIt) #

import 'package:dio/dio.dart';
import 'package:get_it/get_it.dart';

final dio = GetIt.I<Dio>();

void fetchData() async {
  final response = await dio.get('https://jsonplaceholder.typicode.com/posts/1');
  print(response.data);
}

Show logs screen anywhere in your app #

import 'package:flutter/material.dart';
import 'package:chucker_flutter/chucker_flutter.dart';
void showLogsPage() async {
  Navigator.push(
    context,
    MaterialPageRoute(builder: (_) => const LogsPage()),
  );
}

Author #

Developed with by Mohamed Gamal


License #

This project is licensed under the MIT License.
See LICENSE for full details.


Acknowledgements #

This package uses and respects the following awesome packages:

  • dio – Powerful HTTP client publish by flutter.cn
  • flutter_local_notifications – Local notification system by Michael Bui & publish by dexterx.dev
  • get_it – Dependency injection publish by fluttercommunity.dev

Make sure to read and comply with their licenses if you plan to redistribute or modify this package.

1
likes
0
points
78
downloads

Publisher

unverified uploader

Weekly Downloads

A Chucker - like HTTP logger for Flutter using Dio, GetIt, and local notifications.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

dio, flutter, flutter_local_notifications, get_it

More

Packages that depend on chucker