mirai-core / net.mamoe.mirai / LowLevelBotAPIAccessor

LowLevelBotAPIAccessor

interface LowLevelBotAPIAccessor

Bot 相关协议层低级 API.

Functions

_lowLevelDeleteAnnouncement

删除群公告

abstract suspend fun _lowLevelDeleteAnnouncement(groupId: Long, fid: String): Unit

_lowLevelGetAnnouncement

获取一条群公告

abstract suspend fun _lowLevelGetAnnouncement(groupId: Long, fid: String): GroupAnnouncement

_lowLevelGetAnnouncements

获取群公告列表

abstract suspend fun _lowLevelGetAnnouncements(groupId: Long, page: Int = 1, amount: Int = 10): GroupAnnouncementList

_lowLevelGetGroupActiveData

获取群活跃信息

abstract suspend fun _lowLevelGetGroupActiveData(groupId: Long): GroupActiveData

_lowLevelNewFriend

构造一个 Friend 对象. 它持有对 Bot 的弱引用(WeakRef).

abstract fun _lowLevelNewFriend(friendInfo: FriendInfo): Friend

_lowLevelQueryGroupInfo

向服务器查询群资料. 获得的仅为当前时刻的资料. 请优先使用 Bot.getGroup 然后查看群资料.

abstract suspend fun _lowLevelQueryGroupInfo(groupCode: Long): GroupInfo

_lowLevelQueryGroupList

向服务器查询群列表. 返回值高 32 bits 为 uin, 低 32 bits 为 groupCode

abstract suspend fun _lowLevelQueryGroupList(): Sequence<Long>

_lowLevelQueryGroupMemberList

向服务器查询群成员列表. 请优先使用 Bot.getGroup, Group.members 查看群成员.

abstract suspend fun _lowLevelQueryGroupMemberList(groupUin: Long, groupCode: Long, ownerId: Long): Sequence<MemberInfo>

_lowLevelSendAnnouncement

发送群公告

abstract suspend fun _lowLevelSendAnnouncement(groupId: Long, announcement: GroupAnnouncement): String

Inheritors

Bot

机器人对象. 一个机器人实例登录一个 QQ 账号. Mirai 为多账号设计, 可同时维护多个机器人.

abstract class Bot : CoroutineScope, LowLevelBotAPIAccessor, BotJavaFriendlyAPI, ContactOrBot