feat(onebot): expose group remarks in group queries

Include each account's saved group remark in group list and detail responses.

Keep joined-group, non-member, and fallback results shape-consistent when no remark is available. Document the field in the public response metadata and cover cached and refreshed query paths with regression tests.

Closes #294
This commit is contained in:
DrSmoothl committed 2026-07-30 10:36:43 +08:00
1 parent 655226d9d7
commit a3b790d472
3 files changed
+30 -7

No files matched your search

@@ -74,6 +74,7 @@ export async function getGroupList(
return bridge.identity.groups.map(g => ({
group_id: g.groupId,
group_name: g.groupName,
group_remark: g.remark,
member_count: g.memberCount,
max_member_count: g.memberMax,
// #197: create_time + memo come free from the list; group_level is only in
@@ -128,6 +129,7 @@ export async function getGroupInfo(
return {
group_id: g.groupId,
group_name: g.groupName,
group_remark: g.remark,
member_count: g.memberCount,
max_member_count: g.memberMax,
group_create_time: g.createTime ?? 0,
@@ -148,6 +150,7 @@ export async function getGroupInfo(
const info: JsonObject = {
group_id: detail.groupId,
group_name: detail.groupName,
group_remark: detail.remark,
member_count: detail.memberCount,
max_member_count: detail.memberMax,
group_create_time: detail.createTime ?? 0,