From e6ca754b9857da4a228611d4bffa308b9e15f11e Mon Sep 17 00:00:00 2001 From: Sahil Kumar Date: Fri, 5 May 2023 17:48:12 +0530 Subject: [PATCH] chore: update changelog. Signed-off-by: xsahil03x --- packages/stream_chat/CHANGELOG.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/packages/stream_chat/CHANGELOG.md b/packages/stream_chat/CHANGELOG.md index f28d7e65..df72ed55 100644 --- a/packages/stream_chat/CHANGELOG.md +++ b/packages/stream_chat/CHANGELOG.md @@ -10,6 +10,29 @@ - Expose `ChannelMute` class. [#1473](https://github.com/GetStream/stream-chat-flutter/issues/1473) - Added synchronization to the `StreamChatClient.sync` api. [#1392](https://github.com/GetStream/stream-chat-flutter/issues/1392) +- Added support for `StreamChatClient.chatApiInterceptors` to add custom interceptors to the API client. + [#1265](https://github.com/GetStream/stream-chat-flutter/issues/1265). + + ```dart + final client = StreamChatClient( + chatApiInterceptors: [ + InterceptorsWrapper( + onRequest: (options, handler) { + // Do something before request is sent. + return handler.next(options); + }, + onResponse: (response, handler) { + // Do something with response data + return handler.next(response); + }, + onError: (DioError e, handler) { + // Do something with response error + return handler.next(e); + }, + ), + ], + ); + ``` ## 6.0.0