@oneie/cli 4.0.6 → 4.1.0
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/dist/package.json +2 -2
- package/dist/src/plugin.js +10 -1
- package/package.json +2 -2
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oneie/cli",
|
|
3
|
-
"version": "4.0
|
|
3
|
+
"version": "4.1.0",
|
|
4
4
|
"description": "ONE agent CLI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"build": "tsc && cp package.json dist/ && chmod +x dist/src/index.js",
|
|
16
16
|
"dev": "tsx src/index.ts",
|
|
17
17
|
"typecheck": "tsc --noEmit",
|
|
18
|
-
"test": "vitest run",
|
|
18
|
+
"test": "bash ../../.claude/scripts/gate-run.sh test-cli -- vitest run",
|
|
19
19
|
"prepublishOnly": "bun run build"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
package/dist/src/plugin.js
CHANGED
|
@@ -19,8 +19,17 @@ function apiBase(opts) {
|
|
|
19
19
|
return resolveBase(opts, 'https://one.ie');
|
|
20
20
|
}
|
|
21
21
|
function bearerHeaders(workspace) {
|
|
22
|
+
// THE TOKEN IS THE PLAIN KEY -- the eleventh site of the `${slug}:${key}` bug.
|
|
23
|
+
// `requireAuth` (one.ie/web/src/lib/api-auth.ts:317) resolves a world key by
|
|
24
|
+
// PREFIX (`one-` / `osk_`), so prepending "<workspace>:" produces
|
|
25
|
+
// `one:one-abc...`, which matches no prefix, falls through to session auth and
|
|
26
|
+
// 401s. Ten call sites in agent.ts and skill.ts were fixed for exactly this;
|
|
27
|
+
// this one was missed, which broke `plugin buy` (POST /api/ask/plugins:buy,
|
|
28
|
+
// gated by requireAuth) and `plugin source` for every key-authenticated user.
|
|
29
|
+
// The workspace still gates whether we send auth at all -- it just never
|
|
30
|
+
// belonged inside the credential.
|
|
22
31
|
const key = resolveKey();
|
|
23
|
-
return key && workspace ? { Authorization: `Bearer ${
|
|
32
|
+
return key && workspace ? { Authorization: `Bearer ${key}` } : {};
|
|
24
33
|
}
|
|
25
34
|
// npm pack wraps a package's contents under a "package/" root — strip-components=1 lands
|
|
26
35
|
// the real package.json + src/ directly at ./plugin-<name>/, same as a real npm install would.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oneie/cli",
|
|
3
|
-
"version": "4.0
|
|
3
|
+
"version": "4.1.0",
|
|
4
4
|
"description": "ONE agent CLI",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
"build": "tsc && cp package.json dist/ && chmod +x dist/src/index.js",
|
|
16
16
|
"dev": "tsx src/index.ts",
|
|
17
17
|
"typecheck": "tsc --noEmit",
|
|
18
|
-
"test": "vitest run",
|
|
18
|
+
"test": "bash ../../.claude/scripts/gate-run.sh test-cli -- vitest run",
|
|
19
19
|
"prepublishOnly": "bun run build"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|