Skip to content

Commit

Permalink
[PBE-3749] ThreadList improvements (#5455)
Browse files Browse the repository at this point in the history
* [PBE-3749] Update ThreadsApi to match the definition.

* [PBE-3749] Register "notification.thread_message_new" EventType.

* [PBE-3749] Implement initial state-management for 'Query Threads'.

* [PBE-3749] Implement ThreadList component.

* [PBE-3749] Implement 'Threads' tab in compose sample app.

* [PBE-3749] FIx pagination logic and add a threshold.

* [PBE-3749] Add queryThreads preconditions checks.

* [PBE-3749] Revert ktlint commit.

* [PBE-3749] Remove redundant state update in ThreadListController.

* [PBE-3749] Add handling for different ChatEvents.

* [PBE-3749] Remove redundant coroutine creation and docs.

* [PBE-3749] Fix detekt and spotless.

* Revert "[PBE-3749] Implement 'Threads' tab in compose sample app."

This reverts commit fdb1ac1

* Revert "Revert "[PBE-3749] Implement 'Threads' tab in compose sample app.""

This reverts commit fbc9b3d.

* Revert "[PBE-3749] Implement 'Threads' tab in compose sample app."

This reverts commit fdb1ac1

* [PBE-3749] Hide threads-related public apis.

* [PBE-3749] Fix PR remarks related DTOs.

* [PBE-3749] Fix wrong composable preview.

* [PBE-3749] Use inheritScope to create ThreadListController coroutine scope.

* [PBE-3749] Implement ChatClient::markThreadRead operation.

* [PBE-3749] Update CHANGELOG for markThreadRead.

* [PBE-3749] Fix failing test.

* [PBE-3749] Separate `markThreadRead` from `markRead`.

* [PBE-3749] Implement unreadThreads logic as part of the GlobalState.

* [PBE-3749] Add GlobalState::unreadThreadsCount to CHANGELOG.md.

* [PBE-3749] Add marking thread as read handling.

* [PBE-3749] Fix incrementing unread count for new thread messages.

* [PBE-3749] Add ThreadItem customization options.

* [PBE-3749] Make Threads API public.

* [PBE-3749] Add Threads tab to compose sample app.

* [PBE-3749] Add threads state tests.

* [PBE-3749] Suppress LongMethod warning.

* [PBE-3749] Add ChatClient::markThreadUnread.

* [PBE-3749] Add ChatClient::markThreadUnread to CHANGELOG.md.

* [PBE-3749] Add stateless ThreadList.

* [PBE-3749] Add ThreadList to CHANGELOG and add docusaurus documentation
.

* [PBE-3749] Ensure threads state is updated on different client operations.

* [PBE-3749] Fix failing tests.

* [PBE-3749] Add 'Mark thread as unread' handling.

* [PBE-3749] apply spotless.

* [PBE-3479] Post merge clean-up.

* [PBE-3749] Delete docusaurus docs.

* [PBE-3749] Update CHANGELOG.md.

* WIP

* Refactor ThreadParticipants

---------

Co-authored-by: PetarVelikov <[email protected]>
Co-authored-by: Aleksandar Apostolov <[email protected]>
Co-authored-by: Jc Miñarro <[email protected]>
  • Loading branch information
4 people authored Nov 20, 2024
1 parent 4966628 commit 42a3aed
Show file tree
Hide file tree
Showing 54 changed files with 3,116 additions and 323 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,7 @@
### ✅ Added
- Add `MessageListViewModel.flagUser()` and `MessageListViewModel.unflagUser()` methods for flagging/un-flagging users. [#5478](https://github.com/GetStream/stream-chat-android/pull/5478)
- Add edge-to-edge support for apps targeting Android 15. [#5469](https://github.com/GetStream/stream-chat-android/pull/5469)
- Add `ThreadList` component for showing the list of threads for the user. [#5455](https://github.com/GetStream/stream-chat-android/pull/5455)

### ⚠️ Changed
- 🚨 Breaking change: Replace usage of `RippleTheme` with `StreamRippleConfiguration` for customizing ripples via `ChatTheme`. [#5475](https://github.com/GetStream/stream-chat-android/pull/5475)
Expand Down
Empty file added gradle/libs.versions.toml
Empty file.
36 changes: 25 additions & 11 deletions stream-chat-android-client/api/stream-chat-android-client.api
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,7 @@ public final class io/getstream/chat/android/client/ChatClient {
public final fun queryMembers (Ljava/lang/String;Ljava/lang/String;IILio/getstream/chat/android/models/FilterObject;Lio/getstream/chat/android/models/querysort/QuerySorter;Ljava/util/List;)Lio/getstream/result/call/Call;
public static synthetic fun queryMembers$default (Lio/getstream/chat/android/client/ChatClient;Ljava/lang/String;Ljava/lang/String;IILio/getstream/chat/android/models/FilterObject;Lio/getstream/chat/android/models/querysort/QuerySorter;Ljava/util/List;ILjava/lang/Object;)Lio/getstream/result/call/Call;
public final fun queryThreads (Lio/getstream/chat/android/client/api/models/QueryThreadsRequest;)Lio/getstream/result/call/Call;
public final fun queryThreadsResult (Lio/getstream/chat/android/client/api/models/QueryThreadsRequest;)Lio/getstream/result/call/Call;
public final fun queryUsers (Lio/getstream/chat/android/client/api/models/QueryUsersRequest;)Lio/getstream/result/call/Call;
public final fun reconnectSocket ()Lio/getstream/result/call/Call;
public final fun rejectInvite (Ljava/lang/String;Ljava/lang/String;)Lio/getstream/result/call/Call;
Expand Down Expand Up @@ -1464,22 +1465,25 @@ public final class io/getstream/chat/android/client/events/MessageDeletedEvent :
}

public final class io/getstream/chat/android/client/events/MessageReadEvent : io/getstream/chat/android/client/events/CidEvent, io/getstream/chat/android/client/events/UserEvent {
public fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)V
public fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Lio/getstream/chat/android/models/ThreadInfo;)V
public synthetic fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Lio/getstream/chat/android/models/ThreadInfo;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
public final fun component1 ()Ljava/lang/String;
public final fun component2 ()Ljava/util/Date;
public final fun component3 ()Ljava/lang/String;
public final fun component4 ()Lio/getstream/chat/android/models/User;
public final fun component5 ()Ljava/lang/String;
public final fun component6 ()Ljava/lang/String;
public final fun component7 ()Ljava/lang/String;
public final fun copy (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Lio/getstream/chat/android/client/events/MessageReadEvent;
public static synthetic fun copy$default (Lio/getstream/chat/android/client/events/MessageReadEvent;Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;ILjava/lang/Object;)Lio/getstream/chat/android/client/events/MessageReadEvent;
public final fun component8 ()Lio/getstream/chat/android/models/ThreadInfo;
public final fun copy (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Lio/getstream/chat/android/models/ThreadInfo;)Lio/getstream/chat/android/client/events/MessageReadEvent;
public static synthetic fun copy$default (Lio/getstream/chat/android/client/events/MessageReadEvent;Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;Lio/getstream/chat/android/models/ThreadInfo;ILjava/lang/Object;)Lio/getstream/chat/android/client/events/MessageReadEvent;
public fun equals (Ljava/lang/Object;)Z
public fun getChannelId ()Ljava/lang/String;
public fun getChannelType ()Ljava/lang/String;
public fun getCid ()Ljava/lang/String;
public fun getCreatedAt ()Ljava/util/Date;
public fun getRawCreatedAt ()Ljava/lang/String;
public final fun getThread ()Lio/getstream/chat/android/models/ThreadInfo;
public fun getType ()Ljava/lang/String;
public fun getUser ()Lio/getstream/chat/android/models/User;
public fun hashCode ()I
Expand Down Expand Up @@ -1726,9 +1730,13 @@ public final class io/getstream/chat/android/client/events/NotificationInvitedEv
}

public final class io/getstream/chat/android/client/events/NotificationMarkReadEvent : io/getstream/chat/android/client/events/CidEvent, io/getstream/chat/android/client/events/HasUnreadCounts, io/getstream/chat/android/client/events/UserEvent {
public fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;II)V
public synthetic fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILkotlin/jvm/internal/DefaultConstructorMarker;)V
public fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IILjava/lang/String;Lio/getstream/chat/android/models/ThreadInfo;Ljava/lang/Integer;Ljava/lang/Integer;)V
public synthetic fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IILjava/lang/String;Lio/getstream/chat/android/models/ThreadInfo;Ljava/lang/Integer;Ljava/lang/Integer;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
public final fun component1 ()Ljava/lang/String;
public final fun component10 ()Ljava/lang/String;
public final fun component11 ()Lio/getstream/chat/android/models/ThreadInfo;
public final fun component12 ()Ljava/lang/Integer;
public final fun component13 ()Ljava/lang/Integer;
public final fun component2 ()Ljava/util/Date;
public final fun component3 ()Ljava/lang/String;
public final fun component4 ()Lio/getstream/chat/android/models/User;
Expand All @@ -1737,30 +1745,35 @@ public final class io/getstream/chat/android/client/events/NotificationMarkReadE
public final fun component7 ()Ljava/lang/String;
public final fun component8 ()I
public final fun component9 ()I
public final fun copy (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;II)Lio/getstream/chat/android/client/events/NotificationMarkReadEvent;
public static synthetic fun copy$default (Lio/getstream/chat/android/client/events/NotificationMarkReadEvent;Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/Object;)Lio/getstream/chat/android/client/events/NotificationMarkReadEvent;
public final fun copy (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IILjava/lang/String;Lio/getstream/chat/android/models/ThreadInfo;Ljava/lang/Integer;Ljava/lang/Integer;)Lio/getstream/chat/android/client/events/NotificationMarkReadEvent;
public static synthetic fun copy$default (Lio/getstream/chat/android/client/events/NotificationMarkReadEvent;Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IILjava/lang/String;Lio/getstream/chat/android/models/ThreadInfo;Ljava/lang/Integer;Ljava/lang/Integer;ILjava/lang/Object;)Lio/getstream/chat/android/client/events/NotificationMarkReadEvent;
public fun equals (Ljava/lang/Object;)Z
public fun getChannelId ()Ljava/lang/String;
public fun getChannelType ()Ljava/lang/String;
public fun getCid ()Ljava/lang/String;
public fun getCreatedAt ()Ljava/util/Date;
public fun getRawCreatedAt ()Ljava/lang/String;
public final fun getThread ()Lio/getstream/chat/android/models/ThreadInfo;
public final fun getThreadId ()Ljava/lang/String;
public fun getTotalUnreadCount ()I
public fun getType ()Ljava/lang/String;
public fun getUnreadChannels ()I
public final fun getUnreadThreadMessages ()Ljava/lang/Integer;
public final fun getUnreadThreads ()Ljava/lang/Integer;
public fun getUser ()Lio/getstream/chat/android/models/User;
public fun hashCode ()I
public fun toString ()Ljava/lang/String;
}

public final class io/getstream/chat/android/client/events/NotificationMarkUnreadEvent : io/getstream/chat/android/client/events/CidEvent, io/getstream/chat/android/client/events/HasUnreadCounts, io/getstream/chat/android/client/events/UserEvent {
public fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/String;Ljava/util/Date;Ljava/lang/String;)V
public synthetic fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/String;Ljava/util/Date;Ljava/lang/String;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
public fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/String;Ljava/util/Date;Ljava/lang/String;I)V
public synthetic fun <init> (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/String;Ljava/util/Date;Ljava/lang/String;IILkotlin/jvm/internal/DefaultConstructorMarker;)V
public final fun component1 ()Ljava/lang/String;
public final fun component10 ()I
public final fun component11 ()Ljava/lang/String;
public final fun component12 ()Ljava/util/Date;
public final fun component13 ()Ljava/lang/String;
public final fun component14 ()I
public final fun component2 ()Ljava/util/Date;
public final fun component3 ()Ljava/lang/String;
public final fun component4 ()Lio/getstream/chat/android/models/User;
Expand All @@ -1769,8 +1782,8 @@ public final class io/getstream/chat/android/client/events/NotificationMarkUnrea
public final fun component7 ()Ljava/lang/String;
public final fun component8 ()I
public final fun component9 ()I
public final fun copy (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/String;Ljava/util/Date;Ljava/lang/String;)Lio/getstream/chat/android/client/events/NotificationMarkUnreadEvent;
public static synthetic fun copy$default (Lio/getstream/chat/android/client/events/NotificationMarkUnreadEvent;Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/String;Ljava/util/Date;Ljava/lang/String;ILjava/lang/Object;)Lio/getstream/chat/android/client/events/NotificationMarkUnreadEvent;
public final fun copy (Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/String;Ljava/util/Date;Ljava/lang/String;I)Lio/getstream/chat/android/client/events/NotificationMarkUnreadEvent;
public static synthetic fun copy$default (Lio/getstream/chat/android/client/events/NotificationMarkUnreadEvent;Ljava/lang/String;Ljava/util/Date;Ljava/lang/String;Lio/getstream/chat/android/models/User;Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;IIILjava/lang/String;Ljava/util/Date;Ljava/lang/String;IILjava/lang/Object;)Lio/getstream/chat/android/client/events/NotificationMarkUnreadEvent;
public fun equals (Ljava/lang/Object;)Z
public fun getChannelId ()Ljava/lang/String;
public fun getChannelType ()Ljava/lang/String;
Expand All @@ -1784,6 +1797,7 @@ public final class io/getstream/chat/android/client/events/NotificationMarkUnrea
public fun getType ()Ljava/lang/String;
public fun getUnreadChannels ()I
public final fun getUnreadMessages ()I
public final fun getUnreadThreads ()I
public fun getUser ()Lio/getstream/chat/android/models/User;
public fun hashCode ()I
public fun toString ()Ljava/lang/String;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3267,7 +3267,6 @@ internal constructor(
* @param query [QueryThreadsRequest] with query parameters to get matching users.
*/
@CheckResult
@InternalStreamChatApi
public fun queryThreadsResult(query: QueryThreadsRequest): Call<QueryThreadsResult> {
return api.queryThreads(query)
.doOnStart(userScope) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,7 @@ private fun MessageReadEventDto.toDomain(currentUserId: UserId?): MessageReadEve
cid = cid,
channelType = channel_type,
channelId = channel_id,
thread = thread?.toDomain(currentUserId),
)
}

