@nextsparkjs/ai-workflow 0.1.0-beta.86
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/LICENSE +21 -0
- package/README.md +86 -0
- package/claude/_docs/workflows-optimizations.md +359 -0
- package/claude/agents/api-tester.md +636 -0
- package/claude/agents/architecture-supervisor.md +1381 -0
- package/claude/agents/backend-developer.md +1021 -0
- package/claude/agents/backend-validator.md +417 -0
- package/claude/agents/bdd-docs-writer.md +737 -0
- package/claude/agents/block-developer.md +677 -0
- package/claude/agents/code-reviewer.md +1460 -0
- package/claude/agents/db-developer.md +721 -0
- package/claude/agents/db-validator.md +407 -0
- package/claude/agents/demo-video-generator.md +493 -0
- package/claude/agents/documentation-writer.md +1291 -0
- package/claude/agents/frontend-developer.md +1259 -0
- package/claude/agents/frontend-validator.md +777 -0
- package/claude/agents/functional-validator.md +630 -0
- package/claude/agents/mock-analyst.md +387 -0
- package/claude/agents/product-manager.md +971 -0
- package/claude/agents/qa-automation.md +1762 -0
- package/claude/agents/release-manager.md +634 -0
- package/claude/agents/selectors-translator.md +262 -0
- package/claude/agents/unit-test-writer.md +785 -0
- package/claude/agents/visual-comparator.md +329 -0
- package/claude/agents/workflow-maintainer.md +373 -0
- package/claude/commands/do/README.md +88 -0
- package/claude/commands/do/create-api.md +64 -0
- package/claude/commands/do/create-entity.md +66 -0
- package/claude/commands/do/create-migration.md +64 -0
- package/claude/commands/do/create-plugin.md +56 -0
- package/claude/commands/do/create-theme.md +70 -0
- package/claude/commands/do/mock-data.md +67 -0
- package/claude/commands/do/reset-db.md +71 -0
- package/claude/commands/do/setup-scheduled-action.md +75 -0
- package/claude/commands/do/sync-code-review.md +117 -0
- package/claude/commands/do/update-selectors.md +112 -0
- package/claude/commands/do/use-skills.md +90 -0
- package/claude/commands/do/validate-blocks.md +69 -0
- package/claude/commands/how-to/README.md +261 -0
- package/claude/commands/how-to/add-metadata.md +692 -0
- package/claude/commands/how-to/add-taxonomies.md +806 -0
- package/claude/commands/how-to/add-translations.md +571 -0
- package/claude/commands/how-to/create-api.md +577 -0
- package/claude/commands/how-to/create-block.md +575 -0
- package/claude/commands/how-to/create-child-entities.md +771 -0
- package/claude/commands/how-to/create-entity.md +597 -0
- package/claude/commands/how-to/create-migrations.md +605 -0
- package/claude/commands/how-to/create-plugin.md +654 -0
- package/claude/commands/how-to/customize-app.md +481 -0
- package/claude/commands/how-to/customize-dashboard.md +553 -0
- package/claude/commands/how-to/customize-theme.md +438 -0
- package/claude/commands/how-to/define-features-flows.md +632 -0
- package/claude/commands/how-to/deploy.md +507 -0
- package/claude/commands/how-to/handle-file-uploads.md +681 -0
- package/claude/commands/how-to/implement-search.md +1001 -0
- package/claude/commands/how-to/install-plugins.md +352 -0
- package/claude/commands/how-to/manage-test-coverage.md +984 -0
- package/claude/commands/how-to/run-tests.md +400 -0
- package/claude/commands/how-to/set-app-languages.md +601 -0
- package/claude/commands/how-to/set-plans-and-permissions.md +575 -0
- package/claude/commands/how-to/set-scheduled-actions.md +527 -0
- package/claude/commands/how-to/set-user-roles-and-permissions.md +550 -0
- package/claude/commands/how-to/setup-authentication.md +388 -0
- package/claude/commands/how-to/setup-claude-code.md +512 -0
- package/claude/commands/how-to/setup-database.md +274 -0
- package/claude/commands/how-to/setup-email-providers.md +598 -0
- package/claude/commands/how-to/setup-mobile-dev.md +627 -0
- package/claude/commands/how-to/start.md +455 -0
- package/claude/commands/how-to/use-devtools.md +639 -0
- package/claude/commands/how-to/use-superadmin.md +622 -0
- package/claude/commands/session/README.md +193 -0
- package/claude/commands/session/block-create.md +190 -0
- package/claude/commands/session/block-list.md +203 -0
- package/claude/commands/session/block-update.md +192 -0
- package/claude/commands/session/block-validate.md +218 -0
- package/claude/commands/session/close.md +146 -0
- package/claude/commands/session/commit.md +174 -0
- package/claude/commands/session/db-entity.md +206 -0
- package/claude/commands/session/db-fix.md +212 -0
- package/claude/commands/session/db-sample.md +206 -0
- package/claude/commands/session/demo.md +178 -0
- package/claude/commands/session/doc-bdd.md +207 -0
- package/claude/commands/session/doc-feature.md +218 -0
- package/claude/commands/session/doc-read.md +225 -0
- package/claude/commands/session/execute.md +204 -0
- package/claude/commands/session/explain.md +202 -0
- package/claude/commands/session/fix-bug.md +210 -0
- package/claude/commands/session/fix-build.md +182 -0
- package/claude/commands/session/fix-test.md +189 -0
- package/claude/commands/session/pending.md +232 -0
- package/claude/commands/session/refine.md +188 -0
- package/claude/commands/session/resume.md +192 -0
- package/claude/commands/session/review.md +192 -0
- package/claude/commands/session/scope-change.md +181 -0
- package/claude/commands/session/start-blocks.md +347 -0
- package/claude/commands/session/start.md +476 -0
- package/claude/commands/session/status.md +169 -0
- package/claude/commands/session/test-fix.md +221 -0
- package/claude/commands/session/test-run.md +203 -0
- package/claude/commands/session/test-write.md +242 -0
- package/claude/commands/session/validate.md +162 -0
- package/claude/config/context.json +54 -0
- package/claude/config/github.json +69 -0
- package/claude/config/github.schema.json +106 -0
- package/claude/config/team.json +46 -0
- package/claude/config/team.schema.json +106 -0
- package/claude/config/workspace.json +49 -0
- package/claude/config/workspace.schema.json +64 -0
- package/claude/scripts/.gitkeep +0 -0
- package/claude/sessions/.gitkeep +0 -0
- package/claude/skills/README.md +228 -0
- package/claude/skills/accessibility/SKILL.md +573 -0
- package/claude/skills/api-bypass-layers/SKILL.md +550 -0
- package/claude/skills/asana-integration/SKILL.md +499 -0
- package/claude/skills/better-auth/SKILL.md +666 -0
- package/claude/skills/billing-subscriptions/SKILL.md +660 -0
- package/claude/skills/block-decision-matrix/SKILL.md +359 -0
- package/claude/skills/clickup-integration/SKILL.md +434 -0
- package/claude/skills/core-theme-responsibilities/SKILL.md +485 -0
- package/claude/skills/create-plugin/SKILL.md +425 -0
- package/claude/skills/create-theme/SKILL.md +331 -0
- package/claude/skills/cypress-api/SKILL.md +511 -0
- package/claude/skills/cypress-api/scripts/generate-api-controller.py +329 -0
- package/claude/skills/cypress-api/scripts/generate-api-test.py +930 -0
- package/claude/skills/cypress-e2e/SKILL.md +526 -0
- package/claude/skills/cypress-e2e/scripts/extract-selectors.py +383 -0
- package/claude/skills/cypress-e2e/scripts/generate-uat-test.py +788 -0
- package/claude/skills/cypress-selectors/SKILL.md +309 -0
- package/claude/skills/cypress-selectors/scripts/extract-missing.py +243 -0
- package/claude/skills/cypress-selectors/scripts/generate-block-selectors.py +283 -0
- package/claude/skills/cypress-selectors/scripts/validate-selectors.py +145 -0
- package/claude/skills/database-migrations/SKILL.md +335 -0
- package/claude/skills/database-migrations/scripts/generate-sample-data.py +284 -0
- package/claude/skills/database-migrations/scripts/validate-migration.py +323 -0
- package/claude/skills/design-system/SKILL.md +682 -0
- package/claude/skills/documentation/SKILL.md +540 -0
- package/claude/skills/entity-api/SKILL.md +482 -0
- package/claude/skills/entity-system/SKILL.md +635 -0
- package/claude/skills/entity-system/scripts/generate-child-migration.py +298 -0
- package/claude/skills/entity-system/scripts/generate-metas-migration.py +233 -0
- package/claude/skills/entity-system/scripts/generate-migration.py +382 -0
- package/claude/skills/entity-system/scripts/generate-sample-data.py +418 -0
- package/claude/skills/entity-system/scripts/scaffold-entity.py +661 -0
- package/claude/skills/github/SKILL.md +467 -0
- package/claude/skills/i18n-nextintl/SKILL.md +302 -0
- package/claude/skills/i18n-nextintl/scripts/add-translation.py +243 -0
- package/claude/skills/i18n-nextintl/scripts/extract-hardcoded.py +246 -0
- package/claude/skills/i18n-nextintl/scripts/validate-translations.py +260 -0
- package/claude/skills/impact-analysis/SKILL.md +203 -0
- package/claude/skills/jest-unit/SKILL.md +306 -0
- package/claude/skills/jest-unit/references/component-testing.md +371 -0
- package/claude/skills/jest-unit/references/mocking-patterns.md +380 -0
- package/claude/skills/jest-unit/references/service-hook-testing.md +454 -0
- package/claude/skills/jira-integration/SKILL.md +539 -0
- package/claude/skills/mock-analysis/SKILL.md +276 -0
- package/claude/skills/monorepo-architecture/SKILL.md +162 -0
- package/claude/skills/nextjs-api-development/SKILL.md +364 -0
- package/claude/skills/nextjs-api-development/scripts/generate-crud-tests.py +456 -0
- package/claude/skills/nextjs-api-development/scripts/scaffold-endpoint.py +481 -0
- package/claude/skills/nextjs-api-development/scripts/validate-api.py +283 -0
- package/claude/skills/notion-integration/SKILL.md +641 -0
- package/claude/skills/npm-development-workflow/SKILL.md +480 -0
- package/claude/skills/page-builder-blocks/SKILL.md +483 -0
- package/claude/skills/page-builder-blocks/scripts/scaffold-block.py +444 -0
- package/claude/skills/permissions-system/SKILL.md +619 -0
- package/claude/skills/plugins/SKILL.md +340 -0
- package/claude/skills/plugins/references/plugin-templates.md +414 -0
- package/claude/skills/plugins/references/plugin-testing.md +353 -0
- package/claude/skills/plugins/references/plugin-types.md +198 -0
- package/claude/skills/plugins/scripts/scaffold-plugin.py +443 -0
- package/claude/skills/pom-patterns/SKILL.md +452 -0
- package/claude/skills/pom-patterns/scripts/generate-pom.py +392 -0
- package/claude/skills/rate-limiting/SKILL.md +342 -0
- package/claude/skills/react-best-practices/AGENTS.md +2410 -0
- package/claude/skills/react-best-practices/README.md +123 -0
- package/claude/skills/react-best-practices/SKILL.md +125 -0
- package/claude/skills/react-best-practices/metadata.json +15 -0
- package/claude/skills/react-best-practices/rules/_sections.md +46 -0
- package/claude/skills/react-best-practices/rules/_template.md +28 -0
- package/claude/skills/react-best-practices/rules/advanced-event-handler-refs.md +55 -0
- package/claude/skills/react-best-practices/rules/advanced-use-latest.md +49 -0
- package/claude/skills/react-best-practices/rules/async-api-routes.md +38 -0
- package/claude/skills/react-best-practices/rules/async-defer-await.md +80 -0
- package/claude/skills/react-best-practices/rules/async-dependencies.md +36 -0
- package/claude/skills/react-best-practices/rules/async-parallel.md +28 -0
- package/claude/skills/react-best-practices/rules/async-suspense-boundaries.md +99 -0
- package/claude/skills/react-best-practices/rules/bundle-barrel-imports.md +59 -0
- package/claude/skills/react-best-practices/rules/bundle-conditional.md +31 -0
- package/claude/skills/react-best-practices/rules/bundle-defer-third-party.md +49 -0
- package/claude/skills/react-best-practices/rules/bundle-dynamic-imports.md +35 -0
- package/claude/skills/react-best-practices/rules/bundle-preload.md +50 -0
- package/claude/skills/react-best-practices/rules/client-event-listeners.md +74 -0
- package/claude/skills/react-best-practices/rules/client-localstorage-schema.md +71 -0
- package/claude/skills/react-best-practices/rules/client-passive-event-listeners.md +48 -0
- package/claude/skills/react-best-practices/rules/client-swr-dedup.md +56 -0
- package/claude/skills/react-best-practices/rules/js-batch-dom-css.md +82 -0
- package/claude/skills/react-best-practices/rules/js-cache-function-results.md +80 -0
- package/claude/skills/react-best-practices/rules/js-cache-property-access.md +28 -0
- package/claude/skills/react-best-practices/rules/js-cache-storage.md +70 -0
- package/claude/skills/react-best-practices/rules/js-combine-iterations.md +32 -0
- package/claude/skills/react-best-practices/rules/js-early-exit.md +50 -0
- package/claude/skills/react-best-practices/rules/js-hoist-regexp.md +45 -0
- package/claude/skills/react-best-practices/rules/js-index-maps.md +37 -0
- package/claude/skills/react-best-practices/rules/js-length-check-first.md +49 -0
- package/claude/skills/react-best-practices/rules/js-min-max-loop.md +82 -0
- package/claude/skills/react-best-practices/rules/js-set-map-lookups.md +24 -0
- package/claude/skills/react-best-practices/rules/js-tosorted-immutable.md +57 -0
- package/claude/skills/react-best-practices/rules/rendering-activity.md +26 -0
- package/claude/skills/react-best-practices/rules/rendering-animate-svg-wrapper.md +47 -0
- package/claude/skills/react-best-practices/rules/rendering-conditional-render.md +40 -0
- package/claude/skills/react-best-practices/rules/rendering-content-visibility.md +38 -0
- package/claude/skills/react-best-practices/rules/rendering-hoist-jsx.md +46 -0
- package/claude/skills/react-best-practices/rules/rendering-hydration-no-flicker.md +82 -0
- package/claude/skills/react-best-practices/rules/rendering-svg-precision.md +28 -0
- package/claude/skills/react-best-practices/rules/rerender-defer-reads.md +39 -0
- package/claude/skills/react-best-practices/rules/rerender-dependencies.md +45 -0
- package/claude/skills/react-best-practices/rules/rerender-derived-state.md +29 -0
- package/claude/skills/react-best-practices/rules/rerender-functional-setstate.md +74 -0
- package/claude/skills/react-best-practices/rules/rerender-lazy-state-init.md +58 -0
- package/claude/skills/react-best-practices/rules/rerender-memo.md +44 -0
- package/claude/skills/react-best-practices/rules/rerender-transitions.md +40 -0
- package/claude/skills/react-best-practices/rules/server-after-nonblocking.md +73 -0
- package/claude/skills/react-best-practices/rules/server-cache-lru.md +41 -0
- package/claude/skills/react-best-practices/rules/server-cache-react.md +76 -0
- package/claude/skills/react-best-practices/rules/server-parallel-fetching.md +83 -0
- package/claude/skills/react-best-practices/rules/server-serialization.md +38 -0
- package/claude/skills/react-patterns/SKILL.md +677 -0
- package/claude/skills/registry-system/SKILL.md +331 -0
- package/claude/skills/scheduled-actions/SKILL.md +431 -0
- package/claude/skills/scope-enforcement/SKILL.md +542 -0
- package/claude/skills/scope-enforcement/scripts/validate-scope.py +357 -0
- package/claude/skills/server-actions/SKILL.md +493 -0
- package/claude/skills/service-layer/SKILL.md +587 -0
- package/claude/skills/session-management/SKILL.md +266 -0
- package/claude/skills/session-management/scripts/create-session.py +166 -0
- package/claude/skills/session-management/scripts/iteration-close.sh +105 -0
- package/claude/skills/session-management/scripts/iteration-init.sh +180 -0
- package/claude/skills/session-management/scripts/session-archive.sh +87 -0
- package/claude/skills/session-management/scripts/session-close.sh +133 -0
- package/claude/skills/session-management/scripts/session-init.sh +225 -0
- package/claude/skills/session-management/scripts/session-list.sh +163 -0
- package/claude/skills/session-management/scripts/split-plan.sh +116 -0
- package/claude/skills/shadcn-components/SKILL.md +586 -0
- package/claude/skills/shadcn-theming/SKILL.md +446 -0
- package/claude/skills/suspense-loading/SKILL.md +280 -0
- package/claude/skills/tailwind-theming/SKILL.md +479 -0
- package/claude/skills/tanstack-query/SKILL.md +608 -0
- package/claude/skills/test-coverage/SKILL.md +239 -0
- package/claude/skills/web-design-guidelines/SKILL.md +39 -0
- package/claude/skills/zod-validation/SKILL.md +537 -0
- package/claude/templates/blocks/progress.md +86 -0
- package/claude/templates/iteration/changes.md +61 -0
- package/claude/templates/iteration/progress.md +55 -0
- package/claude/templates/log.md +31 -0
- package/claude/templates/story/context.md +77 -0
- package/claude/templates/story/pendings.md +37 -0
- package/claude/templates/story/plan.md +299 -0
- package/claude/templates/story/requirements.md +109 -0
- package/claude/templates/story/scope.json +10 -0
- package/claude/templates/story/tests.md +91 -0
- package/claude/templates/task/progress.md +58 -0
- package/claude/templates/task/requirements.md +54 -0
- package/claude/workflows/README.md +154 -0
- package/claude/workflows/blocks.md +614 -0
- package/claude/workflows/story.md +1207 -0
- package/claude/workflows/task.md +927 -0
- package/claude/workflows/tweak.md +527 -0
- package/cursor/.gitkeep +0 -0
- package/package.json +34 -0
- package/scripts/setup.mjs +282 -0
- package/scripts/sync.mjs +209 -0
|
@@ -0,0 +1,218 @@
|
|
|
1
|
+
# /session:doc:feature
|
|
2
|
+
|
|
3
|
+
Generate comprehensive documentation for a completed feature.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Required Skills
|
|
8
|
+
|
|
9
|
+
**[MANDATORY]** Read before executing:
|
|
10
|
+
- `.claude/skills/documentation/SKILL.md` - Documentation structure and format
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## Syntax
|
|
15
|
+
|
|
16
|
+
```
|
|
17
|
+
/session:doc:feature [--format <format>]
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
---
|
|
21
|
+
|
|
22
|
+
## Behavior
|
|
23
|
+
|
|
24
|
+
Creates feature documentation by analyzing session files and implementation.
|
|
25
|
+
|
|
26
|
+
---
|
|
27
|
+
|
|
28
|
+
## Flow
|
|
29
|
+
|
|
30
|
+
```
|
|
31
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
32
|
+
│ /session:doc:feature │
|
|
33
|
+
├─────────────────────────────────────────────────────────────────┤
|
|
34
|
+
│ │
|
|
35
|
+
│ 1. Load session context │
|
|
36
|
+
│ - requirements.md │
|
|
37
|
+
│ - plan.md │
|
|
38
|
+
│ - scope.json │
|
|
39
|
+
│ ↓ │
|
|
40
|
+
│ 2. Analyze implementation │
|
|
41
|
+
│ - Read modified files │
|
|
42
|
+
│ - Extract key patterns │
|
|
43
|
+
│ ↓ │
|
|
44
|
+
│ 3. Generate documentation │
|
|
45
|
+
│ - Overview │
|
|
46
|
+
│ - API reference │
|
|
47
|
+
│ - Usage examples │
|
|
48
|
+
│ - Configuration │
|
|
49
|
+
│ ↓ │
|
|
50
|
+
│ 4. Add to documentation system │
|
|
51
|
+
│ ↓ │
|
|
52
|
+
│ 5. Update navigation │
|
|
53
|
+
│ │
|
|
54
|
+
└─────────────────────────────────────────────────────────────────┘
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
---
|
|
58
|
+
|
|
59
|
+
## Example Output
|
|
60
|
+
|
|
61
|
+
```
|
|
62
|
+
📚 GENERATE FEATURE DOCUMENTATION
|
|
63
|
+
|
|
64
|
+
Session: stories/2026-01-11-new-products-entity
|
|
65
|
+
Feature: Products Management
|
|
66
|
+
|
|
67
|
+
─────────────────────────────────────────
|
|
68
|
+
|
|
69
|
+
🔍 ANALYZING SESSION
|
|
70
|
+
|
|
71
|
+
From requirements.md:
|
|
72
|
+
├─ 5 Acceptance Criteria
|
|
73
|
+
└─ 3 PM Decisions
|
|
74
|
+
|
|
75
|
+
From scope.json:
|
|
76
|
+
├─ 12 files modified
|
|
77
|
+
├─ API: 5 endpoints
|
|
78
|
+
└─ UI: 4 components
|
|
79
|
+
|
|
80
|
+
─────────────────────────────────────────
|
|
81
|
+
|
|
82
|
+
📝 GENERATING DOCUMENTATION
|
|
83
|
+
|
|
84
|
+
File: docs/features/products.md
|
|
85
|
+
|
|
86
|
+
```markdown
|
|
87
|
+
---
|
|
88
|
+
title: Products Management
|
|
89
|
+
description: Complete guide to the products entity and management system
|
|
90
|
+
category: features
|
|
91
|
+
order: 5
|
|
92
|
+
---
|
|
93
|
+
|
|
94
|
+
# Products Management
|
|
95
|
+
|
|
96
|
+
The products system provides complete CRUD functionality for
|
|
97
|
+
managing products with categories, images, and team isolation.
|
|
98
|
+
|
|
99
|
+
## Overview
|
|
100
|
+
|
|
101
|
+
Products are team-scoped entities that support:
|
|
102
|
+
- Basic information (name, description, price)
|
|
103
|
+
- Category assignment
|
|
104
|
+
- Image uploads (max 5)
|
|
105
|
+
- Active/inactive status
|
|
106
|
+
|
|
107
|
+
## Quick Start
|
|
108
|
+
|
|
109
|
+
### Creating a Product
|
|
110
|
+
|
|
111
|
+
```typescript
|
|
112
|
+
// Using the API
|
|
113
|
+
const response = await fetch('/api/v1/products', {
|
|
114
|
+
method: 'POST',
|
|
115
|
+
headers: {
|
|
116
|
+
'Content-Type': 'application/json',
|
|
117
|
+
'Authorization': `Bearer ${apiKey}`
|
|
118
|
+
},
|
|
119
|
+
body: JSON.stringify({
|
|
120
|
+
name: 'My Product',
|
|
121
|
+
price: 99.99,
|
|
122
|
+
categoryId: 'cat-uuid'
|
|
123
|
+
})
|
|
124
|
+
});
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
### Using the UI
|
|
128
|
+
|
|
129
|
+
1. Navigate to Dashboard > Products
|
|
130
|
+
2. Click "New Product"
|
|
131
|
+
3. Fill in the required fields
|
|
132
|
+
4. Upload images (optional)
|
|
133
|
+
5. Click "Save"
|
|
134
|
+
|
|
135
|
+
## API Reference
|
|
136
|
+
|
|
137
|
+
### Endpoints
|
|
138
|
+
|
|
139
|
+
| Method | Path | Description |
|
|
140
|
+
|--------|------|-------------|
|
|
141
|
+
| GET | /api/v1/products | List products |
|
|
142
|
+
| GET | /api/v1/products/:id | Get product |
|
|
143
|
+
| POST | /api/v1/products | Create product |
|
|
144
|
+
| PATCH | /api/v1/products/:id | Update product |
|
|
145
|
+
| DELETE | /api/v1/products/:id | Delete product |
|
|
146
|
+
|
|
147
|
+
### Query Parameters
|
|
148
|
+
|
|
149
|
+
| Parameter | Type | Description |
|
|
150
|
+
|-----------|------|-------------|
|
|
151
|
+
| page | number | Page number |
|
|
152
|
+
| limit | number | Items per page |
|
|
153
|
+
| categoryId | uuid | Filter by category |
|
|
154
|
+
| isActive | boolean | Filter by status |
|
|
155
|
+
|
|
156
|
+
## Configuration
|
|
157
|
+
|
|
158
|
+
### Entity Config
|
|
159
|
+
|
|
160
|
+
Location: `core/config/entities/products.ts`
|
|
161
|
+
|
|
162
|
+
```typescript
|
|
163
|
+
export const productsEntity: EntityConfig = {
|
|
164
|
+
name: 'products',
|
|
165
|
+
displayName: 'Products',
|
|
166
|
+
icon: 'Package',
|
|
167
|
+
fields: {
|
|
168
|
+
// Field definitions
|
|
169
|
+
}
|
|
170
|
+
};
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
## Permissions
|
|
174
|
+
|
|
175
|
+
| Role | Create | Read | Update | Delete |
|
|
176
|
+
|------|--------|------|--------|--------|
|
|
177
|
+
| Admin | ✓ | ✓ | ✓ | ✓ |
|
|
178
|
+
| Member | - | ✓ | - | - |
|
|
179
|
+
| Viewer | - | ✓ | - | - |
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
─────────────────────────────────────────
|
|
183
|
+
|
|
184
|
+
📁 FILE CREATED
|
|
185
|
+
|
|
186
|
+
Location: docs/features/products.md
|
|
187
|
+
Words: 450
|
|
188
|
+
Sections: 6
|
|
189
|
+
|
|
190
|
+
Updating navigation...
|
|
191
|
+
✓ Added to docs sidebar
|
|
192
|
+
|
|
193
|
+
─────────────────────────────────────────
|
|
194
|
+
|
|
195
|
+
Preview: http://localhost:3000/docs/features/products
|
|
196
|
+
|
|
197
|
+
✓ Documentation generated successfully
|
|
198
|
+
```
|
|
199
|
+
|
|
200
|
+
---
|
|
201
|
+
|
|
202
|
+
## Options
|
|
203
|
+
|
|
204
|
+
| Option | Description |
|
|
205
|
+
|--------|-------------|
|
|
206
|
+
| `--format <format>` | md, mdx, or notion |
|
|
207
|
+
| `--api-only` | Only API documentation |
|
|
208
|
+
| `--no-examples` | Skip code examples |
|
|
209
|
+
|
|
210
|
+
---
|
|
211
|
+
|
|
212
|
+
## Related Commands
|
|
213
|
+
|
|
214
|
+
| Command | Action |
|
|
215
|
+
|---------|--------|
|
|
216
|
+
| `/session:doc:read` | Read existing docs |
|
|
217
|
+
| `/session:doc:bdd` | Generate BDD docs |
|
|
218
|
+
| `/session:close` | Close session |
|
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
# /session:doc:read
|
|
2
|
+
|
|
3
|
+
Gain context by reading documentation before working on a task.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Syntax
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
/session:doc:read [topic] [--skill <name>]
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## Behavior
|
|
16
|
+
|
|
17
|
+
Reads relevant documentation and skills to understand project patterns before development.
|
|
18
|
+
|
|
19
|
+
---
|
|
20
|
+
|
|
21
|
+
## Flow
|
|
22
|
+
|
|
23
|
+
```
|
|
24
|
+
┌─────────────────────────────────────────────────────────────────┐
|
|
25
|
+
│ /session:doc:read │
|
|
26
|
+
├─────────────────────────────────────────────────────────────────┤
|
|
27
|
+
│ │
|
|
28
|
+
│ 1. Determine what to read │
|
|
29
|
+
│ - Topic provided? │
|
|
30
|
+
│ - Skill specified? │
|
|
31
|
+
│ - Infer from session context? │
|
|
32
|
+
│ ↓ │
|
|
33
|
+
│ 2. Locate relevant files │
|
|
34
|
+
│ - Skills (SKILL.md) │
|
|
35
|
+
│ - Documentation (docs/) │
|
|
36
|
+
│ - Architecture files (.rules/) │
|
|
37
|
+
│ ↓ │
|
|
38
|
+
│ 3. Read and summarize │
|
|
39
|
+
│ ↓ │
|
|
40
|
+
│ 4. Present key information │
|
|
41
|
+
│ - Patterns to follow │
|
|
42
|
+
│ - Anti-patterns to avoid │
|
|
43
|
+
│ - Related files │
|
|
44
|
+
│ │
|
|
45
|
+
└─────────────────────────────────────────────────────────────────┘
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
---
|
|
49
|
+
|
|
50
|
+
## Example: Read Topic
|
|
51
|
+
|
|
52
|
+
```
|
|
53
|
+
/session:doc:read authentication
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
Output:
|
|
57
|
+
|
|
58
|
+
```
|
|
59
|
+
📚 DOCUMENTATION: Authentication
|
|
60
|
+
|
|
61
|
+
─────────────────────────────────────────
|
|
62
|
+
|
|
63
|
+
📖 RELEVANT SKILLS
|
|
64
|
+
|
|
65
|
+
## better-auth (SKILL.md)
|
|
66
|
+
|
|
67
|
+
Key patterns:
|
|
68
|
+
- Session-based auth for web app
|
|
69
|
+
- API key auth for external access
|
|
70
|
+
- Dual auth: both methods per endpoint
|
|
71
|
+
|
|
72
|
+
```typescript
|
|
73
|
+
// Dual auth pattern
|
|
74
|
+
const { user, team } = await authenticateRequest(req, {
|
|
75
|
+
allowApiKey: true,
|
|
76
|
+
allowSession: true
|
|
77
|
+
});
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Anti-patterns:
|
|
81
|
+
- DON'T use only session auth for API endpoints
|
|
82
|
+
- DON'T skip team context validation
|
|
83
|
+
|
|
84
|
+
─────────────────────────────────────────
|
|
85
|
+
|
|
86
|
+
## api-bypass-layers (SKILL.md)
|
|
87
|
+
|
|
88
|
+
Multi-layer security:
|
|
89
|
+
1. Authentication layer
|
|
90
|
+
2. Authorization layer
|
|
91
|
+
3. Team context layer
|
|
92
|
+
4. RLS layer
|
|
93
|
+
|
|
94
|
+
Bypass rules:
|
|
95
|
+
- Superadmin bypasses team context
|
|
96
|
+
- Developer API key bypasses for testing
|
|
97
|
+
|
|
98
|
+
─────────────────────────────────────────
|
|
99
|
+
|
|
100
|
+
📖 RELATED DOCUMENTATION
|
|
101
|
+
|
|
102
|
+
docs/features/authentication.md
|
|
103
|
+
- Overview of auth flows
|
|
104
|
+
- Token management
|
|
105
|
+
- OAuth providers
|
|
106
|
+
|
|
107
|
+
docs/architecture/security.md
|
|
108
|
+
- Security best practices
|
|
109
|
+
- OWASP guidelines
|
|
110
|
+
|
|
111
|
+
─────────────────────────────────────────
|
|
112
|
+
|
|
113
|
+
📖 KEY FILES
|
|
114
|
+
|
|
115
|
+
core/lib/auth/
|
|
116
|
+
├─ session.ts - Session management
|
|
117
|
+
├─ api-key.ts - API key validation
|
|
118
|
+
└─ middleware.ts - Auth middleware
|
|
119
|
+
|
|
120
|
+
─────────────────────────────────────────
|
|
121
|
+
|
|
122
|
+
📌 SUMMARY FOR DEVELOPMENT
|
|
123
|
+
|
|
124
|
+
When implementing auth-related features:
|
|
125
|
+
1. Use authenticateRequest() helper
|
|
126
|
+
2. Enable both session AND API key
|
|
127
|
+
3. Always validate team context
|
|
128
|
+
4. RLS handles data isolation
|
|
129
|
+
|
|
130
|
+
Questions? Ask about specific patterns.
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
---
|
|
134
|
+
|
|
135
|
+
## Example: Read Skill
|
|
136
|
+
|
|
137
|
+
```
|
|
138
|
+
/session:doc:read --skill entity-system
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
Output:
|
|
142
|
+
|
|
143
|
+
```
|
|
144
|
+
📚 SKILL: entity-system
|
|
145
|
+
|
|
146
|
+
─────────────────────────────────────────
|
|
147
|
+
|
|
148
|
+
## Overview
|
|
149
|
+
|
|
150
|
+
Config-driven entity system for automatic CRUDs.
|
|
151
|
+
Creates API, UI, and types from configuration.
|
|
152
|
+
|
|
153
|
+
## Key Files
|
|
154
|
+
|
|
155
|
+
When creating an entity:
|
|
156
|
+
1. config.ts - Entity configuration
|
|
157
|
+
2. fields.ts - Field definitions
|
|
158
|
+
3. schema.ts - Zod validation
|
|
159
|
+
4. service.ts - Business logic (optional)
|
|
160
|
+
5. messages.ts - i18n translations
|
|
161
|
+
|
|
162
|
+
## Pattern Example
|
|
163
|
+
|
|
164
|
+
```typescript
|
|
165
|
+
// core/config/entities/products.ts
|
|
166
|
+
export const productsEntity: EntityConfig = {
|
|
167
|
+
name: 'products',
|
|
168
|
+
table: 'products',
|
|
169
|
+
displayName: 'Products',
|
|
170
|
+
fields: {
|
|
171
|
+
name: { type: 'string', required: true },
|
|
172
|
+
price: { type: 'number', required: true },
|
|
173
|
+
}
|
|
174
|
+
};
|
|
175
|
+
```
|
|
176
|
+
|
|
177
|
+
## Anti-Patterns
|
|
178
|
+
|
|
179
|
+
- DON'T use snake_case in field names
|
|
180
|
+
- DON'T skip RLS configuration
|
|
181
|
+
- DON'T create custom API when entity system works
|
|
182
|
+
|
|
183
|
+
## Related Skills
|
|
184
|
+
|
|
185
|
+
- database-migrations
|
|
186
|
+
- service-layer
|
|
187
|
+
- nextjs-api-development
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
---
|
|
191
|
+
|
|
192
|
+
## Auto-Read for Session
|
|
193
|
+
|
|
194
|
+
When starting a session, relevant docs are auto-suggested:
|
|
195
|
+
|
|
196
|
+
```
|
|
197
|
+
📚 SUGGESTED READING
|
|
198
|
+
|
|
199
|
+
Based on session "new-products-entity":
|
|
200
|
+
|
|
201
|
+
1. entity-system (SKILL) - How to create entities
|
|
202
|
+
2. database-migrations (SKILL) - Migration patterns
|
|
203
|
+
3. cypress-api (SKILL) - API testing
|
|
204
|
+
|
|
205
|
+
Read now? [Yes, all / Select specific / Skip]
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
---
|
|
209
|
+
|
|
210
|
+
## Options
|
|
211
|
+
|
|
212
|
+
| Option | Description |
|
|
213
|
+
|--------|-------------|
|
|
214
|
+
| `--skill <name>` | Read specific skill |
|
|
215
|
+
| `--all` | Read all related docs |
|
|
216
|
+
| `--brief` | Summary only |
|
|
217
|
+
|
|
218
|
+
---
|
|
219
|
+
|
|
220
|
+
## Related Commands
|
|
221
|
+
|
|
222
|
+
| Command | Action |
|
|
223
|
+
|---------|--------|
|
|
224
|
+
| `/session:doc:feature` | Generate feature docs |
|
|
225
|
+
| `/session:start` | Start session (auto-reads) |
|
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
# /session:execute
|
|
2
|
+
|
|
3
|
+
Execute the development of the active session.
|
|
4
|
+
|
|
5
|
+
**Aliases:** `/execute`
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Workflow Detection
|
|
10
|
+
|
|
11
|
+
**[MANDATORY]** Before executing, determine the workflow type:
|
|
12
|
+
|
|
13
|
+
1. Check session path:
|
|
14
|
+
- `stories/*` → STORY workflow
|
|
15
|
+
- `tasks/*` → TASK workflow
|
|
16
|
+
- No session files → TWEAK workflow
|
|
17
|
+
|
|
18
|
+
2. Read `progress.md` (if exists) for current phase
|
|
19
|
+
|
|
20
|
+
3. Adapt execution based on workflow type
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Syntax
|
|
25
|
+
|
|
26
|
+
```
|
|
27
|
+
/session:execute [--from-phase <phase>]
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+
## Behavior
|
|
33
|
+
|
|
34
|
+
Continues workflow execution from the current phase (or from a specific phase).
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## Flow by Workflow
|
|
39
|
+
|
|
40
|
+
### TWEAK
|
|
41
|
+
|
|
42
|
+
```
|
|
43
|
+
Does not use /session:execute
|
|
44
|
+
Development is direct without phases.
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
### TASK
|
|
48
|
+
|
|
49
|
+
```
|
|
50
|
+
/session:execute
|
|
51
|
+
|
|
52
|
+
1. Read requirements.md
|
|
53
|
+
2. Implement changes
|
|
54
|
+
- Call subagents if needed
|
|
55
|
+
3. Validate
|
|
56
|
+
- Build passes?
|
|
57
|
+
- Tests pass?
|
|
58
|
+
4. Update progress.md
|
|
59
|
+
5. Ready for commit
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### STORY
|
|
63
|
+
|
|
64
|
+
```
|
|
65
|
+
/session:execute
|
|
66
|
+
|
|
67
|
+
1. Read progress.md (current phase)
|
|
68
|
+
2. Execute next phase:
|
|
69
|
+
- Call corresponding subagent
|
|
70
|
+
- Wait for result
|
|
71
|
+
- Validate gate (if applicable)
|
|
72
|
+
3. Update progress.md
|
|
73
|
+
4. Repeat until complete or blocker
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
---
|
|
77
|
+
|
|
78
|
+
## Example: TASK
|
|
79
|
+
|
|
80
|
+
```
|
|
81
|
+
🚀 EXECUTING: improve-search
|
|
82
|
+
|
|
83
|
+
Reading requirements.md...
|
|
84
|
+
✓ 3 ACs defined
|
|
85
|
+
|
|
86
|
+
─────────────────────────────────────────
|
|
87
|
+
|
|
88
|
+
📋 EXECUTION PLAN
|
|
89
|
+
|
|
90
|
+
1. [ ] Optimize query in SearchService
|
|
91
|
+
2. [ ] Add index in DB
|
|
92
|
+
3. [ ] Update tests
|
|
93
|
+
|
|
94
|
+
─────────────────────────────────────────
|
|
95
|
+
|
|
96
|
+
Starting implementation...
|
|
97
|
+
|
|
98
|
+
[backend-developer] Optimizing SearchService...
|
|
99
|
+
✓ Query optimized
|
|
100
|
+
|
|
101
|
+
[backend-developer] Verifying build...
|
|
102
|
+
✓ Build successful
|
|
103
|
+
|
|
104
|
+
─────────────────────────────────────────
|
|
105
|
+
|
|
106
|
+
📊 PROGRESS: 66%
|
|
107
|
+
|
|
108
|
+
- [x] Optimize query
|
|
109
|
+
- [x] Add index
|
|
110
|
+
- [ ] Update tests
|
|
111
|
+
|
|
112
|
+
Continue with tests? [Yes/Pause]
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
---
|
|
116
|
+
|
|
117
|
+
## Example: STORY
|
|
118
|
+
|
|
119
|
+
```
|
|
120
|
+
🚀 EXECUTING: new-products-entity
|
|
121
|
+
|
|
122
|
+
Session: stories/2026-01-11-new-products-entity
|
|
123
|
+
Iteration: 02-scope-change
|
|
124
|
+
|
|
125
|
+
─────────────────────────────────────────
|
|
126
|
+
|
|
127
|
+
📊 CURRENT STATE
|
|
128
|
+
|
|
129
|
+
Completed phase: backend-validator [PASS]
|
|
130
|
+
Current phase: api-tester
|
|
131
|
+
|
|
132
|
+
─────────────────────────────────────────
|
|
133
|
+
|
|
134
|
+
Starting Phase 9: api-tester...
|
|
135
|
+
|
|
136
|
+
[api-tester] Running API tests...
|
|
137
|
+
├─ POST /api/v1/products ✓
|
|
138
|
+
├─ GET /api/v1/products ✓
|
|
139
|
+
├─ GET /api/v1/products/:id ✓
|
|
140
|
+
├─ PATCH /api/v1/products/:id ✓
|
|
141
|
+
└─ DELETE /api/v1/products/:id ✓
|
|
142
|
+
|
|
143
|
+
[api-tester] Result: 5/5 tests passed
|
|
144
|
+
|
|
145
|
+
─────────────────────────────────────────
|
|
146
|
+
|
|
147
|
+
✓ GATE PASSED: api-tester
|
|
148
|
+
|
|
149
|
+
Next phase: frontend-developer
|
|
150
|
+
Continue? [Yes/Pause]
|
|
151
|
+
```
|
|
152
|
+
|
|
153
|
+
---
|
|
154
|
+
|
|
155
|
+
## Options
|
|
156
|
+
|
|
157
|
+
| Option | Description |
|
|
158
|
+
|--------|-------------|
|
|
159
|
+
| `--from-phase <phase>` | Start from specific phase |
|
|
160
|
+
| `--skip-gates` | Skip gate validation (not recommended) |
|
|
161
|
+
| `--dry-run` | Show what would be done without executing |
|
|
162
|
+
|
|
163
|
+
---
|
|
164
|
+
|
|
165
|
+
## Error Handling
|
|
166
|
+
|
|
167
|
+
### Failed Gate
|
|
168
|
+
|
|
169
|
+
```
|
|
170
|
+
❌ GATE FAILED: backend-validator
|
|
171
|
+
|
|
172
|
+
Errors found:
|
|
173
|
+
- TypeScript error in products.ts:45
|
|
174
|
+
- Test failing: products.test.ts
|
|
175
|
+
|
|
176
|
+
Options:
|
|
177
|
+
[1] Call backend-developer to fix
|
|
178
|
+
[2] Fix manually
|
|
179
|
+
[3] Pause execution
|
|
180
|
+
```
|
|
181
|
+
|
|
182
|
+
### Blocker
|
|
183
|
+
|
|
184
|
+
```
|
|
185
|
+
🚫 BLOCKER DETECTED
|
|
186
|
+
|
|
187
|
+
The api-tester subagent reported:
|
|
188
|
+
"API endpoint /products returns 500"
|
|
189
|
+
|
|
190
|
+
Options:
|
|
191
|
+
[1] Create new iteration (blocked)
|
|
192
|
+
[2] Call backend-developer
|
|
193
|
+
[3] Pause and review manually
|
|
194
|
+
```
|
|
195
|
+
|
|
196
|
+
---
|
|
197
|
+
|
|
198
|
+
## Related Commands
|
|
199
|
+
|
|
200
|
+
| Command | Action |
|
|
201
|
+
|---------|--------|
|
|
202
|
+
| `/session:status` | View current state |
|
|
203
|
+
| `/session:scope-change` | If there's a scope change |
|
|
204
|
+
| `/session:close` | When finished |
|