awaitAuthenticate

suspend fun SendbirdChat.awaitAuthenticate(userId: String, authToken: String? = null, apiHost: String? = null): AuthUser

Authenticates to SendbirdChat with given User ID and auth token. This method is different from SendbirdChat.awaitConnect in that it doesn't create a websocket connection. This should be used in below cases: 1. If you want to use the interface provided by the FeedChannel only. 2. If you want to use chat interface prior to SendbirdChat.connect, i.e. SendbirdChat.getTotalUnreadMessageCount.

Since

4.17.0

Parameters

userId

User ID to authenticate with. Refer to User.userId.

authToken

Auth token. It should not be saved on the client side. Set null if not used.

apiHost

Custom API Host. Internal use only.