@howlil/ez-agents 3.4.1 → 3.5.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.
Files changed (162) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +84 -20
  3. package/agents/ez-observer-agent.md +260 -0
  4. package/agents/ez-release-agent.md +333 -0
  5. package/agents/ez-requirements-agent.md +377 -0
  6. package/agents/ez-scrum-master-agent.md +242 -0
  7. package/agents/ez-tech-lead-agent.md +267 -0
  8. package/bin/install.js +3221 -3230
  9. package/commands/ez/arch-review.md +102 -0
  10. package/commands/ez/execute-phase.md +11 -0
  11. package/commands/ez/export-session.md +79 -0
  12. package/commands/ez/gather-requirements.md +117 -0
  13. package/commands/ez/git-workflow.md +72 -0
  14. package/commands/ez/hotfix.md +120 -0
  15. package/commands/ez/import-session.md +82 -0
  16. package/commands/ez/join-discord.md +18 -18
  17. package/commands/ez/list-sessions.md +96 -0
  18. package/commands/ez/package-manager.md +316 -0
  19. package/commands/ez/plan-phase.md +9 -1
  20. package/commands/ez/preflight.md +79 -0
  21. package/commands/ez/progress.md +13 -1
  22. package/commands/ez/release.md +153 -0
  23. package/commands/ez/resume.md +107 -0
  24. package/commands/ez/standup.md +85 -0
  25. package/ez-agents/bin/ez-tools.cjs +1095 -716
  26. package/ez-agents/bin/lib/assistant-adapter.cjs +264 -264
  27. package/ez-agents/bin/lib/audit-exec.cjs +7 -2
  28. package/ez-agents/bin/lib/bdd-validator.cjs +622 -0
  29. package/ez-agents/bin/lib/circuit-breaker.cjs +118 -118
  30. package/ez-agents/bin/lib/config.cjs +190 -190
  31. package/ez-agents/bin/lib/content-scanner.cjs +238 -0
  32. package/ez-agents/bin/lib/context-cache.cjs +154 -0
  33. package/ez-agents/bin/lib/context-errors.cjs +71 -0
  34. package/ez-agents/bin/lib/context-manager.cjs +220 -0
  35. package/ez-agents/bin/lib/discussion-synthesizer.cjs +458 -0
  36. package/ez-agents/bin/lib/file-access.cjs +207 -0
  37. package/ez-agents/bin/lib/file-lock.cjs +236 -236
  38. package/ez-agents/bin/lib/frontmatter.cjs +299 -299
  39. package/ez-agents/bin/lib/fs-utils.cjs +153 -153
  40. package/ez-agents/bin/lib/git-errors.cjs +83 -0
  41. package/ez-agents/bin/lib/git-utils.cjs +118 -0
  42. package/ez-agents/bin/lib/git-workflow-engine.cjs +1157 -0
  43. package/ez-agents/bin/lib/index.cjs +157 -113
  44. package/ez-agents/bin/lib/init.cjs +757 -757
  45. package/ez-agents/bin/lib/lockfile-validator.cjs +227 -0
  46. package/ez-agents/bin/lib/logger.cjs +124 -124
  47. package/ez-agents/bin/lib/memory-compression.cjs +256 -0
  48. package/ez-agents/bin/lib/metrics-tracker.cjs +406 -0
  49. package/ez-agents/bin/lib/milestone.cjs +241 -241
  50. package/ez-agents/bin/lib/model-provider.cjs +241 -241
  51. package/ez-agents/bin/lib/package-manager-detector.cjs +203 -0
  52. package/ez-agents/bin/lib/package-manager-executor.cjs +385 -0
  53. package/ez-agents/bin/lib/package-manager-service.cjs +216 -0
  54. package/ez-agents/bin/lib/phase.cjs +925 -925
  55. package/ez-agents/bin/lib/planning-write.cjs +107 -107
  56. package/ez-agents/bin/lib/release-validator.cjs +614 -0
  57. package/ez-agents/bin/lib/retry.cjs +119 -119
  58. package/ez-agents/bin/lib/roadmap.cjs +306 -306
  59. package/ez-agents/bin/lib/safe-exec.cjs +128 -128
  60. package/ez-agents/bin/lib/safe-path.cjs +130 -130
  61. package/ez-agents/bin/lib/session-chain.cjs +304 -0
  62. package/ez-agents/bin/lib/session-errors.cjs +81 -0
  63. package/ez-agents/bin/lib/session-export.cjs +251 -0
  64. package/ez-agents/bin/lib/session-import.cjs +262 -0
  65. package/ez-agents/bin/lib/session-manager.cjs +280 -0
  66. package/ez-agents/bin/lib/state.cjs +736 -736
  67. package/ez-agents/bin/lib/temp-file.cjs +239 -239
  68. package/ez-agents/bin/lib/template.cjs +223 -223
  69. package/ez-agents/bin/lib/test-file-lock.cjs +112 -112
  70. package/ez-agents/bin/lib/test-graceful.cjs +93 -93
  71. package/ez-agents/bin/lib/test-logger.cjs +60 -60
  72. package/ez-agents/bin/lib/test-safe-exec.cjs +38 -38
  73. package/ez-agents/bin/lib/test-safe-path.cjs +33 -33
  74. package/ez-agents/bin/lib/test-temp-file.cjs +125 -125
  75. package/ez-agents/bin/lib/tier-manager.cjs +428 -0
  76. package/ez-agents/bin/lib/timeout-exec.cjs +63 -63
  77. package/ez-agents/bin/lib/url-fetch.cjs +170 -0
  78. package/ez-agents/bin/lib/verify.cjs +15 -1
  79. package/ez-agents/references/checkpoints.md +776 -776
  80. package/ez-agents/references/continuation-format.md +249 -249
  81. package/ez-agents/references/metrics-schema.md +118 -0
  82. package/ez-agents/references/planning-config.md +140 -0
  83. package/ez-agents/references/questioning.md +162 -162
  84. package/ez-agents/references/tdd.md +263 -263
  85. package/ez-agents/references/tier-strategy.md +103 -0
  86. package/ez-agents/templates/bdd-feature.md +173 -0
  87. package/ez-agents/templates/codebase/concerns.md +310 -310
  88. package/ez-agents/templates/codebase/conventions.md +307 -307
  89. package/ez-agents/templates/codebase/integrations.md +280 -280
  90. package/ez-agents/templates/codebase/stack.md +186 -186
  91. package/ez-agents/templates/codebase/testing.md +480 -480
  92. package/ez-agents/templates/config.json +37 -37
  93. package/ez-agents/templates/continue-here.md +78 -78
  94. package/ez-agents/templates/discussion.md +68 -0
  95. package/ez-agents/templates/incident-runbook.md +205 -0
  96. package/ez-agents/templates/milestone-archive.md +123 -123
  97. package/ez-agents/templates/milestone.md +115 -115
  98. package/ez-agents/templates/release-checklist.md +133 -0
  99. package/ez-agents/templates/requirements.md +231 -231
  100. package/ez-agents/templates/research-project/ARCHITECTURE.md +204 -204
  101. package/ez-agents/templates/research-project/FEATURES.md +147 -147
  102. package/ez-agents/templates/research-project/PITFALLS.md +200 -200
  103. package/ez-agents/templates/research-project/STACK.md +120 -120
  104. package/ez-agents/templates/research-project/SUMMARY.md +170 -170
  105. package/ez-agents/templates/retrospective.md +54 -54
  106. package/ez-agents/templates/roadmap.md +202 -202
  107. package/ez-agents/templates/rollback-plan.md +201 -0
  108. package/ez-agents/templates/summary-minimal.md +41 -41
  109. package/ez-agents/templates/summary-standard.md +48 -48
  110. package/ez-agents/templates/summary.md +248 -248
  111. package/ez-agents/templates/user-setup.md +311 -311
  112. package/ez-agents/templates/verification-report.md +322 -322
  113. package/ez-agents/workflows/add-phase.md +112 -112
  114. package/ez-agents/workflows/add-tests.md +351 -351
  115. package/ez-agents/workflows/add-todo.md +158 -158
  116. package/ez-agents/workflows/arch-review.md +54 -0
  117. package/ez-agents/workflows/audit-milestone.md +332 -332
  118. package/ez-agents/workflows/autonomous.md +131 -30
  119. package/ez-agents/workflows/check-todos.md +177 -177
  120. package/ez-agents/workflows/cleanup.md +152 -152
  121. package/ez-agents/workflows/complete-milestone.md +766 -766
  122. package/ez-agents/workflows/diagnose-issues.md +219 -219
  123. package/ez-agents/workflows/discovery-phase.md +289 -289
  124. package/ez-agents/workflows/discuss-phase.md +762 -762
  125. package/ez-agents/workflows/execute-phase.md +513 -468
  126. package/ez-agents/workflows/execute-plan.md +483 -483
  127. package/ez-agents/workflows/export-session.md +255 -0
  128. package/ez-agents/workflows/gather-requirements.md +206 -0
  129. package/ez-agents/workflows/health.md +159 -159
  130. package/ez-agents/workflows/help.md +584 -492
  131. package/ez-agents/workflows/hotfix.md +291 -0
  132. package/ez-agents/workflows/import-session.md +303 -0
  133. package/ez-agents/workflows/insert-phase.md +130 -130
  134. package/ez-agents/workflows/list-phase-assumptions.md +178 -178
  135. package/ez-agents/workflows/map-codebase.md +316 -316
  136. package/ez-agents/workflows/new-milestone.md +339 -10
  137. package/ez-agents/workflows/new-project.md +293 -299
  138. package/ez-agents/workflows/node-repair.md +92 -92
  139. package/ez-agents/workflows/pause-work.md +122 -122
  140. package/ez-agents/workflows/plan-milestone-gaps.md +274 -274
  141. package/ez-agents/workflows/plan-phase.md +673 -651
  142. package/ez-agents/workflows/progress.md +372 -382
  143. package/ez-agents/workflows/quick.md +610 -610
  144. package/ez-agents/workflows/release.md +253 -0
  145. package/ez-agents/workflows/remove-phase.md +155 -155
  146. package/ez-agents/workflows/research-phase.md +74 -74
  147. package/ez-agents/workflows/resume-project.md +307 -307
  148. package/ez-agents/workflows/resume-session.md +215 -0
  149. package/ez-agents/workflows/set-profile.md +81 -81
  150. package/ez-agents/workflows/settings.md +242 -242
  151. package/ez-agents/workflows/standup.md +64 -0
  152. package/ez-agents/workflows/stats.md +57 -57
  153. package/ez-agents/workflows/transition.md +544 -544
  154. package/ez-agents/workflows/ui-phase.md +290 -290
  155. package/ez-agents/workflows/ui-review.md +157 -157
  156. package/ez-agents/workflows/update.md +320 -320
  157. package/ez-agents/workflows/validate-phase.md +167 -167
  158. package/ez-agents/workflows/verify-phase.md +243 -243
  159. package/ez-agents/workflows/verify-work.md +584 -584
  160. package/package.json +10 -4
  161. package/scripts/build-hooks.js +43 -43
  162. package/scripts/run-tests.cjs +29 -29
