Party API 参考

Party API 参考

此API提供用户好友互动、私人聊天、群组聊天等功能

此API参考是按资源类型组织的。每种资源类型都有一个或多个数据表示形式和一个或多个方法。

资源类型

ContactList

有关“ContactList”的详细信息,请参见资源表示页面。

MethodHTTP requestDescription
archiveGET /api/party/contact-list/archive/获取归档联系人列表
inboxGET /api/party/contact-list/inbox/获取会话联系人列表
getContactGET /api/party/contact-list/get_contact/获取指定联系人信息
blackListGET /api/party/contact-list/black_list/获取黑名单列表
updateRelationPOST /api/party/contact-list/update_relation/更新联系人关系

Group

有关“Group”的详细信息,请参见资源表示页面。

MethodHTTP requestDescription
getGET /api/party/group/获取群组列表
createPOST /api/party/group/创建一个群组
addMemberPOST /api/party/group/{id}/add_member/指定群组ID,添加用户成为该群的成员
removeMemberPOST /api/party/group/{id}/remove_member/移除一个群组成员
renamePOST /api/party/group/{id}/rename/重命名群组名字
getAvatarGET /api/party/group/{id}/get_avatar/获取群组头像
dismissPOST /api/party/group/{id}/dismiss/解散一个群组
restorePOST /api/party/group/{id}/restore/恢复一个群组
getMemberGET /api/party/group/{id}/get_member/指定群组ID,获取群组成员列表
blackPOST /api/party/group/{id}/black/拉黑(离开)一个群组
unblackPOST /api/party/group/{id}/unblack/取消拉黑(重返)一个群组
mergeRequestPOST /api/party/group/{id}/merge_request/发送群组合并请求
processMergeRequestPOST /api/party/group/{id}/process_merge_request/处理群组合并请求

Message

有关“Message”的详细信息,请参见资源表示页面。

MethodHTTP requestDescription
createPOST /api/party/message/创建一条聊天消息
broadcastPOST /api/party/message/broadcast/发送广播消息
markReadPOST /api/party/message/mark_read/标记指定联系人已读当前所有消息
historyPOST /api/party/message/history/获取消息历史记录

Enums

ContactList.Status

enum Status {
  Stranger = 0,
  Creating = 100,
  Applying = 200,
  Created = 300,
  Recalled = 400,
  Rejected = 500,
  Black = 600
}

Group.Status

enum Status {
  CREATED = 0
  REQUESTING_MERGE = 100
  CHECKING_MERGE = 200
  DISMISS = 300
  DELETED = 500
}

Message.Message_type

enum Message_type {
  FRIEND_IM = 0
  GROUP_IM = 100
  GROUP_PM = 200
  BROADCAST = 300
  LIKED = 400
  COMMENT = 500
  INVITATION = 600
  SYSTEM = 700
  FRIEND_APPLY = 800
  FRIEND_ACCEPT = 900
  FRIEND_REJECT = 1000
  FRIEND_RECALL = 2000
  ORDER = 1100
  GROUP_MERGE_REQUEST = 1200
  GROUP_MERGE = 1300
  GROUP_DISMISS = 1400
  GROUP_RESTORE = 1500
  GROUP_NEW_MEMBER = 1600
  GROUP_BLACK = 1700
  GROUP_UNBLACK = 1800
  GROUP_REMOVE_MEMBER = 1810
  GROUP_RESTORE_MEMBER = 1820
  GROUP_MERGE_REQUEST_REJECT = 1900
  GROUP_NEW = 2100
  RELATION_REQUEST = 2200
  RELATION_ACCEPT = 2300
  RELATION_REJECT = 2400
  GROUP_NEW_NAME = 2500
  PAY_ERROR = 2600
  NO_RECEIPET_ACCOUNT = 2700
  DIMZOU_NEW_REWORD = 3000
  DIMZOU_NEW_CHECK_STATUS = 3100
  DIMZOU_NEW_COMMENT = 3200
  DIMZOU_NEW_LIKE = 3300
  DIMZOU_NEW_COLLABORATOR = 3400
  DIMZOU_COLLABORATOR_UPDATED = 3500
  DIMZOU_NEW_COPY_BUNDLE = 3600
  NOTIFICATION = 4000
}

发表评论

您的电子邮箱地址不会被公开。

您可以使用以下 HTML标签和属性:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

Captcha Code