IMSDK
IM features a comprehensive suite of solutions including global access, one-to-one chat, group chat, message push, profile and relationship chain hosting, and account authentication. It also provides complete app access and backend management APIs.
V2TIMSendMessageOption

Detailed Description

Options for sending an advanced message.

Properties

V2TIMMessagePriority priority
 
BOOL onlineUserOnly
 
V2TIMPushInfo * pushInfo
 

Property Documentation

◆ priority

- (V2TIMMessagePriority) priority
readwritenonatomicassign

Message priority, valid only for group chat messages. Default: V2TIM_PRIORITY_DEFAULT. You are advised to set higher priorities for important messages (such as red packet and gift messages) and lower priorities for frequent but unimportant messages (such as like messages).

◆ onlineUserOnly

- (BOOL) onlineUserOnly
readwritenonatomicassign

Whether the message can be received only by online users. Default: NO. If this field is set to YES, the message will not appear in the recipient's historical message list. This field is often used to implement less important notifications such as typing indicators.

Attention
  • Audio-video groups (AVChatRoom) do not support this field. You need to set it to NO for audio-video groups (AVChatRoom).
  • If this field is set to YES, the message is an online message and is not counted as an unread message.

◆ pushInfo

- (V2TIMPushInfo*) pushInfo
readwritenonatomicstrong

Offline push configuration. Default: nil.

Attention
  • If nil, offline push is disabled for this message.
  • If you want to push custom messages as well, set the desc field in pushInfo so that the information specified by desc will be displayed by default during push.