feat(sdk): expose group request query options
Add typed group, pending-state, and per-inbox limit options to group-system message queries while preserving existing call sites. Regenerate the shared action catalog so SDK and MCP consumers receive consistent validation rules and updated request-flag guidance.
This commit is contained in:
@@ -4781,7 +4781,7 @@
|
||||
},
|
||||
"flag": {
|
||||
"type": "string",
|
||||
"description": "处理用 flag(eventType:groupId:targetUid:filtered)"
|
||||
"description": "处理请求使用的规范 flag"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -5815,6 +5815,18 @@
|
||||
"type": "boolean"
|
||||
},
|
||||
"default": false
|
||||
},
|
||||
{
|
||||
"name": "count",
|
||||
"type": "int",
|
||||
"required": false,
|
||||
"schema": {
|
||||
"type": "integer",
|
||||
"minimum": 1,
|
||||
"maximum": 100
|
||||
},
|
||||
"default": 50,
|
||||
"desc": "每个收件箱最多读取的记录数"
|
||||
}
|
||||
],
|
||||
"invariants": [],
|
||||
@@ -5829,6 +5841,13 @@
|
||||
"only_pending": {
|
||||
"type": "boolean",
|
||||
"default": false
|
||||
},
|
||||
"count": {
|
||||
"type": "integer",
|
||||
"minimum": 1,
|
||||
"maximum": 100,
|
||||
"description": "每个收件箱最多读取的记录数",
|
||||
"default": 50
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
|
||||
@@ -4784,7 +4784,7 @@ export const ACTIONS: CatalogAction[] = [
|
||||
},
|
||||
"flag": {
|
||||
"type": "string",
|
||||
"description": "处理用 flag(eventType:groupId:targetUid:filtered)"
|
||||
"description": "处理请求使用的规范 flag"
|
||||
}
|
||||
},
|
||||
"required": [
|
||||
@@ -5818,6 +5818,18 @@ export const ACTIONS: CatalogAction[] = [
|
||||
"type": "boolean"
|
||||
},
|
||||
"default": false
|
||||
},
|
||||
{
|
||||
"name": "count",
|
||||
"type": "int",
|
||||
"required": false,
|
||||
"schema": {
|
||||
"type": "integer",
|
||||
"minimum": 1,
|
||||
"maximum": 100
|
||||
},
|
||||
"default": 50,
|
||||
"desc": "每个收件箱最多读取的记录数"
|
||||
}
|
||||
],
|
||||
"invariants": [],
|
||||
@@ -5832,6 +5844,13 @@ export const ACTIONS: CatalogAction[] = [
|
||||
"only_pending": {
|
||||
"type": "boolean",
|
||||
"default": false
|
||||
},
|
||||
"count": {
|
||||
"type": "integer",
|
||||
"minimum": 1,
|
||||
"maximum": 100,
|
||||
"description": "每个收件箱最多读取的记录数",
|
||||
"default": 50
|
||||
}
|
||||
},
|
||||
"additionalProperties": true
|
||||
|
||||
@@ -132,8 +132,16 @@ export abstract class SnowLumaApiClient {
|
||||
return this.call('get_group_honor_info', params, options);
|
||||
}
|
||||
|
||||
getGroupSystemMessages(options?: RequestOptions) {
|
||||
return this.call('get_group_system_msg', {}, options);
|
||||
getGroupSystemMessages(options?: RequestOptions & {
|
||||
groupId?: number;
|
||||
onlyPending?: boolean;
|
||||
count?: number;
|
||||
}) {
|
||||
return this.call('get_group_system_msg', {
|
||||
group_id: options?.groupId,
|
||||
only_pending: options?.onlyPending,
|
||||
count: options?.count,
|
||||
}, options);
|
||||
}
|
||||
|
||||
setGroupKick(groupId: number, userId: number, options?: RequestOptions & { rejectAddRequest?: boolean }) {
|
||||
|
||||
@@ -18,6 +18,7 @@ import type {
|
||||
GetGroupFilesParams,
|
||||
GetGroupFileUrlParams,
|
||||
GetGroupHonorInfoParams,
|
||||
GetGroupSystemMsgParams,
|
||||
GetGroupInfoParams,
|
||||
GetGroupListParams,
|
||||
GetGroupMemberInfoParams,
|
||||
@@ -131,7 +132,7 @@ export interface SnowLumaActionMap {
|
||||
get_group_member_list: { params: GetGroupMemberListParams; data: JsonObject[] };
|
||||
get_group_member_info: { params: GetGroupMemberInfoParams; data: JsonObject };
|
||||
get_group_honor_info: { params: GetGroupHonorInfoParams; data: JsonValue };
|
||||
get_group_system_msg: { params: JsonObject; data: JsonObject[] };
|
||||
get_group_system_msg: { params: GetGroupSystemMsgParams; data: JsonObject[] };
|
||||
set_group_kick: { params: SetGroupKickParams; data: EmptyData };
|
||||
set_group_kick_members: { params: SetGroupKickMembersParams; data: EmptyData };
|
||||
set_group_ban: { params: SetGroupBanParams; data: EmptyData };
|
||||
|
||||
@@ -57,6 +57,12 @@ export interface GetGroupHonorInfoParams extends GroupIdParams {
|
||||
type?: 'talkative' | 'performer' | 'legend' | 'strong_newbie' | 'emotion' | 'all' | string;
|
||||
}
|
||||
|
||||
export interface GetGroupSystemMsgParams extends JsonObject {
|
||||
group_id?: number;
|
||||
only_pending?: boolean;
|
||||
count?: number;
|
||||
}
|
||||
|
||||
export interface DeleteFriendParams extends UserIdParams {
|
||||
block?: boolean;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user