This commit is contained in:
手瓜一十雪 2024-04-27 22:52:57 +08:00
parent ebab8a190e
commit b31876d2d1
3 changed files with 20 additions and 2 deletions

View File

@ -0,0 +1,14 @@
import { OB11User } from '../../types';
import { OB11Constructor } from '../../constructor';
import { friends } from '../../../common/data';
import BaseAction from '../BaseAction';
import { ActionName } from '../types';
import { NTQQUserApi } from '@/core/apis';
export class GetRobotUinRange extends BaseAction<void, Array<any>> {
actionName = ActionName.GetRobotUinRange;
protected async _handle(payload: void) {
// console.log(await NTQQUserApi.getRobotUinRange());
return await NTQQUserApi.getRobotUinRange();
}
}

View File

@ -47,6 +47,7 @@ import { GoCQHTTGetForwardMsgAction } from './go-cqhttp/GetForwardMsg';
import GetFriendMsgHistory from './go-cqhttp/GetFriendMsgHistory'; import GetFriendMsgHistory from './go-cqhttp/GetFriendMsgHistory';
import { GetCookies } from './user/GetCookies'; import { GetCookies } from './user/GetCookies';
import { SetMsgEmojiLike } from '@/onebot11/action/msg/SetMsgEmojiLike'; import { SetMsgEmojiLike } from '@/onebot11/action/msg/SetMsgEmojiLike';
import { GetRobotUinRange } from './extends/GetRobotUinRange';
export const actionHandlers = [ export const actionHandlers = [
new GetFile(), new GetFile(),
@ -84,6 +85,8 @@ export const actionHandlers = [
new SetMsgEmojiLike(), new SetMsgEmojiLike(),
// new CleanCache(), // new CleanCache(),
new GetCookies(), new GetCookies(),
//
new GetRobotUinRange(),
//以下为go-cqhttp api //以下为go-cqhttp api
new GoCQHTTPSendForwardMsg(), new GoCQHTTPSendForwardMsg(),
new GoCQHTTPSendGroupForwardMsg(), new GoCQHTTPSendGroupForwardMsg(),

View File

@ -51,8 +51,9 @@ export enum ActionName {
GetImage = 'get_image', GetImage = 'get_image',
GetRecord = 'get_record', GetRecord = 'get_record',
CleanCache = 'clean_cache', CleanCache = 'clean_cache',
GetCookies = "get_cookies", GetCookies = 'get_cookies',
// 以下为扩展napcat扩展
GetRobotUinRange = 'get_robot_uin_range',
// 以下为go-cqhttp api // 以下为go-cqhttp api
GoCQHTTP_SendForwardMsg = 'send_forward_msg', GoCQHTTP_SendForwardMsg = 'send_forward_msg',
GoCQHTTP_SendGroupForwardMsg = 'send_group_forward_msg', GoCQHTTP_SendGroupForwardMsg = 'send_group_forward_msg',