FriendRequest 类(Native (C ABI) IMLib)

类继承图​

Object→FriendRequest

继承关系:Object → FriendRequest。该数据结构不包含行为方法,字段与 domain.json → schemas.FriendRequest 一一对应。

类说明​

好友请求:请求 ID、发起/接收双方、附言与处理状态(pending / accepted / rejected)。

项值
类型数据结构(值对象)
字段数10
IDL 定义domain.json → schemas.FriendRequest
程序包libim_sdk
跨端一致性字段名与取值在 7 个平台绑定中一致;仅语言类型映射不同
平台状态已交付

字段概要​

字段类型必填说明
requestIdstring是好友请求 ID
appkeystring是应用 AppKey
fromUserIdstring是发起方 userId
toUserIdstring是接收方 userId
messagestring否请求附言
statusFriendRequestStatus是状态
fromNamestring否发起方昵称
toNamestring否接收方昵称
createdAtint64是创建时间(epoch ms)
updatedAtint64是最后更新时间(epoch ms)

详细字段说明​

string requestId
必填

好友请求 ID

string appkey
必填

应用 AppKey

string fromUserId
必填

发起方 userId

string toUserId
必填

接收方 userId

string message
可选

请求附言

FriendRequestStatus status
必填

状态

string fromName
可选

发起方昵称

string toName
可选

接收方昵称

int64 createdAt
必填

创建时间(epoch ms)

int64 updatedAt
必填

最后更新时间(epoch ms)

相关链接​