woodenfish-bot 4.7.1 → 4.7.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/es/index.js CHANGED
@@ -11,7 +11,8 @@ import https from 'https';
11
11
  import _possibleConstructorReturn from '@babel/runtime/helpers/possibleConstructorReturn';
12
12
  import _getPrototypeOf from '@babel/runtime/helpers/getPrototypeOf';
13
13
  import _inherits from '@babel/runtime/helpers/inherits';
14
- import WebSocket, { EventEmitter } from 'ws';
14
+ import WebSocket from 'ws';
15
+ import { EventEmitter } from 'node:events';
15
16
 
16
17
  var versionMapping = Object.create(null);
17
18
  function register(version, api) {
@@ -70,6 +71,24 @@ var apiMap = {
70
71
  // 群组富媒体消息
71
72
  groupMessageURI: '/v2/groups/:groupOpenid/messages/:messageID',
72
73
  // 群组撤回消息
74
+ groupInfoURI: '/v2/groups/:groupOpenid/info',
75
+ // 群基本信息
76
+ groupBotStateURI: '/v2/groups/:groupOpenid/bot_state',
77
+ // 机器人群内状态
78
+ groupJoinRequestListURI: '/v2/groups/:groupOpenid/join_request_list',
79
+ // 入群申请列表
80
+ groupJoinRequestApprovalURI: '/v2/groups/:groupOpenid/approval_join_request/:memberOpenid',
81
+ // 入群申请审批
82
+ groupRestrictChatSettingURI: '/v2/groups/:groupOpenid/restrict_chat_setting',
83
+ // 群禁言状态及成员禁言
84
+ groupJoinApprovalStrategiesURI: '/v2/groups/join_approval_strategy',
85
+ // 入群自动审批策略列表及创建
86
+ groupJoinApprovalStrategyURI: '/v2/groups/join_approval_strategy/:strategyID',
87
+ // 入群自动审批策略
88
+ groupJoinApprovalStrategyExecuteURI: '/v2/groups/join_approval_strategy/:strategyID/execute',
89
+ // 执行入群自动审批策略
90
+ groupJoinApprovalStrategyWhitelistURI: '/v2/groups/join_approval_strategy/:strategyID/whitelist_users',
91
+ // 入群自动审批白名单
73
92
  c2cMessagesURI: '/v2/users/:userID/messages',
74
93
  // C2C消息
75
94
  c2cRichMediaURI: '/v2/users/:userID/files',
@@ -300,7 +319,7 @@ var Guild = /*#__PURE__*/function () {
300
319
  }]);
301
320
  }();
302
321
 
303
- var version = "4.7.1";
322
+ var version = "4.7.3";
304
323
 
305
324
  function getDefaultExportFromCjs (x) {
306
325
  return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
@@ -2127,6 +2146,164 @@ var Interaction = /*#__PURE__*/function () {
2127
2146
  }]);
2128
2147
  }();
2129
2148
 
2149
+ var Group = /*#__PURE__*/function () {
2150
+ function Group(request, config) {
2151
+ _classCallCheck(this, Group);
2152
+ _defineProperty(this, "request", void 0);
2153
+ _defineProperty(this, "config", void 0);
2154
+ this.request = request;
2155
+ this.config = config;
2156
+ }
2157
+ return _createClass(Group, [{
2158
+ key: "getGroupInfo",
2159
+ value: function getGroupInfo(groupOpenid) {
2160
+ return this.request({
2161
+ method: 'GET',
2162
+ url: getURL('groupInfoURI'),
2163
+ rest: {
2164
+ groupOpenid: groupOpenid
2165
+ },
2166
+ apiVersion: 'v2'
2167
+ });
2168
+ }
2169
+ }, {
2170
+ key: "getGroupBotState",
2171
+ value: function getGroupBotState(groupOpenid) {
2172
+ return this.request({
2173
+ method: 'GET',
2174
+ url: getURL('groupBotStateURI'),
2175
+ rest: {
2176
+ groupOpenid: groupOpenid
2177
+ },
2178
+ apiVersion: 'v2'
2179
+ });
2180
+ }
2181
+ }, {
2182
+ key: "getGroupJoinRequests",
2183
+ value: function getGroupJoinRequests(groupOpenid, pager) {
2184
+ return this.request({
2185
+ method: 'GET',
2186
+ url: getURL('groupJoinRequestListURI'),
2187
+ rest: {
2188
+ groupOpenid: groupOpenid
2189
+ },
2190
+ params: pager || {},
2191
+ apiVersion: 'v2'
2192
+ });
2193
+ }
2194
+ }, {
2195
+ key: "approveGroupJoinRequest",
2196
+ value: function approveGroupJoinRequest(groupOpenid, memberOpenid, options) {
2197
+ return this.request({
2198
+ method: 'POST',
2199
+ url: getURL('groupJoinRequestApprovalURI'),
2200
+ rest: {
2201
+ groupOpenid: groupOpenid,
2202
+ memberOpenid: memberOpenid
2203
+ },
2204
+ data: options,
2205
+ apiVersion: 'v2'
2206
+ });
2207
+ }
2208
+ }, {
2209
+ key: "getGroupRestrictChatSetting",
2210
+ value: function getGroupRestrictChatSetting(groupOpenid) {
2211
+ return this.request({
2212
+ method: 'GET',
2213
+ url: getURL('groupRestrictChatSettingURI'),
2214
+ rest: {
2215
+ groupOpenid: groupOpenid
2216
+ },
2217
+ apiVersion: 'v2'
2218
+ });
2219
+ }
2220
+ }, {
2221
+ key: "setGroupRestrictChatSetting",
2222
+ value: function setGroupRestrictChatSetting(groupOpenid, options) {
2223
+ return this.request({
2224
+ method: 'POST',
2225
+ url: getURL('groupRestrictChatSettingURI'),
2226
+ rest: {
2227
+ groupOpenid: groupOpenid
2228
+ },
2229
+ data: options,
2230
+ apiVersion: 'v2'
2231
+ });
2232
+ }
2233
+ }, {
2234
+ key: "getGroupJoinApprovalStrategies",
2235
+ value: function getGroupJoinApprovalStrategies(pager) {
2236
+ return this.request({
2237
+ method: 'GET',
2238
+ url: getURL('groupJoinApprovalStrategiesURI'),
2239
+ params: pager || {},
2240
+ apiVersion: 'v2'
2241
+ });
2242
+ }
2243
+ }, {
2244
+ key: "createGroupJoinApprovalStrategy",
2245
+ value: function createGroupJoinApprovalStrategy(options) {
2246
+ return this.request({
2247
+ method: 'POST',
2248
+ url: getURL('groupJoinApprovalStrategiesURI'),
2249
+ data: options,
2250
+ apiVersion: 'v2'
2251
+ });
2252
+ }
2253
+ }, {
2254
+ key: "updateGroupJoinApprovalStrategy",
2255
+ value: function updateGroupJoinApprovalStrategy(strategyID, options) {
2256
+ return this.request({
2257
+ method: 'PATCH',
2258
+ url: getURL('groupJoinApprovalStrategyURI'),
2259
+ rest: {
2260
+ strategyID: strategyID
2261
+ },
2262
+ data: options,
2263
+ apiVersion: 'v2'
2264
+ });
2265
+ }
2266
+ }, {
2267
+ key: "deleteGroupJoinApprovalStrategy",
2268
+ value: function deleteGroupJoinApprovalStrategy(strategyID) {
2269
+ return this.request({
2270
+ method: 'DELETE',
2271
+ url: getURL('groupJoinApprovalStrategyURI'),
2272
+ rest: {
2273
+ strategyID: strategyID
2274
+ },
2275
+ apiVersion: 'v2'
2276
+ });
2277
+ }
2278
+ }, {
2279
+ key: "executeGroupJoinApprovalStrategy",
2280
+ value: function executeGroupJoinApprovalStrategy(strategyID) {
2281
+ return this.request({
2282
+ method: 'POST',
2283
+ url: getURL('groupJoinApprovalStrategyExecuteURI'),
2284
+ rest: {
2285
+ strategyID: strategyID
2286
+ },
2287
+ data: {},
2288
+ apiVersion: 'v2'
2289
+ });
2290
+ }
2291
+ }, {
2292
+ key: "updateGroupJoinApprovalStrategyWhitelist",
2293
+ value: function updateGroupJoinApprovalStrategyWhitelist(strategyID, options) {
2294
+ return this.request({
2295
+ method: 'POST',
2296
+ url: getURL('groupJoinApprovalStrategyWhitelistURI'),
2297
+ rest: {
2298
+ strategyID: strategyID
2299
+ },
2300
+ data: options,
2301
+ apiVersion: 'v2'
2302
+ });
2303
+ }
2304
+ }]);
2305
+ }();
2306
+
2130
2307
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
2131
2308
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), true).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
2132
2309
  var apiVersion = 'v2';
