@zhin.js/adapter-line 1.1.14 → 1.1.16

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/CHANGELOG.md CHANGED
@@ -1,5 +1,54 @@
1
1
  # @zhin.js/adapter-line
2
2
 
3
+ ## 1.1.16
4
+
5
+ ### Patch Changes
6
+
7
+ - 53bc6a0: 适配器配置标签、端点命令和工具反馈支持中英文;复用当前操作语言,保持协议值、用户内容、身份、权限与发送链路不变。Sandbox 展示使用项目语言,QQ 绑定与交互状态保留完整会话身份。
8
+ - Updated dependencies [334e92d]
9
+ - Updated dependencies [f3b7c9f]
10
+ - Updated dependencies [658a5fb]
11
+ - Updated dependencies [144a17b]
12
+ - Updated dependencies [18296cf]
13
+ - Updated dependencies [08e64de]
14
+ - Updated dependencies [9cade30]
15
+ - Updated dependencies [53bc6a0]
16
+ - Updated dependencies [7595136]
17
+ - Updated dependencies [66b6404]
18
+ - Updated dependencies [adb4af2]
19
+ - Updated dependencies [69f9ef6]
20
+ - Updated dependencies [17d1301]
21
+ - @zhin.js/adapter@1.1.23
22
+ - @zhin.js/host-http@1.1.10
23
+ - @zhin.js/core@1.1.51
24
+ - @zhin.js/tool@1.1.10
25
+ - @zhin.js/skill@1.1.10
26
+ - @zhin.js/im-contract@1.1.7
27
+ - @zhin.js/agent-feature@1.1.10
28
+ - @zhin.js/feature-kit@1.1.9
29
+
30
+ ## 1.1.15
31
+
32
+ ### Patch Changes
33
+
34
+ - 7d68df6: 精简 Agent 内置固定提示词与消息说明,保留工具、审批和结构化回复能力。适配器 Skill 按会话场景拆分,群/频道管理仅向对应场景披露;提示段与模型消息段支持场景声明,沿用当前回合权限和 generation 投影。
35
+ - Updated dependencies [f98025b]
36
+ - Updated dependencies [66ec1a5]
37
+ - Updated dependencies [7d68df6]
38
+ - Updated dependencies [bf0fa9f]
39
+ - Updated dependencies [3326db3]
40
+ - Updated dependencies [e91235e]
41
+ - Updated dependencies [6da2bad]
42
+ - Updated dependencies [3781f1c]
43
+ - @zhin.js/core@1.1.50
44
+ - @zhin.js/adapter@1.1.22
45
+ - @zhin.js/im-contract@1.1.6
46
+ - @zhin.js/tool@1.1.9
47
+ - @zhin.js/host-http@1.1.9
48
+ - @zhin.js/agent-feature@1.1.9
49
+ - @zhin.js/feature-kit@1.1.8
50
+ - @zhin.js/skill@1.1.9
51
+
3
52
  ## 1.1.14
4
53
 
5
54
  ### Patch Changes
@@ -2,10 +2,7 @@
2
2
  name: line
3
3
  platforms:
4
4
  - line
5
- description: >-
6
- LINE Messaging API 适配器技能。当用户在 LINE 私聊或群组中发送消息时,
7
- 框架通过 Webhook 接收并处理。支持文本、图片、视频、音频、文件、位置、贴纸
8
- 等消息类型。回复消息使用 Reply API(自动引用上下文),主动发送使用 Push API。
5
+ description: LINE 用户资料查询。
9
6
  keywords:
10
7
  - line
11
8
  - adapter:line
@@ -15,28 +12,8 @@ tags:
15
12
  - im
16
13
  - adapter
17
14
  tools:
18
- - "get_group_members"
19
- - "get_profile"
15
+ - get_profile
20
16
  ---
21
- # LINE Messaging API 技能
17
+ # LINE
22
18
 