Expand Down Expand Up @@ -493,6 +494,10 @@ private fun NotificationMarkReadEventDto.toDomain(currentUserId: UserId?): Notif
channelId = channel_id,
totalUnreadCount = total_unread_count,
unreadChannels = unread_channels,
threadId = thread_id,
thread = thread?.toDomain(currentUserId),
unreadThreads = unread_threads,
unreadThreadMessages = unread_thread_messages,
)
}

Expand All @@ -511,6 +516,7 @@ private fun NotificationMarkUnreadEventDto.toDomain(currentUserId: UserId?): Not
lastReadMessageId = last_read_message_id,
lastReadMessageAt = last_read_at.date,
unreadMessages = unread_messages,
unreadThreads = unread_threads,
)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,11 @@
package io.getstream.chat.android.client.api2.mapping

import io.getstream.chat.android.client.api2.model.dto.DownstreamThreadDto
import io.getstream.chat.android.client.api2.model.dto.DownstreamThreadInfoDto
import io.getstream.chat.android.client.api2.model.dto.DownstreamThreadParticipantDto
import io.getstream.chat.android.models.Thread
import io.getstream.chat.android.models.User
import io.getstream.chat.android.models.ThreadInfo
import io.getstream.chat.android.models.ThreadParticipant
import io.getstream.chat.android.models.UserId