@@ -2154,6 +2331,7 @@ var OpenAPI = /*#__PURE__*/function () {
2154
2331
  _defineProperty(this, "interactionApi", void 0);
2155
2332
  _defineProperty(this, "pinsMessageApi", void 0);
2156
2333
  _defineProperty(this, "guildPermissionsApi", void 0);
2334
+ _defineProperty(this, "groupApi", void 0);
2157
2335
  this.config = config;
2158
2336
  this.register(this);
2159
2337
  }
@@ -2178,6 +2356,7 @@ var OpenAPI = /*#__PURE__*/function () {
2178
2356
  client.reactionApi = new Reaction(this.request, this.config);
2179
2357
  client.interactionApi = new Interaction(this.request, this.config);
2180
2358
  client.pinsMessageApi = new PinsMessage(this.request, this.config);
2359
+ client.groupApi = new Group(this.request, this.config);
2181
2360
  }
2182
2361
 
2183
2362
  // 基础rest请求
@@ -2314,7 +2493,8 @@ var AvailableIntentsEventsEnum = /*#__PURE__*/function (AvailableIntentsEventsEn
2314
2493
  AvailableIntentsEventsEnum["PUBLIC_GUILD_MESSAGES"] = "PUBLIC_GUILD_MESSAGES";
2315
2494
  AvailableIntentsEventsEnum["MESSAGE_AUDIT"] = "MESSAGE_AUDIT";
2316
2495
  AvailableIntentsEventsEnum["INTERACTION"] = "INTERACTION";
2317
- AvailableIntentsEventsEnum["GROUP_C2C_EVENT"] = "GROUP_C2C_EVENT";
2496
+ AvailableIntentsEventsEnum["GROUP_MEMBER"] = "GROUP_MEMBER";
2497
+ AvailableIntentsEventsEnum["GROUP_AND_C2C_EVENT"] = "GROUP_AND_C2C_EVENT";
2318
2498
  return AvailableIntentsEventsEnum;
2319
2499
  }({});
2320
2500
 
@@ -2426,28 +2606,36 @@ var WsEventType = {
2426
2606
  PUBLIC_MESSAGE_DELETE: AvailableIntentsEventsEnum.PUBLIC_GUILD_MESSAGES,
2427
2607
  // 当频道的消息被删除时
2428
2608
 
2429
- // ======= GROUP_C2C_EVENT ======
2430
- GROUP_AT_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2609
+ // ======= GROUP_AND_C2C_EVENT ======
2610
+ GROUP_AT_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2431
2611
  // 机器人在群聊被@时触发
2432
- GROUP_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2612
+ GROUP_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2433
2613
  // 机器人收到群聊全量消息时触发
2434
- C2C_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2614
+ C2C_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2435
2615
  // 机器人收到C2C消息时触发
2436
- FRIEND_ADD: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2616
+ FRIEND_ADD: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2437
2617
  // 机器人被加好友时触发
2438
- FRIEND_DEL: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2618
+ FRIEND_DEL: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2439
2619
  // 机器人被删除好友时触发
2440
- C2C_MSG_RECEIVE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2620
+ C2C_MSG_RECEIVE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2441
2621
  // 用户在机器人资料卡手动开启"主动消息"推送
2442
- C2C_MSG_REJECT: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2622
+ C2C_MSG_REJECT: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2443
2623
  // 用户在机器人资料卡手动关闭"主动消息"推送
2444
- GROUP_ADD_ROBOT: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2624
+ GROUP_ADD_ROBOT: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2445
2625
  // 机器人被加入群聊时触发
2446
- GROUP_DEL_ROBOT: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2626
+ GROUP_DEL_ROBOT: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2447
2627
  // 机器人被移出群聊时触发
2448
- GROUP_MSG_RECEIVE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2628
+ GROUP_MSG_RECEIVE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2449
2629
  // 群管理员主动在机器人资料页操作开启通知
2450
- GROUP_MSG_REJECT: AvailableIntentsEventsEnum.GROUP_C2C_EVENT // 群管理员主动在机器人资料页操作关闭通知
2630
+ GROUP_MSG_REJECT: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2631
+ // 群管理员主动在机器人资料页操作关闭通知
2632
+ GROUP_JOIN_REQUEST: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2633
+ // 用户申请加群
2634
+
2635
+ // ======= GROUP_MEMBER(兼容旧版群成员事件位) ======
2636
+ GROUP_MEMBER_ADD: AvailableIntentsEventsEnum.GROUP_MEMBER,
2637
+ // 群成员加入
2638
+ GROUP_MEMBER_REMOVE: AvailableIntentsEventsEnum.GROUP_MEMBER // 群成员退出或被移出
2451
2639
  };
