@seclai/cli 1.1.0 → 1.2.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 +108 -1
- package/dist/cli.js +971 -157
- package/dist/cli.js.map +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -17,12 +17,39 @@ Or run directly via npx (no install needed):
|
|
|
17
17
|
npx @seclai/cli agents list
|
|
18
18
|
```
|
|
19
19
|
|
|
20
|
+
### Setup Skills and MCP
|
|
21
|
+
|
|
22
|
+
If you are using an AI coding agent like Claude Code, you can also install the skill individually with:
|
|
23
|
+
|
|
24
|
+
```sh
|
|
25
|
+
seclai skills install
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
This installs skills into all detected coding editors by default. Use `--tool <tool>` to scope it to one editor.
|
|
29
|
+
|
|
30
|
+
To install the Seclai MCP server into your editors (Cursor, Claude Code, VS Code, etc.):
|
|
31
|
+
|
|
32
|
+
```sh
|
|
33
|
+
seclai mcp configure --key "$SECLAI_API_KEY"
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
Or directly via npx:
|
|
37
|
+
|
|
38
|
+
```sh
|
|
39
|
+
npx skills add seclai/seclai-cli --full-depth --global --all
|
|
40
|
+
npx add-mcp https://api.seclai.com/mcp --header "X-API-Key: $SECLAI_API_KEY" --name Seclai
|
|
41
|
+
```
|
|
42
|
+
|
|
20
43
|
## Documentation
|
|
21
44
|
|
|
22
|
-
Command reference (latest): https://seclai.github.io/seclai-cli/1.
|
|
45
|
+
Command reference (latest): https://seclai.github.io/seclai-cli/1.2.0/
|
|
23
46
|
|
|
24
47
|
## Authentication
|
|
25
48
|
|
|
49
|
+
The CLI supports two authentication methods:
|
|
50
|
+
|
|
51
|
+
### API Key
|
|
52
|
+
|
|
26
53
|
Set the `SECLAI_API_KEY` environment variable, or pass `--api-key` per-command:
|
|
27
54
|
|
|
28
55
|
```bash
|
|
@@ -32,18 +59,61 @@ export SECLAI_API_KEY="sk-..."
|
|
|
32
59
|
seclai --api-key "$SECLAI_API_KEY" agents list
|
|
33
60
|
```
|
|
34
61
|
|
|
62
|
+
### SSO (OAuth2 Bearer Token)
|
|
63
|
+
|
|
64
|
+
SSO works out of the box with built-in production defaults — no configuration needed:
|
|
65
|
+
|
|
66
|
+
```bash
|
|
67
|
+
# Authenticate via browser (Authorization Code + PKCE)
|
|
68
|
+
seclai auth login
|
|
69
|
+
|
|
70
|
+
# Check authentication status
|
|
71
|
+
seclai auth status
|
|
72
|
+
|
|
73
|
+
# Refresh tokens manually
|
|
74
|
+
seclai auth refresh
|
|
75
|
+
|
|
76
|
+
# Log out (clears cached tokens)
|
|
77
|
+
seclai auth logout
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
For custom SSO settings (e.g. staging environment), use `seclai configure sso`
|
|
81
|
+
or set environment variables:
|
|
82
|
+
|
|
83
|
+
| Variable | Description | Default |
|
|
84
|
+
|---|---|---|
|
|
85
|
+
| `SECLAI_SSO_DOMAIN` | Cognito domain | `auth.seclai.com` |
|
|
86
|
+
| `SECLAI_SSO_CLIENT_ID` | Cognito app client ID | `4bgf8v9qmc5puivbaqon9n5lmr` |
|
|
87
|
+
| `SECLAI_SSO_REGION` | AWS region | `us-west-2` |
|
|
88
|
+
|
|
89
|
+
Use a named profile with `--profile`:
|
|
90
|
+
|
|
91
|
+
```bash
|
|
92
|
+
seclai --profile staging agents list
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
Tokens are cached in `~/.seclai/sso/cache/` and auto-refreshed when expired.
|
|
96
|
+
|
|
35
97
|
## Environment Variables
|
|
36
98
|
|
|
37
99
|
| Variable | Description |
|
|
38
100
|
|---|---|
|
|
39
101
|
| `SECLAI_API_KEY` | Default API key (alternative to `--api-key`) |
|
|
40
102
|
| `SECLAI_API_URL` | Override API base URL (default: `https://api.seclai.com`) |
|
|
103
|
+
| `SECLAI_PROFILE` | Default SSO profile name (default: `default`) |
|
|
104
|
+
| `SECLAI_CONFIG_DIR` | Config directory path (default: `~/.seclai`) |
|
|
105
|
+
| `SECLAI_SSO_DOMAIN` | Override SSO domain (default: `auth.seclai.com`) |
|
|
106
|
+
| `SECLAI_SSO_CLIENT_ID` | Override SSO client ID (default: `4bgf8v9qmc5puivbaqon9n5lmr`) |
|
|
107
|
+
| `SECLAI_SSO_REGION` | Override SSO region (default: `us-west-2`) |
|
|
41
108
|
|
|
42
109
|
## Global Options
|
|
43
110
|
|
|
44
111
|
| Flag | Description |
|
|
45
112
|
|---|---|
|
|
46
113
|
| `--api-key <key>` | Seclai API key |
|
|
114
|
+
| `--profile <name>` | SSO profile name |
|
|
115
|
+
| `--account-id <id>` | Account ID (`X-Account-Id` header) |
|
|
116
|
+
| `--config-dir <path>` | Config directory path |
|
|
47
117
|
| `--compact` | Output compact (single-line) JSON |
|
|
48
118
|
| `-V, --version` | Print version |
|
|
49
119
|
|
|
@@ -388,6 +458,43 @@ Skills follow the [Agent Skills specification](https://agentskills.io/specificat
|
|
|
388
458
|
| Gemini | `.gemini/seclai-cli/` |
|
|
389
459
|
| Antigravity | `.antigravity/seclai-cli/` |
|
|
390
460
|
|
|
461
|
+
You can also install skills using the [skills CLI](https://github.com/vercel-labs/skills):
|
|
462
|
+
|
|
463
|
+
```bash
|
|
464
|
+
npx skills add seclai/seclai-cli
|
|
465
|
+
```
|
|
466
|
+
|
|
467
|
+
### MCP Server
|
|
468
|
+
|
|
469
|
+
Configure the [Seclai MCP server](https://github.com/seclai/seclai-mcp) for AI coding tools:
|
|
470
|
+
|
|
471
|
+
```bash
|
|
472
|
+
# Auto-detect tools and write MCP config
|
|
473
|
+
seclai mcp configure --key YOUR_API_KEY
|
|
474
|
+
|
|
475
|
+
# Target a specific tool
|
|
476
|
+
seclai mcp configure --key YOUR_API_KEY --target claude-code
|
|
477
|
+
seclai mcp configure --key YOUR_API_KEY --target cursor
|
|
478
|
+
seclai mcp configure --key YOUR_API_KEY --target claude-desktop
|
|
479
|
+
seclai mcp configure --key YOUR_API_KEY --target windsurf
|
|
480
|
+
|
|
481
|
+
# Configure all known targets
|
|
482
|
+
seclai mcp configure --key YOUR_API_KEY --target all
|
|
483
|
+
|
|
484
|
+
# Show the MCP config snippet (for manual setup)
|
|
485
|
+
seclai mcp show
|
|
486
|
+
seclai mcp show --key YOUR_API_KEY
|
|
487
|
+
```
|
|
488
|
+
|
|
489
|
+
| Target | Config File | Scope |
|
|
490
|
+
|---|---|---|
|
|
491
|
+
| claude-code | `.mcp.json` | Project |
|
|
492
|
+
| cursor | `.cursor/mcp.json` | Project |
|
|
493
|
+
| claude-desktop | `~/Library/Application Support/Claude/claude_desktop_config.json` | Global |
|
|
494
|
+
| windsurf | `~/.codeium/windsurf/mcp_config.json` | Global |
|
|
495
|
+
|
|
496
|
+
The command merges into existing config files — it won't overwrite other MCP servers.
|
|
497
|
+
|
|
391
498
|
### Shell Completion
|
|
392
499
|
|
|
393
500
|
Generate shell completion scripts for tab-completion of commands:
|