@zhin.js/adapter-slack 1.1.25 → 1.1.26

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,14 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.1.26
4
+
5
+ ### Patch Changes
6
+
7
+ - 0d76a7c: Overhaul Console interactive workbenches, platform-specific adapter account onboarding/login flows, DeclarativePageView visual/interactive capabilities, and official utility plugin Console pages.
8
+ - Updated dependencies [0d76a7c]
9
+ - @zhin.js/adapter@1.1.32
10
+ - @zhin.js/core@1.1.60
11
+
3
12
  ## 1.1.25
4
13
 
5
14
  ### Patch Changes
@@ -2,17 +2,125 @@ export const slackConsoleSpec = {
2
2
  adapterKey: 'slack',
3
3
  adapterDisplayName: 'Slack',
4
4
  fields: [
5
- { key: 'token', required: true, env: true, description: 'Bot User OAuth Token(xoxb-...)' },
6
- { key: 'signingSecret', env: true, description: '签名密钥(HTTP Events,socketMode: false 必填)', descriptionI18n: { en: 'Signing secret (required for HTTP Events)' } },
7
- { key: 'appToken', env: true, description: 'App-Level Token(xapp-...,Socket Mode)', descriptionI18n: { en: 'App-level token (xapp-..., Socket Mode)' } },
8
- { key: 'socketMode', type: 'boolean', description: 'Socket Mode; false selects HTTP Events' },
9
- { key: 'streaming', type: 'boolean', description: '生成时逐步显示回复', descriptionI18n: { en: 'Show replies progressively while generating' } },
10
- { key: 'streamingIntervalMs', type: 'number', description: '回复更新间隔(毫秒)', descriptionI18n: { en: 'Reply update interval in milliseconds' } },
11
- { key: 'webhookPath', description: 'HTTP Events route' },
12
- { key: 'clientPingTimeout', type: 'number', description: 'SDK client ping timeout in milliseconds' },
13
- { key: 'webApiProxy.port', type: 'number', description: 'Configured Web API loopback proxy port' },
14
- { key: 'streamProxy.port', type: 'number', description: 'Configured Socket Mode loopback proxy port' },
15
- { key: 'streamProxy.serverName', description: 'Expected Socket Mode TLS hostname' },
5
+ {
6
+ key: 'token',
7
+ required: true,
8
+ env: true,
9
+ label: 'Bot User OAuth Token',
10
+ labelI18n: { en: 'Bot User OAuth Token' },
11
+ group: '基础认证',
12
+ groupI18n: { en: 'Basic Auth' },
13
+ placeholder: 'xoxb-...',
14
+ description: 'Bot User OAuth Token(xoxb-...)',
15
+ descriptionI18n: { en: 'Bot User OAuth Token (xoxb-...)' },
16
+ },
17
+ {
18
+ key: 'appToken',
19
+ env: true,
20
+ label: 'App-Level Token (Socket Mode)',
21
+ labelI18n: { en: 'App-Level Token' },
22
+ group: '基础认证',
23
+ groupI18n: { en: 'Basic Auth' },
24
+ placeholder: 'xapp-...',
25
+ description: 'App-Level Token(xapp-...,Socket Mode)',
26
+ descriptionI18n: { en: 'App-level token (xapp-..., Socket Mode)' },
27
+ },
28
+ {
29
+ key: 'signingSecret',
30
+ env: true,
31
+ label: 'Signing Secret (签名密钥)',
32
+ labelI18n: { en: 'Signing Secret' },
33
+ group: '基础认证',
34
+ groupI18n: { en: 'Basic Auth' },
35
+ placeholder: '32 位十六进制签名密钥',
36
+ placeholderI18n: { en: 'Slack app signing secret' },
37
+ description: '签名密钥(HTTP Events,socketMode: false 必填)',
38
+ descriptionI18n: { en: 'Signing secret (required for HTTP Events)' },
39
+ },
40
+ {
41
+ key: 'socketMode',
42
+ type: 'boolean',
43
+ label: '启用 Socket Mode',
44
+ labelI18n: { en: 'Enable Socket Mode' },
45
+ group: '连接与回调',
46
+ groupI18n: { en: 'Connection & Webhook' },
47
+ description: '开启后使用 WebSocket 长连接;关闭则使用 HTTP Events 回调',
48
+ descriptionI18n: { en: 'Socket Mode; false selects HTTP Events' },
49
+ },
50
+ {
51
+ key: 'webhookPath',
52
+ label: 'HTTP Events 本地路由',
53
+ labelI18n: { en: 'HTTP Events Local Path' },
54
+ group: '连接与回调',
55
+ groupI18n: { en: 'Connection & Webhook' },
56
+ placeholder: '/slack/events',
57
+ description: 'HTTP Events 模式下监听的本地路由',
58
+ descriptionI18n: { en: 'HTTP Events route' },
59
+ },
60
+ {
61
+ key: 'clientPingTimeout',
62
+ type: 'number',
63
+ label: '心跳超时时间 (ms)',
64
+ labelI18n: { en: 'Client Ping Timeout (ms)' },
65
+ group: '连接与回调',
66
+ groupI18n: { en: 'Connection & Webhook' },
67
+ placeholder: '5000',
68
+ description: 'Socket Mode 客户端心跳超时毫秒数',
69
+ descriptionI18n: { en: 'SDK client ping timeout in milliseconds' },
70
+ },
71
+ {
72
+ key: 'streaming',
73
+ type: 'boolean',
74
+ label: '流式回复',
75
+ labelI18n: { en: 'Streaming Reply' },
76
+ group: '流式体验与代理',
77
+ groupI18n: { en: 'Streaming & Proxy' },
78
+ description: '生成时逐步显示回复',
79
+ descriptionI18n: { en: 'Show replies progressively while generating' },
80
+ },
81
+ {
82
+ key: 'streamingIntervalMs',
83
+ type: 'number',
84
+ label: '流式刷新间隔 (ms)',
85
+ labelI18n: { en: 'Streaming Interval (ms)' },
86
+ group: '流式体验与代理',
87
+ groupI18n: { en: 'Streaming & Proxy' },
88
+ placeholder: '500',
89
+ description: '回复更新间隔(毫秒)',
90
+ descriptionI18n: { en: 'Reply update interval in milliseconds' },
91
+ },
92
+ {
93
+ key: 'webApiProxy.port',
94
+ type: 'number',
95
+ label: 'Web API 代理端口',
96
+ labelI18n: { en: 'Web API Proxy Port' },
97
+ group: '流式体验与代理',
98
+ groupI18n: { en: 'Streaming & Proxy' },
99
+ placeholder: '例如 7890',
100
+ description: '本地回环 Web API 代理端口(可选)',
101
+ descriptionI18n: { en: 'Configured Web API loopback proxy port' },
102
+ },
103
+ {
104
+ key: 'streamProxy.port',
105
+ type: 'number',
106
+ label: 'Socket Mode 代理端口',
107
+ labelI18n: { en: 'Socket Mode Proxy Port' },
108
+ group: '流式体验与代理',
109
+ groupI18n: { en: 'Streaming & Proxy' },
110
+ placeholder: '例如 7890',
111
+ description: '本地回环 Socket Mode 代理端口(可选)',
112
+ descriptionI18n: { en: 'Configured Socket Mode loopback proxy port' },
113
+ },
114
+ {
115
+ key: 'streamProxy.serverName',
116
+ label: 'Socket Mode TLS 主机名',
117
+ labelI18n: { en: 'Socket Mode TLS Server Name' },
118
+ group: '流式体验与代理',
119
+ groupI18n: { en: 'Streaming & Proxy' },
120
+ placeholder: 'wss-primary.slack.com',
121
+ description: '代理校验的 Socket Mode TLS 主机名(可选)',
122
+ descriptionI18n: { en: 'Expected Socket Mode TLS hostname' },
123
+ },
16
124
  ],
17
125
  docsUrl: 'https://zhin.js.org/adapters/slack',
18
126
  readPermission: 'slack:read',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zhin.js/adapter-slack",
3
- "version": "1.1.25",
3
+ "version": "1.1.26",
4
4
  "description": "Zhin.js Slack adapter for Plugin Runtime (Socket Mode / HTTP Events)",
5
5
  "type": "module",
6
6
  "main": "./lib/index.js",
@@ -33,10 +33,10 @@
33
33
  "dependencies": {
34
34
  "@slack/socket-mode": "^2.0.7",
35
35
  "@slack/web-api": "^7.19.0",
36
- "@zhin.js/adapter": "1.1.31",
36
+ "@zhin.js/adapter": "1.1.32",
37
37
  "@zhin.js/agent-feature": "1.1.16",
38
38
  "@zhin.js/console-contract": "1.1.5",
39
- "@zhin.js/core": "1.1.59",
39
+ "@zhin.js/core": "1.1.60",
40
40
  "@zhin.js/feature-kit": "1.1.15",
41
41
  "@zhin.js/host-http": "1.1.17",
42
42
  "@zhin.js/im-contract": "1.1.13",
@@ -47,12 +47,12 @@
47
47
  },
48
48
  "peerDependencies": {
49
49
  "zod": "^4.0.0",
50
- "@zhin.js/adapter": "^1.1.31",
50
+ "@zhin.js/adapter": "^1.1.32",
51
51
  "@zhin.js/command": "^1.1.17",
52
- "@zhin.js/core": "^1.1.59",
52
+ "@zhin.js/core": "^1.1.60",
53
53
  "@zhin.js/host-http": "^1.1.17",
54
54
  "@zhin.js/permission": "^1.1.15",
55
- "zhin.js": "^1.1.24"
55
+ "zhin.js": "^1.1.25"
56
56
  },
57
57
  "peerDependenciesMeta": {
58
58
  "@zhin.js/command": {
@@ -70,7 +70,7 @@
70
70
  "typescript": "^6.0.3",
71
71
  "vitest": "^4.1.10",
72
72
  "zod": "^4.4.3",
73
- "zhin.js": "1.1.24"
73
+ "zhin.js": "1.1.25"
74
74
  },
75
75
  "files": [
76
76
  "adapters",
@@ -7,17 +7,125 @@ export const slackConsoleSpec = {
7
7
  adapterKey: 'slack',
8
8
  adapterDisplayName: 'Slack',
9
9
  fields: [
10
- { key: 'token', required: true, env: true, description: 'Bot User OAuth Token(xoxb-...)' },
11
- { key: 'signingSecret', env: true, description: '签名密钥(HTTP Events,socketMode: false 必填)', descriptionI18n: { en: 'Signing secret (required for HTTP Events)' } },
12
- { key: 'appToken', env: true, description: 'App-Level Token(xapp-...,Socket Mode)', descriptionI18n: { en: 'App-level token (xapp-..., Socket Mode)' } },
13
- { key: 'socketMode', type: 'boolean', description: 'Socket Mode; false selects HTTP Events' },
14
- { key: 'streaming', type: 'boolean', description: '生成时逐步显示回复', descriptionI18n: { en: 'Show replies progressively while generating' } },
15
- { key: 'streamingIntervalMs', type: 'number', description: '回复更新间隔(毫秒)', descriptionI18n: { en: 'Reply update interval in milliseconds' } },
16
- { key: 'webhookPath', description: 'HTTP Events route' },
17
- { key: 'clientPingTimeout', type: 'number', description: 'SDK client ping timeout in milliseconds' },
18
- { key: 'webApiProxy.port', type: 'number', description: 'Configured Web API loopback proxy port' },
19
- { key: 'streamProxy.port', type: 'number', description: 'Configured Socket Mode loopback proxy port' },
20
- { key: 'streamProxy.serverName', description: 'Expected Socket Mode TLS hostname' },
10
+ {
11
+ key: 'token',
12
+ required: true,
13
+ env: true,
14
+ label: 'Bot User OAuth Token',
15
+ labelI18n: { en: 'Bot User OAuth Token' },
16
+ group: '基础认证',
17
+ groupI18n: { en: 'Basic Auth' },
18
+ placeholder: 'xoxb-...',
19
+ description: 'Bot User OAuth Token(xoxb-...)',
20
+ descriptionI18n: { en: 'Bot User OAuth Token (xoxb-...)' },
21
+ },
22
+ {
23
+ key: 'appToken',
24
+ env: true,
25
+ label: 'App-Level Token (Socket Mode)',
26
+ labelI18n: { en: 'App-Level Token' },
27
+ group: '基础认证',
28
+ groupI18n: { en: 'Basic Auth' },
29
+ placeholder: 'xapp-...',
30
+ description: 'App-Level Token(xapp-...,Socket Mode)',
31
+ descriptionI18n: { en: 'App-level token (xapp-..., Socket Mode)' },
32
+ },
33
+ {
34
+ key: 'signingSecret',
35
+ env: true,
36
+ label: 'Signing Secret (签名密钥)',
37
+ labelI18n: { en: 'Signing Secret' },
38
+ group: '基础认证',
39
+ groupI18n: { en: 'Basic Auth' },
40
+ placeholder: '32 位十六进制签名密钥',
41
+ placeholderI18n: { en: 'Slack app signing secret' },
42
+ description: '签名密钥(HTTP Events,socketMode: false 必填)',
43
+ descriptionI18n: { en: 'Signing secret (required for HTTP Events)' },
44
+ },
45
+ {
46
+ key: 'socketMode',
47
+ type: 'boolean',
48
+ label: '启用 Socket Mode',
49
+ labelI18n: { en: 'Enable Socket Mode' },
50
+ group: '连接与回调',
51
+ groupI18n: { en: 'Connection & Webhook' },
52
+ description: '开启后使用 WebSocket 长连接;关闭则使用 HTTP Events 回调',
53
+ descriptionI18n: { en: 'Socket Mode; false selects HTTP Events' },
54
+ },
55
+ {
56
+ key: 'webhookPath',
57
+ label: 'HTTP Events 本地路由',
58
+ labelI18n: { en: 'HTTP Events Local Path' },
59
+ group: '连接与回调',
60
+ groupI18n: { en: 'Connection & Webhook' },
61
+ placeholder: '/slack/events',
62
+ description: 'HTTP Events 模式下监听的本地路由',
63
+ descriptionI18n: { en: 'HTTP Events route' },
64
+ },
65
+ {
66
+ key: 'clientPingTimeout',
67
+ type: 'number',
68
+ label: '心跳超时时间 (ms)',
69
+ labelI18n: { en: 'Client Ping Timeout (ms)' },
70
+ group: '连接与回调',
71
+ groupI18n: { en: 'Connection & Webhook' },
72
+ placeholder: '5000',
73
+ description: 'Socket Mode 客户端心跳超时毫秒数',
74
+ descriptionI18n: { en: 'SDK client ping timeout in milliseconds' },
75
+ },
76
+ {
77
+ key: 'streaming',
78
+ type: 'boolean',
79
+ label: '流式回复',
80
+ labelI18n: { en: 'Streaming Reply' },
81
+ group: '流式体验与代理',
82
+ groupI18n: { en: 'Streaming & Proxy' },
83
+ description: '生成时逐步显示回复',
84
+ descriptionI18n: { en: 'Show replies progressively while generating' },
85
+ },
86
+ {
87
+ key: 'streamingIntervalMs',
88
+ type: 'number',
89
+ label: '流式刷新间隔 (ms)',
90
+ labelI18n: { en: 'Streaming Interval (ms)' },
91
+ group: '流式体验与代理',
92
+ groupI18n: { en: 'Streaming & Proxy' },
93
+ placeholder: '500',
94
+ description: '回复更新间隔(毫秒)',
95
+ descriptionI18n: { en: 'Reply update interval in milliseconds' },
96
+ },
97
+ {
98
+ key: 'webApiProxy.port',
99
+ type: 'number',
100
+ label: 'Web API 代理端口',
101
+ labelI18n: { en: 'Web API Proxy Port' },
102
+ group: '流式体验与代理',
103
+ groupI18n: { en: 'Streaming & Proxy' },
104
+ placeholder: '例如 7890',
105
+ description: '本地回环 Web API 代理端口(可选)',
106
+ descriptionI18n: { en: 'Configured Web API loopback proxy port' },
107
+ },
108
+ {
109
+ key: 'streamProxy.port',
110
+ type: 'number',
111
+ label: 'Socket Mode 代理端口',
112
+ labelI18n: { en: 'Socket Mode Proxy Port' },
113
+ group: '流式体验与代理',
114
+ groupI18n: { en: 'Streaming & Proxy' },
115
+ placeholder: '例如 7890',
116
+ description: '本地回环 Socket Mode 代理端口(可选)',
117
+ descriptionI18n: { en: 'Configured Socket Mode loopback proxy port' },
118
+ },
119
+ {
120
+ key: 'streamProxy.serverName',
121
+ label: 'Socket Mode TLS 主机名',
122
+ labelI18n: { en: 'Socket Mode TLS Server Name' },
123
+ group: '流式体验与代理',
124
+ groupI18n: { en: 'Streaming & Proxy' },
125
+ placeholder: 'wss-primary.slack.com',
126
+ description: '代理校验的 Socket Mode TLS 主机名(可选)',
127
+ descriptionI18n: { en: 'Expected Socket Mode TLS hostname' },
128
+ },
21
129
  ] as readonly AdapterConsoleField[],
22
130
  docsUrl: 'https://zhin.js.org/adapters/slack',
23
131
  readPermission: 'slack:read',