@lightdash-tools/cli 0.9.0 → 0.12.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/README.md +3 -3
- package/dist/commands/schema.test.js +1 -2
- package/dist/index.js +1 -1
- package/package.json +3 -3
- package/src/commands/schema.test.ts +1 -2
- package/src/index.ts +1 -1
package/README.md
CHANGED
|
@@ -29,11 +29,11 @@ The CLI requires the following environment variables (consistent with `@lightdas
|
|
|
29
29
|
- `LIGHTDASH_TOOLS_ALLOWED_PROJECT_UUIDS` - Optional comma-separated project UUIDs (restrict operations to these projects; empty = all allowed)
|
|
30
30
|
- `LIGHTDASH_TOOLS_DRY_RUN` - Set to `1`, `true`, or `yes` to simulate mutating operations without executing
|
|
31
31
|
|
|
32
|
-
Prefer env vars from the parent process. Avoid plaintext `.env` when AI agents have file access. If using `.env`, use [dotenvx](https://dotenvx.com/) for encrypted secrets. See [docs/secrets
|
|
32
|
+
Prefer env vars from the parent process. Avoid plaintext `.env` when AI agents have file access. If using `.env`, use [dotenvx](https://dotenvx.com/) for encrypted secrets. See [docs/operators/secrets.md](../../docs/operators/secrets.md).
|
|
33
33
|
|
|
34
34
|
### Agent-safe surface
|
|
35
35
|
|
|
36
|
-
CLI exposes the agent-safe operation tier (with `--safety-mode` / `--dry-run` / project allowlist). MCP ships a narrower
|
|
36
|
+
CLI exposes the agent-safe operation tier (with `--safety-mode` / `--dry-run` / project allowlist). MCP ships a narrower profile surface (semantic-layer discovery/compile) without those process knobs — see [ADR-0008](../../docs/adr/0008-mcp-request-scope-and-hardening.md). Irrecoverable actions (e.g. deleting org members) are **not** CLI or MCP tools — use `@lightdash-tools/client`. See [ADR-0004](../../docs/adr/0004-agent-safe-exposure-mcp-cli-vs-client-only.md) and [docs/operators/agent-context.md](../../docs/operators/agent-context.md).
|
|
37
37
|
|
|
38
38
|
Example:
|
|
39
39
|
|
|
@@ -230,7 +230,7 @@ The CLI validates all resource IDs (project UUIDs, slugs) before executing. Inva
|
|
|
230
230
|
- Query/fragment chars (`?`, `#`, `%`)
|
|
231
231
|
- Path traversal (`..`)
|
|
232
232
|
|
|
233
|
-
This guards against adversarial or hallucinated inputs when used by AI agents. See [docs/agent-context
|
|
233
|
+
This guards against adversarial or hallucinated inputs when used by AI agents. See [docs/operators/agent-context.md](../../docs/operators/agent-context.md) for agent-specific guidance.
|
|
234
234
|
|
|
235
235
|
## Error Handling
|
|
236
236
|
|
|
@@ -12,8 +12,7 @@ const schema_1 = require("./schema");
|
|
|
12
12
|
(0, vitest_1.expect)(schema).toHaveProperty('cliCommand', 'agents list');
|
|
13
13
|
(0, vitest_1.expect)(schema).toHaveProperty('mcpToolName', 'list_project_agents');
|
|
14
14
|
(0, vitest_1.expect)(schema).toHaveProperty('profiles');
|
|
15
|
-
(0, vitest_1.expect)(schema === null || schema === void 0 ? void 0 : schema.profiles).
|
|
16
|
-
(0, vitest_1.expect)(schema === null || schema === void 0 ? void 0 : schema.profiles).toContain('ai-agent-ops');
|
|
15
|
+
(0, vitest_1.expect)(schema === null || schema === void 0 ? void 0 : schema.profiles).toEqual(['ai-agent-ops']);
|
|
17
16
|
(0, vitest_1.expect)(schema).toHaveProperty('sensitivity', 'none');
|
|
18
17
|
});
|
|
19
18
|
(0, vitest_1.it)('returns schema for ai-agents.admin.settings.update from the operation catalog', () => {
|
package/dist/index.js
CHANGED
|
@@ -33,7 +33,7 @@ const program = new commander_1.Command();
|
|
|
33
33
|
program
|
|
34
34
|
.name('lightdash-ai')
|
|
35
35
|
.description('CLI for Lightdash AI')
|
|
36
|
-
.version('0.
|
|
36
|
+
.version('0.12.0')
|
|
37
37
|
.option('--safety-mode <mode>', 'Safety mode (read-only, write-idempotent, write-destructive)', 'read-only')
|
|
38
38
|
.option('--projects <uuids>', 'Comma-separated list of allowed project UUIDs (security guardrail)')
|
|
39
39
|
.option('--dry-run', 'Simulate mutating operations without executing (env: LIGHTDASH_TOOLS_DRY_RUN=1)');
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lightdash-tools/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.12.0",
|
|
4
4
|
"description": "CLI for Lightdash AI.",
|
|
5
5
|
"keywords": [],
|
|
6
6
|
"repository": {
|
|
@@ -18,8 +18,8 @@
|
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"commander": "^15.0.0",
|
|
20
20
|
"yaml": "^2.9.0",
|
|
21
|
-
"@lightdash-tools/client": "0.
|
|
22
|
-
"@lightdash-tools/common": "0.
|
|
21
|
+
"@lightdash-tools/client": "0.12.0",
|
|
22
|
+
"@lightdash-tools/common": "0.12.0"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"@types/node": "^25.9.3"
|
|
@@ -12,8 +12,7 @@ describe('schema command', () => {
|
|
|
12
12
|
expect(schema).toHaveProperty('cliCommand', 'agents list');
|
|
13
13
|
expect(schema).toHaveProperty('mcpToolName', 'list_project_agents');
|
|
14
14
|
expect(schema).toHaveProperty('profiles');
|
|
15
|
-
expect(schema?.profiles).
|
|
16
|
-
expect(schema?.profiles).toContain('ai-agent-ops');
|
|
15
|
+
expect(schema?.profiles).toEqual(['ai-agent-ops']);
|
|
17
16
|
expect(schema).toHaveProperty('sensitivity', 'none');
|
|
18
17
|
});
|
|
19
18
|
|
package/src/index.ts
CHANGED