2452
2640
  var WSCodes = {
2453
2641
  1000: 'WS_CLOSE_REQUESTED',
@@ -2536,7 +2724,8 @@ var IntentEvents = {
2536
2724
  DIRECT_MESSAGE: 1 << 12,
2537
2725
  OPEN_FORUM_EVENT: 1 << 18,
2538
2726
  AUDIO_OR_LIVE_CHANNEL_MEMBER: 1 << 19,
2539
- GROUP_C2C_EVENT: 1 << 25,
2727
+ GROUP_MEMBER: 1 << 24,
2728
+ GROUP_AND_C2C_EVENT: 1 << 25,
2540
2729
  INTERACTION: 1 << 26,
2541
2730
  MESSAGE_AUDIT: 1 << 27,
2542
2731
  FORUM_EVENT: 1 << 28,
@@ -2563,7 +2752,8 @@ var Intents = {
2563
2752
  DIRECT_MESSAGE_TYPING: 14,
2564
2753
  OPEN_FORUM_EVENT: 18,
2565
2754
  AUDIO_OR_LIVE_CHANNEL_MEMBER: 19,
2566
- GROUP_C2C_EVENT: 25,
2755
+ GROUP_MEMBER: 24,
2756
+ GROUP_AND_C2C_EVENT: 25,
2567
2757
  INTERACTION: 26,
2568
2758
  MESSAGE_AUDIT: 27,
2569
2759
  FORUM_EVENT: 28,
package/lib/index.js CHANGED
@@ -14,6 +14,7 @@ var _possibleConstructorReturn = require('@babel/runtime/helpers/possibleConstru
14
14
  var _getPrototypeOf = require('@babel/runtime/helpers/getPrototypeOf');
15
15
  var _inherits = require('@babel/runtime/helpers/inherits');
16
16
  var WebSocket = require('ws');
17
+ var node_events = require('node:events');
17
18
 
18
19
  var versionMapping = Object.create(null);
19
20
  function register(version, api) {
@@ -72,6 +73,24 @@ var apiMap = {
72
73
  // 群组富媒体消息
73
74
  groupMessageURI: '/v2/groups/:groupOpenid/messages/:messageID',
74
75
  // 群组撤回消息
76
+ groupInfoURI: '/v2/groups/:groupOpenid/info',
77
+ // 群基本信息
78
+ groupBotStateURI: '/v2/groups/:groupOpenid/bot_state',
79
+ // 机器人群内状态
80
+ groupJoinRequestListURI: '/v2/groups/:groupOpenid/join_request_list',
81
+ // 入群申请列表
82
+ groupJoinRequestApprovalURI: '/v2/groups/:groupOpenid/approval_join_request/:memberOpenid',
83
+ // 入群申请审批
84
+ groupRestrictChatSettingURI: '/v2/groups/:groupOpenid/restrict_chat_setting',
85
+ // 群禁言状态及成员禁言
86
+ groupJoinApprovalStrategiesURI: '/v2/groups/join_approval_strategy',
87
+ // 入群自动审批策略列表及创建
88
+ groupJoinApprovalStrategyURI: '/v2/groups/join_approval_strategy/:strategyID',
89
+ // 入群自动审批策略
90
+ groupJoinApprovalStrategyExecuteURI: '/v2/groups/join_approval_strategy/:strategyID/execute',
91
+ // 执行入群自动审批策略
92
+ groupJoinApprovalStrategyWhitelistURI: '/v2/groups/join_approval_strategy/:strategyID/whitelist_users',
93
+ // 入群自动审批白名单
75
94
  c2cMessagesURI: '/v2/users/:userID/messages',
76
95
  // C2C消息
77
96
  c2cRichMediaURI: '/v2/users/:userID/files',
@@ -302,7 +321,7 @@ var Guild = /*#__PURE__*/function () {
302
321
  }]);
303
322
  }();
304
323
 
305
- var version = "4.7.1";
324
+ var version = "4.7.3";
306
325
 
307
326
  function getDefaultExportFromCjs (x) {
308
327
  return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
@@ -2129,6 +2148,164 @@ var Interaction = /*#__PURE__*/function () {
2129
2148
  }]);
2130
2149
  }();
2131
2150
 
2151
+ var Group = /*#__PURE__*/function () {
2152
+ function Group(request, config) {
2153
+ _classCallCheck(this, Group);
2154
+ _defineProperty(this, "request", void 0);
2155
+ _defineProperty(this, "config", void 0);
2156
+ this.request = request;
2157
+ this.config = config;
2158
+ }
2159
+ return _createClass(Group, [{
2160
+ key: "getGroupInfo",
2161
+ value: function getGroupInfo(groupOpenid) {
2162
+ return this.request({
2163
+ method: 'GET',
2164
+ url: getURL('groupInfoURI'),
2165
+ rest: {
2166
+ groupOpenid: groupOpenid
2167
+ },
2168
+ apiVersion: 'v2'
2169
+ });
2170
+ }
2171
+ }, {
2172
+ key: "getGroupBotState",
2173
+ value: function getGroupBotState(groupOpenid) {
2174
+ return this.request({
2175
+ method: 'GET',
2176
+ url: getURL('groupBotStateURI'),
2177
+ rest: {
2178
+ groupOpenid: groupOpenid
2179
+ },
2180
+ apiVersion: 'v2'
2181
+ });
2182
+ }
2183
+ }, {
2184
+ key: "getGroupJoinRequests",
2185
+ value: function getGroupJoinRequests(groupOpenid, pager) {
2186
+ return this.request({
2187
+ method: 'GET',
2188
+ url: getURL('groupJoinRequestListURI'),
2189
+ rest: {
2190
+ groupOpenid: groupOpenid
2191
+ },
2192
+ params: pager || {},
2193
+ apiVersion: 'v2'
2194
+ });
2195
+ }
2196
+ }, {
2197
+ key: "approveGroupJoinRequest",
2198
+ value: function approveGroupJoinRequest(groupOpenid, memberOpenid, options) {
2199
+ return this.request({
2200
+ method: 'POST',
2201
+ url: getURL('groupJoinRequestApprovalURI'),
2202
+ rest: {
2203
+ groupOpenid: groupOpenid,
2204
+ memberOpenid: memberOpenid
2205
+ },
2206
+ data: options,
2207
+ apiVersion: 'v2'
2208
+ });
2209
+ }
2210
+ }, {
2211
+ key: "getGroupRestrictChatSetting",
2212
+ value: function getGroupRestrictChatSetting(groupOpenid) {
2213
+ return this.request({
2214
+ method: 'GET',
2215
+ url: getURL('groupRestrictChatSettingURI'),
2216
+ rest: {
2217
+ groupOpenid: groupOpenid
2218
+ },
2219
+ apiVersion: 'v2'
2220
+ });
2221
+ }
2222
+ }, {
2223
+ key: "setGroupRestrictChatSetting",
2224
+ value: function setGroupRestrictChatSetting(groupOpenid, options) {
2225
+ return this.request({
2226
+ method: 'POST',
2227
+ url: getURL('groupRestrictChatSettingURI'),
2228
+ rest: {
2229
+ groupOpenid: groupOpenid
2230
+ },
2231
+ data: options,
2232
+ apiVersion: 'v2'
2233
+ });
2234
+ }
2235
+ }, {
2236
+ key: "getGroupJoinApprovalStrategies",
2237
+ value: function getGroupJoinApprovalStrategies(pager) {
2238
+ return this.request({
2239
+ method: 'GET',
2240
+ url: getURL('groupJoinApprovalStrategiesURI'),
2241
+ params: pager || {},
2242
+ apiVersion: 'v2'
2243
+ });
2244
+ }
2245
+ }, {
2246
+ key: "createGroupJoinApprovalStrategy",
2247
+ value: function createGroupJoinApprovalStrategy(options) {
2248
+ return this.request({
2249
+ method: 'POST',
2250
+ url: getURL('groupJoinApprovalStrategiesURI'),
2251
+ data: options,
2252
+ apiVersion: 'v2'
2253
+ });
2254
+ }
2255
+ }, {
2256
+ key: "updateGroupJoinApprovalStrategy",
2257
+ value: function updateGroupJoinApprovalStrategy(strategyID, options) {
2258
+ return this.request({
2259
+ method: 'PATCH',
2260
+ url: getURL('groupJoinApprovalStrategyURI'),
2261
+ rest: {
2262
+ strategyID: strategyID
2263
+ },
2264
+ data: options,
2265
+ apiVersion: 'v2'
2266
+ });
2267
+ }
2268
+ }, {
2269
+ key: "deleteGroupJoinApprovalStrategy",
2270
+ value: function deleteGroupJoinApprovalStrategy(strategyID) {
2271
+ return this.request({
2272
+ method: 'DELETE',
2273
+ url: getURL('groupJoinApprovalStrategyURI'),
2274
+ rest: {
2275
+ strategyID: strategyID
2276
+ },
2277
+ apiVersion: 'v2'
2278
+ });
2279
+ }
2280
+ }, {
2281
+ key: "executeGroupJoinApprovalStrategy",
2282
+ value: function executeGroupJoinApprovalStrategy(strategyID) {
2283
+ return this.request({
2284
+ method: 'POST',
2285
+ url: getURL('groupJoinApprovalStrategyExecuteURI'),
2286
+ rest: {
2287
+ strategyID: strategyID
2288
+ },
2289
+ data: {},
2290
+ apiVersion: 'v2'
2291
+ });
2292
+ }
2293
+ }, {
2294
+ key: "updateGroupJoinApprovalStrategyWhitelist",
2295
+ value: function updateGroupJoinApprovalStrategyWhitelist(strategyID, options) {
2296
+ return this.request({
2297
+ method: 'POST',
2298
+ url: getURL('groupJoinApprovalStrategyWhitelistURI'),
2299
+ rest: {
2300
+ strategyID: strategyID
2301
+ },
2302
+ data: options,
2303
+ apiVersion: 'v2'
2304
+ });
2305
+ }
2306
+ }]);
2307
+ }();
2308
+
2132
2309
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
2133
2310
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), true).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
2134
2311
  var apiVersion = 'v2';