23
- LINE 的 Messaging API 基于 Webhook 模式:平台将事件 POST 到指定 URL,适配器签名验证后处理。
24
-
25
- ## 消息接收
26
-
27
- - 文本消息:直接转发为 text segment
28
- - 媒体消息(image/video/audio/file):包含 message_id,可通过 Content API 获取
29
- - 位置消息:包含经纬度和地址
30
- - 贴纸消息:包含 packageId 和 stickerId
31
-
32
- ## 消息发送
33
-
34
- - **Reply API**:有 replyToken 时自动使用,回复会关联原始消息
35
- - **Push API**:无 replyToken 时使用,主动推送到 userId/groupId/roomId
36
- - 单次最多 5 条消息,单条文本最多 5000 字符
37
-
38
- ## 限制
39
-
40
- - 不支持消息撤回
41
- - 不支持已读回执(read receipt)
42
- - 媒体消息仅提供 message_id,需额外 API 调用获取内容
19
+ 通过真实 userId 查询用户资料,不把昵称当作 ID。消息发送和接收由适配器处理。
@@ -0,0 +1,16 @@
1
+ ---
2
+ name: line-group-directory
3
+ platforms:
4
+ - line
5
+ scopes:
6
+ - group
7
+ description: LINE 群成员 ID 查询。
8
+ keywords:
9
+ - line
10
+ - adapter:line
11
+ tools:
12
+ - get_group_members
13
+ ---
14
+ # line-group-directory
15
+
16
+ 确认群 ID,只查询任务必需的成员列表。
@@ -4,6 +4,7 @@ import { z } from 'zod';
4
4
  export default defineAgentTool({
5
5
  description: 'Get LINE group member IDs',
6
6
  adapter: 'line',
7
+ scopes: ["group"],
7
8
  inputSchema: z.object({
8
9
  groupId: z.string().min(1),
9
10
  }),
@@ -4,6 +4,7 @@ import { z } from 'zod';
4
4
  export default defineAgentTool<{ groupId: string }>({
5
5
  description: 'Get LINE group member IDs',
6
6
  adapter: 'line',
7
+ scopes: ["group"],
7
8
  inputSchema: z.object({
8
9
  groupId: z.string().min(1),
9
10
  }),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zhin.js/adapter-line",
3
- "version": "1.1.14",
3
+ "version": "1.1.16",
4
4
  "description": "Zhin.js LINE Messaging API adapter for Plugin Runtime (HTTP webhook)",
5
5
  "type": "module",
6
6
  "main": "./lib/index.js",
@@ -31,23 +31,23 @@
31
31
  "directory": "plugins/adapters/line"
32
32
  },
33
33
  "dependencies": {
34
- "@zhin.js/adapter": "1.1.21",
35
- "@zhin.js/agent-feature": "1.1.8",
36
- "@zhin.js/core": "1.1.49",
37
- "@zhin.js/feature-kit": "1.1.7",
38
- "@zhin.js/host-http": "1.1.8",
39
- "@zhin.js/im-contract": "1.1.5",
34
+ "@zhin.js/adapter": "1.1.23",
35
+ "@zhin.js/agent-feature": "1.1.10",
36
+ "@zhin.js/core": "1.1.51",
37
+ "@zhin.js/feature-kit": "1.1.9",
38
+ "@zhin.js/host-http": "1.1.10",
39
+ "@zhin.js/im-contract": "1.1.7",
40
40
  "@zhin.js/logger": "1.1.2",
41
- "@zhin.js/skill": "1.1.8",
42
- "@zhin.js/tool": "1.1.8"
41
+ "@zhin.js/skill": "1.1.10",
42
+ "@zhin.js/tool": "1.1.10"
43
43
  },
44
44
  "peerDependencies": {
45
45
  "zod": "^4.0.0",
46
- "@zhin.js/adapter": "^1.1.21",
47
- "@zhin.js/command": "^1.1.9",
48
- "@zhin.js/core": "^1.1.49",
49
- "@zhin.js/host-http": "^1.1.8",
50
- "zhin.js": "^1.1.14"
46
+ "@zhin.js/adapter": "^1.1.23",
47
+ "@zhin.js/command": "^1.1.11",
48
+ "@zhin.js/core": "^1.1.51",
49
+ "@zhin.js/host-http": "^1.1.10",
50
+ "zhin.js": "^1.1.16"
51
51
  },
52
52
  "peerDependenciesMeta": {
53
53
  "@zhin.js/command": {
@@ -65,7 +65,7 @@
65
65
  "typescript": "^6.0.3",
66
66
  "vitest": "^4.1.10",
67
67
  "zod": "^4.4.3",
68
- "zhin.js": "1.1.14"
68
+ "zhin.js": "1.1.16"
69
69
  },
70
70
  "files": [
71
71
  "adapters",
package/schema.json CHANGED
@@ -16,7 +16,12 @@
16
16
  "string",
17
17
  "number"
18
18
  ],
19
- "description": "框架 master(LINE user id;AI/工具权限、endpoint 管理)。endpoints[i].master 可逐项覆盖"
19
+ "description": "框架 master(LINE user id;AI/工具权限、endpoint 管理)。endpoints[i].master 可逐项覆盖",
20
+ "x-i18n": {
21
+ "en": {
22
+ "description": "Framework masters (LINE user id; AI/tool permissions and endpoint management). endpoints[i].master can override this value."
23
+ }
24
+ }
20
25
  },
21
26
  "trusted": {
22
27
  "type": "array",
@@ -27,7 +32,12 @@
27
32
  ],
28
33
  "description": "Trusted LINE user id"
29
34
  },
30
- "description": "框架 trusted 用户列表(弱于 master)。endpoints[i].trusted 可逐项追加"
35
+ "description": "框架 trusted 用户列表(弱于 master)。endpoints[i].trusted 可逐项追加",
36
+ "x-i18n": {
37
+ "en": {
38
+ "description": "Framework trusted users, below master authority. endpoints[i].trusted can add users."
39
+ }
40
+ }
31
41
  },
32
42
  "endpoints": {
33
43
  "type": "array",
@@ -42,7 +52,12 @@
42
52
  "string",
43
53
  "number"
44
54
  ],
45
- "description": "本 endpoint 的框架 master(LINE user id);覆盖顶层 master"
55
+ "description": "本 endpoint 的框架 master(LINE user id);覆盖顶层 master",
56
+ "x-i18n": {
57
+ "en": {
58
+ "description": "Framework masters for this endpoint (LINE user id), overriding the top-level master list."
59
+ }
60
+ }
46
61
  },