internal fun DownstreamThreadDto.toDomain(currentUserId: UserId?): Thread =
Expand All @@ -43,4 +45,23 @@ internal fun DownstreamThreadDto.toDomain(currentUserId: UserId?): Thread =
read = read.orEmpty().map { it.toDomain(currentUserId, last_message_at) },
)

internal fun DownstreamThreadParticipantDto.toDomain(currentUserId: UserId?): User = user.toDomain(currentUserId)
internal fun DownstreamThreadInfoDto.toDomain(currentUserId: UserId?): ThreadInfo =
ThreadInfo(
activeParticipantCount = active_participant_count ?: 0,
cid = channel_cid,
createdAt = created_at,
createdBy = created_by?.toDomain(currentUserId),
createdByUserId = created_by_user_id,
deletedAt = deleted_at,
lastMessageAt = last_message_at,
parentMessage = parent_message?.toDomain(currentUserId),
parentMessageId = parent_message_id,
participantCount = participant_count ?: 0,
replyCount = reply_count ?: 0,
title = title,
updatedAt = updated_at,
)

internal fun DownstreamThreadParticipantDto.toDomain(currentUserId: UserId?): ThreadParticipant = ThreadParticipant(
user = user.toDomain(currentUserId),
)
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ internal data class MessageReadEventDto(
val cid: String,
val channel_type: String,
val channel_id: String,
val thread: DownstreamThreadInfoDto? = null,
) : ChatEventDto()

