Skip to main content

Common Fields

Common Field Descriptions

Field NameTypeString Length LimitDescriptionValue Description
secretstring32OpenIM secret, the secret field from the server-side config/share.yml fileString
platformIDintDevice type when the user logs in1: iOS, 2: Android, 3: Windows, 4: OSX, 5: WEB, 6: Mini Program, 7: Linux, 8: AndroidPad, 9: IPad, 10: Admin
userIDstring64User ID, must be unique within the IM systemString
nicknamestring255NicknameString
faceURLstring255Profile picture URLURL
exstring1024Extended field, recommended to be encapsulated as a JSON stringString/JSON
operationIDstringOperation ID, used for tracking issues, must be unique, suggested to use current timestamp, random number, and userIDString
operatorUserIDstring64Operator, specific meaning depends on the contextString
groupIDstring64Group ID, must be unique within the IM systemString
sessionTypeintSession type1: Single chat, 3: Group chat, 4: System notification

PublicUserInfo

Public user information object

Field NameTypeMax String LengthDescription
userIDstring64User ID
nicknamestring255Username
faceURLstring255Profile picture URL
exstring1024Extended field

UserInfo

User information object

Field NameTypeMax String LengthDescriptionValue Description
userIDstringUser ID
nicknamestringUsername
faceURLstringProfile picture URL
exstringExtended field
createTimeintCreation time
appMangerLevelintInternal field, can be ignored
globalRecvMsgOptintGlobal offline message reception option0: Receive; 2: Do not receive

FriendInfo

Friend information object

Field NameTypeMax String LengthDescriptionValue Description
ownerUserIDstringUser ID
remarkstringRemark
createTimeintCreation time
addSourceintAdd source
operatorUserIDstringOperator ID
exstringExtended field
friendUserUserInfo-User information object

BlackInfo

Blacklist information object

Field NameTypeMax String LengthDescriptionValue Description
ownerUserIDstringUser ID
createTimeintBlacklist time
blackUserInfoPublicUserInfoBlacklisted user information
addSourceintBlacklist source
operatorUserIDstringOperator ID
exstringExtended field

GroupInfo

Object containing group information.

Field NameTypeMax String LengthDescriptionValue Description
groupIDstringGroup ID
groupNamestringGroup name
notificationstringGroup announcement
introductionstringGroup introduction
faceURLstringGroup profile picture URL
ownerUserIDstringGroup owner ID
createTimeintCreation time
memberCountintNumber of group members
exstringGroup extended field
statusintGroup status0: Active; 1: Banned (unused); 2: Disbanded; 3: All muted
creatorUserIDstringGroup creator ID
groupTypeintGroup typeFixed at 2
needVerificationintIs verification required to join the group0: Join requests require approval, member invites are automatic; 1: Everyone needs verification except admin invites; 2: Join automatically
lookMemberInfointCan group members view other members' info?0: Yes; 1: No
applyMemberFriendintCan group members add friends?0: Yes; 1: No
notificationUpdateTimeintLast group announcement update time
notificationUserIDstringLast user to update the group announcement

GroupMemberInfo

Object containing group member information.

Field NameTypeMax String LengthDescriptionValue Description
groupIDstringGroup ID
userIDstringGroup member ID
roleLevelintGroup member role100: Owner; 60: Admin; 20: Member
joinTimeintGroup join time
nicknamestringGroup member nickname
faceURLstringGroup member profile picture URL
appManagerLevelintInternal field, can be ignored
joinSourceintJoin source1: Admin invite; 2: Member invite; 3: Search to join; 4: QR code join
operatorUserIDstringOperator user ID
exstringExtended field
muteEndTimeintMute end time
inviterUserIDstringID of the person who invited the member

FriendRequestInfo

Object containing friend request information.

Field NameTypeMax String LengthDescriptionValue Description
fromUserIDstringRequesting user's ID
fromNicknamestringRequesting user's nickname
fromFaceURLstringRequesting user's profile picture URL
toUserIDstringReceiving user's ID
toNicknamestringReceiving user's nickname
toFaceURLstringReceiving user's profile picture URL
handleResultintFriend request status1: Accepted; 0: Pending; -1: Declined
reqMsgstringRequest message
createTimeintCreation time
handlerUserIDstringHandler ID
handleMsgstringHandling message
handleTimeintHandling time
exstringExtended field

GroupRequestInfo

Group join request object

Field NameTypeMax String LengthDescriptionValue Explanation
userInfoPublicUserInfoInformation of the user requesting to join the group
groupInfoGroupInfoGroup information
handleResultintProcessing result1: Accepted; 0: Pending; -1: Rejected
reqMsgstringMessage with the group join request
handleMsgstringMessage handling details
reqTimeintRequest timestamp
handleUserIDstringID of the user handling the request
handleTimeintTimestamp of handling
exstringExtended field for group request
joinSourceintSource of group joining1: Admin invite; 2: Member invite; 3: Search; 4: QR code
inviterUserIDstringID of the inviter

PictureBaseInfo

Picture Base Information

Field NameTypeMax String LengthDescriptionValue Range
uuidstringUnique UUID of the picture
typestringPicture type
sizeintPicture size
widthintPicture width
heightintPicture height

ConversationInfo

Conversation Information

Field NameTypeMax String LengthDescriptionValue Range
ownerUserIDstringUser ID of the conversation owner
conversationIDstringConversation ID
recvMsgOptintMessage reception options: 0 for receive; 1 for mute; 2 for silent receive
conversationTypeintConversation type, 1 for single chat, 3 for group chat
userIDstringUser ID for the conversation, applicable when type is 1
groupIDstringGroup ID for the conversation, applicable when type is 3
isPinnedbooleanWhether the conversation is pinned
attachedInfostringOpenIM-specific extended field
isPrivateChatbooleanWhether private chat mode is enabled
groupAtTypeintGroup mention type: special identifiers for @ownerUserID or @all
exstringUser-specific extended field
burnDurationintDuration of message burn after reading
minSeqintMinimum sequence the user can retrieve in this conversation
maxSeqintMaximum sequence the user can retrieve in this conversation
msgDestructTimeintInterval for message destruction
latestMsgDestructTimeintLatest message destruction timestamp
isMsgDestructbooleanWhether timed message destruction is enabled