47
62
  "trusted": {
48
63
  "type": "array",
@@ -53,7 +68,12 @@
53
68
  ],
54
69
  "description": "Trusted LINE user id"
55
70
  },
56
- "description": "本 endpoint 的 trusted 列表"
71
+ "description": "本 endpoint 的 trusted 列表",
72
+ "x-i18n": {
73
+ "en": {
74
+ "description": "Trusted users for this endpoint."
75
+ }
76
+ }
57
77
  },
58
78
  "channelSecret": {
59
79
  "type": "string",
@@ -82,12 +102,22 @@
82
102
  "channelSecret",
83
103
  "channelAccessToken"
84
104
  ]
105
+ },
106
+ "x-i18n": {
107
+ "en": {
108
+ "description": "Multiple accounts: mount multiple endpoints in one plugin instance. Each entry uses the top-level fields; id is required and other fields override defaults."
109
+ }
85
110
  }
86
111
  },
87
112
  "commandPrefix": {
88
113
  "type": "string",
89
114
  "default": "",
90
- "description": "命令前缀(默认 '' 无前缀,任意文本按命令匹配;如 '/' 要求 / 开头)。endpoints[i] 可逐项覆盖"
115
+ "description": "命令前缀(默认 '' 无前缀,任意文本按命令匹配;如 '/' 要求 / 开头)。endpoints[i] 可逐项覆盖",
116
+ "x-i18n": {
117
+ "en": {
118
+ "description": "Command prefix. The default empty string allows unprefixed commands; '/' requires a leading slash. Each endpoints[i] can override it."
119
+ }
120
+ }
91
121
  }
92
122
  },
93
123
  "required": [