@JsonClass(generateAdapter = true)
Expand Down Expand Up @@ -266,6 +267,10 @@ internal data class NotificationMarkReadEventDto(
val channel_id: String,
val total_unread_count: Int = 0,
val unread_channels: Int = 0,
val thread_id: String? = null,
val thread: DownstreamThreadInfoDto? = null,
val unread_threads: Int? = null,
val unread_thread_messages: Int? = null,
) : ChatEventDto()

@JsonClass(generateAdapter = true)
Expand All @@ -277,11 +282,12 @@ internal data class NotificationMarkUnreadEventDto(
val channel_type: String,
val channel_id: String,
val first_unread_message_id: String,
val last_read_message_id: String,
val last_read_message_id: String?,
val last_read_at: ExactDate,
val unread_messages: Int,
val total_unread_count: Int,
val unread_channels: Int,
val unread_threads: Int = 0,
) : ChatEventDto()

@JsonClass(generateAdapter = true)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import java.util.Date

/**
* The DTO for a thread.
* Corresponds to [ThreadStateResponse].
*
* @param active_participant_count: The number of active participants.
* @param channel_cid: The channel CID.
Expand Down Expand Up @@ -54,22 +55,60 @@ internal data class DownstreamThreadDto(
val thread_participants: List<DownstreamThreadParticipantDto>?,
val last_message_at: Date,
val created_at: Date,
val updated_at: Date?,
val updated_at: Date,
val deleted_at: Date?,
val title: String,
val latest_replies: List<DownstreamMessageDto>,
val read: List<DownstreamChannelUserRead>?,
)

/**
* The DTO for Thread Participant.
* The DTO for a shortened thread info.
* Corresponds to [ThreadResponse].
*
* @param active_participant_count: The number of active participants.
* @param channel_cid: The channel CID.
* @param created_at: The date when the thread was created.
* @param created_by: The user who created the thread.
* @param created_by_user_id: The ID of the user who created the thread.
* @param deleted_at: The date when the thread was deleted.
* @param last_message_at: The date of the last message in the thread.
* @param parent_message: The parent message.
* @param parent_message_id: The parent message ID.
* @param participant_count: The number of participants in the thread.
* @param reply_count: The number of replies in the thread.
* @param thread_participants: The participants in the thread.
* @param title: The title of the thread.
* @param updated_at: The date when the thread was updated.
*/
@JsonClass(generateAdapter = true)
internal data class DownstreamThreadInfoDto(
val active_participant_count: Int?,
val channel_cid: String,
val created_at: Date,
val created_by: DownstreamUserDto?,
val created_by_user_id: String,
val deleted_at: Date?,
val last_message_at: Date?,
val parent_message: DownstreamMessageDto?,
val parent_message_id: String,
val participant_count: Int?,
val reply_count: Int?,
val title: String,
val updated_at: Date,
)

/**
* The DTO for Thread Participant.
*
* @param channel_cid: The channel CID.
* @param user: The user as the thread participant. (Note: It is not always delivered, sometimes we only get the ID of
* the user - [user_id]).
* @param user_id: The ID of the user (thread participant).
*/
@JsonClass(generateAdapter = true)
internal data class DownstreamThreadParticipantDto(
val channel_cid: String,
val user_id: String,
val user: DownstreamUserDto,
val user_id: String,
)
Loading

0 comments on commit 42a3aed

Please sign in to comment.