@@ -2156,6 +2333,7 @@ var OpenAPI = /*#__PURE__*/function () {
2156
2333
  _defineProperty(this, "interactionApi", void 0);
2157
2334
  _defineProperty(this, "pinsMessageApi", void 0);
2158
2335
  _defineProperty(this, "guildPermissionsApi", void 0);
2336
+ _defineProperty(this, "groupApi", void 0);
2159
2337
  this.config = config;
2160
2338
  this.register(this);
2161
2339
  }
@@ -2180,6 +2358,7 @@ var OpenAPI = /*#__PURE__*/function () {
2180
2358
  client.reactionApi = new Reaction(this.request, this.config);
2181
2359
  client.interactionApi = new Interaction(this.request, this.config);
2182
2360
  client.pinsMessageApi = new PinsMessage(this.request, this.config);
2361
+ client.groupApi = new Group(this.request, this.config);
2183
2362
  }
2184
2363
 
2185
2364
  // 基础rest请求
@@ -2316,7 +2495,8 @@ var AvailableIntentsEventsEnum = /*#__PURE__*/function (AvailableIntentsEventsEn
2316
2495
  AvailableIntentsEventsEnum["PUBLIC_GUILD_MESSAGES"] = "PUBLIC_GUILD_MESSAGES";
2317
2496
  AvailableIntentsEventsEnum["MESSAGE_AUDIT"] = "MESSAGE_AUDIT";
2318
2497
  AvailableIntentsEventsEnum["INTERACTION"] = "INTERACTION";
2319
- AvailableIntentsEventsEnum["GROUP_C2C_EVENT"] = "GROUP_C2C_EVENT";
2498
+ AvailableIntentsEventsEnum["GROUP_MEMBER"] = "GROUP_MEMBER";
2499
+ AvailableIntentsEventsEnum["GROUP_AND_C2C_EVENT"] = "GROUP_AND_C2C_EVENT";
2320
2500
  return AvailableIntentsEventsEnum;
2321
2501
  }({});