@@ -1,311 +1,311 @@
1
- # User Setup Template
2
-
3
- Template for `.planning/phases/XX-name/{phase}-USER-SETUP.md` - human-required configuration that Claude cannot automate.
4
-
5
- **Purpose:** Document setup tasks that literally require human action - account creation, dashboard configuration, secret retrieval. Claude automates everything possible; this file captures only what remains.
6
-
7
- ---
8
-
9
- ## File Template
10
-
11
- ```markdown
12
- # Phase {X}: User Setup Required
13
-
14
- **Generated:** [YYYY-MM-DD]
15
- **Phase:** {phase-name}
16
- **Status:** Incomplete
17
-
18
- Complete these items for the integration to function. Claude automated everything possible; these items require human access to external dashboards/accounts.
19
-
20
- ## Environment Variables
21
-
22
- | Status | Variable | Source | Add to |
23
- |--------|----------|--------|--------|
24
- | [ ] | `ENV_VAR_NAME` | [Service Dashboard → Path → To → Value] | `.env.local` |
25
- | [ ] | `ANOTHER_VAR` | [Service Dashboard → Path → To → Value] | `.env.local` |
26
-
27
- ## Account Setup
28
-
29
- [Only if new account creation is required]
30
-
31
- - [ ] **Create [Service] account**
32
- - URL: [signup URL]
33
- - Skip if: Already have account
34
-
35
- ## Dashboard Configuration
36
-
37
- [Only if dashboard configuration is required]
38
-
39
- - [ ] **[Configuration task]**
40
- - Location: [Service Dashboard → Path → To → Setting]
41
- - Set to: [Required value or configuration]
42
- - Notes: [Any important details]
43
-
44
- ## Verification
45
-
46
- After completing setup, verify with:
47
-
48
- ```bash
49
- # [Verification commands]
50
- ```
51
-
52
- Expected results:
53
- - [What success looks like]
54
-
55
- ---
56
-
57
- **Once all items complete:** Mark status as "Complete" at top of file.
58
- ```
59
-
60
- ---
61
-
62
- ## When to Generate
63
-
64
- Generate `{phase}-USER-SETUP.md` when plan frontmatter contains `user_setup` field.
65
-
66
- **Trigger:** `user_setup` exists in PLAN.md frontmatter and has items.
67
-
68
- **Location:** Same directory as PLAN.md and SUMMARY.md.
69
-
70
- **Timing:** Generated during execute-plan.md after tasks complete, before SUMMARY.md creation.
71
-
72
- ---
73
-
74
- ## Frontmatter Schema
75
-
76
- In PLAN.md, `user_setup` declares human-required configuration:
77
-
78
- ```yaml
79
- user_setup:
80
- - service: stripe
81
- why: "Payment processing requires API keys"
82
- env_vars:
83
- - name: STRIPE_SECRET_KEY
84
- source: "Stripe Dashboard → Developers → API keys → Secret key"
85
- - name: STRIPE_WEBHOOK_SECRET
86
- source: "Stripe Dashboard → Developers → Webhooks → Signing secret"
87
- dashboard_config:
88
- - task: "Create webhook endpoint"
89
- location: "Stripe Dashboard → Developers → Webhooks → Add endpoint"
90
- details: "URL: https://[your-domain]/api/webhooks/stripe, Events: checkout.session.completed, customer.subscription.*"
91
- local_dev:
92
- - "Run: stripe listen --forward-to localhost:3000/api/webhooks/stripe"
93
- - "Use the webhook secret from CLI output for local testing"
94
- ```
95
-
96
- ---
97
-
98
- ## The Automation-First Rule
99
-
100
- **USER-SETUP.md contains ONLY what Claude literally cannot do.**
101
-
102
- | Claude CAN Do (not in USER-SETUP) | Claude CANNOT Do (→ USER-SETUP) |
103
- |-----------------------------------|--------------------------------|
104
- | `npm install stripe` | Create Stripe account |
105
- | Write webhook handler code | Get API keys from dashboard |
106
- | Create `.env.local` file structure | Copy actual secret values |
107
- | Run `stripe listen` | Authenticate Stripe CLI (browser OAuth) |
108
- | Configure package.json | Access external service dashboards |
109
- | Write any code | Retrieve secrets from third-party systems |
110
-
111
- **The test:** "Does this require a human in a browser, accessing an account Claude doesn't have credentials for?"
112
- - Yes → USER-SETUP.md
113
- - No → Claude does it automatically
114
-
115
- ---
116
-
117
- ## Service-Specific Examples
118
-
119
- <stripe_example>
120
- ```markdown
121
- # Phase 10: User Setup Required
122
-
123
- **Generated:** 2025-01-14
124
- **Phase:** 10-monetization
125
- **Status:** Incomplete
126
-
127
- Complete these items for Stripe integration to function.
128
-
129
- ## Environment Variables
130
-
131
- | Status | Variable | Source | Add to |
132
- |--------|----------|--------|--------|
133
- | [ ] | `STRIPE_SECRET_KEY` | Stripe Dashboard → Developers → API keys → Secret key | `.env.local` |
134
- | [ ] | `NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY` | Stripe Dashboard → Developers → API keys → Publishable key | `.env.local` |
135
- | [ ] | `STRIPE_WEBHOOK_SECRET` | Stripe Dashboard → Developers → Webhooks → [endpoint] → Signing secret | `.env.local` |
136
-
137
- ## Account Setup
138
-
139
- - [ ] **Create Stripe account** (if needed)
140
- - URL: https://dashboard.stripe.com/register
141
- - Skip if: Already have Stripe account
142
-
143
- ## Dashboard Configuration
144
-
145
- - [ ] **Create webhook endpoint**
146
- - Location: Stripe Dashboard → Developers → Webhooks → Add endpoint
147
- - Endpoint URL: `https://[your-domain]/api/webhooks/stripe`
148
- - Events to send:
149
- - `checkout.session.completed`
150
- - `customer.subscription.created`
151
- - `customer.subscription.updated`
152
- - `customer.subscription.deleted`
153
-
154
- - [ ] **Create products and prices** (if using subscription tiers)
155
- - Location: Stripe Dashboard → Products → Add product
156
- - Create each subscription tier
157
- - Copy Price IDs to:
158
- - `STRIPE_STARTER_PRICE_ID`
159
- - `STRIPE_PRO_PRICE_ID`
160
-
161
- ## Local Development
162
-
163
- For local webhook testing:
164
- ```bash
165
- stripe listen --forward-to localhost:3000/api/webhooks/stripe
166
- ```
167
- Use the webhook signing secret from CLI output (starts with `whsec_`).
168
-
169
- ## Verification
170
-
171
- After completing setup:
172
-
173
- ```bash
174
- # Check env vars are set
175
- grep STRIPE .env.local
176
-
177
- # Verify build passes
178
- npm run build
179
-
180
- # Test webhook endpoint (should return 400 bad signature, not 500 crash)
181
- curl -X POST http://localhost:3000/api/webhooks/stripe \
182
- -H "Content-Type: application/json" \
183
- -d '{}'
184
- ```
185
-
186
- Expected: Build passes, webhook returns 400 (signature validation working).
187
-
188
- ---
189
-
190
- **Once all items complete:** Mark status as "Complete" at top of file.
191
- ```
192
- </stripe_example>
193
-
194
- <supabase_example>
195
- ```markdown
196
- # Phase 2: User Setup Required
197
-
198
- **Generated:** 2025-01-14
199
- **Phase:** 02-authentication
200
- **Status:** Incomplete
201
-
202
- Complete these items for Supabase Auth to function.
203
-
204
- ## Environment Variables
205
-
206
- | Status | Variable | Source | Add to |
207
- |--------|----------|--------|--------|
208
- | [ ] | `NEXT_PUBLIC_SUPABASE_URL` | Supabase Dashboard → Settings → API → Project URL | `.env.local` |
209
- | [ ] | `NEXT_PUBLIC_SUPABASE_ANON_KEY` | Supabase Dashboard → Settings → API → anon public | `.env.local` |
210
- | [ ] | `SUPABASE_SERVICE_ROLE_KEY` | Supabase Dashboard → Settings → API → service_role | `.env.local` |
211
-
212
- ## Account Setup
213
-
214
- - [ ] **Create Supabase project**
215
- - URL: https://supabase.com/dashboard/new
216
- - Skip if: Already have project for this app
217
-
218
- ## Dashboard Configuration
219
-
220
- - [ ] **Enable Email Auth**
221
- - Location: Supabase Dashboard → Authentication → Providers
222
- - Enable: Email provider
223
- - Configure: Confirm email (on/off based on preference)
224
-
225
- - [ ] **Configure OAuth providers** (if using social login)
226
- - Location: Supabase Dashboard → Authentication → Providers
227
- - For Google: Add Client ID and Secret from Google Cloud Console
228
- - For GitHub: Add Client ID and Secret from GitHub OAuth Apps
229
-
230
- ## Verification
231
-
232
- After completing setup:
233
-
234
- ```bash
235
- # Check env vars
236
- grep SUPABASE .env.local
237
-
238
- # Verify connection (run in project directory)
239
- npx supabase status
240
- ```
241
-
242
- ---
243
-
244
- **Once all items complete:** Mark status as "Complete" at top of file.
245
- ```
246
- </supabase_example>
247
-
248
- <sendgrid_example>
249
- ```markdown
250
- # Phase 5: User Setup Required
251
-
252
- **Generated:** 2025-01-14
253
- **Phase:** 05-notifications
254
- **Status:** Incomplete
255
-
256
- Complete these items for SendGrid email to function.
257
-
258
- ## Environment Variables
259
-
260
- | Status | Variable | Source | Add to |
261
- |--------|----------|--------|--------|
262
- | [ ] | `SENDGRID_API_KEY` | SendGrid Dashboard → Settings → API Keys → Create API Key | `.env.local` |
263
- | [ ] | `SENDGRID_FROM_EMAIL` | Your verified sender email address | `.env.local` |
264
-
265
- ## Account Setup
266
-
267
- - [ ] **Create SendGrid account**
268
- - URL: https://signup.sendgrid.com/
269
- - Skip if: Already have account
270
-
271
- ## Dashboard Configuration
272
-
273
- - [ ] **Verify sender identity**
274
- - Location: SendGrid Dashboard → Settings → Sender Authentication
275
- - Option 1: Single Sender Verification (quick, for dev)
276
- - Option 2: Domain Authentication (production)
277
-
278
- - [ ] **Create API Key**
279
- - Location: SendGrid Dashboard → Settings → API Keys → Create API Key
280
- - Permission: Restricted Access → Mail Send (Full Access)
281
- - Copy key immediately (shown only once)
282
-
283
- ## Verification
284
-
285
- After completing setup:
286
-
287
- ```bash
288
- # Check env var
289
- grep SENDGRID .env.local
290
-
291
- # Test email sending (replace with your test email)
292
- curl -X POST http://localhost:3000/api/test-email \
293
- -H "Content-Type: application/json" \
294
- -d '{"to": "your@email.com"}'
295
- ```
296
-
297
- ---
298
-
299
- **Once all items complete:** Mark status as "Complete" at top of file.
300
- ```
301
- </sendgrid_example>
302
-
303
- ---
304
-
305
- ## Guidelines
306
-
307
- **Never include:** Actual secret values. Steps Claude can automate (package installs, code changes).
308
-
309
- **Naming:** `{phase}-USER-SETUP.md` matches the phase number pattern.
310
- **Status tracking:** User marks checkboxes and updates status line when complete.
311
- **Searchability:** `grep -r "USER-SETUP" .planning/` finds all phases with user requirements.
1
+ # User Setup Template
2
+
3
+ Template for `.planning/phases/XX-name/{phase}-USER-SETUP.md` - human-required configuration that Claude cannot automate.
4
+
5
+ **Purpose:** Document setup tasks that literally require human action - account creation, dashboard configuration, secret retrieval. Claude automates everything possible; this file captures only what remains.
6
+
7
+ ---
8
+
9
+ ## File Template
10
+
11
+ ```markdown
12
+ # Phase {X}: User Setup Required
13
+
14
+ **Generated:** [YYYY-MM-DD]
15
+ **Phase:** {phase-name}
16
+ **Status:** Incomplete
17
+
18
+ Complete these items for the integration to function. Claude automated everything possible; these items require human access to external dashboards/accounts.
19
+
20
+ ## Environment Variables
21
+
22
+ | Status | Variable | Source | Add to |
23
+ |--------|----------|--------|--------|
24
+ | [ ] | `ENV_VAR_NAME` | [Service Dashboard → Path → To → Value] | `.env.local` |
25
+ | [ ] | `ANOTHER_VAR` | [Service Dashboard → Path → To → Value] | `.env.local` |
26
+
27
+ ## Account Setup
28
+
29
+ [Only if new account creation is required]
30
+
31
+ - [ ] **Create [Service] account**
32
+ - URL: [signup URL]
33
+ - Skip if: Already have account
34
+
35
+ ## Dashboard Configuration
36
+
37
+ [Only if dashboard configuration is required]
38
+
39
+ - [ ] **[Configuration task]**
40
+ - Location: [Service Dashboard → Path → To → Setting]
41
+ - Set to: [Required value or configuration]
42
+ - Notes: [Any important details]
43
+
44
+ ## Verification
45
+
46
+ After completing setup, verify with:
47
+
48
+ ```bash
49
+ # [Verification commands]
50
+ ```
51
+
52
+ Expected results:
53
+ - [What success looks like]
54
+
55
+ ---
56
+
57
+ **Once all items complete:** Mark status as "Complete" at top of file.
58
+ ```
59
+
60
+ ---
61
+
62
+ ## When to Generate
63
+
64
+ Generate `{phase}-USER-SETUP.md` when plan frontmatter contains `user_setup` field.
65
+
66
+ **Trigger:** `user_setup` exists in PLAN.md frontmatter and has items.
67
+
68
+ **Location:** Same directory as PLAN.md and SUMMARY.md.
69
+
70
+ **Timing:** Generated during execute-plan.md after tasks complete, before SUMMARY.md creation.
71
+
72
+ ---
73
+
74
+ ## Frontmatter Schema
75
+
76
+ In PLAN.md, `user_setup` declares human-required configuration:
77
+
78
+ ```yaml
79
+ user_setup:
80
+ - service: stripe
81
+ why: "Payment processing requires API keys"
82
+ env_vars:
83
+ - name: STRIPE_SECRET_KEY
84
+ source: "Stripe Dashboard → Developers → API keys → Secret key"
85
+ - name: STRIPE_WEBHOOK_SECRET
86
+ source: "Stripe Dashboard → Developers → Webhooks → Signing secret"
87
+ dashboard_config:
88
+ - task: "Create webhook endpoint"
89
+ location: "Stripe Dashboard → Developers → Webhooks → Add endpoint"
90
+ details: "URL: https://[your-domain]/api/webhooks/stripe, Events: checkout.session.completed, customer.subscription.*"
91
+ local_dev:
92
+ - "Run: stripe listen --forward-to localhost:3000/api/webhooks/stripe"
93
+ - "Use the webhook secret from CLI output for local testing"
94
+ ```
95
+
96
+ ---
97
+
98
+ ## The Automation-First Rule
99
+
100
+ **USER-SETUP.md contains ONLY what Claude literally cannot do.**
101
+
102
+ | Claude CAN Do (not in USER-SETUP) | Claude CANNOT Do (→ USER-SETUP) |
103
+ |-----------------------------------|--------------------------------|
104
+ | `npm install stripe` | Create Stripe account |
105
+ | Write webhook handler code | Get API keys from dashboard |
106
+ | Create `.env.local` file structure | Copy actual secret values |
107
+ | Run `stripe listen` | Authenticate Stripe CLI (browser OAuth) |
108
+ | Configure package.json | Access external service dashboards |
109
+ | Write any code | Retrieve secrets from third-party systems |
110
+
111
+ **The test:** "Does this require a human in a browser, accessing an account Claude doesn't have credentials for?"
112
+ - Yes → USER-SETUP.md
113
+ - No → Claude does it automatically
114
+
115
+ ---
116
+
117
+ ## Service-Specific Examples
118
+
119
+ <stripe_example>
120
+ ```markdown
121
+ # Phase 10: User Setup Required
122
+
123
+ **Generated:** 2025-01-14
124
+ **Phase:** 10-monetization
125
+ **Status:** Incomplete
126
+
127
+ Complete these items for Stripe integration to function.
128
+
129
+ ## Environment Variables
130
+
131
+ | Status | Variable | Source | Add to |
132
+ |--------|----------|--------|--------|
133
+ | [ ] | `STRIPE_SECRET_KEY` | Stripe Dashboard → Developers → API keys → Secret key | `.env.local` |
134
+ | [ ] | `NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY` | Stripe Dashboard → Developers → API keys → Publishable key | `.env.local` |
135
+ | [ ] | `STRIPE_WEBHOOK_SECRET` | Stripe Dashboard → Developers → Webhooks → [endpoint] → Signing secret | `.env.local` |
136
+
137
+ ## Account Setup
138
+
139
+ - [ ] **Create Stripe account** (if needed)
140
+ - URL: https://dashboard.stripe.com/register
141
+ - Skip if: Already have Stripe account
142
+
143
+ ## Dashboard Configuration
144
+
145
+ - [ ] **Create webhook endpoint**
146
+ - Location: Stripe Dashboard → Developers → Webhooks → Add endpoint
147
+ - Endpoint URL: `https://[your-domain]/api/webhooks/stripe`
148
+ - Events to send:
149
+ - `checkout.session.completed`
150
+ - `customer.subscription.created`
151
+ - `customer.subscription.updated`
152
+ - `customer.subscription.deleted`
153
+
154
+ - [ ] **Create products and prices** (if using subscription tiers)
155
+ - Location: Stripe Dashboard → Products → Add product
156
+ - Create each subscription tier
157
+ - Copy Price IDs to:
158
+ - `STRIPE_STARTER_PRICE_ID`
159
+ - `STRIPE_PRO_PRICE_ID`
160
+
161
+ ## Local Development
162
+
163
+ For local webhook testing:
164
+ ```bash
165
+ stripe listen --forward-to localhost:3000/api/webhooks/stripe
166
+ ```
167
+ Use the webhook signing secret from CLI output (starts with `whsec_`).
168
+
169
+ ## Verification
170
+
171
+ After completing setup:
172
+
173
+ ```bash
174
+ # Check env vars are set
175
+ grep STRIPE .env.local
176
+
177
+ # Verify build passes
178
+ npm run build
179
+
180
+ # Test webhook endpoint (should return 400 bad signature, not 500 crash)
181
+ curl -X POST http://localhost:3000/api/webhooks/stripe \
182
+ -H "Content-Type: application/json" \
183
+ -d '{}'
184
+ ```
185
+
186
+ Expected: Build passes, webhook returns 400 (signature validation working).
187
+
188
+ ---
189
+
190
+ **Once all items complete:** Mark status as "Complete" at top of file.
191
+ ```
192
+ </stripe_example>
193
+
194
+ <supabase_example>
195
+ ```markdown
196
+ # Phase 2: User Setup Required
197
+
198
+ **Generated:** 2025-01-14
199
+ **Phase:** 02-authentication
200
+ **Status:** Incomplete
201
+
202
+ Complete these items for Supabase Auth to function.
203
+
204
+ ## Environment Variables
205
+
206
+ | Status | Variable | Source | Add to |
207
+ |--------|----------|--------|--------|
208
+ | [ ] | `NEXT_PUBLIC_SUPABASE_URL` | Supabase Dashboard → Settings → API → Project URL | `.env.local` |
209
+ | [ ] | `NEXT_PUBLIC_SUPABASE_ANON_KEY` | Supabase Dashboard → Settings → API → anon public | `.env.local` |
210
+ | [ ] | `SUPABASE_SERVICE_ROLE_KEY` | Supabase Dashboard → Settings → API → service_role | `.env.local` |
211
+
212
+ ## Account Setup
213
+
214
+ - [ ] **Create Supabase project**
215
+ - URL: https://supabase.com/dashboard/new
216
+ - Skip if: Already have project for this app
217
+
218
+ ## Dashboard Configuration
219
+
220
+ - [ ] **Enable Email Auth**
221
+ - Location: Supabase Dashboard → Authentication → Providers
222
+ - Enable: Email provider
223
+ - Configure: Confirm email (on/off based on preference)
224
+
225
+ - [ ] **Configure OAuth providers** (if using social login)
226
+ - Location: Supabase Dashboard → Authentication → Providers
227
+ - For Google: Add Client ID and Secret from Google Cloud Console
228
+ - For GitHub: Add Client ID and Secret from GitHub OAuth Apps
229
+
230
+ ## Verification
231
+
232
+ After completing setup:
233
+
234
+ ```bash
235
+ # Check env vars
236
+ grep SUPABASE .env.local
237
+
238
+ # Verify connection (run in project directory)
239
+ npx supabase status
240
+ ```
241
+
242
+ ---
243
+
244
+ **Once all items complete:** Mark status as "Complete" at top of file.
245
+ ```
246
+ </supabase_example>
247
+
248
+ <sendgrid_example>
249
+ ```markdown
250
+ # Phase 5: User Setup Required
251
+
252
+ **Generated:** 2025-01-14
253
+ **Phase:** 05-notifications
254
+ **Status:** Incomplete
255
+
256
+ Complete these items for SendGrid email to function.
257
+
258
+ ## Environment Variables
259
+
260
+ | Status | Variable | Source | Add to |
261
+ |--------|----------|--------|--------|
262
+ | [ ] | `SENDGRID_API_KEY` | SendGrid Dashboard → Settings → API Keys → Create API Key | `.env.local` |
263
+ | [ ] | `SENDGRID_FROM_EMAIL` | Your verified sender email address | `.env.local` |
264
+
265
+ ## Account Setup
266
+
267
+ - [ ] **Create SendGrid account**
268
+ - URL: https://signup.sendgrid.com/
269
+ - Skip if: Already have account
270
+
271
+ ## Dashboard Configuration
272
+
273
+ - [ ] **Verify sender identity**
274
+ - Location: SendGrid Dashboard → Settings → Sender Authentication
275
+ - Option 1: Single Sender Verification (quick, for dev)
276
+ - Option 2: Domain Authentication (production)
277
+
278
+ - [ ] **Create API Key**
279
+ - Location: SendGrid Dashboard → Settings → API Keys → Create API Key
280
+ - Permission: Restricted Access → Mail Send (Full Access)
281
+ - Copy key immediately (shown only once)
282
+
283
+ ## Verification
284
+
285
+ After completing setup:
286
+
287
+ ```bash
288
+ # Check env var
289
+ grep SENDGRID .env.local
290
+
291
+ # Test email sending (replace with your test email)
292
+ curl -X POST http://localhost:3000/api/test-email \
293
+ -H "Content-Type: application/json" \
294
+ -d '{"to": "your@email.com"}'
295
+ ```
296
+
297
+ ---
298
+
299
+ **Once all items complete:** Mark status as "Complete" at top of file.
300
+ ```
301
+ </sendgrid_example>
302
+
303
+ ---
304
+
305
+ ## Guidelines
306
+
307
+ **Never include:** Actual secret values. Steps Claude can automate (package installs, code changes).
308
+
309
+ **Naming:** `{phase}-USER-SETUP.md` matches the phase number pattern.
310
+ **Status tracking:** User marks checkboxes and updates status line when complete.
311
+ **Searchability:** `grep -r "USER-SETUP" .planning/` finds all phases with user requirements.