见fun.zhaoxi.tim.TIMBooter文件
public class TIMBooter {
static String BASE_URL = "https://console.tim.qq.com/";
static String IDENTIFIER = "your identifier";
static Long SDK_APPID = 1L;// your sdk appid
static String USER_SIGN = "your sign";
public static void main(String[] args) {
TIMSdkConfig config = new TIMSdkConfig();
config.setBaseUrl(BASE_URL);
config.setIdentifier(IDENTIFIER);
config.setSdkAppId(SDK_APPID);
config.setUserSign(USER_SIGN);
TIMSdkService timSdkService = new TIMSdkServiceImpl(config);
GetGroupInfoRequest request = new GetGroupInfoRequest();
request.setGroupIdList(new String[]{"686b82cd67204ae6b2dbaf2dde96c40f"});
request.setResponseFilter(null);
GetGroupInfoResponse response = timSdkService.GetGroupInfo(request);
}
}
所有的方法都通过TimSdkService进行调用
- 生成用户Sign
String generateSig(String userID)
- 独立模式帐号导入 v4/im_open_login_svc/account_import
AccountImportResponse accountImport(AccountImportRequest request);
- 独立模式帐号批量导入 v4/im_open_login_svc/multiaccount_import
AccountMultiImportResponse multiAccountImport(AccountMultiImportRequest request);
- 失效帐号登录态 v4/im_open_login_svc/kick
AccountExpiredResponse accountExpired(AccountExpiredRequest request);
- 托管模式帐号导入
接口作废
- 单发单聊消息
AccountImportResponse accountImport(AccountImportRequest request);
- 批量发单聊消息
AccountMultiImportResponse multiAccountImport(AccountMultiImportRequest request);
- 导入单聊消息
AccountExpiredResponse accountExpired(AccountExpiredRequest request);
- 获取APP中的所有群组 v4/group_open_http_svc/get_appid_group_list
GetAppIdGroupListResponse GroupGetListByAppId(GetAppIdGroupListRequest request);
- 创建群组 v4/group_open_http_svc/create_group
GroupCreateResponse GroupCreate(GroupCreateRequest request);
- 获取群组详细资料 v4/group_open_http_svc/get_group_info
GetGroupInfoResponse GetGroupInfo(GetGroupInfoRequest request) ;
- 获取群成员详细资料 v4/group_open_http_svc/get_group_member_info
GetGroupMemberInfoResponse GetGroupMemberInfo(GetGroupMemberInfoRequest request);
- 修改群组基础资料 v4/group_open_http_svc/modify_group_base_info
ModifyGroupBaseInfoResponse ModifyGroupBaseInfo(ModifyGroupBaseInfoRequest request);
- 增加群组成员 v4/group_open_http_svc/add_group_member
GroupAddMemberResponse GroupAddMember(GroupAddMemberRequest request);
- 删除群组成员 v4/group_open_http_svc/delete_group_member
GroupDeleteMemberResponse GroupDeleteMember(GroupDeleteMemberRequest request);
- 修改群组成员资料 v4/group_open_http_svc/modify_group_member_info
ModifyGroupMemberInfoResponse ModifyGroupMemberInfo(ModifyGroupMemberInfoRequest request);
- 解散群组 v4/group_open_http_svc/destroy_group
GroupDestroyResponse GroupDestroy(GroupDestroyRequest request);
- 获取用户所加入的群组 v4/group_open_http_svc/get_joined_group_list
GetJoinedGroupListResponse GetJoinedGroupList(GetJoinedGroupListRequest request);
- 查询用户在群组中的身份 v4/group_open_http_svc/get_role_in_group
GetRoleInGroupResponse GetRoleInGroup(GetRoleInGroupRequest request);
- 批量禁言和取消禁言 v4/group_open_http_svc/forbid_send_msg
ForbidSendMsgResponse ForbidSendMsg(ForbidSendMsgRequest request);
- 获取群组被禁言用户列表 v4/group_open_http_svc/get_group_shutted_uin
GetGroupShuttedUinResponse GetGroupShuttedUin(GetGroupShuttedUinRequest request);
- 在群组中发送普通消息 v4/group_open_http_svc/send_group_msg
SendGroupMsgResponse SendGroupMsg(SendGroupMsgRequest request);
- 在群组中发送系统通知 v4/group_open_http_svc/send_group_system_notification
SendGroupSystemNotificationResponse SendGroupSystemNotification(SendGroupSystemNotificationRequest request);
- 转让群组 v4/group_open_http_svc/change_group_owner
ChangeGroupOwnerResponse ChangeGroupOwner(ChangeGroupOwnerRequest request);
- 导入群基础资料 v4/group_open_http_svc/import_group
ImportGroupResponse ImportGroup(ImportGroupRequest request) ;
- 导入群消息 v4/group_open_http_svc/import_group_msg
ImportGroupMsgResponse ImportGroupMsg(ImportGroupMsgRequest request) ;
- 导入群成员 v4/group_open_http_svc/import_group_member
ImportGroupMemberResponse ImportGroupMember(ImportGroupMemberRequest request) ;
- 设置成员未读消息计数 v4/group_open_http_svc/set_unread_msg_num
SetUnreadMsgNumResponse SetUnreadMsgNum(SetUnreadMsgNumRequest request) ;
- 删除指定用户发送的消息 v4/group_open_http_svc/delete_group_msg_by_sender
DeleteGroupMsgBySenderResponse DeleteGroupMsgBySender(DeleteGroupMsgBySenderRequest request) ;
- 拉取群漫游消息 v4/group_open_http_svc/group_msg_get_simple
GroupMsgGetSimpleResponse groupMsgGetSimple(GroupMsgGetSimpleRequest request) ;
- 拉取资料 v4/profile/portrait_get
PortraitSetResponse portraitSet(PortraitSetRequest request);
- 设置资料 v4/profile/portrait_set
PortraitGetResponse portraitGet(PortraitGetRequest request);
- 添加好友 v4/sns/friend_add
FriendAddResponse friendAdd(FriendAddRequest request);
- 导入好友 v4/sns/friend_import
FriendImportResponse friendImport(FriendImportRequest request);
- 删除好友 v4/sns/friend_delete
FriendDeleteResponse friendDelete(FriendDeleteRequest request);
- 删除所有好友 v4/sns/friend_delete_all
FriendDeleteAllResponse friendDeleteAll(FriendDeleteAllRequest request);
- 校验好友 v4/sns/friend_check
FriendCheckResponse friendCheck(FriendCheckRequest request);
- 拉取好友 v4/sns/friend_get_all
FriendGetAllResponse friendGetAll(FriendGetAllRequest request);
- 拉取指定好友 v4/sns/friend_get_list
FriendGetListResponse friendGetList(FriendGetListRequest request);
- 添加黑名单 v4/sns/black_list_add
BlackListAddResponse blackListAdd(BlackListAddRequest request);
- 删除黑名单 v4/sns/black_list_delete
BlackListDeleteResponse blackListDelete(BlackListDeleteRequest request);
- 拉取黑名单 v4/sns/black_list_get
BlackListGetResponse blackListGet(BlackListGetRequest request);
- 校验黑名单 v4/sns/black_list_check
BlackListCheckResponse blackListCheck(BlackListCheckRequest request);
- 添加分组 v4/sns/group_add
GroupAddResponse groupAdd(GroupAddRequest request);
- 删除分组 v4/sns/group_delete
GroupAddResponse groupAdd(GroupAddRequest request);
- 更新好友 v4/sns/friend_update
FriendUpdateResponse friendUpdate(FriendUpdateRequest request);
- 查询脏字 v4/openim_dirty_words/get
DirtyWordsGetResponse dirtyWordsGet(DirtyWordsGetRequest request);
- 添加脏字 v4/openim_dirty_words/add
DirtyWordsAddResponse dirtyWordsAdd(DirtyWordsAddRequest request);
- 删除脏字 v4/openim_dirty_words/delete
DirtyWordsDeleteResponse dirtyWordsDelete(DirtyWordsDeleteRequest request);
- 消息记录下载 v4/open_msg_svc/get_history
GetHistoryResponse getHistory(GetHistoryRequest request);
- 获取用户在线状态 v4/openim/querystate
QueryStateResponse queryState(QueryStateRequest request);
- 设置全局禁言 v4/openconfigsvr/setnospeaking
SetNoSpeakingResponse setNoSpeaking(SetNoSpeakingRequest request);
- 查询全局禁言 v4/openconfigsvr/getnospeaking
GetNoSpeakingResponse getNoSpeaking(GetNoSpeakingRequest request);
- 推送 v4/openim/im_push
- 获取推送报告 v4/openim/im_get_push_report
- 设置应用属性名称 v4/openim/im_set_attr_name
- 获取应用属性名称 v4/openim/im_get_attr_name
- 设置用户属性 v4/openim/im_set_attr
- 删除用户属性 v4/openim/im_remove_attr
- 获取用户属性 v4/openim/im_get_attr
- 添加用户标签 v4/openim/im_add_tag
- 删除用户标签 v4/openim/im_remove_tag
- 删除用户所有标签 v4/openim/im_remove_tag_all
计划1.1 版本提交