getLastMessageId

open fun getLastMessageId(@NonNull context: Context, @NonNull conversationId: String): String

Call this method to retrieve the last inserted message id in the associated conversation from local Database.

The returned message can be :

  • a business message
  • a VoIP message
  • an emergency message (ManDown or Emergency alert)
  • an update conversation name message

Return

The last message id

Parameters

context

The application context

conversationId

The conversation ID