2322
2502
 
@@ -2428,28 +2608,36 @@ var WsEventType = {
2428
2608
  PUBLIC_MESSAGE_DELETE: AvailableIntentsEventsEnum.PUBLIC_GUILD_MESSAGES,
2429
2609
  // 当频道的消息被删除时
2430
2610
 
2431
- // ======= GROUP_C2C_EVENT ======
2432
- GROUP_AT_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2611
+ // ======= GROUP_AND_C2C_EVENT ======
2612
+ GROUP_AT_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2433
2613
  // 机器人在群聊被@时触发
2434
- GROUP_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2614
+ GROUP_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2435
2615
  // 机器人收到群聊全量消息时触发
2436
- C2C_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2616
+ C2C_MESSAGE_CREATE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2437
2617
  // 机器人收到C2C消息时触发
2438
- FRIEND_ADD: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2618
+ FRIEND_ADD: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2439
2619
  // 机器人被加好友时触发
2440
- FRIEND_DEL: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2620
+ FRIEND_DEL: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2441
2621
  // 机器人被删除好友时触发
2442
- C2C_MSG_RECEIVE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2622
+ C2C_MSG_RECEIVE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2443
2623
  // 用户在机器人资料卡手动开启"主动消息"推送
2444
- C2C_MSG_REJECT: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2624
+ C2C_MSG_REJECT: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2445
2625
  // 用户在机器人资料卡手动关闭"主动消息"推送
2446
- GROUP_ADD_ROBOT: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2626
+ GROUP_ADD_ROBOT: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2447
2627
  // 机器人被加入群聊时触发
2448
- GROUP_DEL_ROBOT: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2628
+ GROUP_DEL_ROBOT: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2449
2629
  // 机器人被移出群聊时触发
2450
- GROUP_MSG_RECEIVE: AvailableIntentsEventsEnum.GROUP_C2C_EVENT,
2630
+ GROUP_MSG_RECEIVE: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2451
2631
  // 群管理员主动在机器人资料页操作开启通知
2452
- GROUP_MSG_REJECT: AvailableIntentsEventsEnum.GROUP_C2C_EVENT // 群管理员主动在机器人资料页操作关闭通知
2632
+ GROUP_MSG_REJECT: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2633
+ // 群管理员主动在机器人资料页操作关闭通知
2634
+ GROUP_JOIN_REQUEST: AvailableIntentsEventsEnum.GROUP_AND_C2C_EVENT,
2635
+ // 用户申请加群
2636
+
2637
+ // ======= GROUP_MEMBER(兼容旧版群成员事件位) ======
2638
+ GROUP_MEMBER_ADD: AvailableIntentsEventsEnum.GROUP_MEMBER,
2639
+ // 群成员加入
2640
+ GROUP_MEMBER_REMOVE: AvailableIntentsEventsEnum.GROUP_MEMBER // 群成员退出或被移出
2453
2641
  };
2454
2642
  var WSCodes = {
2455
2643
  1000: 'WS_CLOSE_REQUESTED',
@@ -2538,7 +2726,8 @@ var IntentEvents = {
2538
2726
  DIRECT_MESSAGE: 1 << 12,
2539
2727
  OPEN_FORUM_EVENT: 1 << 18,
2540
2728
  AUDIO_OR_LIVE_CHANNEL_MEMBER: 1 << 19,
2541
- GROUP_C2C_EVENT: 1 << 25,
2729
+ GROUP_MEMBER: 1 << 24,
2730
+ GROUP_AND_C2C_EVENT: 1 << 25,
2542
2731
  INTERACTION: 1 << 26,
2543
2732
  MESSAGE_AUDIT: 1 << 27,
2544
2733
  FORUM_EVENT: 1 << 28,
@@ -2565,7 +2754,8 @@ var Intents = {
2565
2754
  DIRECT_MESSAGE_TYPING: 14,
2566
2755
  OPEN_FORUM_EVENT: 18,
2567
2756
  AUDIO_OR_LIVE_CHANNEL_MEMBER: 19,
2568
- GROUP_C2C_EVENT: 25,
2757
+ GROUP_MEMBER: 24,
2758
+ GROUP_AND_C2C_EVENT: 25,
2569
2759
  INTERACTION: 26,
2570
2760
  MESSAGE_AUDIT: 27,
2571
2761
  FORUM_EVENT: 28,
@@ -3057,7 +3247,7 @@ var WebsocketClient = /*#__PURE__*/function (_EventEmitter) {
3057
3247
  this.session.closeSession();
3058
3248
  }
3059
3249
  }]);
3060
- }(WebSocket.EventEmitter);
3250
+ }(node_events.EventEmitter);
3061
3251
 
3062
3252
  // 注册v1接口
3063
3253
  v1Setup();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "woodenfish-bot",
3
- "version": "4.7.1",
3
+ "version": "4.7.3",
4
4
  "description": "woodenfish-bot",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -73,7 +73,6 @@
73
73
  "rimraf": "^6.1.3",
74
74
  "rollup": "^4.62.4",
75
75
  "rollup-plugin-dts": "^6.5.1",
76
- "rollup-plugin-typescript-paths": "^1.5.0",
77
76
  "typescript": "^5.9.3"
78
77
  },
