DEV Community

Stanislav Ilin
Stanislav Ilin

Posted on • Edited on

104

Http logs in Flutter app with talker is easy as possible

A major update of the talker package has recently been released.
New release contains updated TalkerScreen with more actions and logs file sharing, fixed logs generation and etc.

😳 But another one big thing in update is talker_dio_logger package that can integrate http logs as simple as it can ever be done.

Let's take it in turns.

How it will works

talker_dio_logger

talker_dio_logger is a separate package that works on the basis of talker error handler and logger package and dio most popular and powerful dart http client.

When you connect it, all information about your work on the network gets into talker's history and the console of the running application.

Get Started

Follow these steps to run talker_dio_logger in your project and see all http logs

Add dependency

dependencies:
  talker_dio_logger: ^0.1.3
Enter fullscreen mode Exit fullscreen mode

Usage

Just add TalkerDioLogger to your dio instance and it will work

final dio = Dio();
dio.interceptors.add(
    TalkerDioLogger(
        settings: const TalkerDioLoggerSettings(
          printRequestHeaders: true,
          printResponseHeaders: true,
        ),
    ),
);
Enter fullscreen mode Exit fullscreen mode

Using with Talker

You can add your talker instance for TalkerDioLogger if your app already uses Talker.

In this case, all logs and errors will fall into your unified talker tracking system

final talker = Talker();
final dio = Dio();
dio.interceptors.add(
    TalkerDioLogger(
        talker: talker,
        settings: const TalkerDioLoggerSettings(
          printRequestHeaders: true,
          printResponseHeaders: true,
        ),
    ),
);
Enter fullscreen mode Exit fullscreen mode

😎 Go to the GitHub repository page!
🥵 Here you can see beautiful examples of usage and code snippets.

Show some ❤️ and star the repo to support the project!

Image of Timescale

🚀 pgai Vectorizer: SQLAlchemy and LiteLLM Make Vector Search Simple

We built pgai Vectorizer to simplify embedding management for AI applications—without needing a separate database or complex infrastructure. Since launch, developers have created over 3,000 vectorizers on Timescale Cloud, with many more self-hosted.

Read full post →

Top comments (9)

Collapse
 
ashishdedania profile image
Ashish Dedaniya

Very nice explaination

Collapse
 
frezyx profile image
Stanislav Ilin

Thank you a lot

Collapse
 
mnosov622 profile image
Maxim Nosov ✪ • Edited

Hi Stanislav !

I enjoy reading your posts :)
Let's connect ?

My linkedIn

Thank you !

Collapse
 
frezyx profile image
Stanislav Ilin

☺️

Collapse
 
ceresexe profile image
Ceres

Awesome content! ^.^;

Collapse
 
frezyx profile image
Stanislav Ilin

Thank you !

Collapse
 
shyambaral profile image
Shyam Baral

very nice

Collapse
 
jaredm profile image
professorjrod

Great article!! I gotta check out talker.

Collapse
 
frezyx profile image
Stanislav Ilin

Thank you! You can see examples here

Postmark Image

Speedy emails, satisfied customers

Are delayed transactional emails costing you user satisfaction? Postmark delivers your emails almost instantly, keeping your customers happy and connected.

Sign up