@zhin.js/plugin-60s 1.1.17 → 1.1.19

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/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 凉菜
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -24,6 +24,10 @@ plugins:
24
24
 
25
25
  每个插件实例拥有独立的 API Client。配置更新由当前 generation 的 Client 即时读取,多个实例不会共享或覆盖运行时地址。
26
26
 
27
+ ## 分层配置(ADR 0050 / 0055)
28
+
29
+ `apiBase` 只能在全局层修改;启停开关支持适配器、账号与会话四级,可在 Console「功能」区或群内 `功能 关闭 60s`(需开启 `features.selfService.enabled` 且有 `admin` 角色)按群关闭。插件没有主动推送。
30
+
27
31
  ## 功能列表
28
32
 
29
33
  | 命令 | 别名 | 说明 |
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zhin.js/plugin-60s",
3
- "version": "1.1.17",
3
+ "version": "1.1.19",
4
4
  "description": "60s API aggregation plugin for Zhin.js — news, weather, hot searches, utilities (Plugin Runtime)",
5
5
  "type": "module",
6
6
  "main": "./lib/index.js",
@@ -18,7 +18,6 @@
18
18
  "commands",
19
19
  "src",
20
20
  "lib",
21
- "tools",
22
21
  "skills",
23
22
  "README.md"
24
23
  ],
@@ -45,26 +44,22 @@
45
44
  },
46
45
  "license": "MIT",
47
46
  "dependencies": {
48
- "@zhin.js/tool": "1.1.17",
49
- "@zhin.js/skill": "1.1.15"
47
+ "zod": "^4.6.7",
48
+ "@zhin.js/skill": "1.1.17",
49
+ "@zhin.js/tool": "1.1.19"
50
50
  },
51
51
  "devDependencies": {
52
52
  "typescript": "^6.0.3",
53
53
  "vitest": "^4.1.10",
54
- "zod": "^4.4.3",
55
- "zhin.js": "1.1.23"
54
+ "zhin.js": "1.1.26"
56
55
  },
57
56
  "peerDependencies": {
58
- "zod": "^4.0.0",
59
- "@zhin.js/command": "^1.1.16",
60
- "zhin.js": "^1.1.23"
57
+ "@zhin.js/command": "^1.2.0",
58
+ "zhin.js": "^1.1.26"
61
59
  },
62
60
  "peerDependenciesMeta": {
63
61
  "@zhin.js/command": {
64
62
  "optional": true
65
- },
66
- "zod": {
67
- "optional": true
68
63
  }
69
64
  },
70
65
  "repository": {
@@ -104,6 +99,6 @@
104
99
  "scripts": {
105
100
  "build": "tsc",
106
101
  "clean": "rimraf lib",
107
- "test": "NODE_OPTIONS=--experimental-strip-types vitest run --root ../../.. plugins/utils/60s/tests"
102
+ "test": "vitest run --root ../../.. plugins/utils/60s/tests"
108
103
  }
109
104
  }
package/schema.json CHANGED
@@ -2,11 +2,24 @@
2
2
  "$schema": "https://json-schema.org/draft/2020-12/schema",
3
3
  "type": "object",
4
4
  "additionalProperties": false,
5
+ "x-zhin-config": {
6
+ "levels": [
7
+ "global",
8
+ "adapter",
9
+ "endpoint",
10
+ "conversation"
11
+ ]
12
+ },
5
13
  "properties": {
6
14
  "apiBase": {
7
15
  "type": "string",
8
16
  "default": "https://60s.viki.moe",
9
- "description": "60s API base URL"
17
+ "description": "60s API base URL",
18
+ "x-zhin-config": {
19
+ "levels": [
20
+ "global"
21
+ ]
22
+ }
10
23
  }
11
24
  }
12
25
  }