@khanglvm/outline-cli 0.1.2 → 0.1.3
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 +5 -0
- package/README.md +23 -22
- package/package.json +1 -1
- package/src/agent-skills.js +159 -22
- package/src/cli.js +4 -1
- package/src/entry-integrity-manifest.generated.js +4 -4
- package/test/agent-skills.unit.test.js +64 -1
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -1,12 +1,6 @@
|
|
|
1
1
|
# outline-cli
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
- Stable JSON envelopes
|
|
6
|
-
- Token-efficient `ids` and `summary` views
|
|
7
|
-
- Batch operations to reduce API round trips
|
|
8
|
-
- Safe mutation gates (`performAction: true`)
|
|
9
|
-
- Automatic large-result offload to temp files
|
|
3
|
+
A CLI for Outline ([`https://getoutline.com`](https://getoutline.com)) - optimized for AI agents.
|
|
10
4
|
|
|
11
5
|
## Quick Start
|
|
12
6
|
|
|
@@ -16,10 +10,12 @@ Install globally:
|
|
|
16
10
|
npm i -g @khanglvm/outline-cli
|
|
17
11
|
```
|
|
18
12
|
|
|
19
|
-
|
|
13
|
+
## Get Started with AI Agents
|
|
20
14
|
|
|
21
|
-
|
|
22
|
-
|
|
15
|
+
After installing, paste this instruction into your AI coding assistant:
|
|
16
|
+
|
|
17
|
+
```text
|
|
18
|
+
Run `outline-cli tools help quick-start-agent --view full` and follow its instructions to help me get started with Outline CLI
|
|
23
19
|
```
|
|
24
20
|
|
|
25
21
|
## Day-to-Day Usage
|
|
@@ -32,7 +28,7 @@ outline-cli tools contract documents.search --pretty
|
|
|
32
28
|
outline-cli tools contract all --result-mode inline
|
|
33
29
|
```
|
|
34
30
|
|
|
35
|
-
Read document metadata by
|
|
31
|
+
Read document metadata by ID:
|
|
36
32
|
|
|
37
33
|
```bash
|
|
38
34
|
outline-cli invoke documents.info \
|
|
@@ -64,7 +60,7 @@ outline-cli batch --ops '[
|
|
|
64
60
|
|
|
65
61
|
## Safe Delete Flow
|
|
66
62
|
|
|
67
|
-
|
|
63
|
+
Deletion is guarded by read-token confirmation.
|
|
68
64
|
|
|
69
65
|
1. Arm-delete read:
|
|
70
66
|
|
|
@@ -103,7 +99,7 @@ outline-cli tmp gc --older-than-hours 24
|
|
|
103
99
|
|
|
104
100
|
## Profile Management
|
|
105
101
|
|
|
106
|
-
Add password-mode profile:
|
|
102
|
+
Add a password-mode profile:
|
|
107
103
|
|
|
108
104
|
```bash
|
|
109
105
|
outline-cli profile add internal \
|
|
@@ -135,16 +131,21 @@ outline-cli profile enrich prod \
|
|
|
135
131
|
|
|
136
132
|
Use this short operating pattern when an AI agent drives the CLI:
|
|
137
133
|
|
|
138
|
-
1. Start with `tools
|
|
139
|
-
2.
|
|
140
|
-
3.
|
|
141
|
-
4.
|
|
142
|
-
5.
|
|
143
|
-
6.
|
|
134
|
+
1. Start with `outline-cli --version` and `tools help --view summary` to confirm onboarding help is available.
|
|
135
|
+
2. Suggest installing the `outline-cli` skill via `npx skills` for all currently supported local AI tools; only run install after explicit user approval.
|
|
136
|
+
3. If approved, run headless install without tool-specific filter: `npx skills add https://github.com/khanglvm/skills --skill outline-cli -y`.
|
|
137
|
+
4. Prefer `view:"ids"` or `view:"summary"` first; hydrate to `full` only when needed.
|
|
138
|
+
5. Bundle independent reads into one `batch` call.
|
|
139
|
+
6. For any mutation endpoint, explicitly set `performAction:true`.
|
|
140
|
+
7. For delete, always run `documents.info` with `armDelete:true` first and pass the returned read token.
|
|
141
|
+
8. List existing profiles before creating one with `outline-cli profile list --pretty`.
|
|
142
|
+
9. For new profiles, prefer API key mode and guide users through base URL + API key generation (`<base-url>/settings/api`) before `profile add`.
|
|
143
|
+
10. If output is file-offloaded, read only the required fields via `tmp cat` + `jq`.
|
|
144
144
|
|
|
145
145
|
For structured AI playbooks and scenario guides:
|
|
146
146
|
|
|
147
147
|
```bash
|
|
148
|
+
outline-cli tools help --view summary
|
|
148
149
|
outline-cli tools help quick-start-agent --view full
|
|
149
150
|
outline-cli tools help ai-skills --view summary
|
|
150
151
|
outline-cli tools help ai-skills --scenario UC-12
|
|
@@ -152,7 +153,7 @@ outline-cli tools help ai-skills --scenario UC-12
|
|
|
152
153
|
|
|
153
154
|
## Testing (Live Environment)
|
|
154
155
|
|
|
155
|
-
Set test credentials in local env file:
|
|
156
|
+
Set test credentials in a local env file:
|
|
156
157
|
|
|
157
158
|
```bash
|
|
158
159
|
cp .env.test.example .env.test.local
|
|
@@ -166,7 +167,7 @@ npm run check
|
|
|
166
167
|
npm test
|
|
167
168
|
```
|
|
168
169
|
|
|
169
|
-
Test
|
|
170
|
+
Test rules in this repository:
|
|
170
171
|
|
|
171
172
|
- Mutation tests create and clean up their own test documents.
|
|
172
173
|
- Read-only tests may use site-wide data.
|
|
@@ -204,7 +205,7 @@ Release prerequisites:
|
|
|
204
205
|
|
|
205
206
|
- Never commit real API keys.
|
|
206
207
|
- Keep local secrets in untracked files such as `.env.test.local`.
|
|
207
|
-
- Profile secrets are stored in OS keychain by default.
|
|
208
|
+
- Profile secrets are stored in the OS keychain by default.
|
|
208
209
|
|
|
209
210
|
## Reference Docs
|
|
210
211
|
|
package/package.json
CHANGED
package/src/agent-skills.js
CHANGED
|
@@ -3,64 +3,166 @@ import { CliError } from "./errors.js";
|
|
|
3
3
|
const AI_SKILL_DATA_VERSION = "2026-03-05.1";
|
|
4
4
|
const AI_HELP_SECTION_ID = "ai-skills";
|
|
5
5
|
const QUICK_START_HELP_SECTION_ID = "quick-start-agent";
|
|
6
|
-
const QUICK_START_HELP_VERSION = "2026-03-
|
|
6
|
+
const QUICK_START_HELP_VERSION = "2026-03-06.3";
|
|
7
7
|
|
|
8
8
|
const QUICK_START_AGENT_PLAYBOOK = {
|
|
9
9
|
title: "outline-cli onboarding for non-expert users",
|
|
10
10
|
audience: "AI agents assisting non-expert users in terminal setup and first usage.",
|
|
11
11
|
objective:
|
|
12
|
-
"
|
|
12
|
+
"Verify existing outline-cli installation first, discover AI onboarding commands, explicitly offer optional outline-cli skill installation via npx skills (approval-gated), list existing profiles before creating one, then guide API-key setup with domain checks and provide natural-language starter prompts.",
|
|
13
13
|
steps: [
|
|
14
14
|
{
|
|
15
15
|
step: 1,
|
|
16
|
-
title: "
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
title: "Check current installation and help command availability",
|
|
17
|
+
commands: [
|
|
18
|
+
"outline-cli --version",
|
|
19
|
+
"outline-cli --help",
|
|
20
|
+
"outline-cli tools --help",
|
|
21
|
+
"outline-cli tools help --view summary",
|
|
22
|
+
],
|
|
23
|
+
fallbackCommands: [
|
|
24
|
+
"npm i -g @khanglvm/outline-cli@latest",
|
|
25
|
+
"outline-cli --version",
|
|
26
|
+
"outline-cli tools help --view summary",
|
|
27
|
+
],
|
|
28
|
+
successCheck: "tools help output includes the quick-start-agent section",
|
|
19
29
|
},
|
|
20
30
|
{
|
|
21
31
|
step: 2,
|
|
32
|
+
title: "Load full onboarding guide for deterministic setup steps",
|
|
33
|
+
command: "outline-cli tools help quick-start-agent --view full",
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
step: 3,
|
|
37
|
+
title: "Suggest optional outline-cli skill installation via npx skills",
|
|
38
|
+
question:
|
|
39
|
+
"Would you like me to install the outline-cli skill now via npx skills for all currently supported local AI tools? This helps future AI sessions use the right workflow by default.",
|
|
40
|
+
commandTemplates: [
|
|
41
|
+
"npx skills add https://github.com/khanglvm/skills --skill outline-cli -y",
|
|
42
|
+
],
|
|
43
|
+
decisionRules: [
|
|
44
|
+
"If user explicitly approves, run the command in headless mode exactly once so installation applies to currently supported local tools.",
|
|
45
|
+
"If user declines, skip installation and continue onboarding without blocking profile setup.",
|
|
46
|
+
],
|
|
47
|
+
expectedSignals: [
|
|
48
|
+
"Successful install prints completion output from npx skills.",
|
|
49
|
+
"Failure should be reported with the exact command and next recovery step.",
|
|
50
|
+
],
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
step: 4,
|
|
22
54
|
title: "Inspect command surfaces before asking the user for inputs",
|
|
23
55
|
commands: [
|
|
24
|
-
"outline-cli --help",
|
|
25
56
|
"outline-cli profile --help",
|
|
26
|
-
"outline-cli tools --help",
|
|
27
57
|
"outline-cli invoke --help",
|
|
28
58
|
],
|
|
29
59
|
},
|
|
30
60
|
{
|
|
31
|
-
step:
|
|
32
|
-
title: "
|
|
61
|
+
step: 5,
|
|
62
|
+
title: "List existing profiles first and branch setup flow",
|
|
63
|
+
command: "outline-cli profile list --pretty",
|
|
64
|
+
decisionRules: [
|
|
65
|
+
"If one or more profiles exist, show them and ask whether to use an existing profile or create a new one.",
|
|
66
|
+
"If no profiles exist, continue with new profile setup questions.",
|
|
67
|
+
],
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
step: 6,
|
|
71
|
+
title: "Ask for Outline base URL with beginner-friendly explanation",
|
|
72
|
+
question:
|
|
73
|
+
"What is your Outline base URL? This is the web address you open in your browser to use Outline.",
|
|
74
|
+
examples: [
|
|
75
|
+
"Official cloud: https://app.getoutline.com",
|
|
76
|
+
"Custom/self-hosted: https://docs.yourcompany.com",
|
|
77
|
+
],
|
|
78
|
+
guidance: [
|
|
79
|
+
"Use https:// and do not include a trailing path.",
|
|
80
|
+
"If unsure, copy the URL from your browser while viewing your Outline workspace home.",
|
|
81
|
+
],
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
step: 7,
|
|
85
|
+
title: "Validate the provided base URL before asking for API key",
|
|
86
|
+
commandTemplates: [
|
|
87
|
+
'curl -sS -o /dev/null -w "HTTP %{http_code}\\n" "<base-url>"',
|
|
88
|
+
'curl -sS -o /dev/null -w "API %{http_code}\\n" "<base-url>/api/auth.info"',
|
|
89
|
+
],
|
|
90
|
+
expectedSignals: [
|
|
91
|
+
"Base URL check should return a reachable HTTP status (often 200/301/302).",
|
|
92
|
+
"API auth endpoint without token often returns 401/403, which still confirms domain + API route are reachable.",
|
|
93
|
+
],
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
step: 8,
|
|
97
|
+
title: "Guide user to create API key in Outline UI",
|
|
98
|
+
apiKeySettingsUrlTemplate: "<base-url>/settings/api",
|
|
99
|
+
fallbackNavigation: "In Outline UI: Settings → API Keys",
|
|
100
|
+
apiKeyConfigTemplate: [
|
|
101
|
+
"Name: outline-cli-<profile-id-or-your-name>",
|
|
102
|
+
"Expiration date: choose your policy (for example 90 days or no expiry if policy allows)",
|
|
103
|
+
"Scopes: leave empty for same permissions as your user, or restrict to needed endpoints",
|
|
104
|
+
],
|
|
105
|
+
scopeExamples: [
|
|
106
|
+
"Read-focused starter scope: *.info documents.search collections.list",
|
|
107
|
+
"Document automation scope: documents.* collections.info",
|
|
108
|
+
],
|
|
109
|
+
requiredUserAction:
|
|
110
|
+
"Create the key, then copy the generated token value (typically starts with ol_api_) and share it with the agent for profile setup.",
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
step: 9,
|
|
114
|
+
title: "Ask follow-up questions for remaining setup values (one at a time)",
|
|
33
115
|
questions: [
|
|
34
|
-
"What is your Outline base URL?",
|
|
35
116
|
"What is your Outline API key?",
|
|
36
117
|
"What profile id do you want? (default to prod if user has no preference)",
|
|
37
118
|
],
|
|
38
119
|
},
|
|
39
120
|
{
|
|
40
|
-
step:
|
|
41
|
-
title: "Guide profile setup and set it as default",
|
|
121
|
+
step: 10,
|
|
122
|
+
title: "Guide profile setup (API key mode) and set it as default",
|
|
42
123
|
command:
|
|
43
|
-
'outline-cli profile add <profile-id> --base-url <base-url> --api-key "<api-key>" --set-default',
|
|
124
|
+
'outline-cli profile add <profile-id> --base-url <base-url> --auth-type apiKey --api-key "<api-key>" --set-default',
|
|
44
125
|
},
|
|
45
126
|
{
|
|
46
|
-
step:
|
|
127
|
+
step: 11,
|
|
47
128
|
title: "Verify profile authentication",
|
|
48
129
|
command: "outline-cli profile test <profile-id> --pretty",
|
|
49
130
|
},
|
|
50
131
|
{
|
|
51
|
-
step:
|
|
52
|
-
title: "Show
|
|
132
|
+
step: 12,
|
|
133
|
+
title: "Show natural-language prompts for what the AI agent can do with outline-cli",
|
|
134
|
+
minimumPromptCount: 10,
|
|
135
|
+
naturalLanguagePrompts: [
|
|
136
|
+
"Find our onboarding checklist in Outline.",
|
|
137
|
+
"List recent documents in the Engineering collection.",
|
|
138
|
+
"Show me a summary of document <document-id>.",
|
|
139
|
+
"Create a draft release notes document with today's date.",
|
|
140
|
+
"Append a short status update to document <document-id>.",
|
|
141
|
+
"Find documents mentioning incident response in the last month.",
|
|
142
|
+
"Show who can access document <document-id>.",
|
|
143
|
+
"Compare two documents and list key differences.",
|
|
144
|
+
"Generate a TODO list from document <document-id>.",
|
|
145
|
+
"Find stale docs that have not been updated recently.",
|
|
146
|
+
],
|
|
53
147
|
commandTemplates: [
|
|
54
148
|
'outline-cli invoke documents.search --args \'{"query":"onboarding checklist","mode":"semantic","limit":5,"view":"summary"}\' --pretty',
|
|
149
|
+
'outline-cli invoke documents.list --args \'{"limit":5,"view":"summary"}\' --pretty',
|
|
55
150
|
'outline-cli invoke documents.info --args \'{"id":"<document-id>","view":"summary"}\' --pretty',
|
|
56
151
|
],
|
|
57
152
|
},
|
|
58
153
|
],
|
|
59
154
|
interactionRules: [
|
|
60
155
|
"Use short and clear explanations for beginners.",
|
|
156
|
+
"Always run installation/help discovery commands before setup questions.",
|
|
157
|
+
"Always suggest optional outline-cli skill installation via npx skills and ask for explicit approval before running install.",
|
|
158
|
+
"If approved, run npx skills installation in headless mode (`-y`, no tool-specific agent filter) and continue onboarding.",
|
|
159
|
+
"Always run profile list before profile add.",
|
|
160
|
+
"Prefer API key authentication for beginner onboarding unless the user explicitly requests another auth mode.",
|
|
161
|
+
"Explain base URL and API key steps in plain language, then validate the domain before requesting the API key.",
|
|
61
162
|
"Ask one question at a time when required information is missing.",
|
|
62
163
|
"If a command fails, explain the cause and provide the exact next command.",
|
|
63
164
|
"Confirm each step completion before moving to the next step.",
|
|
165
|
+
"After setup, provide at least 10 natural-language prompts and run one command example.",
|
|
64
166
|
],
|
|
65
167
|
};
|
|
66
168
|
|
|
@@ -707,11 +809,46 @@ function summarizeQuickStartPlaybook() {
|
|
|
707
809
|
title: QUICK_START_AGENT_PLAYBOOK.title,
|
|
708
810
|
audience: QUICK_START_AGENT_PLAYBOOK.audience,
|
|
709
811
|
objective: QUICK_START_AGENT_PLAYBOOK.objective,
|
|
710
|
-
steps: QUICK_START_AGENT_PLAYBOOK.steps.map((row) =>
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
812
|
+
steps: QUICK_START_AGENT_PLAYBOOK.steps.map((row) => {
|
|
813
|
+
const summaryRow = {
|
|
814
|
+
step: row.step,
|
|
815
|
+
title: row.title,
|
|
816
|
+
};
|
|
817
|
+
if (row.command) {
|
|
818
|
+
summaryRow.command = row.command;
|
|
819
|
+
}
|
|
820
|
+
if (Array.isArray(row.commands)) {
|
|
821
|
+
summaryRow.commands = row.commands;
|
|
822
|
+
}
|
|
823
|
+
if (Array.isArray(row.questions)) {
|
|
824
|
+
summaryRow.questions = row.questions;
|
|
825
|
+
}
|
|
826
|
+
if (row.question) {
|
|
827
|
+
summaryRow.question = row.question;
|
|
828
|
+
}
|
|
829
|
+
if (row.minimumPromptCount) {
|
|
830
|
+
summaryRow.minimumPromptCount = row.minimumPromptCount;
|
|
831
|
+
}
|
|
832
|
+
if (Array.isArray(row.commandTemplates)) {
|
|
833
|
+
summaryRow.commandTemplates = row.commandTemplates;
|
|
834
|
+
}
|
|
835
|
+
if (Array.isArray(row.decisionRules)) {
|
|
836
|
+
summaryRow.decisionRules = row.decisionRules;
|
|
837
|
+
}
|
|
838
|
+
if (Array.isArray(row.expectedSignals)) {
|
|
839
|
+
summaryRow.expectedSignals = row.expectedSignals;
|
|
840
|
+
}
|
|
841
|
+
if (row.apiKeySettingsUrlTemplate) {
|
|
842
|
+
summaryRow.apiKeySettingsUrlTemplate = row.apiKeySettingsUrlTemplate;
|
|
843
|
+
}
|
|
844
|
+
if (Array.isArray(row.apiKeyConfigTemplate)) {
|
|
845
|
+
summaryRow.apiKeyConfigTemplate = row.apiKeyConfigTemplate;
|
|
846
|
+
}
|
|
847
|
+
if (Array.isArray(row.scopeExamples)) {
|
|
848
|
+
summaryRow.scopeExamples = row.scopeExamples;
|
|
849
|
+
}
|
|
850
|
+
return summaryRow;
|
|
851
|
+
}),
|
|
715
852
|
interactionRules: QUICK_START_AGENT_PLAYBOOK.interactionRules,
|
|
716
853
|
nextCommand: "outline-cli tools help quick-start-agent --view full",
|
|
717
854
|
};
|
|
@@ -850,7 +987,7 @@ export function listHelpSections() {
|
|
|
850
987
|
id: QUICK_START_HELP_SECTION_ID,
|
|
851
988
|
title: "AI setup onboarding",
|
|
852
989
|
description:
|
|
853
|
-
"Copy-ready AI onboarding instructions to
|
|
990
|
+
"Copy-ready AI onboarding instructions to verify installation, guide API-key profile setup (including base URL + settings path), and provide natural-language starter prompts.",
|
|
854
991
|
commandExample: "outline-cli tools help quick-start-agent --view full",
|
|
855
992
|
},
|
|
856
993
|
{
|
package/src/cli.js
CHANGED
|
@@ -789,8 +789,11 @@ export async function run(argv = process.argv) {
|
|
|
789
789
|
if (
|
|
790
790
|
sectionName === "quick-start-agent" ||
|
|
791
791
|
sectionName === "quickstart-agent" ||
|
|
792
|
+
sectionName === "quick-start" ||
|
|
792
793
|
sectionName === "quickstart" ||
|
|
793
|
-
sectionName === "setup"
|
|
794
|
+
sectionName === "setup" ||
|
|
795
|
+
sectionName === "agent" ||
|
|
796
|
+
sectionName === "onboarding"
|
|
794
797
|
) {
|
|
795
798
|
await emitOutput(
|
|
796
799
|
store,
|
|
@@ -3,8 +3,8 @@ export const ENTRY_INTEGRITY_MANIFEST = Object.freeze({
|
|
|
3
3
|
version: 1,
|
|
4
4
|
algorithm: "sha256",
|
|
5
5
|
signatureAlgorithm: "sha256-salted-manifest-v1",
|
|
6
|
-
signature: "
|
|
7
|
-
generatedAt: "2026-03-
|
|
6
|
+
signature: "03f876687f3972f11cce73da3da5f5f5266536bdce151a03326a813082240016",
|
|
7
|
+
generatedAt: "2026-03-06T04:21:12.443Z",
|
|
8
8
|
files: [
|
|
9
9
|
{
|
|
10
10
|
"path": "src/action-gate.js",
|
|
@@ -12,11 +12,11 @@ export const ENTRY_INTEGRITY_MANIFEST = Object.freeze({
|
|
|
12
12
|
},
|
|
13
13
|
{
|
|
14
14
|
"path": "src/agent-skills.js",
|
|
15
|
-
"sha256": "
|
|
15
|
+
"sha256": "12d54830ec84d9e8815cd28915070453175520416c83983de2496c1734acd7a2"
|
|
16
16
|
},
|
|
17
17
|
{
|
|
18
18
|
"path": "src/cli.js",
|
|
19
|
-
"sha256": "
|
|
19
|
+
"sha256": "7959970b8e2d0d81de0c2e35201274f0d16744aaa2a73f001decfdad45c85522"
|
|
20
20
|
},
|
|
21
21
|
{
|
|
22
22
|
"path": "src/config-store.js",
|
|
@@ -18,6 +18,34 @@ test("getQuickStartAgentHelp returns summary by default", () => {
|
|
|
18
18
|
assert.equal(payload.view, "summary");
|
|
19
19
|
assert.ok(Array.isArray(payload.steps));
|
|
20
20
|
assert.ok(payload.steps.length >= 4);
|
|
21
|
+
assert.ok(
|
|
22
|
+
payload.steps.some(
|
|
23
|
+
(row) => Array.isArray(row.commands) && row.commands.includes("outline-cli --version")
|
|
24
|
+
)
|
|
25
|
+
);
|
|
26
|
+
assert.ok(
|
|
27
|
+
payload.steps.some(
|
|
28
|
+
(row) =>
|
|
29
|
+
typeof row.question === "string" &&
|
|
30
|
+
row.question.toLowerCase().includes("install the outline-cli skill")
|
|
31
|
+
)
|
|
32
|
+
);
|
|
33
|
+
assert.ok(
|
|
34
|
+
payload.steps.some(
|
|
35
|
+
(row) =>
|
|
36
|
+
Array.isArray(row.commandTemplates) &&
|
|
37
|
+
row.commandTemplates.some(
|
|
38
|
+
(cmd) => cmd.includes("npx skills add") && cmd.includes("--skill outline-cli -y") && !cmd.includes("--agent")
|
|
39
|
+
)
|
|
40
|
+
)
|
|
41
|
+
);
|
|
42
|
+
assert.ok(
|
|
43
|
+
payload.steps.some(
|
|
44
|
+
(row) =>
|
|
45
|
+
typeof row.question === "string" &&
|
|
46
|
+
row.question.toLowerCase().includes("base url")
|
|
47
|
+
)
|
|
48
|
+
);
|
|
21
49
|
assert.equal(payload.nextCommand, "outline-cli tools help quick-start-agent --view full");
|
|
22
50
|
});
|
|
23
51
|
|
|
@@ -26,7 +54,42 @@ test("getQuickStartAgentHelp returns full payload and validates view", () => {
|
|
|
26
54
|
assert.equal(payload.section, "quick-start-agent");
|
|
27
55
|
assert.equal(payload.view, "full");
|
|
28
56
|
assert.ok(Array.isArray(payload.steps));
|
|
29
|
-
assert.ok(payload.steps.some((row) => row.command === "
|
|
57
|
+
assert.ok(payload.steps.some((row) => row.command === "outline-cli profile list --pretty"));
|
|
58
|
+
assert.ok(
|
|
59
|
+
payload.steps.some(
|
|
60
|
+
(row) =>
|
|
61
|
+
row.command &&
|
|
62
|
+
row.command.includes("--auth-type apiKey") &&
|
|
63
|
+
row.command.includes("--api-key")
|
|
64
|
+
)
|
|
65
|
+
);
|
|
66
|
+
assert.ok(
|
|
67
|
+
payload.steps.some(
|
|
68
|
+
(row) =>
|
|
69
|
+
Array.isArray(row.commandTemplates) &&
|
|
70
|
+
row.commandTemplates.includes(
|
|
71
|
+
"npx skills add https://github.com/khanglvm/skills --skill outline-cli -y"
|
|
72
|
+
) &&
|
|
73
|
+
Array.isArray(row.decisionRules) &&
|
|
74
|
+
row.decisionRules.some((rule) => rule.toLowerCase().includes("explicitly approves"))
|
|
75
|
+
)
|
|
76
|
+
);
|
|
77
|
+
assert.ok(
|
|
78
|
+
payload.steps.some(
|
|
79
|
+
(row) =>
|
|
80
|
+
row.apiKeySettingsUrlTemplate === "<base-url>/settings/api" &&
|
|
81
|
+
Array.isArray(row.apiKeyConfigTemplate) &&
|
|
82
|
+
row.apiKeyConfigTemplate.length >= 3
|
|
83
|
+
)
|
|
84
|
+
);
|
|
85
|
+
assert.ok(
|
|
86
|
+
payload.steps.some(
|
|
87
|
+
(row) =>
|
|
88
|
+
row.minimumPromptCount >= 10 &&
|
|
89
|
+
Array.isArray(row.naturalLanguagePrompts) &&
|
|
90
|
+
row.naturalLanguagePrompts.length >= 10
|
|
91
|
+
)
|
|
92
|
+
);
|
|
30
93
|
assert.ok(Array.isArray(payload.interactionRules));
|
|
31
94
|
|
|
32
95
|
assert.throws(
|