79
78
  "dependencies": {
@@ -1,11 +1,10 @@
1
1
  import { RestyResponse, RequestOptions } from 'resty-client';
2
- import WebSocket, { EventEmitter } from 'ws';
2
+ import { EventEmitter } from 'node:events';
3
+ import WebSocket from 'ws';
3
4
 
4
- interface wsResData {
5
+ interface wsResData<T = any> {
5
6
  op: number;
6
- d?: {
7
- heartbeat_interval?: number;
8
- };
7
+ d?: T;
9
8
  s: number;
10
9
  t: string;
11
10
  id?: string;
@@ -67,7 +66,8 @@ declare enum AvailableIntentsEventsEnum {
67
66
  PUBLIC_GUILD_MESSAGES = "PUBLIC_GUILD_MESSAGES",
68
67
  MESSAGE_AUDIT = "MESSAGE_AUDIT",
69
68
  INTERACTION = "INTERACTION",
70
- GROUP_C2C_EVENT = "GROUP_C2C_EVENT"
69
+ GROUP_MEMBER = "GROUP_MEMBER",
70
+ GROUP_AND_C2C_EVENT = "GROUP_AND_C2C_EVENT"
71
71
  }
72
72
  declare const WsEventType: {
73
73
  [key: string]: AvailableIntentsEventsEnum;
@@ -124,7 +124,8 @@ declare const Intents: {
124
124
  DIRECT_MESSAGE_TYPING: number;
125
125
  OPEN_FORUM_EVENT: number;
126
126
  AUDIO_OR_LIVE_CHANNEL_MEMBER: number;
127
- GROUP_C2C_EVENT: number;
127
+ GROUP_MEMBER: number;
128
+ GROUP_AND_C2C_EVENT: number;
128
129
  INTERACTION: number;
129
130
  MESSAGE_AUDIT: number;
130
131
  FORUM_EVENT: number;
@@ -155,6 +156,202 @@ declare const WsObjRequestOptions: (sandbox: boolean) => {
155
156
  };
156
157
  };
157
158
 
159
+ interface GroupAPI {
160
+ getGroupInfo: (groupOpenid: string) => Promise<RestyResponse<GroupInfo>>;
161
+ getGroupBotState: (groupOpenid: string) => Promise<RestyResponse<GroupBotState>>;
162
+ getGroupJoinRequests: (groupOpenid: string, pager?: GroupCursorPager) => Promise<RestyResponse<GroupJoinRequestList>>;
163
+ approveGroupJoinRequest: (groupOpenid: string, memberOpenid: string, options: GroupJoinRequestApproval) => Promise<RestyResponse<Record<string, never>>>;
164
+ getGroupRestrictChatSetting: (groupOpenid: string) => Promise<RestyResponse<GroupRestrictChatSetting>>;
165
+ setGroupRestrictChatSetting: (groupOpenid: string, options: SetGroupRestrictChatSetting) => Promise<RestyResponse<Record<string, never>>>;
166
+ getGroupJoinApprovalStrategies: (pager?: GroupCursorPager) => Promise<RestyResponse<GroupJoinApprovalStrategyList>>;
167
+ createGroupJoinApprovalStrategy: (options: CreateGroupJoinApprovalStrategy) => Promise<RestyResponse<GroupJoinApprovalStrategyResult>>;
168
+ updateGroupJoinApprovalStrategy: (strategyID: string, options: UpdateGroupJoinApprovalStrategy) => Promise<RestyResponse<GroupJoinApprovalStrategyResult>>;
169
+ deleteGroupJoinApprovalStrategy: (strategyID: string) => Promise<RestyResponse<Record<string, never>>>;
170
+ executeGroupJoinApprovalStrategy: (strategyID: string) => Promise<RestyResponse<Record<string, never>>>;
171
+ updateGroupJoinApprovalStrategyWhitelist: (strategyID: string, options: UpdateGroupJoinApprovalStrategyWhitelist) => Promise<RestyResponse<GroupJoinApprovalStrategyWhitelistResult>>;
172
+ }
173
+ interface GroupInfo {
174
+ group_openid: string;
175
+ group_name: string;
176
+ group_finger_memo: string;
177
+ group_class_text: string;
178
+ group_tags: string[];
179
+ group_member_num: number;
180
+ }
181
+ type GroupReceiveMessageSetting = 'all' | 'only_mention' | 'mention_and_context';
182
+ type GroupMemberRole = 'member' | 'owner' | 'admin';
183
+ interface GroupBotState {
184
+ member_openid: string;
185
+ joined_at: string;
186
+ allow_proactive_msg: boolean;
187
+ recv_msg_setting: GroupReceiveMessageSetting;
188
+ member_role: GroupMemberRole;
189
+ }
190
+ interface GroupCursorPager {
191
+ cursor?: string;
192
+ limit?: number;
193
+ }
194
+ interface GroupJoinRequestList {
195
+ list: GroupJoinRequest[];
196
+ next_cursor: string;
197
+ }
198
+ type GroupJoinApplySource = 'self_apply' | 'invited';
199
+ type GroupJoinVerifyMethod = 'verify_message' | 'admin_review_qa';
200
+ interface GroupJoinReviewQA {
201
+ question: string;
202
+ answer: string;
203
+ }
204
+ interface GroupJoinVerifyInfo {
205
+ method: GroupJoinVerifyMethod;
206
+ verify_message?: string;
207
+ review_qa_list?: GroupJoinReviewQA[];
208
+ }
209
+ interface GroupJoinRequest {
210
+ join_request_id: string;
211
+ risk_tips?: string;
212
+ union_openid?: string;
213
+ member_openid: string;
214
+ username: string;
215
+ apply_at: string;
216
+ apply_source: GroupJoinApplySource;
217
+ invited_by?: string;
218
+ bot?: boolean;
219
+ verify_info?: GroupJoinVerifyInfo;
220
+ }
221
+ interface GroupJoinRequestApproval {
222
+ op: 'approve' | 'decline';
223
+ join_request_id?: string;
224
+ reject_reason?: string;
225
+ add_to_member_blacklist?: boolean;
226
+ }
227
+ type GroupMuteMode = 'none' | 'always' | 'schedule';
228
+ interface GroupMuteScheduleRule {
229
+ task_id: string;
230
+ start_at: string;
231
+ end_at: string;
232
+ enabled: boolean;
233
+ }
234
+ interface GroupMuteRecurringRule {
235
+ task_id: string;
236
+ weekdays: number[];
237
+ start_time: string;
238
+ end_time: string;
239
+ enabled: boolean;
240
+ }
241
+ interface GroupGlobalMuteRule {
242
+ mode: GroupMuteMode;
243
+ schedule_rules: GroupMuteScheduleRule[];
244
+ recurring_rules: GroupMuteRecurringRule[];
245
+ }
246
+ interface GroupMemberMuteState {
247
+ member_openid: string;
248
+ mute_expire_at: string;
249
+ username: string;
250
+ union_openid?: string;
251
+ }
252
+ interface GroupRestrictChatSetting {
253
+ global_rule: GroupGlobalMuteRule;
254
+ members: GroupMemberMuteState[];
255
+ }
256
+ interface SetGroupMemberMuteState {
257
+ op: 'add' | 'update' | 'del';
258
+ member_openid: string;
259
+ mute_expire_at?: string;
260
+ }
261
+ interface SetGroupRestrictChatSetting {
262
+ members?: SetGroupMemberMuteState[];
263
+ }
264
+ type GroupJoinApprovalStrategyState = 'on' | 'off';
265
+ type GroupJoinApprovalStrategyGroups = {
266
+ group_openids: string[];
267
+ group_ids?: never;
268
+ } | {
269
+ group_ids: number[];
270
+ group_openids?: never;
271
+ };
272
+ interface GroupJoinApprovalStrategy {
273
+ strategy_id: string;
274
+ group_openids?: string[];
275
+ group_ids?: string[];
276
+ whitelist_user_count: number;
277
+ is_enable: GroupJoinApprovalStrategyState;
278
+ expire_at: string;
279
+ created_at: string;
280
+ updated_at: string;
281
+ remark?: string;
282
+ }
283
+ interface GroupJoinApprovalStrategyList {
284
+ strategies: GroupJoinApprovalStrategy[];
285
+ next_cursor: string;
286
+ }
287
+ type CreateGroupJoinApprovalStrategy = GroupJoinApprovalStrategyGroups & {
288
+ is_enable?: GroupJoinApprovalStrategyState;
289
+ expire_at?: string;
290
+ remark?: string;
291
+ };
292
+ type GroupJoinApprovalStrategyGroupAction = GroupJoinApprovalStrategyGroups & {
293
+ op: 'add' | 'del';
294
+ };
295
+ interface UpdateGroupJoinApprovalStrategy {
296
+ is_enable?: GroupJoinApprovalStrategyState;
297
+ expire_at?: string;
298
+ group_action?: GroupJoinApprovalStrategyGroupAction;
299
+ remark?: string;
300
+ }
301
+ interface GroupJoinApprovalStrategyResult {
302
+ strategy_id?: string;
303
+ is_enable: GroupJoinApprovalStrategyState;
304
+ expire_at: string;
305
+ }
306
+ interface UpdateGroupJoinApprovalStrategyWhitelist {
307
+ op: 'add' | 'del';
308
+ whitelist_users: string[];
309
+ }
310
+ interface GroupJoinApprovalStrategyWhitelistResult {
311
+ strategy_id: string;
312
+ whitelist_user_count: number;
313
+ updated_at: string;
314
+ }
315
+
316
+ interface GroupRobotEvent {
317
+ timestamp: number;
318
+ group_openid: string;
319
+ op_member_openid: string;
320
+ }
321
+ type GroupAddRobotEvent = GroupRobotEvent;
322
+ type GroupDelRobotEvent = GroupRobotEvent;
323
+ type GroupMsgReceiveEvent = GroupRobotEvent;
324
+ type GroupMsgRejectEvent = GroupRobotEvent;
325
+ interface GroupMemberEvent {
326
+ timestamp: number;
327
+ group_openid: string;
328
+ member_openid: string;
329
+ user_openid?: string;
330
+ }
331
+ type GroupMemberAddEvent = GroupMemberEvent;
332
+ type GroupMemberRemoveEvent = GroupMemberEvent;
333
+ interface GroupJoinRequestEvent extends GroupJoinRequest {
334
+ group_openid: string;
335
+ auto_approved?: {
336
+ strategy_id: string;
337
+ };
338
+ }
339
+ interface GroupEventPayloadMap {
340
+ GROUP_ADD_ROBOT: GroupAddRobotEvent;
341
+ GROUP_DEL_ROBOT: GroupDelRobotEvent;
342
+ GROUP_MSG_RECEIVE: GroupMsgReceiveEvent;
343
+ GROUP_MSG_REJECT: GroupMsgRejectEvent;
344
+ GROUP_MEMBER_ADD: GroupMemberAddEvent;
345
+ GROUP_MEMBER_REMOVE: GroupMemberRemoveEvent;
346
+ GROUP_JOIN_REQUEST: GroupJoinRequestEvent;
347
+ }
348
+ type GroupEventType = keyof GroupEventPayloadMap;
349
+ interface WebsocketEventData<T = unknown> {
350
+ eventType: string;
351
+ eventId: string;
352
+ msg: T;
353
+ }
354
+
158
355
  interface AudioAPI {
159
356
  postAudio: (channelID: string, value: AudioControl) => Promise<RestyResponse<AudioControl>>;
160
357
  botOnMic: (channelID: string) => Promise<RestyResponse<{}>>;
@@ -654,7 +851,10 @@ interface GuildPermissionDemandIdentify {
654
851
  method: string;
655
852
  }
656
853
 
657
- type OpenAPIRequest = <T extends Record<any, any> = any>(options: RequestOptions) => Promise<RestyResponse<T>>;
854
+ interface OpenAPIRequestOptions extends RequestOptions {
855
+ apiVersion?: string;
856
+ }
857
+ type OpenAPIRequest = <T extends Record<any, any> = any>(options: OpenAPIRequestOptions) => Promise<RestyResponse<T>>;
658
858
  interface Config {
659
859
  appID: string;
660
860
  token: string;
@@ -682,6 +882,7 @@ interface IOpenAPI {
682
882
  reactionApi: ReactionAPI;
683
883
  interactionApi: InteractionAPI;
684
884
  pinsMessageApi: PinsMessageAPI;
885
+ groupApi: GroupAPI;
685
886
  }
686
887
  type APIVersion = `v${number}`;
687
888
  interface Token {
@@ -715,6 +916,7 @@ declare class OpenAPI implements IOpenAPI {
715
916
  interactionApi: InteractionAPI;
716
917
  pinsMessageApi: PinsMessageAPI;
717
918
  guildPermissionsApi: GuildPermissionsAPI;
919
+ groupApi: GroupAPI;
718
920
  constructor(config: Config);
719
921
  register(client: IOpenAPI): void;
720
922
  request<T extends Record<any, any> = any>(options: any): Promise<RestyResponse<T>>;
@@ -775,4 +977,4 @@ declare function createOpenAPI(config: Config): OpenAPI;
775
977
  declare function createWebsocket(config: GetWsParam): WebsocketClient;
776
978
 
777
979
  export { AvailableIntentsEventsEnum, IntentEvents, Intents, OpCode, SessionEvents, WSCodes, WebsocketCloseReason, WebsocketCode, WsEventType, WsObjRequestOptions, createOpenAPI, createWebsocket, selectOpenAPIVersion };
778
- export type { APIVersion, Action, AnnounceAPI, Ark, ArkKV, ArkObj, ArkObjKV, AudioAPI, AudioControl, Button, ChannelAPI, ChannelPermissionsAPI, ChannelSubType, ChannelType, Config, CustomKeyboard, DirectMessageAPI, DirectMessageToCreate, Embed, EmbedField, EmbedThumbnail, EventTypes, GetWsParam, GuildAPI, GuildMembersPager, GuildPermission, GuildPermissionDemand, GuildPermissionDemandIdentify, GuildPermissionRes, GuildPermissionsAPI, GuildRoles, HeartbeatParam, IAnnounce, IChannel, IChannelPermissions, IChannelRolePermissions, IDirectMessage, IGuild, IMedia, IMember, IMessage, IMessageRes, IOpenAPI, IPinsMessage, IRole, IRoleFilter, ISchedule, IUser, IVoiceMember, InputNotify, IntentEventsMapType, InteractionAPI, InteractionData, MeAPI, MeGuildsReq, Media, MediaToCreate, MemberAPI, MemberAddRoleBody, MessageAPI, MessageAttachment, MessageKeyboard, MessageReference, MessageToCreate, MessagesPager, MuteAPI, MuteOptions, Nullish, OpenAPIRequest, PatchChannelObj, Permission, PermissionDemandToCreate, PinsMessageAPI, PostChannelObj, ReactionAPI, ReactionObj, ReactionUserListObj, RecommendChannel, RecommendObj, RenderData, RoleAPI, Row, ScheduleAPI, ScheduleRemindType, ScheduleToCreate, ScheduleToPatch, SessionRecord, ThreadReplyToCreate, ThreadsAPI, ThreadsToCreate, Token, UpdateChannelPermissions, UpdateRoleRes, WebsocketAPI, WsAddressObj, WsDataInfo, wsResData };
980
+ export type { APIVersion, Action, AnnounceAPI, Ark, ArkKV, ArkObj, ArkObjKV, AudioAPI, AudioControl, Button, ChannelAPI, ChannelPermissionsAPI, ChannelSubType, ChannelType, Config, CreateGroupJoinApprovalStrategy, CustomKeyboard, DirectMessageAPI, DirectMessageToCreate, Embed, EmbedField, EmbedThumbnail, EventTypes, GetWsParam, GroupAPI, GroupAddRobotEvent, GroupBotState, GroupCursorPager, GroupDelRobotEvent, GroupEventPayloadMap, GroupEventType, GroupGlobalMuteRule, GroupInfo, GroupJoinApplySource, GroupJoinApprovalStrategy, GroupJoinApprovalStrategyGroupAction, GroupJoinApprovalStrategyGroups, GroupJoinApprovalStrategyList, GroupJoinApprovalStrategyResult, GroupJoinApprovalStrategyState, GroupJoinApprovalStrategyWhitelistResult, GroupJoinRequest, GroupJoinRequestApproval, GroupJoinRequestEvent, GroupJoinRequestList, GroupJoinReviewQA, GroupJoinVerifyInfo, GroupJoinVerifyMethod, GroupMemberAddEvent, GroupMemberEvent, GroupMemberMuteState, GroupMemberRemoveEvent, GroupMemberRole, GroupMsgReceiveEvent, GroupMsgRejectEvent, GroupMuteMode, GroupMuteRecurringRule, GroupMuteScheduleRule, GroupReceiveMessageSetting, GroupRestrictChatSetting, GroupRobotEvent, GuildAPI, GuildMembersPager, GuildPermission, GuildPermissionDemand, GuildPermissionDemandIdentify, GuildPermissionRes, GuildPermissionsAPI, GuildRoles, HeartbeatParam, IAnnounce, IChannel, IChannelPermissions, IChannelRolePermissions, IDirectMessage, IGuild, IMedia, IMember, IMessage, IMessageRes, IOpenAPI, IPinsMessage, IRole, IRoleFilter, ISchedule, IUser, IVoiceMember, InputNotify, IntentEventsMapType, InteractionAPI, InteractionData, MeAPI, MeGuildsReq, Media, MediaToCreate, MemberAPI, MemberAddRoleBody, MessageAPI, MessageAttachment, MessageKeyboard, MessageReference, MessageToCreate, MessagesPager, MuteAPI, MuteOptions, Nullish, OpenAPIRequest, OpenAPIRequestOptions, PatchChannelObj, Permission, PermissionDemandToCreate, PinsMessageAPI, PostChannelObj, ReactionAPI, ReactionObj, ReactionUserListObj, RecommendChannel, RecommendObj, RenderData, RoleAPI, Row, ScheduleAPI, ScheduleRemindType, ScheduleToCreate, ScheduleToPatch, SessionRecord, SetGroupMemberMuteState, SetGroupRestrictChatSetting, ThreadReplyToCreate, ThreadsAPI, ThreadsToCreate, Token, UpdateChannelPermissions, UpdateGroupJoinApprovalStrategy, UpdateGroupJoinApprovalStrategyWhitelist, UpdateRoleRes, WebsocketAPI, WebsocketEventData, WsAddressObj, WsDataInfo, wsResData };