rapidkit 0.19.1 → 0.21.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 +423 -1509
- package/dist/chunk-7LU4Z66R.js +4 -0
- package/dist/chunk-D2ZRDZOE.js +17 -0
- package/dist/chunk-RV6HBTFC.js +2 -0
- package/dist/index.js +194 -800
- package/dist/package.json +10 -3
- package/dist/pythonRapidkitExec-GFCAVUOY.js +1 -0
- package/dist/workspace-LZZGJRGV.js +587 -0
- package/dist/workspace-marker-IOPQ42A7.js +1 -0
- package/package.json +8 -2
package/README.md
CHANGED
|
@@ -1,889 +1,567 @@
|
|
|
1
1
|
<div align="center">
|
|
2
2
|
|
|
3
|
-
# 🚀 RapidKit
|
|
3
|
+
# 🚀 RapidKit
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
### Build Production-Ready APIs in Seconds
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
FastAPI & NestJS scaffolding with **27+ plug-and-play modules**.
|
|
8
|
+
Clean architecture • Zero boilerplate • Instant deployment.
|
|
8
9
|
|
|
9
10
|
[](https://www.npmjs.com/package/rapidkit)
|
|
10
11
|
[](https://www.npmjs.com/package/rapidkit)
|
|
11
12
|
[](https://opensource.org/licenses/MIT)
|
|
12
13
|
[](https://github.com/getrapidkit/rapidkit-npm/stargazers)
|
|
13
14
|
|
|
14
|
-
|
|
15
|
+
```bash
|
|
16
|
+
npx rapidkit create project fastapi.standard my-api
|
|
17
|
+
cd my-api
|
|
18
|
+
npx rapidkit init && npx rapidkit dev
|
|
19
|
+
# ✅ Production-ready API running at http://localhost:8000
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
[Quick Start](#-quick-start) • [Docs](https://getrapidkit.com) • [VS Code Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode) • [Examples](https://github.com/getrapidkit/rapidkit-examples)
|
|
23
|
+
|
|
24
|
+
---
|
|
25
|
+
|
|
26
|
+
### 👉 Get Started in 30 Seconds
|
|
27
|
+
|
|
28
|
+
No account. No config. No pain. Just build.
|
|
29
|
+
|
|
30
|
+
[📖 Read Full Docs](https://getrapidkit.com) • [🎥 Watch Demo](https://www.youtube.com/watch?v=demo) • [⭐ Star on GitHub](https://github.com/getrapidkit/rapidkit-npm)
|
|
15
31
|
|
|
16
32
|
</div>
|
|
17
33
|
|
|
18
34
|
---
|
|
19
35
|
|
|
20
|
-
##
|
|
36
|
+
## ⚡ Why RapidKit?
|
|
37
|
+
|
|
38
|
+
| 🚀 **Instant Setup** | 🧩 **Modular By Design** | 🎯 **Production-Ready** |
|
|
39
|
+
|-------------------------------|-------------------------------|--------------------------------|
|
|
40
|
+
| Project in 30 seconds | 27+ plug-and-play modules | Docker + CI/CD included |
|
|
41
|
+
| Zero configuration needed | Add features in 1 command | Best practices baked in |
|
|
42
|
+
| FastAPI & NestJS support | Auth, DB, Cache, Monitoring | Clean architecture guaranteed |
|
|
43
|
+
|
|
44
|
+
### 🔥 From This...
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
mkdir my-api && cd my-api
|
|
48
|
+
python -m venv .venv && source .venv/bin/activate
|
|
49
|
+
pip install fastapi uvicorn sqlalchemy alembic pydantic redis...
|
|
50
|
+
# Create project structure manually
|
|
51
|
+
# Configure Docker, CI/CD, testing...
|
|
52
|
+
# Write boilerplate code...
|
|
53
|
+
# ... 2 hours later
|
|
54
|
+
```
|
|
21
55
|
|
|
22
|
-
|
|
56
|
+
### ...To This! ✨
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
npx rapidkit create project fastapi.standard my-api
|
|
60
|
+
cd my-api && npx rapidkit init && npx rapidkit dev
|
|
61
|
+
# ✅ Done in 30 seconds!
|
|
62
|
+
```
|
|
23
63
|
|
|
24
|
-
|
|
25
|
-
-
|
|
26
|
-
-
|
|
27
|
-
-
|
|
28
|
-
-
|
|
64
|
+
**What you get:**
|
|
65
|
+
- ✅ Production-ready project structure
|
|
66
|
+
- ✅ Docker & docker-compose configured
|
|
67
|
+
- ✅ GitHub Actions CI/CD pipeline
|
|
68
|
+
- ✅ Testing & linting setup
|
|
69
|
+
- ✅ Environment configuration
|
|
70
|
+
- ✅ Hot reload development server
|
|
71
|
+
- ✅ Best practices & clean architecture
|
|
29
72
|
|
|
30
|
-
**Perfect for:**
|
|
31
|
-
- Starting new microservices quickly
|
|
32
|
-
- Maintaining architectural consistency across teams
|
|
33
|
-
- Rapid prototyping with production-ready structure
|
|
34
|
-
- Learning best practices for FastAPI/NestJS development
|
|
35
73
|
|
|
36
74
|
---
|
|
37
75
|
|
|
38
76
|
## 📦 Table of Contents
|
|
39
77
|
|
|
40
|
-
- [
|
|
41
|
-
- [Features](#-features)
|
|
78
|
+
- [Why RapidKit?](#-why-rapidkit)
|
|
42
79
|
- [Quick Start](#-quick-start)
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
- [
|
|
46
|
-
- [Available Commands](#-available-commands)
|
|
47
|
-
- [Project Commands](#project-commands)
|
|
48
|
-
- [Global Commands](#global-commands)
|
|
49
|
-
- [Workspace Commands](#workspace-commands)
|
|
50
|
-
- [Module System](#-module-system)
|
|
51
|
-
- [Architecture](#-architecture)
|
|
52
|
-
- [Workspace Management](#-workspace-management)
|
|
53
|
-
- [Project Structure](#-project-structure)
|
|
80
|
+
- [Core Concepts](#-core-concepts)
|
|
81
|
+
- [Module Ecosystem](#-module-ecosystem)
|
|
82
|
+
- [Commands Reference](#-commands-reference)
|
|
54
83
|
- [Requirements](#-requirements)
|
|
55
|
-
- [CLI Options](#-cli-options)
|
|
56
|
-
- [Troubleshooting](#-troubleshooting)
|
|
57
84
|
- [FAQs](#-faqs)
|
|
58
|
-
- [
|
|
59
|
-
- [Contributing](#-contributing)
|
|
60
|
-
- [Related Projects](#-related-projects)
|
|
61
|
-
- [License](#-license)
|
|
62
|
-
- [Support](#-support)
|
|
63
|
-
|
|
64
|
-
---
|
|
65
|
-
|
|
66
|
-
## ✨ Features
|
|
67
|
-
|
|
68
|
-
<table>
|
|
69
|
-
<tr>
|
|
70
|
-
<td width="50%">
|
|
71
|
-
|
|
72
|
-
### 🚀 **Instant Scaffolding**
|
|
73
|
-
- FastAPI DDD & Standard kits
|
|
74
|
-
- NestJS Standard kit
|
|
75
|
-
- Production-ready project structure
|
|
76
|
-
- Docker & CI/CD configuration included
|
|
77
|
-
- Best practices baked in
|
|
78
|
-
|
|
79
|
-
</td>
|
|
80
|
-
<td width="50%">
|
|
81
|
-
|
|
82
|
-
### 🧩 **Modular Architecture**
|
|
83
|
-
- 27+ free plug-and-play modules
|
|
84
|
-
- Authentication (JWT, OAuth, WebAuthn)
|
|
85
|
-
- Databases (PostgreSQL, MongoDB, Redis)
|
|
86
|
-
- Monitoring, logging, and tracing
|
|
87
|
-
- Caching and message queues
|
|
88
|
-
|
|
89
|
-
</td>
|
|
90
|
-
</tr>
|
|
91
|
-
<tr>
|
|
92
|
-
<td width="50%">
|
|
93
|
-
|
|
94
|
-
### 🎯 **Workspace Management**
|
|
95
|
-
- Organize multiple projects
|
|
96
|
-
- Shared Python environment
|
|
97
|
-
- Auto-tracking in registry
|
|
98
|
-
- VS Code Extension integration
|
|
99
|
-
- Cross-tool compatibility
|
|
100
|
-
|
|
101
|
-
</td>
|
|
102
|
-
<td width="50%">
|
|
103
|
-
|
|
104
|
-
### 🔧 **Developer Experience**
|
|
105
|
-
- Interactive TUI wizard
|
|
106
|
-
- Hot reload development
|
|
107
|
-
- Built-in testing & linting
|
|
108
|
-
- Comprehensive CLI commands
|
|
109
|
-
- One-command project setup
|
|
110
|
-
|
|
111
|
-
</td>
|
|
112
|
-
</tr>
|
|
113
|
-
</table>
|
|
85
|
+
- [Links](#-links)
|
|
114
86
|
|
|
115
87
|
---
|
|
116
88
|
|
|
117
89
|
## 🚀 Quick Start
|
|
118
90
|
|
|
119
|
-
###
|
|
91
|
+
### Option 1: Single Project (Fastest)
|
|
120
92
|
|
|
121
|
-
Perfect for
|
|
93
|
+
Perfect for trying out RapidKit or building a standalone service:
|
|
122
94
|
|
|
123
95
|
**FastAPI:**
|
|
124
96
|
```bash
|
|
97
|
+
# Create project
|
|
125
98
|
npx rapidkit create project fastapi.standard my-api
|
|
99
|
+
|
|
100
|
+
# Start developing
|
|
126
101
|
cd my-api
|
|
127
102
|
npx rapidkit init # Install dependencies
|
|
128
|
-
npx rapidkit dev # Start dev server
|
|
103
|
+
npx rapidkit dev # Start dev server → http://localhost:8000
|
|
104
|
+
|
|
105
|
+
# Add modules as needed
|
|
106
|
+
npx rapidkit add module auth
|
|
107
|
+
npx rapidkit add module db_postgres
|
|
129
108
|
```
|
|
130
109
|
|
|
131
110
|
**NestJS:**
|
|
132
111
|
```bash
|
|
112
|
+
# Create project
|
|
133
113
|
npx rapidkit create project nestjs.standard my-service
|
|
114
|
+
|
|
115
|
+
# Start developing
|
|
134
116
|
cd my-service
|
|
135
117
|
npx rapidkit init # Install dependencies
|
|
136
|
-
npx rapidkit dev # Start dev server
|
|
118
|
+
npx rapidkit dev # Start dev server → http://localhost:3000
|
|
119
|
+
|
|
120
|
+
# Add modules as needed
|
|
121
|
+
npx rapidkit add module auth
|
|
122
|
+
npx rapidkit add module db_postgres
|
|
137
123
|
```
|
|
138
124
|
|
|
139
|
-
### Workspace
|
|
125
|
+
### Option 2: Workspace (Recommended for Multiple Projects)
|
|
140
126
|
|
|
141
|
-
|
|
127
|
+
Organize multiple microservices with a shared environment:
|
|
142
128
|
|
|
143
129
|
```bash
|
|
144
130
|
# 1. Create workspace
|
|
145
131
|
npx rapidkit my-workspace
|
|
146
132
|
cd my-workspace
|
|
147
133
|
|
|
148
|
-
# 2. Activate environment (choose one
|
|
134
|
+
# 2. Activate environment (choose one):
|
|
149
135
|
|
|
150
|
-
#
|
|
136
|
+
# A. Activate virtualenv (recommended)
|
|
151
137
|
source "$(poetry env info --path)/bin/activate"
|
|
152
138
|
|
|
153
|
-
#
|
|
139
|
+
# B. Use poetry run prefix
|
|
154
140
|
poetry run rapidkit create
|
|
155
141
|
|
|
156
|
-
#
|
|
142
|
+
# C. Create alias (add to ~/.bashrc or ~/.zshrc)
|
|
157
143
|
alias rapidkit="poetry run rapidkit"
|
|
158
144
|
|
|
159
|
-
# 3. Create projects
|
|
160
|
-
rapidkit create
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
rapidkit create project fastapi.
|
|
164
|
-
rapidkit create project nestjs.standard user-service
|
|
165
|
-
rapidkit create project fastapi.ddd order-service
|
|
145
|
+
# 3. Create projects
|
|
146
|
+
rapidkit create # Interactive wizard
|
|
147
|
+
rapidkit create project fastapi.standard api
|
|
148
|
+
rapidkit create project nestjs.standard users
|
|
149
|
+
rapidkit create project fastapi.ddd orders
|
|
166
150
|
|
|
167
151
|
# 4. View all projects
|
|
168
|
-
rapidkit workspace list
|
|
152
|
+
npx rapidkit workspace list
|
|
169
153
|
```
|
|
170
154
|
|
|
171
|
-
**Why
|
|
172
|
-
- ✅ One shared Python environment
|
|
155
|
+
**Why workspace mode?**
|
|
156
|
+
- ✅ One shared Python environment (~150MB once vs 150MB per project)
|
|
173
157
|
- ✅ All projects auto-tracked in `~/.rapidkit/workspaces.json`
|
|
174
|
-
- ✅ VS Code Extension auto-discovers
|
|
175
|
-
- ✅ Consistent RapidKit Core version
|
|
176
|
-
- ✅
|
|
177
|
-
|
|
178
|
-
---
|
|
179
|
-
|
|
180
|
-
## 🆚 Workspace vs Standalone
|
|
181
|
-
|
|
182
|
-
Choose the right mode for your use case:
|
|
183
|
-
|
|
184
|
-
<table>
|
|
185
|
-
<thead>
|
|
186
|
-
<tr>
|
|
187
|
-
<th width="25%">Feature</th>
|
|
188
|
-
<th width="37.5%">Workspace Mode</th>
|
|
189
|
-
<th width="37.5%">Standalone</th>
|
|
190
|
-
</tr>
|
|
191
|
-
</thead>
|
|
192
|
-
<tbody>
|
|
193
|
-
<tr>
|
|
194
|
-
<td><strong>Best for</strong></td>
|
|
195
|
-
<td>✅ Teams, microservices, multiple projects</td>
|
|
196
|
-
<td>⚡ Single project, quick prototyping</td>
|
|
197
|
-
</tr>
|
|
198
|
-
<tr>
|
|
199
|
-
<td><strong>Python Environment</strong></td>
|
|
200
|
-
<td>✅ Shared across all projects (~150MB once)</td>
|
|
201
|
-
<td>⚠️ Separate per project (150MB each)</td>
|
|
202
|
-
</tr>
|
|
203
|
-
<tr>
|
|
204
|
-
<td><strong>Project Registry</strong></td>
|
|
205
|
-
<td>✅ Auto-tracked in <code>~/.rapidkit/workspaces.json</code></td>
|
|
206
|
-
<td>❌ Not tracked</td>
|
|
207
|
-
</tr>
|
|
208
|
-
<tr>
|
|
209
|
-
<td><strong>VS Code Extension</strong></td>
|
|
210
|
-
<td>✅ Auto-discovers all projects</td>
|
|
211
|
-
<td>⚠️ Manual discovery</td>
|
|
212
|
-
</tr>
|
|
213
|
-
<tr>
|
|
214
|
-
<td><strong>Setup Time</strong></td>
|
|
215
|
-
<td>⏱️ ~2 minutes (once)</td>
|
|
216
|
-
<td>⏱️ ~30 seconds</td>
|
|
217
|
-
</tr>
|
|
218
|
-
<tr>
|
|
219
|
-
<td><strong>Disk Usage</strong></td>
|
|
220
|
-
<td>✅ Efficient (one venv)</td>
|
|
221
|
-
<td>⚠️ Higher (multiple venvs)</td>
|
|
222
|
-
</tr>
|
|
223
|
-
<tr>
|
|
224
|
-
<td><strong>Dependency Management</strong></td>
|
|
225
|
-
<td>✅ Centralized Core version</td>
|
|
226
|
-
<td>⚠️ Independent per project</td>
|
|
227
|
-
</tr>
|
|
228
|
-
<tr>
|
|
229
|
-
<td><strong>Use Case</strong></td>
|
|
230
|
-
<td>Production teams, long-term projects</td>
|
|
231
|
-
<td>Quick demos, learning, single services</td>
|
|
232
|
-
</tr>
|
|
233
|
-
</tbody>
|
|
234
|
-
</table>
|
|
235
|
-
|
|
236
|
-
---
|
|
237
|
-
|
|
238
|
-
## 🎯 Architecture
|
|
239
|
-
|
|
240
|
-
```
|
|
241
|
-
┌──────────────────────────────────────────────────────────────┐
|
|
242
|
-
│ RapidKit CLI (npm) │
|
|
243
|
-
│ • Command routing & delegation │
|
|
244
|
-
│ • Workspace management & registry │
|
|
245
|
-
│ • VS Code Extension integration │
|
|
246
|
-
│ • Python Core bridge & bootstrapping │
|
|
247
|
-
└────────────────────────┬─────────────────────────────────────┘
|
|
248
|
-
│
|
|
249
|
-
┌──────────┴──────────┐
|
|
250
|
-
│ │
|
|
251
|
-
▼ ▼
|
|
252
|
-
┌──────────────────────┐ ┌──────────────────────────┐
|
|
253
|
-
│ Project Local CLI │ │ RapidKit Core │
|
|
254
|
-
│ Launcher │ │ (Python Engine) │
|
|
255
|
-
├──────────────────────┤ ├──────────────────────────┤
|
|
256
|
-
│ • init │ │ • create │
|
|
257
|
-
│ • dev │ │ • add module │
|
|
258
|
-
│ • test │ │ • list kits/modules │
|
|
259
|
-
│ • build │ │ • info │
|
|
260
|
-
│ • lint │ │ • doctor │
|
|
261
|
-
│ • format │ │ • upgrade │
|
|
262
|
-
│ • start │ │ • TUI wizard │
|
|
263
|
-
└──────────────────────┘ └──────────────────────────┘
|
|
264
|
-
│ │
|
|
265
|
-
└──────────┬───────────────┘
|
|
266
|
-
▼
|
|
267
|
-
┌────────────────────┐
|
|
268
|
-
│ Generated Project │
|
|
269
|
-
│ (FastAPI/NestJS) │
|
|
270
|
-
└────────────────────┘
|
|
271
|
-
```
|
|
272
|
-
|
|
273
|
-
**How it works:**
|
|
274
|
-
|
|
275
|
-
1. **Inside a project:** Commands like `init`, `dev`, `test` are delegated to the project-local launcher
|
|
276
|
-
2. **Outside a project:** Commands like `create`, `list`, `add` are forwarded to RapidKit Core (Python)
|
|
277
|
-
3. **Workspace mode:** Python Core is installed in workspace venv via Poetry/pipx
|
|
278
|
-
4. **Standalone mode:** Each project manages its own environment
|
|
279
|
-
|
|
280
|
-
---
|
|
281
|
-
|
|
282
|
-
## 💻 Available Commands
|
|
283
|
-
|
|
284
|
-
### Project Commands
|
|
285
|
-
|
|
286
|
-
Run these inside a RapidKit project:
|
|
287
|
-
|
|
288
|
-
```bash
|
|
289
|
-
npx rapidkit init # Install dependencies (auto-activates environment)
|
|
290
|
-
npx rapidkit dev # Start dev server with hot reload
|
|
291
|
-
npx rapidkit start # Start production server
|
|
292
|
-
npx rapidkit build # Build for production
|
|
293
|
-
npx rapidkit test # Run tests with coverage
|
|
294
|
-
npx rapidkit lint # Run linting checks
|
|
295
|
-
npx rapidkit format # Format code automatically
|
|
296
|
-
npx rapidkit --help # Show all commands
|
|
297
|
-
```
|
|
298
|
-
|
|
299
|
-
### Global Commands
|
|
300
|
-
|
|
301
|
-
Run these anywhere:
|
|
302
|
-
|
|
303
|
-
```bash
|
|
304
|
-
# Project creation
|
|
305
|
-
npx rapidkit create # Interactive wizard
|
|
306
|
-
npx rapidkit create project <kit> <name> # Direct creation
|
|
307
|
-
|
|
308
|
-
# Information
|
|
309
|
-
npx rapidkit list # List available kits
|
|
310
|
-
npx rapidkit list modules # List available modules
|
|
311
|
-
npx rapidkit info kit <name> # Kit details
|
|
312
|
-
npx rapidkit info module <name> # Module details
|
|
313
|
-
|
|
314
|
-
# System
|
|
315
|
-
npx rapidkit doctor # Diagnose environment
|
|
316
|
-
npx rapidkit doctor --workspace # Check entire workspace
|
|
317
|
-
npx rapidkit doctor --workspace --json # JSON output (CI/CD)
|
|
318
|
-
npx rapidkit doctor --workspace --fix # Auto-fix issues
|
|
319
|
-
npx rapidkit --version # Show version
|
|
320
|
-
npx rapidkit --tui # Launch interactive TUI
|
|
158
|
+
- ✅ VS Code Extension auto-discovers projects
|
|
159
|
+
- ✅ Consistent RapidKit Core version
|
|
160
|
+
- ✅ Perfect for microservices architecture
|
|
321
161
|
|
|
322
|
-
|
|
323
|
-
npx rapidkit workspace list # List workspaces
|
|
324
|
-
npx rapidkit workspace sync # Sync projects
|
|
325
|
-
```
|
|
326
|
-
|
|
327
|
-
### Doctor Command (Health Check)
|
|
328
|
-
|
|
329
|
-
The enhanced `doctor` command provides comprehensive health monitoring:
|
|
162
|
+
### Next Steps
|
|
330
163
|
|
|
331
164
|
```bash
|
|
332
|
-
#
|
|
333
|
-
rapidkit
|
|
334
|
-
|
|
335
|
-
#
|
|
336
|
-
rapidkit
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
# ✅ Environment file validation (.env)
|
|
341
|
-
# ✅ Module structure integrity
|
|
342
|
-
# ✅ Version compatibility warnings
|
|
343
|
-
# ✅ Actionable fix commands
|
|
344
|
-
|
|
345
|
-
# JSON output for CI/CD pipelines
|
|
346
|
-
rapidkit doctor --workspace --json
|
|
347
|
-
|
|
348
|
-
# Auto-fix common issues
|
|
349
|
-
rapidkit doctor --workspace --fix
|
|
350
|
-
# Interactive confirmation before applying fixes
|
|
351
|
-
```
|
|
352
|
-
|
|
353
|
-
**Features:**
|
|
354
|
-
- **Health Score**: Visual percentage with pass/warn/error breakdown
|
|
355
|
-
- **Fix Commands**: Project-specific commands to resolve issues
|
|
356
|
-
- **JSON Mode**: Machine-readable output for automation
|
|
357
|
-
- **Auto-Fix**: Apply fixes automatically with confirmation
|
|
358
|
-
- **Module Checks**: Validates `__init__.py` files
|
|
359
|
-
- **Environment Checks**: Detects missing `.env` files
|
|
360
|
-
- **Version Compatibility**: Warns about Core/CLI mismatches
|
|
361
|
-
```
|
|
165
|
+
# Project commands (run inside project directory)
|
|
166
|
+
npx rapidkit init # Install dependencies
|
|
167
|
+
npx rapidkit dev # Start dev server with hot reload
|
|
168
|
+
npx rapidkit test # Run tests with coverage
|
|
169
|
+
npx rapidkit lint # Run linting checks
|
|
170
|
+
npx rapidkit format # Format code
|
|
171
|
+
npx rapidkit build # Build for production
|
|
172
|
+
npx rapidkit start # Start production server
|
|
362
173
|
|
|
363
|
-
|
|
174
|
+
# Explore modules
|
|
175
|
+
npx rapidkit modules list # List all 27+ modules
|
|
176
|
+
npx rapidkit modules info db_postgres # View module details
|
|
364
177
|
|
|
365
|
-
|
|
366
|
-
#
|
|
367
|
-
rapidkit workspace
|
|
368
|
-
|
|
369
|
-
# Sync current workspace (scan for new projects)
|
|
370
|
-
rapidkit workspace sync
|
|
178
|
+
# Health check
|
|
179
|
+
npx rapidkit doctor # Check system requirements
|
|
180
|
+
npx rapidkit doctor --workspace # Check entire workspace
|
|
371
181
|
```
|
|
372
182
|
|
|
373
|
-
|
|
183
|
+
> 💡 **Pro Tip:** Install [RapidKit VS Code Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode) for visual project creation, module browsing, and one-click installation!
|
|
374
184
|
|
|
375
185
|
---
|
|
376
186
|
|
|
377
|
-
##
|
|
378
|
-
|
|
379
|
-
RapidKit's modular architecture lets you extend your project with pre-built modules.
|
|
380
|
-
|
|
381
|
-
### Adding Modules
|
|
382
|
-
|
|
383
|
-
```bash
|
|
384
|
-
# Add single module
|
|
385
|
-
rapidkit add module <module-slug>
|
|
386
|
-
|
|
387
|
-
# Examples
|
|
388
|
-
rapidkit add module auth # Authentication
|
|
389
|
-
rapidkit add module db_postgres # PostgreSQL
|
|
390
|
-
rapidkit add module redis # Redis caching
|
|
391
|
-
rapidkit add module monitoring # Monitoring & metrics
|
|
392
|
-
```
|
|
393
|
-
|
|
394
|
-
### List Available Modules
|
|
395
|
-
|
|
396
|
-
```bash
|
|
397
|
-
rapidkit list modules # Human-readable list
|
|
398
|
-
rapidkit list modules --json # JSON format
|
|
399
|
-
```
|
|
400
|
-
|
|
401
|
-
### Module Information
|
|
402
|
-
|
|
403
|
-
```bash
|
|
404
|
-
rapidkit info module auth # View module details
|
|
405
|
-
rapidkit info module db_postgres # Dependencies, config, etc.
|
|
406
|
-
```
|
|
407
|
-
|
|
408
|
-
### Available Modules (27 Total)
|
|
409
|
-
|
|
410
|
-
#### 🔐 Authentication & Authorization (5)
|
|
411
|
-
|
|
412
|
-
| Module | Slug | Description |
|
|
413
|
-
|--------|------|-------------|
|
|
414
|
-
| **Authentication Core** | `auth` | Opinionated password hashing, token signing, and runtime auth |
|
|
415
|
-
| **API Keys** | `api_keys` | API key issuance, verification, and auditing |
|
|
416
|
-
| **OAuth Providers** | `oauth` | Lightweight OAuth 2.0 scaffolding with provider registry |
|
|
417
|
-
| **Passwordless Authentication** | `passwordless` | Magic link and one-time code authentication helpers |
|
|
418
|
-
| **Session Management** | `session` | Opinionated session management with signed cookies |
|
|
419
|
-
|
|
420
|
-
#### 💳 Billing & E-commerce (3)
|
|
421
|
-
|
|
422
|
-
| Module | Slug | Description |
|
|
423
|
-
|--------|------|-------------|
|
|
424
|
-
| **Cart** | `cart` | Shopping cart service for checkout flows |
|
|
425
|
-
| **Inventory** | `inventory` | Inventory and pricing service backing Cart + Stripe |
|
|
426
|
-
| **Stripe Payment** | `stripe` | Stripe payments and subscriptions |
|
|
427
|
-
|
|
428
|
-
#### 🗄️ Database (3)
|
|
429
|
-
|
|
430
|
-
| Module | Slug | Description |
|
|
431
|
-
|--------|------|-------------|
|
|
432
|
-
| **PostgreSQL** | `db_postgres` | SQLAlchemy async+sync Postgres with clean DI, healthcheck |
|
|
433
|
-
| **MongoDB** | `db_mongo` | MongoDB integration with async driver support, health diagnostics |
|
|
434
|
-
| **SQLite** | `db_sqlite` | SQLite database integration for development |
|
|
435
|
-
|
|
436
|
-
#### 🔒 Security (3)
|
|
187
|
+
## 💎 Prefer Visual Interface?
|
|
437
188
|
|
|
438
|
-
|
|
439
|
-
|--------|------|-------------|
|
|
440
|
-
| **CORS** | `cors` | Cross-Origin Resource Sharing security module |
|
|
441
|
-
| **Rate Limiting** | `rate_limiting` | Production request throttling with configurable rules |
|
|
442
|
-
| **Security Headers** | `security_headers` | Harden HTTP responses with industry-standard security headers |
|
|
443
|
-
|
|
444
|
-
#### 📧 Communication (2)
|
|
445
|
-
|
|
446
|
-
| Module | Slug | Description |
|
|
447
|
-
|--------|------|-------------|
|
|
448
|
-
| **Email** | `email` | Email sending capabilities |
|
|
449
|
-
| **Unified Notifications** | `notifications` | Email-first notification runtime with SMTP delivery |
|
|
450
|
-
|
|
451
|
-
#### 👥 User Management (2)
|
|
452
|
-
|
|
453
|
-
| Module | Slug | Description |
|
|
454
|
-
|--------|------|-------------|
|
|
455
|
-
| **Users Core** | `users` | Opinionated user management backbone with immutable user records |
|
|
456
|
-
| **Users Profiles** | `users_profiles` | Extends Users Core with rich profile modeling |
|
|
457
|
-
|
|
458
|
-
#### ⚙️ Essentials (4)
|
|
459
|
-
|
|
460
|
-
| Module | Slug | Description |
|
|
461
|
-
|--------|------|-------------|
|
|
462
|
-
| **Application Settings** | `settings` | Centralized modular configuration management using Pydantic |
|
|
463
|
-
| **Middleware** | `middleware` | HTTP middleware pipeline with FastAPI and NestJS support |
|
|
464
|
-
| **Structured Logging** | `logging` | Structured logging runtime with correlation IDs, multi-sink output |
|
|
465
|
-
| **Deployment Toolkit** | `deployment` | Portable Docker, Compose, Makefile, and CI assets for RapidKit |
|
|
466
|
-
|
|
467
|
-
#### 📊 Observability (1)
|
|
468
|
-
|
|
469
|
-
| Module | Slug | Description |
|
|
470
|
-
|--------|------|-------------|
|
|
471
|
-
| **Observability Core** | `observability` | Cohesive metrics, tracing, and structured logging foundation |
|
|
472
|
-
|
|
473
|
-
#### 💾 Caching (1)
|
|
474
|
-
|
|
475
|
-
| Module | Slug | Description |
|
|
476
|
-
|--------|------|-------------|
|
|
477
|
-
| **Redis Cache** | `redis` | Production Redis runtime with async and sync client support |
|
|
478
|
-
|
|
479
|
-
#### 🤖 AI (1)
|
|
480
|
-
|
|
481
|
-
| Module | Slug | Description |
|
|
482
|
-
|--------|------|-------------|
|
|
483
|
-
| **AI Assistant** | `ai_assistant` | AI assistant integration capabilities |
|
|
189
|
+
<div align="center">
|
|
484
190
|
|
|
485
|
-
|
|
191
|
+
### **RapidKit VS Code Extension** is the recommended way to use RapidKit
|
|
486
192
|
|
|
487
|
-
|
|
488
|
-
|--------|------|-------------|
|
|
489
|
-
| **Celery** | `celery` | Production Celery task orchestration for asynchronous workflows |
|
|
193
|
+
All npm CLI features + powerful visual tools in one integrated experience
|
|
490
194
|
|
|
491
|
-
|
|
195
|
+
[](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode)
|
|
492
196
|
|
|
493
|
-
|
|
494
|
-
|--------|------|-------------|
|
|
495
|
-
| **Storage** | `storage` | File Storage & Media Management - Upload, store, and retrieve files |
|
|
197
|
+
</div>
|
|
496
198
|
|
|
497
|
-
|
|
199
|
+
**Why use the Extension?**
|
|
200
|
+
|
|
201
|
+
| Feature | npm CLI | VS Code Extension |
|
|
202
|
+
|---------|---------|-------------------|
|
|
203
|
+
| **Project Creation** | ✅ Terminal commands | ✅ Visual wizard with preview |
|
|
204
|
+
| **Module Browse** | ✅ List in terminal | ✅ Rich UI with search & categories |
|
|
205
|
+
| **Module Installation** | ✅ `add module` command | ✅ One-click install with previews |
|
|
206
|
+
| **Workspace Management** | ✅ Basic commands | ✅ Visual tree + auto-discovery |
|
|
207
|
+
| **System Health Check** | ✅ `doctor` command | ✅ Real-time status indicators |
|
|
208
|
+
| **Project Templates** | ✅ Kit selection | ✅ Preview + compare kits visually |
|
|
209
|
+
| **Documentation** | ❌ External links | ✅ Integrated docs & tooltips |
|
|
210
|
+
| **AI Recommendations** | ✅ Terminal prompts | ✅ Interactive suggestions panel |
|
|
211
|
+
| **Multi-project View** | ❌ | ✅ Workspace explorer & switcher |
|
|
212
|
+
| **Quick Actions** | ❌ | ✅ Right-click context menus |
|
|
213
|
+
|
|
214
|
+
**Extension-only features:**
|
|
215
|
+
- 🎨 **Visual Project Browser**: See all projects at a glance
|
|
216
|
+
- 📊 **Live Health Monitoring**: Real-time project status
|
|
217
|
+
- 🔍 **Smart Search**: Find modules instantly with filters
|
|
218
|
+
- 📝 **Inline Documentation**: Hover tooltips for every module
|
|
219
|
+
- ⚡ **Quick Commands**: Keyboard shortcuts for common tasks
|
|
220
|
+
- 🔄 **Auto-sync**: Automatically detect new projects
|
|
221
|
+
- 🎯 **Context Menus**: Right-click actions everywhere
|
|
222
|
+
|
|
223
|
+
> 💡 The Extension includes the full npm package functionality, so you get **both** the CLI and the visual interface!
|
|
224
|
+
|
|
225
|
+
[📥 Install VS Code Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode) • [📖 Extension Docs](https://getrapidkit.com/docs/vscode-extension)
|
|
498
226
|
|
|
499
227
|
---
|
|
500
228
|
|
|
501
|
-
##
|
|
502
|
-
|
|
503
|
-
RapidKit maintains a shared workspace registry at `~/.rapidkit/workspaces.json` for cross-tool compatibility with the VS Code Extension.
|
|
504
|
-
|
|
505
|
-
### List Registered Workspaces
|
|
229
|
+
## 🧠 Core Concepts
|
|
506
230
|
|
|
507
|
-
|
|
508
|
-
rapidkit workspace list
|
|
509
|
-
```
|
|
510
|
-
|
|
511
|
-
**Example output:**
|
|
512
|
-
```
|
|
513
|
-
📦 Registered RapidKit Workspaces:
|
|
514
|
-
|
|
515
|
-
my-workspace
|
|
516
|
-
Path: /home/user/projects/my-workspace
|
|
517
|
-
Projects: 3
|
|
518
|
-
|
|
519
|
-
microservices
|
|
520
|
-
Path: /home/user/work/microservices
|
|
521
|
-
Projects: 7
|
|
522
|
-
|
|
523
|
-
Total: 2 workspace(s)
|
|
524
|
-
```
|
|
525
|
-
|
|
526
|
-
### Sync Workspace Projects
|
|
527
|
-
|
|
528
|
-
Projects are automatically tracked when created. Manual sync is available if needed:
|
|
529
|
-
|
|
530
|
-
```bash
|
|
531
|
-
cd my-workspace
|
|
532
|
-
rapidkit workspace sync
|
|
533
|
-
```
|
|
534
|
-
|
|
535
|
-
This scans the workspace directory and registers all RapidKit projects (directories with `.rapidkit/context.json` or `.rapidkit/project.json`).
|
|
536
|
-
|
|
537
|
-
**When to use manual sync:**
|
|
538
|
-
- Manually moved/copied projects into workspace
|
|
539
|
-
- Created projects before sync feature existed
|
|
540
|
-
- Registry got out of sync
|
|
541
|
-
- Want to refresh after external changes
|
|
542
|
-
|
|
543
|
-
### Registry Format
|
|
544
|
-
|
|
545
|
-
The registry stores workspace and project metadata:
|
|
546
|
-
|
|
547
|
-
```json
|
|
548
|
-
{
|
|
549
|
-
"workspaces": [
|
|
550
|
-
{
|
|
551
|
-
"name": "my-workspace",
|
|
552
|
-
"path": "/home/user/projects/my-workspace",
|
|
553
|
-
"mode": "full",
|
|
554
|
-
"projects": [
|
|
555
|
-
{
|
|
556
|
-
"name": "api-gateway",
|
|
557
|
-
"path": "/home/user/projects/my-workspace/api-gateway"
|
|
558
|
-
},
|
|
559
|
-
{
|
|
560
|
-
"name": "user-service",
|
|
561
|
-
"path": "/home/user/projects/my-workspace/user-service"
|
|
562
|
-
}
|
|
563
|
-
]
|
|
564
|
-
}
|
|
565
|
-
]
|
|
566
|
-
}
|
|
567
|
-
```
|
|
231
|
+
### Workspace vs Standalone
|
|
568
232
|
|
|
569
|
-
|
|
570
|
-
- Workspaces registered when created via `npx rapidkit <name>` or VS Code Extension
|
|
571
|
-
- Projects registered when created via `rapidkit create project ...` inside workspace
|
|
572
|
-
- VS Code Extension and npm CLI share the same registry
|
|
233
|
+
Choose the right mode for your use case:
|
|
573
234
|
|
|
574
|
-
|
|
235
|
+
| Feature | Workspace Mode | Standalone Mode |
|
|
236
|
+
|---------|----------------|-----------------|
|
|
237
|
+
| **Best For** | Teams, microservices, multiple projects | Single project, quick prototyping |
|
|
238
|
+
| **Setup Time** | ~2 minutes (one time) | ~30 seconds |
|
|
239
|
+
| **Disk Usage** | Efficient (one venv) | Higher (multiple venvs) |
|
|
240
|
+
| **Python Environment** | Shared across all projects | Separate per project |
|
|
241
|
+
| **Project Tracking** | Auto-tracked in registry | Manual |
|
|
242
|
+
| **VS Code Extension** | Auto-discovery | Manual discovery |
|
|
575
243
|
|
|
576
|
-
|
|
244
|
+
### Project Structure
|
|
577
245
|
|
|
578
|
-
|
|
246
|
+
#### Workspace Structure
|
|
579
247
|
|
|
580
248
|
```
|
|
581
249
|
my-workspace/
|
|
582
|
-
├──
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
├── my-service/ # NestJS project
|
|
590
|
-
│ ├── .rapidkit/ # Project config
|
|
591
|
-
│ ├── src/ # Source code
|
|
592
|
-
│ ├── test/ # Test suite
|
|
593
|
-
│ ├── package.json # npm config
|
|
594
|
-
│ └── Dockerfile # Docker setup
|
|
595
|
-
├── .venv/ # Workspace Python environment
|
|
596
|
-
├── .rapidkit-workspace # Workspace metadata
|
|
597
|
-
├── poetry.lock # Locked Python dependencies
|
|
598
|
-
├── pyproject.toml # Workspace Python config
|
|
599
|
-
├── rapidkit # CLI script (bash)
|
|
600
|
-
├── rapidkit.cmd # CLI script (Windows)
|
|
250
|
+
├── .rapidkit-workspace # Workspace marker file
|
|
251
|
+
├── .venv/ # Shared Python environment
|
|
252
|
+
├── poetry.lock # Locked dependencies
|
|
253
|
+
├── poetry.toml # Poetry configuration
|
|
254
|
+
├── pyproject.toml # Workspace Python config
|
|
255
|
+
├── rapidkit # CLI script (Unix)
|
|
256
|
+
├── rapidkit.cmd # CLI script (Windows)
|
|
601
257
|
├── README.md
|
|
602
|
-
|
|
258
|
+
├── my-api/ # FastAPI project
|
|
259
|
+
├── my-service/ # NestJS project
|
|
260
|
+
└── my-admin/ # Another project
|
|
603
261
|
```
|
|
604
262
|
|
|
605
|
-
|
|
263
|
+
#### FastAPI Project (DDD Architecture)
|
|
606
264
|
|
|
607
265
|
```
|
|
608
266
|
my-api/
|
|
609
|
-
├── .rapidkit/ # RapidKit
|
|
610
|
-
│ ├──
|
|
611
|
-
│ ├──
|
|
612
|
-
│ ├──
|
|
613
|
-
│ └──
|
|
614
|
-
├── src/
|
|
615
|
-
│ ├──
|
|
267
|
+
├── .rapidkit/ # RapidKit metadata & CLI
|
|
268
|
+
│ ├── activate # Environment activation
|
|
269
|
+
│ ├── cli.py # Local CLI commands
|
|
270
|
+
│ ├── context.json # Build context
|
|
271
|
+
│ └── rapidkit # Project CLI launcher
|
|
272
|
+
├── src/
|
|
273
|
+
│ ├── app/ # DDD layers
|
|
274
|
+
│ │ ├── application/ # Use cases & interfaces
|
|
275
|
+
│ │ ├── domain/ # Business logic & models
|
|
276
|
+
│ │ ├── infrastructure/ # External services & repos
|
|
277
|
+
│ │ ├── presentation/ # API controllers & routes
|
|
278
|
+
│ │ ├── config/ # Configuration
|
|
279
|
+
│ │ ├── shared/ # Shared utilities
|
|
280
|
+
│ │ └── main.py # Application entry
|
|
281
|
+
│ ├── modules/ # RapidKit modules
|
|
282
|
+
│ │ └── free/ # Free modules (auth, db, etc.)
|
|
616
283
|
│ ├── routing/ # API routes
|
|
617
|
-
│
|
|
618
|
-
│
|
|
619
|
-
│
|
|
620
|
-
│ └── modules/ # Feature modules
|
|
621
|
-
│ └── __init__.py
|
|
622
|
-
├── config/ # Configuration
|
|
284
|
+
│ ├── health/ # Health check endpoints
|
|
285
|
+
│ ├── cli.py # CLI commands
|
|
286
|
+
│ └── main.py # FastAPI app entry
|
|
623
287
|
├── tests/ # Test suite
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
├──
|
|
628
|
-
├──
|
|
629
|
-
├── .
|
|
630
|
-
├── bootstrap.sh # Setup script
|
|
631
|
-
├── docker-compose.yml # Docker Compose
|
|
632
|
-
├── Dockerfile # Docker configuration
|
|
633
|
-
├── Makefile # Make commands
|
|
288
|
+
├── config/ # Configuration files
|
|
289
|
+
├── .github/workflows/ # CI/CD pipelines
|
|
290
|
+
├── docker-compose.yml # Docker Compose setup
|
|
291
|
+
├── Dockerfile # Production container
|
|
292
|
+
├── Makefile # Quick commands
|
|
293
|
+
├── pyproject.toml # Poetry dependencies
|
|
634
294
|
├── poetry.lock # Locked dependencies
|
|
635
|
-
├──
|
|
636
|
-
├──
|
|
295
|
+
├── bootstrap.sh # Setup script
|
|
296
|
+
├── .env.example # Environment template
|
|
297
|
+
├── .pre-commit-config.yaml # Pre-commit hooks
|
|
637
298
|
└── README.md
|
|
638
299
|
```
|
|
639
300
|
|
|
640
|
-
|
|
301
|
+
#### NestJS Project (Standard Architecture)
|
|
641
302
|
|
|
642
303
|
```
|
|
643
|
-
my-
|
|
644
|
-
├── .rapidkit/ # RapidKit
|
|
645
|
-
│ ├──
|
|
646
|
-
│ ├── context.json #
|
|
647
|
-
│ └──
|
|
648
|
-
├── src/
|
|
649
|
-
│ ├── main.ts # NestJS entry point
|
|
304
|
+
my-service/
|
|
305
|
+
├── .rapidkit/ # RapidKit metadata & CLI
|
|
306
|
+
│ ├── activate # Environment activation
|
|
307
|
+
│ ├── context.json # Build context
|
|
308
|
+
│ └── rapidkit # Project CLI launcher
|
|
309
|
+
├── src/
|
|
650
310
|
│ ├── app.module.ts # Root module
|
|
651
311
|
│ ├── app.controller.ts # Root controller
|
|
652
312
|
│ ├── app.service.ts # Root service
|
|
313
|
+
│ ├── main.ts # NestJS entry point
|
|
653
314
|
│ ├── config/ # Configuration module
|
|
654
315
|
│ │ ├── configuration.ts
|
|
655
|
-
│ │
|
|
656
|
-
│ └──
|
|
657
|
-
│
|
|
658
|
-
│
|
|
659
|
-
│
|
|
660
|
-
├──
|
|
661
|
-
│ ├──
|
|
662
|
-
│
|
|
663
|
-
├── .
|
|
664
|
-
|
|
665
|
-
├──
|
|
666
|
-
├──
|
|
667
|
-
├──
|
|
668
|
-
├──
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
├──
|
|
316
|
+
│ │ ├── validation.ts
|
|
317
|
+
│ │ └── index.ts
|
|
318
|
+
│ ├── modules/ # RapidKit modules
|
|
319
|
+
│ │ ├── free/ # Free modules (auth, db, etc.)
|
|
320
|
+
│ │ └── index.ts # Module registry
|
|
321
|
+
│ ├── auth/ # Auth feature module
|
|
322
|
+
│ │ ├── auth.module.ts
|
|
323
|
+
│ │ ├── auth.controller.ts
|
|
324
|
+
│ │ ├── auth.service.ts
|
|
325
|
+
│ │ └── entities/
|
|
326
|
+
│ ├── examples/ # Example CRUD module
|
|
327
|
+
│ │ ├── examples.module.ts
|
|
328
|
+
│ │ ├── examples.controller.ts
|
|
329
|
+
│ │ ├── examples.service.ts
|
|
330
|
+
│ │ └── dto/
|
|
331
|
+
│ └── health/ # Health check endpoints
|
|
332
|
+
├── test/ # E2E tests
|
|
333
|
+
├── tests/ # Unit tests
|
|
334
|
+
├── .github/workflows/ # CI/CD pipelines
|
|
335
|
+
├── docker-compose.yml # Docker Compose setup
|
|
336
|
+
├── Dockerfile # Production container
|
|
337
|
+
├── Makefile # Quick commands
|
|
672
338
|
├── package.json # npm dependencies
|
|
339
|
+
├── yarn.lock / package-lock.json # Locked dependencies
|
|
340
|
+
├── nest-cli.json # NestJS CLI config
|
|
673
341
|
├── tsconfig.json # TypeScript config
|
|
674
|
-
├──
|
|
342
|
+
├── tsconfig.build.json # Build config
|
|
343
|
+
├── jest.config.ts # Jest test config
|
|
344
|
+
├── eslint.config.cjs # ESLint config
|
|
345
|
+
├── bootstrap.sh # Setup script
|
|
346
|
+
├── .env.example # Environment template
|
|
675
347
|
└── README.md
|
|
676
348
|
```
|
|
677
349
|
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
## 📋 Requirements
|
|
681
|
-
|
|
682
|
-
### System Requirements
|
|
350
|
+
### Module System
|
|
683
351
|
|
|
684
|
-
|
|
685
|
-
- **Python**: 3.10+ (required for RapidKit Core)
|
|
686
|
-
- **Git**: For version control
|
|
352
|
+
RapidKit's modules are plug-and-play components that extend your project:
|
|
687
353
|
|
|
688
|
-
|
|
354
|
+
```bash
|
|
355
|
+
# Add authentication
|
|
356
|
+
rapidkit add module auth
|
|
689
357
|
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
358
|
+
# Add database with caching
|
|
359
|
+
rapidkit add module db_postgres
|
|
360
|
+
rapidkit add module redis
|
|
693
361
|
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
362
|
+
# Add payment processing
|
|
363
|
+
rapidkit add module stripe
|
|
364
|
+
```
|
|
697
365
|
|
|
698
|
-
|
|
366
|
+
Modules include:
|
|
367
|
+
- ✅ Pre-configured code
|
|
368
|
+
- ✅ Dependencies (auto-added to pyproject.toml/package.json)
|
|
369
|
+
- ✅ Configuration templates
|
|
370
|
+
- ✅ Tests and documentation
|
|
371
|
+
- ✅ Best practices baked in
|
|
699
372
|
|
|
700
|
-
|
|
701
|
-
- **VS Code**: For Extension integration
|
|
702
|
-
- **Make**: For Makefile commands (usually pre-installed on Unix)
|
|
373
|
+
### 🤖 AI-Powered Recommendations
|
|
703
374
|
|
|
704
|
-
|
|
375
|
+
Not sure which modules you need? Ask AI:
|
|
705
376
|
|
|
706
|
-
|
|
377
|
+
```bash
|
|
378
|
+
npx rapidkit ai recommend "I want to build a SaaS with authentication and payments"
|
|
707
379
|
|
|
708
|
-
|
|
380
|
+
# Output:
|
|
381
|
+
# 📦 Recommended Modules:
|
|
382
|
+
# 1. Authentication Core (92% match)
|
|
383
|
+
# 2. Users Core (88% match)
|
|
384
|
+
# 3. Stripe Payment (85% match)
|
|
385
|
+
# 4. PostgreSQL (82% match)
|
|
386
|
+
```
|
|
709
387
|
|
|
388
|
+
**Setup (one-time):**
|
|
710
389
|
```bash
|
|
711
|
-
|
|
712
|
-
|
|
390
|
+
rapidkit config set-api-key # Configure OpenAI API key
|
|
391
|
+
rapidkit ai generate-embeddings # Generate embeddings (~$0.50)
|
|
713
392
|
```
|
|
714
393
|
|
|
715
|
-
|
|
394
|
+
**Features:**
|
|
395
|
+
- 🧠 Understands natural language queries
|
|
396
|
+
- 🎯 Suggests relevant modules with confidence scores
|
|
397
|
+
- 💰 Ultra-cheap: ~$0.0002 per query
|
|
398
|
+
- ✅ Works in mock mode without API key (for testing)
|
|
399
|
+
|
|
400
|
+
[More about AI features →](https://getrapidkit.com/docs/ai)
|
|
716
401
|
|
|
717
|
-
|
|
718
|
-
- `action` - For workspace commands: `list` or `sync`
|
|
402
|
+
---
|
|
719
403
|
|
|
720
|
-
|
|
404
|
+
## 🧩 Module Ecosystem
|
|
721
405
|
|
|
722
|
-
|
|
723
|
-
- `--skip-git` - Skip git initialization
|
|
724
|
-
- `--debug` - Enable verbose debug logging
|
|
725
|
-
- `--dry-run` - Preview what would be created without creating it
|
|
726
|
-
- `--no-update-check` - Skip checking for newer versions
|
|
727
|
-
- `--help` - Display help information
|
|
728
|
-
- `--version` - Show version number
|
|
406
|
+
RapidKit includes **27 production-ready modules** across 10 categories:
|
|
729
407
|
|
|
730
|
-
###
|
|
408
|
+
### Quick Overview
|
|
731
409
|
|
|
732
|
-
-
|
|
733
|
-
-
|
|
734
|
-
-
|
|
410
|
+
- 🔐 **Authentication** (5 modules): Core Auth, API Keys, OAuth, Passwordless, Sessions
|
|
411
|
+
- 💳 **Payments & E-commerce** (3): Stripe, Shopping Cart, Inventory
|
|
412
|
+
- 🗄️ **Databases** (3): PostgreSQL, MongoDB, SQLite
|
|
413
|
+
- 🔒 **Security** (3): CORS, Rate Limiting, Security Headers
|
|
414
|
+
- 📧 **Communication** (2): Email, Unified Notifications
|
|
415
|
+
- 👥 **User Management** (2): Users Core, User Profiles
|
|
416
|
+
- ⚙️ **Essentials** (4): Settings, Middleware, Logging, Deployment
|
|
417
|
+
- 📊 **Observability** (1): Metrics & Tracing
|
|
418
|
+
- 💾 **Caching** (1): Redis
|
|
419
|
+
- 🤖 **AI** (1): AI Assistant
|
|
420
|
+
- ⚡ **Tasks** (1): Celery
|
|
421
|
+
- 💼 **Storage** (1): File Management
|
|
735
422
|
|
|
736
|
-
###
|
|
423
|
+
### Browse & Install
|
|
737
424
|
|
|
738
425
|
```bash
|
|
739
|
-
#
|
|
740
|
-
|
|
426
|
+
# List all modules
|
|
427
|
+
rapidkit modules list
|
|
741
428
|
|
|
742
|
-
#
|
|
743
|
-
|
|
429
|
+
# View module details
|
|
430
|
+
rapidkit modules info auth
|
|
431
|
+
rapidkit modules info db_postgres
|
|
744
432
|
|
|
745
|
-
#
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
# Skip update check
|
|
749
|
-
npx rapidkit create --no-update-check
|
|
433
|
+
# Install modules
|
|
434
|
+
rapidkit add module auth
|
|
435
|
+
rapidkit add module db_postgres redis
|
|
750
436
|
```
|
|
751
437
|
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
## 🔧 Troubleshooting
|
|
755
|
-
|
|
756
|
-
### Common Issues
|
|
438
|
+
### Popular Combinations
|
|
757
439
|
|
|
758
|
-
|
|
759
|
-
|
|
440
|
+
**SaaS Starter:**
|
|
441
|
+
```bash
|
|
442
|
+
rapidkit add module auth users db_postgres redis session
|
|
443
|
+
```
|
|
760
444
|
|
|
761
|
-
**
|
|
445
|
+
**E-commerce API:**
|
|
446
|
+
```bash
|
|
447
|
+
rapidkit add module auth users db_postgres cart inventory stripe
|
|
448
|
+
```
|
|
762
449
|
|
|
763
|
-
**
|
|
450
|
+
**Enterprise API:**
|
|
451
|
+
```bash
|
|
452
|
+
rapidkit add module auth api_keys db_postgres redis rate_limiting observability
|
|
453
|
+
```
|
|
764
454
|
|
|
765
|
-
**
|
|
455
|
+
📚 **[View Full Module Catalog →](https://getrapidkit.com/modules)**
|
|
766
456
|
|
|
767
|
-
|
|
768
|
-
# Solution 1: Use poetry run prefix
|
|
769
|
-
poetry run rapidkit create
|
|
457
|
+
---
|
|
770
458
|
|
|
771
|
-
|
|
772
|
-
source "$(poetry env info --path)/bin/activate"
|
|
773
|
-
rapidkit create
|
|
459
|
+
## 💻 Commands Reference
|
|
774
460
|
|
|
775
|
-
|
|
776
|
-
rapidkit create project fastapi.standard my-api
|
|
461
|
+
### Global Commands (Run Anywhere)
|
|
777
462
|
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
npx rapidkit
|
|
782
|
-
```
|
|
783
|
-
</details>
|
|
463
|
+
```bash
|
|
464
|
+
# Project creation
|
|
465
|
+
npx rapidkit create project # Interactive wizard
|
|
466
|
+
npx rapidkit create project <kit> <name> # Direct creation
|
|
784
467
|
|
|
785
|
-
|
|
786
|
-
|
|
468
|
+
# Information
|
|
469
|
+
npx rapidkit list # List kits
|
|
470
|
+
npx rapidkit modules list # List modules
|
|
471
|
+
npx rapidkit kits info <name> # Kit details
|
|
472
|
+
npx rapidkit modules info <name> # Module details
|
|
787
473
|
|
|
788
|
-
|
|
474
|
+
# System health
|
|
475
|
+
npx rapidkit doctor # Check system
|
|
476
|
+
npx rapidkit doctor --workspace # Check workspace
|
|
477
|
+
npx rapidkit doctor --workspace --fix # Auto-fix issues
|
|
478
|
+
npx rapidkit doctor --workspace --json # JSON output (CI/CD)
|
|
789
479
|
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
ls -la .rapidkit-workspace
|
|
480
|
+
# Workspace management
|
|
481
|
+
npx rapidkit workspace list # List workspaces
|
|
482
|
+
npx rapidkit workspace sync # Sync projects
|
|
794
483
|
|
|
795
|
-
#
|
|
796
|
-
rapidkit
|
|
484
|
+
# CLI info
|
|
485
|
+
npx rapidkit --version # Show version
|
|
486
|
+
npx rapidkit --help # Show help
|
|
797
487
|
```
|
|
798
488
|
|
|
799
|
-
|
|
489
|
+
### Project Commands (Run Inside Project)
|
|
490
|
+
|
|
800
491
|
```bash
|
|
801
|
-
#
|
|
802
|
-
rapidkit
|
|
492
|
+
npx rapidkit init # Install dependencies (auto-activates venv)
|
|
493
|
+
npx rapidkit dev # Start dev server with hot reload
|
|
494
|
+
npx rapidkit start # Start production server
|
|
495
|
+
npx rapidkit build # Build for production
|
|
496
|
+
npx rapidkit test # Run tests with coverage
|
|
497
|
+
npx rapidkit lint # Run linting
|
|
498
|
+
npx rapidkit format # Format code
|
|
803
499
|
```
|
|
804
|
-
</details>
|
|
805
500
|
|
|
806
|
-
|
|
807
|
-
<summary><strong>📋 Project not auto-registered</strong></summary>
|
|
808
|
-
|
|
809
|
-
**Problem:** New project not showing in `workspace list`.
|
|
501
|
+
### Module Commands
|
|
810
502
|
|
|
811
|
-
**Solution:**
|
|
812
503
|
```bash
|
|
813
|
-
|
|
814
|
-
rapidkit
|
|
504
|
+
npx rapidkit add module <slug> # Add single module
|
|
505
|
+
npx rapidkit add module auth redis # Add multiple modules
|
|
506
|
+
npx rapidkit modules list # List available modules
|
|
507
|
+
npx rapidkit modules info <slug> # Module details
|
|
815
508
|
```
|
|
816
509
|
|
|
817
|
-
|
|
818
|
-
</details>
|
|
819
|
-
|
|
820
|
-
<details>
|
|
821
|
-
<summary><strong>🐍 Python version mismatch</strong></summary>
|
|
822
|
-
|
|
823
|
-
**Problem:** Python 3.10+ required but not found.
|
|
824
|
-
|
|
825
|
-
**Solution:**
|
|
510
|
+
### Advanced Options
|
|
826
511
|
|
|
827
512
|
```bash
|
|
828
|
-
#
|
|
829
|
-
|
|
513
|
+
# Workspace creation
|
|
514
|
+
npx rapidkit <name> --yes # Skip prompts
|
|
515
|
+
npx rapidkit <name> --skip-git # Skip git init
|
|
516
|
+
npx rapidkit <name> --dry-run # Preview only
|
|
517
|
+
npx rapidkit <name> --debug # Verbose logging
|
|
830
518
|
|
|
831
|
-
#
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
# Verify installation
|
|
835
|
-
python3.10 --version
|
|
519
|
+
# Project creation
|
|
520
|
+
npx rapidkit create --output <dir> # Custom location
|
|
521
|
+
npx rapidkit create --no-update-check # Skip version check
|
|
836
522
|
```
|
|
837
|
-
</details>
|
|
838
|
-
|
|
839
|
-
<details>
|
|
840
|
-
<summary><strong>📦 Poetry not found</strong></summary>
|
|
841
523
|
|
|
842
|
-
**
|
|
524
|
+
**Quick Reference Table:**
|
|
843
525
|
|
|
844
|
-
|
|
526
|
+
| Command | Description | Context |
|
|
527
|
+
|---------|-------------|---------|
|
|
528
|
+
| `create project` | Create project | Anywhere |
|
|
529
|
+
| `init` | Install dependencies | Inside project |
|
|
530
|
+
| `dev` | Start dev server | Inside project |
|
|
531
|
+
| `test` | Run tests | Inside project |
|
|
532
|
+
| `add module` | Add module to project | Inside project |
|
|
533
|
+
| `list` | List kits | Anywhere |
|
|
534
|
+
| `modules list` | List modules | Anywhere |
|
|
535
|
+
| `doctor` | Health check | Anywhere |
|
|
536
|
+
| `workspace` | Manage workspaces | Anywhere |
|
|
845
537
|
|
|
846
|
-
|
|
847
|
-
# Install Poetry
|
|
848
|
-
curl -sSL https://install.python-poetry.org | python3 -
|
|
538
|
+
---
|
|
849
539
|
|
|
850
|
-
|
|
851
|
-
export PATH="$HOME/.local/bin:$PATH"
|
|
540
|
+
## 📋 Requirements
|
|
852
541
|
|
|
853
|
-
|
|
854
|
-
poetry --version
|
|
855
|
-
```
|
|
856
|
-
</details>
|
|
542
|
+
### System Requirements
|
|
857
543
|
|
|
858
|
-
|
|
859
|
-
|
|
544
|
+
- **Node.js**: 20.19.6+ LTS (20.x or 22.x recommended)
|
|
545
|
+
- **Python**: 3.10+ (required for RapidKit Core)
|
|
546
|
+
- **Git**: For version control
|
|
860
547
|
|
|
861
|
-
|
|
548
|
+
### Framework-Specific
|
|
862
549
|
|
|
863
|
-
**
|
|
550
|
+
**FastAPI Projects:**
|
|
551
|
+
- Python 3.10+
|
|
552
|
+
- Poetry (auto-installed if missing)
|
|
864
553
|
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
poetry env remove python
|
|
869
|
-
poetry install
|
|
870
|
-
|
|
871
|
-
# For venv workspace
|
|
872
|
-
rm -rf .venv
|
|
873
|
-
python3 -m venv .venv
|
|
874
|
-
source .venv/bin/activate
|
|
875
|
-
pip install rapidkit-core
|
|
876
|
-
```
|
|
877
|
-
</details>
|
|
554
|
+
**NestJS Projects:**
|
|
555
|
+
- Node.js 20.19.6+
|
|
556
|
+
- npm/yarn/pnpm
|
|
878
557
|
|
|
879
|
-
###
|
|
558
|
+
### Optional but Recommended
|
|
880
559
|
|
|
881
|
-
|
|
560
|
+
- **Docker**: For containerized development
|
|
561
|
+
- **VS Code**: For Extension integration
|
|
562
|
+
- **Make**: For Makefile commands (pre-installed on Unix)
|
|
882
563
|
|
|
883
|
-
|
|
884
|
-
2. **Search existing issues:** https://github.com/getrapidkit/rapidkit-npm/issues
|
|
885
|
-
3. **Run diagnostics:** `rapidkit doctor`
|
|
886
|
-
4. **Open a new issue:** Include `rapidkit --version`, OS, Node.js version, and error output
|
|
564
|
+
> 💡 **Tip:** Use `rapidkit doctor` to check all requirements automatically!
|
|
887
565
|
|
|
888
566
|
---
|
|
889
567
|
|
|
@@ -892,13 +570,13 @@ If you encounter issues not covered here:
|
|
|
892
570
|
<details>
|
|
893
571
|
<summary><strong>Do I need Python installed?</strong></summary>
|
|
894
572
|
|
|
895
|
-
Yes, Python 3.10+ is required for RapidKit Core (the engine). The npm package will bootstrap it
|
|
573
|
+
Yes, Python 3.10+ is required for RapidKit Core (the engine). The npm package will bootstrap it if needed, but system-wide installation is recommended.
|
|
896
574
|
</details>
|
|
897
575
|
|
|
898
576
|
<details>
|
|
899
577
|
<summary><strong>Can I use this without npm?</strong></summary>
|
|
900
578
|
|
|
901
|
-
Yes! Install globally: `npm i -g rapidkit`, then use `rapidkit` directly
|
|
579
|
+
Yes! Install globally: `npm i -g rapidkit`, then use `rapidkit` directly. You'll still need Node.js installed.
|
|
902
580
|
</details>
|
|
903
581
|
|
|
904
582
|
<details>
|
|
@@ -906,853 +584,89 @@ Yes! Install globally: `npm i -g rapidkit`, then use `rapidkit` directly without
|
|
|
906
584
|
|
|
907
585
|
RapidKit provides:
|
|
908
586
|
- **Living templates** that receive updates
|
|
909
|
-
- **
|
|
910
|
-
- **Workspace management**
|
|
911
|
-
- **VS Code integration**
|
|
912
|
-
- **
|
|
913
|
-
- **Built-in CLI** commands (dev, test, lint, etc.)
|
|
587
|
+
- **27+ plug-and-play modules**
|
|
588
|
+
- **Workspace management**
|
|
589
|
+
- **VS Code integration**
|
|
590
|
+
- **Built-in dev commands** (dev, test, lint)
|
|
914
591
|
|
|
915
|
-
Cookiecutter is
|
|
592
|
+
Cookiecutter is one-time scaffolding. RapidKit is a complete development platform.
|
|
916
593
|
</details>
|
|
917
594
|
|
|
918
595
|
<details>
|
|
919
596
|
<summary><strong>Do I need the VS Code Extension?</strong></summary>
|
|
920
597
|
|
|
921
|
-
No, but
|
|
922
|
-
- Visual interface for creating projects
|
|
923
|
-
- One-click module installation
|
|
924
|
-
- Workspace browser
|
|
925
|
-
- System requirements checker
|
|
926
|
-
- Integrated terminal commands
|
|
927
|
-
|
|
928
|
-
CLI is fully functional standalone.
|
|
598
|
+
No, but highly recommended! It provides visual interface, one-click module installation, workspace browser, and system checker.
|
|
929
599
|
</details>
|
|
930
600
|
|
|
931
601
|
<details>
|
|
932
|
-
<summary><strong>Can I
|
|
933
|
-
|
|
934
|
-
Yes! During workspace creation, you can choose:
|
|
935
|
-
- **Poetry** (recommended - better dependency management)
|
|
936
|
-
- **venv** (standard Python virtualenv)
|
|
937
|
-
- **pipx** (global user install)
|
|
602
|
+
<summary><strong>Can I customize generated projects?</strong></summary>
|
|
938
603
|
|
|
939
|
-
|
|
604
|
+
Yes! After generation, files are yours. Modify as needed, add/remove modules, update dependencies. RapidKit won't overwrite your changes.
|
|
940
605
|
</details>
|
|
941
606
|
|
|
942
607
|
<details>
|
|
943
608
|
<summary><strong>How do I upgrade RapidKit?</strong></summary>
|
|
944
609
|
|
|
945
610
|
```bash
|
|
946
|
-
# For global install
|
|
947
|
-
npm update -g rapidkit
|
|
948
|
-
|
|
949
611
|
# For npx usage (automatic)
|
|
950
612
|
npx rapidkit@latest create
|
|
951
613
|
|
|
614
|
+
# For global install
|
|
615
|
+
npm update -g rapidkit
|
|
616
|
+
|
|
952
617
|
# For workspace Python Core
|
|
953
618
|
cd my-workspace
|
|
954
619
|
poetry update rapidkit-core
|
|
955
|
-
# OR
|
|
956
|
-
pip install --upgrade rapidkit-core
|
|
957
620
|
```
|
|
958
621
|
</details>
|
|
959
622
|
|
|
960
623
|
<details>
|
|
961
|
-
<summary><strong>
|
|
962
|
-
|
|
963
|
-
Yes! After generation:
|
|
964
|
-
1. Modify files as needed - they're yours
|
|
965
|
-
2. Add/remove modules: `rapidkit add module <name>`
|
|
966
|
-
3. Update dependencies in `pyproject.toml` or `package.json`
|
|
967
|
-
4. RapidKit won't overwrite your changes
|
|
968
|
-
|
|
969
|
-
For template-level changes, consider:
|
|
970
|
-
- Creating custom kits (see Core docs)
|
|
971
|
-
- Using RapidKit as a starting point
|
|
972
|
-
</details>
|
|
973
|
-
|
|
974
|
-
<details>
|
|
975
|
-
<summary><strong>Is there a Docker workflow?</strong></summary>
|
|
624
|
+
<summary><strong>Is there Docker support?</strong></summary>
|
|
976
625
|
|
|
977
626
|
Yes! All projects include:
|
|
978
|
-
- `Dockerfile` for production
|
|
627
|
+
- `Dockerfile` for production
|
|
979
628
|
- `docker-compose.yml` for development
|
|
980
629
|
- `.dockerignore` for optimization
|
|
981
630
|
|
|
982
631
|
```bash
|
|
983
|
-
# Development
|
|
984
|
-
docker-
|
|
985
|
-
|
|
986
|
-
# Production
|
|
987
|
-
docker build -t my-service .
|
|
988
|
-
docker run -p 8000:8000 my-service
|
|
632
|
+
docker-compose up # Development
|
|
633
|
+
docker build -t my-service . && docker run -p 8000:8000 my-service # Production
|
|
989
634
|
```
|
|
990
635
|
</details>
|
|
991
636
|
|
|
992
|
-
|
|
993
|
-
<summary><strong>How does workspace registry work with teams?</strong></summary>
|
|
994
|
-
|
|
995
|
-
The registry (`~/.rapidkit/workspaces.json`) is **user-local**, not project-local:
|
|
996
|
-
- Each developer has their own registry
|
|
997
|
-
- Workspaces are auto-discovered when cloned
|
|
998
|
-
- VS Code Extension syncs automatically
|
|
999
|
-
- Git doesn't track the registry (it's in `~/.rapidkit/`)
|
|
1000
|
-
|
|
1001
|
-
For team sharing:
|
|
1002
|
-
- Commit workspace code to Git
|
|
1003
|
-
- Each developer runs `rapidkit workspace sync` after clone
|
|
1004
|
-
- Or let VS Code Extension auto-discover
|
|
1005
|
-
</details>
|
|
637
|
+
**More Questions?** Check [Full Documentation](https://getrapidkit.com) or [Open an Issue](https://github.com/getrapidkit/rapidkit-npm/issues)
|
|
1006
638
|
|
|
1007
639
|
---
|
|
1008
640
|
|
|
1009
|
-
##
|
|
641
|
+
## 🔗 Links
|
|
1010
642
|
|
|
1011
|
-
###
|
|
643
|
+
### 📚 Documentation & Resources
|
|
644
|
+
- [Official Website](https://getrapidkit.com) – Complete documentation and guides
|
|
645
|
+
- [Full Module Catalog](https://getrapidkit.com/modules) – Browse all 27+ modules
|
|
646
|
+
- [Getting Started Guide](https://getrapidkit.com/docs/getting-started) – Step-by-step tutorials
|
|
1012
647
|
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
|
|
1016
|
-
cd rapidkit-npm
|
|
648
|
+
### 🛠️ Tools & Extensions
|
|
649
|
+
- [VS Code Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode) – Visual project creation & module management
|
|
650
|
+
- [RapidKit Core (Python)](https://pypi.org/project/rapidkit-core/) – The engine powering RapidKit
|
|
1017
651
|
|
|
1018
|
-
|
|
1019
|
-
npm
|
|
652
|
+
### 💬 Community & Support
|
|
653
|
+
- [GitHub Discussions](https://github.com/getrapidkit/rapidkit-npm/discussions) – Ask questions & share ideas
|
|
654
|
+
- [GitHub Issues](https://github.com/getrapidkit/rapidkit-npm/issues) – Report bugs & request features
|
|
655
|
+
- [Discord Community](https://discord.gg/rapidkit) – Chat with other developers
|
|
1020
656
|
|
|
1021
|
-
|
|
1022
|
-
|
|
657
|
+
### 📱 Social
|
|
658
|
+
- [Twitter/X](https://twitter.com/getrapidkit) – Updates & announcements
|
|
659
|
+
- [GitHub Organization](https://github.com/getrapidkit) – All repositories
|
|
660
|
+
- [Blog](https://getrapidkit.com/blog) – Tutorials & best practices
|
|
1023
661
|
|
|
1024
|
-
|
|
1025
|
-
npm test
|
|
662
|
+
---
|
|
1026
663
|
|
|
1027
|
-
|
|
1028
|
-
npm run dev
|
|
1029
|
-
```
|
|
664
|
+
<div align="center">
|
|
1030
665
|
|
|
1031
|
-
|
|
1032
|
-
|
|
1033
|
-
```bash
|
|
1034
|
-
# Build and link locally
|
|
1035
|
-
npm run install:local
|
|
1036
|
-
|
|
1037
|
-
# Now rapidkit command uses your local build
|
|
1038
|
-
rapidkit --version
|
|
1039
|
-
|
|
1040
|
-
# Uninstall local version
|
|
1041
|
-
npm run uninstall:local
|
|
1042
|
-
```
|
|
1043
|
-
|
|
1044
|
-
### Project Scripts
|
|
1045
|
-
|
|
1046
|
-
```json
|
|
1047
|
-
{
|
|
1048
|
-
"dev": "tsup --watch",
|
|
1049
|
-
"build": "tsup",
|
|
1050
|
-
"test": "vitest run",
|
|
1051
|
-
"test:watch": "vitest",
|
|
1052
|
-
"lint": "eslint src",
|
|
1053
|
-
"install:local": "npm unlink -g rapidkit 2>/dev/null || true && npm run build && npm link",
|
|
1054
|
-
"uninstall:local": "npm unlink -g rapidkit"
|
|
1055
|
-
}
|
|
1056
|
-
```
|
|
1057
|
-
|
|
1058
|
-
---
|
|
1059
|
-
|
|
1060
|
-
## 🤝 Contributing
|
|
1061
|
-
|
|
1062
|
-
We welcome contributions! See [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.
|
|
1063
|
-
|
|
1064
|
-
### Ways to Contribute
|
|
1065
|
-
|
|
1066
|
-
- 🐛 [Report bugs](https://github.com/getrapidkit/rapidkit-npm/issues)
|
|
1067
|
-
- 💡 [Request features](https://github.com/getrapidkit/rapidkit-npm/issues)
|
|
1068
|
-
- 📖 [Improve documentation](https://github.com/getrapidkit/rapidkit-npm/pulls)
|
|
1069
|
-
- 🔧 [Submit pull requests](https://github.com/getrapidkit/rapidkit-npm/pulls)
|
|
1070
|
-
|
|
1071
|
-
### Development Guidelines
|
|
1072
|
-
|
|
1073
|
-
1. Fork the repository
|
|
1074
|
-
2. Create a feature branch: `git checkout -b feature/my-feature`
|
|
1075
|
-
3. Make your changes with tests
|
|
1076
|
-
4. Run tests: `npm test`
|
|
1077
|
-
5. Commit: `git commit -m "feat: add awesome feature"`
|
|
1078
|
-
6. Push: `git push origin feature/my-feature`
|
|
1079
|
-
7. Open a Pull Request
|
|
1080
|
-
|
|
1081
|
-
---
|
|
1082
|
-
|
|
1083
|
-
## 🔗 Related Projects
|
|
1084
|
-
|
|
1085
|
-
- **[RapidKit Core (Python)](https://pypi.org/project/rapidkit-core/)** - The engine powering RapidKit
|
|
1086
|
-
- **[RapidKit VS Code Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode)** - Visual interface
|
|
1087
|
-
- **[RapidKit Documentation](https://getrapidkit.com)** - Full documentation
|
|
1088
|
-
- **[GitHub Organization](https://github.com/getrapidkit)** - All repositories
|
|
1089
|
-
|
|
1090
|
-
---
|
|
1091
|
-
|
|
1092
|
-
## 📄 License
|
|
1093
|
-
|
|
1094
|
-
MIT License - see [LICENSE](LICENSE) for details.
|
|
1095
|
-
|
|
1096
|
-
---
|
|
1097
|
-
|
|
1098
|
-
## 🌟 Support
|
|
1099
|
-
|
|
1100
|
-
<div align="center">
|
|
1101
|
-
|
|
1102
|
-
### Show Your Support
|
|
666
|
+
**Made with ❤️ by the RapidKit team**
|
|
1103
667
|
|
|
1104
668
|
⭐ Star this repo if you find it helpful!
|
|
1105
669
|
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
🐦 Follow [@getrapidkit](https://twitter.com/getrapidkit) for updates
|
|
1109
|
-
|
|
1110
|
-
💬 Join our [Discord community](https://discord.gg/rapidkit)
|
|
1111
|
-
|
|
1112
|
-
📚 Read the [full documentation](https://getrapidkit.com)
|
|
1113
|
-
|
|
1114
|
-
### Get Help
|
|
1115
|
-
|
|
1116
|
-
🐛 [Report Issues](https://github.com/getrapidkit/rapidkit-npm/issues)
|
|
1117
|
-
|
|
1118
|
-
💡 [Request Features](https://github.com/getrapidkit/rapidkit-npm/issues)
|
|
1119
|
-
|
|
1120
|
-
📖 [Browse Docs](https://getrapidkit.com)
|
|
1121
|
-
|
|
1122
|
-
---
|
|
1123
|
-
|
|
1124
|
-
**Made with ❤️ by the RapidKit team**
|
|
1125
|
-
|
|
1126
|
-
[Website](https://getrapidkit.com) • [GitHub](https://github.com/getrapidkit) • [Twitter](https://twitter.com/getrapidkit) • [Discord](https://discord.gg/rapidkit)
|
|
670
|
+
[Install Now](https://www.npmjs.com/package/rapidkit) • [Read Docs](https://getrapidkit.com) • [Get Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode)
|
|
1127
671
|
|
|
1128
672
|
</div>
|
|
1129
|
-
>
|
|
1130
|
-
> _Note: The AI recommender feature is complete in the `feature/ai-recommender` branch but not yet released. We will announce it when Core module support is available._
|
|
1131
|
-
|
|
1132
|
-
RapidKit's single source of truth for kits and global commands is **RapidKit Core (Python)**.
|
|
1133
|
-
This npm package is a **bridge/wrapper** that:
|
|
1134
|
-
|
|
1135
|
-
- Delegates project commands (e.g. `init`, `dev`, `test`) to the project-local launcher when you are inside a RapidKit project.
|
|
1136
|
-
- Forwards global/core commands (e.g. `list`, `info`, `create`, `add`, `doctor`, `--tui`, `--json`) to `python -m rapidkit ...`.
|
|
1137
|
-
- If `rapidkit-core` is not available in your system Python, it can bootstrap a cached virtualenv and install Core there.
|
|
1138
|
-
|
|
1139
|
-
**🤖 NEW:** [AI-powered module recommendations](#-ai-features) to help you build faster!
|
|
1140
|
-
**💡 Tip:** Use the [RapidKit VS Code Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode) for a visual interface!
|
|
1141
|
-
|
|
1142
|
-
## Quick Start
|
|
1143
|
-
|
|
1144
|
-
### Create a Project (FastAPI)
|
|
1145
|
-
|
|
1146
|
-
```bash
|
|
1147
|
-
npx rapidkit create project fastapi.standard my-api --output .
|
|
1148
|
-
cd my-api
|
|
1149
|
-
npx rapidkit init # Install dependencies
|
|
1150
|
-
npx rapidkit dev # Start dev server at http://localhost:8000
|
|
1151
|
-
```
|
|
1152
|
-
|
|
1153
|
-
### Create a Project (NestJS)
|
|
1154
|
-
|
|
1155
|
-
```bash
|
|
1156
|
-
npx rapidkit create project nestjs.standard my-api --output .
|
|
1157
|
-
cd my-api
|
|
1158
|
-
npx rapidkit init # Install dependencies
|
|
1159
|
-
npx rapidkit dev # Start dev server at http://localhost:8000
|
|
1160
|
-
```
|
|
1161
|
-
|
|
1162
|
-
### Create a Workspace (Recommended)
|
|
1163
|
-
|
|
1164
|
-
For organizing multiple projects:
|
|
1165
|
-
|
|
1166
|
-
```bash
|
|
1167
|
-
npx rapidkit my-workspace # Create workspace with Poetry
|
|
1168
|
-
cd my-workspace
|
|
1169
|
-
|
|
1170
|
-
# Activate environment (choose one):
|
|
1171
|
-
source "$(poetry env info --path)/bin/activate"
|
|
1172
|
-
# OR use poetry run prefix for all commands
|
|
1173
|
-
alias rapidkit="poetry run rapidkit"
|
|
1174
|
-
|
|
1175
|
-
# Create projects
|
|
1176
|
-
rapidkit create # Interactive mode
|
|
1177
|
-
rapidkit create project fastapi.standard my-api --output .
|
|
1178
|
-
cd my-api
|
|
1179
|
-
rapidkit init && rapidkit dev
|
|
1180
|
-
```
|
|
1181
|
-
|
|
1182
|
-
**Why use a workspace?**
|
|
1183
|
-
- ✅ Centralized Python environment for all projects
|
|
1184
|
-
- ✅ Auto-tracks all projects in registry (`~/.rapidkit/workspaces.json`)
|
|
1185
|
-
- ✅ VS Code Extension auto-discovers your projects
|
|
1186
|
-
- ✅ Easier dependency management across projects
|
|
1187
|
-
|
|
1188
|
-
### Interactive mode (recommended)
|
|
1189
|
-
|
|
1190
|
-
```bash
|
|
1191
|
-
# Outside workspace
|
|
1192
|
-
npx rapidkit create
|
|
1193
|
-
|
|
1194
|
-
# Inside workspace (after activation)
|
|
1195
|
-
rapidkit create
|
|
1196
|
-
# OR
|
|
1197
|
-
poetry run rapidkit create
|
|
1198
|
-
```
|
|
1199
|
-
|
|
1200
|
-
This runs the RapidKit Core wizard and guides you through kit selection and project creation.
|
|
1201
|
-
|
|
1202
|
-
## Two Modes of Operation
|
|
1203
|
-
|
|
1204
|
-
### 1. Direct Project Creation (Core-first)
|
|
1205
|
-
|
|
1206
|
-
Create a standalone project directly via Core:
|
|
1207
|
-
|
|
1208
|
-
```bash
|
|
1209
|
-
npx rapidkit create project fastapi.standard my-api --output .
|
|
1210
|
-
npx rapidkit create project nestjs.standard my-api --output .
|
|
1211
|
-
```
|
|
1212
|
-
|
|
1213
|
-
### 2. RapidKit Workspace Mode
|
|
1214
|
-
|
|
1215
|
-
Create a workspace to organize multiple projects:
|
|
1216
|
-
|
|
1217
|
-
```bash
|
|
1218
|
-
npx rapidkit my-workspace # Create a RapidKit workspace
|
|
1219
|
-
cd my-workspace
|
|
1220
|
-
|
|
1221
|
-
# Activate the environment (Poetry installs to cache, not .venv)
|
|
1222
|
-
source "$(poetry env info --path)/bin/activate"
|
|
1223
|
-
|
|
1224
|
-
# Or use poetry run prefix
|
|
1225
|
-
poetry run rapidkit create # Interactive project creation
|
|
1226
|
-
poetry run rapidkit create project fastapi.standard my-api --output .
|
|
1227
|
-
```
|
|
1228
|
-
|
|
1229
|
-
This mode creates a "RapidKit workspace" directory and installs the Python Core there via Poetry/venv/pipx, so you can create/manage multiple projects from the same environment.
|
|
1230
|
-
|
|
1231
|
-
**Important:** When using Poetry (recommended), the virtualenv is created in Poetry's cache, not as a local `.venv` folder. You must either:
|
|
1232
|
-
- Activate the environment: `source "$(poetry env info --path)/bin/activate"`
|
|
1233
|
-
- Use `poetry run` prefix: `poetry run rapidkit create`
|
|
1234
|
-
- Create an alias: `alias rapidkit="poetry run rapidkit"`
|
|
1235
|
-
|
|
1236
|
-
**Workspace Features:**
|
|
1237
|
-
- All projects are automatically tracked in `~/.rapidkit/workspaces.json`
|
|
1238
|
-
- VS Code Extension auto-discovers workspace projects
|
|
1239
|
-
- Use `rapidkit workspace list` to see all workspaces and projects
|
|
1240
|
-
- Use `rapidkit workspace sync` to update project registry
|
|
1241
|
-
|
|
1242
|
-
## Kits / Templates
|
|
1243
|
-
|
|
1244
|
-
Kits/templates are provided by the Python Core. This npm package is not limited to two templates.
|
|
1245
|
-
|
|
1246
|
-
List kits:
|
|
1247
|
-
|
|
1248
|
-
```bash
|
|
1249
|
-
rapidkit list
|
|
1250
|
-
rapidkit list --json
|
|
1251
|
-
```
|
|
1252
|
-
|
|
1253
|
-
Create a project with any kit slug:
|
|
1254
|
-
|
|
1255
|
-
```bash
|
|
1256
|
-
npx rapidkit create project <kit-slug> my-service --output .
|
|
1257
|
-
```
|
|
1258
|
-
|
|
1259
|
-
Examples:
|
|
1260
|
-
|
|
1261
|
-
```bash
|
|
1262
|
-
npx rapidkit create project fastapi.standard my-service --output .
|
|
1263
|
-
npx rapidkit create project nestjs.standard my-service --output .
|
|
1264
|
-
```
|
|
1265
|
-
|
|
1266
|
-
### Offline fallback (deprecated, last resort)
|
|
1267
|
-
|
|
1268
|
-
**Deprecated:** With the Python Core (PyPI `rapidkit-core`) now providing dynamic kits and the interactive wizard, the npm package no longer relies on static embedded templates. The offline fallback remains available only as an absolute last-resort for environments where Python/Core cannot be used, but it is not recommended for normal usage.
|
|
1269
|
-
|
|
1270
|
-
If you still need the fallback it supports:
|
|
1271
|
-
|
|
1272
|
-
- `fastapi.standard` (and `fastapi` shorthand)
|
|
1273
|
-
- `nestjs.standard` (and `nestjs` shorthand)
|
|
1274
|
-
|
|
1275
|
-
Example (deprecated fallback):
|
|
1276
|
-
|
|
1277
|
-
```bash
|
|
1278
|
-
npx rapidkit create project fastapi.standard my-api --output .
|
|
1279
|
-
```
|
|
1280
|
-
|
|
1281
|
-
Limitations of the offline fallback (deprecated):
|
|
1282
|
-
|
|
1283
|
-
- Only FastAPI/NestJS embedded templates are supported.
|
|
1284
|
-
- The full kit catalog (`rapidkit list`) and the interactive wizard (`rapidkit create`) require Python Core.
|
|
1285
|
-
- `--json` output is not supported for fallback `create`.
|
|
1286
|
-
|
|
1287
|
-
---
|
|
1288
|
-
|
|
1289
|
-
### Bootstrapping Python Core into a workspace
|
|
1290
|
-
|
|
1291
|
-
The recommended flow is to use the Python Core (`rapidkit-core` on PyPI) as the single source of truth for kits and modules. The npm CLI will bootstrap the Python Core into a workspace virtual environment so you can create and manage projects even on a fresh machine.
|
|
1292
|
-
|
|
1293
|
-
Example: create a workspace and verify Core is bootstrapped
|
|
1294
|
-
|
|
1295
|
-
```bash
|
|
1296
|
-
# Create a RapidKit workspace non-interactively (workspace .venv will be created)
|
|
1297
|
-
npx rapidkit my-workspace --yes --skip-git
|
|
1298
|
-
|
|
1299
|
-
# Activate the workspace environment
|
|
1300
|
-
cd my-workspace
|
|
1301
|
-
source .venv/bin/activate
|
|
1302
|
-
|
|
1303
|
-
# Confirm rapidkit-core is installed inside the workspace venv
|
|
1304
|
-
python -m pip show rapidkit-core
|
|
1305
|
-
# -> Name: rapidkit-core
|
|
1306
|
-
# -> Version: 0.2.1rc1 (or newer)
|
|
1307
|
-
```
|
|
1308
|
-
|
|
1309
|
-
## Install Python Core (optional) 🐍🔧
|
|
1310
|
-
|
|
1311
|
-
RapidKit's engine is provided by the Python package `rapidkit-core` on PyPI. If you prefer to install the engine manually (for development or testing), you can do so:
|
|
1312
|
-
|
|
1313
|
-
```bash
|
|
1314
|
-
# Install for current user
|
|
1315
|
-
pip install --user rapidkit-core
|
|
1316
|
-
|
|
1317
|
-
# Or install into an active virtual environment / system
|
|
1318
|
-
pip install rapidkit-core
|
|
1319
|
-
```
|
|
1320
|
-
|
|
1321
|
-
Project page: https://pypi.org/project/rapidkit-core/
|
|
1322
|
-
|
|
1323
|
-
Notes:
|
|
1324
|
-
|
|
1325
|
-
- The CLI will prefer system Python with `rapidkit-core` if available. If not present it bootstraps `rapidkit-core` into the workspace `.venv` (or a cached bridge venv as a fallback for some global flows).
|
|
1326
|
-
- To emulate a clean system in CI/QA, ensure `rapidkit-core` is not installed in the global/system Python before running the workspace creation script.
|
|
1327
|
-
- If you prefer Poetry to create in-project virtualenvs (`.venv`), enable it via `poetry config virtualenvs.in-project true` or let the workspace installer configure Poetry for you.
|
|
1328
|
-
|
|
1329
|
-
## Workspace Management
|
|
1330
|
-
|
|
1331
|
-
RapidKit maintains a shared workspace registry at `~/.rapidkit/workspaces.json` for cross-tool compatibility with the VS Code Extension.
|
|
1332
|
-
|
|
1333
|
-
### List Registered Workspaces
|
|
1334
|
-
|
|
1335
|
-
```bash
|
|
1336
|
-
npx rapidkit workspace list
|
|
1337
|
-
```
|
|
1338
|
-
|
|
1339
|
-
This shows all workspaces created via npm package or VS Code Extension, including:
|
|
1340
|
-
- Workspace name and path
|
|
1341
|
-
- Number of projects in each workspace
|
|
1342
|
-
- Validation status (path exists/missing)
|
|
1343
|
-
|
|
1344
|
-
**Example output:**
|
|
1345
|
-
```
|
|
1346
|
-
📦 Registered RapidKit Workspaces:
|
|
1347
|
-
|
|
1348
|
-
my-workspace
|
|
1349
|
-
Path: /home/user/projects/my-workspace
|
|
1350
|
-
Projects: 3
|
|
1351
|
-
|
|
1352
|
-
Total: 1 workspace(s)
|
|
1353
|
-
```
|
|
1354
|
-
|
|
1355
|
-
### Sync Workspace Projects
|
|
1356
|
-
|
|
1357
|
-
When you create projects inside a workspace, they are automatically tracked. If needed, you can manually sync:
|
|
1358
|
-
|
|
1359
|
-
```bash
|
|
1360
|
-
cd my-workspace
|
|
1361
|
-
rapidkit workspace sync
|
|
1362
|
-
```
|
|
1363
|
-
|
|
1364
|
-
This command scans the workspace directory and registers all RapidKit projects (directories with `.rapidkit/context.json` or `.rapidkit/project.json`) in the registry.
|
|
1365
|
-
|
|
1366
|
-
**Note:** Project registration happens automatically when you create projects with `rapidkit create project ...` inside a workspace. Manual sync is only needed if you:
|
|
1367
|
-
- Manually moved/copied projects into the workspace
|
|
1368
|
-
- Created projects before the sync feature was added
|
|
1369
|
-
- Want to refresh the registry after external changes
|
|
1370
|
-
|
|
1371
|
-
### Workspace Registry Format
|
|
1372
|
-
|
|
1373
|
-
The registry stores workspace metadata:
|
|
1374
|
-
|
|
1375
|
-
```json
|
|
1376
|
-
{
|
|
1377
|
-
"workspaces": [
|
|
1378
|
-
{
|
|
1379
|
-
"name": "my-workspace",
|
|
1380
|
-
"path": "/home/user/projects/my-workspace",
|
|
1381
|
-
"mode": "full",
|
|
1382
|
-
"projects": [
|
|
1383
|
-
{
|
|
1384
|
-
"name": "my-api",
|
|
1385
|
-
"path": "/home/user/projects/my-workspace/my-api"
|
|
1386
|
-
},
|
|
1387
|
-
{
|
|
1388
|
-
"name": "admin-api",
|
|
1389
|
-
"path": "/home/user/projects/my-workspace/admin-api"
|
|
1390
|
-
}
|
|
1391
|
-
]
|
|
1392
|
-
}
|
|
1393
|
-
]
|
|
1394
|
-
}
|
|
1395
|
-
```
|
|
1396
|
-
|
|
1397
|
-
Workspaces are automatically registered when created via:
|
|
1398
|
-
- `npx rapidkit <workspace-name>`
|
|
1399
|
-
- VS Code Extension "Create Workspace" command
|
|
1400
|
-
|
|
1401
|
-
Projects are automatically registered when created via:
|
|
1402
|
-
- `rapidkit create project ...` (inside a workspace)
|
|
1403
|
-
- VS Code Extension "Create Project" command
|
|
1404
|
-
|
|
1405
|
-
## 🤖 AI Features
|
|
1406
|
-
|
|
1407
|
-
RapidKit now includes AI-powered module recommendations using OpenAI embeddings!
|
|
1408
|
-
|
|
1409
|
-
### Quick Start with AI
|
|
1410
|
-
|
|
1411
|
-
**First time setup** (automatic):
|
|
1412
|
-
```bash
|
|
1413
|
-
# Just use AI recommendations - it will guide you through setup!
|
|
1414
|
-
npx rapidkit ai recommend "user authentication with social login"
|
|
1415
|
-
|
|
1416
|
-
# If embeddings don't exist, you'll see:
|
|
1417
|
-
# ⚠️ Module embeddings not found
|
|
1418
|
-
# ? What would you like to do?
|
|
1419
|
-
# 🚀 Generate embeddings now (requires OpenAI API key)
|
|
1420
|
-
# 📝 Show me how to generate them manually
|
|
1421
|
-
# ❌ Cancel
|
|
1422
|
-
```
|
|
1423
|
-
|
|
1424
|
-
**Example Usage:**
|
|
1425
|
-
```bash
|
|
1426
|
-
# Get intelligent module recommendations
|
|
1427
|
-
npx rapidkit ai recommend "I need user authentication with email"
|
|
1428
|
-
|
|
1429
|
-
# Output:
|
|
1430
|
-
# 📦 Recommended Modules:
|
|
1431
|
-
# 1. Authentication Core
|
|
1432
|
-
# Complete authentication with JWT, OAuth 2.0, secure sessions
|
|
1433
|
-
# Match: 92.5% - Matches: auth, login, email
|
|
1434
|
-
# Category: auth
|
|
1435
|
-
#
|
|
1436
|
-
# 2. Users Core
|
|
1437
|
-
# User management with profiles, roles, permissions
|
|
1438
|
-
# Match: 88.3% - Matches: user
|
|
1439
|
-
# Category: auth
|
|
1440
|
-
# Requires: authentication-core
|
|
1441
|
-
```
|
|
1442
|
-
|
|
1443
|
-
### AI Commands
|
|
1444
|
-
|
|
1445
|
-
```bash
|
|
1446
|
-
# Get recommendations
|
|
1447
|
-
npx rapidkit ai recommend "payment processing with Stripe"
|
|
1448
|
-
npx rapidkit ai recommend "real-time notifications" --number 3
|
|
1449
|
-
|
|
1450
|
-
# Setup and management
|
|
1451
|
-
npx rapidkit config set-api-key # Configure OpenAI API key
|
|
1452
|
-
npx rapidkit ai generate-embeddings # Manual embedding generation
|
|
1453
|
-
npx rapidkit ai generate-embeddings --force # Force regeneration
|
|
1454
|
-
npx rapidkit ai update-embeddings # Update with latest modules
|
|
1455
|
-
npx rapidkit ai info # Show features & pricing
|
|
1456
|
-
```
|
|
1457
|
-
|
|
1458
|
-
### Features
|
|
1459
|
-
|
|
1460
|
-
- 🧠 **Semantic Search**: AI understands intent, not just keywords
|
|
1461
|
-
- 🤖 **Auto-Setup**: Embeddings generate automatically on first use
|
|
1462
|
-
- 📦 **27+ Modules**: Production-ready modules from RapidKit Python Core
|
|
1463
|
-
- 💰 **Ultra-Cheap**: ~$0.0002 per query (practically free)
|
|
1464
|
-
- 🎯 **Dependency Detection**: Automatically shows required modules
|
|
1465
|
-
- ✅ **Mock Mode**: Test without API key using deterministic embeddings
|
|
1466
|
-
- 🔄 **Dynamic Catalog**: Fetches latest modules from Python Core
|
|
1467
|
-
|
|
1468
|
-
### Pricing
|
|
1469
|
-
|
|
1470
|
-
**One-time Setup:**
|
|
1471
|
-
- Generate embeddings: ~$0.50 (one time only)
|
|
1472
|
-
|
|
1473
|
-
**Per Query:**
|
|
1474
|
-
- Single query: ~$0.0002
|
|
1475
|
-
- 100 queries: ~$0.02 (2 cents)
|
|
1476
|
-
- 1,000 queries: ~$0.20 (20 cents)
|
|
1477
|
-
|
|
1478
|
-
💡 **Tip:** Setup cost is paid once, then queries are essentially free!
|
|
1479
|
-
|
|
1480
|
-
### Available Module Categories
|
|
1481
|
-
|
|
1482
|
-
- 🔐 **Auth**: authentication-core, users-core, session-management, 2fa
|
|
1483
|
-
- 💾 **Database**: db-postgres, db-mongodb, db-mysql
|
|
1484
|
-
- 💳 **Payment**: stripe-payment, payment-core
|
|
1485
|
-
- 📧 **Communication**: email, sms, notifications
|
|
1486
|
-
- 🚀 **Infrastructure**: redis-cache, celery, storage, rate-limiter
|
|
1487
|
-
- 📊 **Monitoring**: logging, analytics, error-tracking
|
|
1488
|
-
- 🔌 **Integrations**: webhooks, api-gateway, graphql
|
|
1489
|
-
|
|
1490
|
-
### Troubleshooting
|
|
1491
|
-
|
|
1492
|
-
**No OpenAI API Key?**
|
|
1493
|
-
```bash
|
|
1494
|
-
# AI works in mock mode without API key (for testing)
|
|
1495
|
-
npx rapidkit ai recommend "auth" # Works without key!
|
|
1496
|
-
|
|
1497
|
-
# For production, get a key:
|
|
1498
|
-
# 1. Visit: https://platform.openai.com/api-keys
|
|
1499
|
-
# 2. Create new key
|
|
1500
|
-
# 3. Configure: npx rapidkit config set-api-key
|
|
1501
|
-
```
|
|
1502
|
-
|
|
1503
|
-
**Embeddings Not Found?**
|
|
1504
|
-
```bash
|
|
1505
|
-
# Just run any AI command - it will prompt you to generate them
|
|
1506
|
-
npx rapidkit ai recommend "database"
|
|
1507
|
-
|
|
1508
|
-
# Or generate manually:
|
|
1509
|
-
npx rapidkit ai generate-embeddings
|
|
1510
|
-
```
|
|
1511
|
-
|
|
1512
|
-
**Update Embeddings After RapidKit Python Update?**
|
|
1513
|
-
```bash
|
|
1514
|
-
npx rapidkit ai update-embeddings
|
|
1515
|
-
```
|
|
1516
|
-
|
|
1517
|
-
**See Current Config:**
|
|
1518
|
-
```bash
|
|
1519
|
-
npx rapidkit config show
|
|
1520
|
-
```
|
|
1521
|
-
|
|
1522
|
-
### Learn More
|
|
1523
|
-
|
|
1524
|
-
- 📚 **Full Guide**: [docs/AI_FEATURES.md](docs/AI_FEATURES.md)
|
|
1525
|
-
- 🔧 **Technical Details**: [docs/AI_DYNAMIC_INTEGRATION.md](docs/AI_DYNAMIC_INTEGRATION.md)
|
|
1526
|
-
|
|
1527
|
-
## CLI Options
|
|
1528
|
-
|
|
1529
|
-
```bash
|
|
1530
|
-
npx rapidkit [project-name] [options]
|
|
1531
|
-
```
|
|
1532
|
-
|
|
1533
|
-
### Arguments
|
|
1534
|
-
|
|
1535
|
-
- `project-name` - Name of project/workspace directory to create
|
|
1536
|
-
- `action` - For workspace commands: `list` or `sync`
|
|
1537
|
-
|
|
1538
|
-
### Workspace Commands
|
|
1539
|
-
|
|
1540
|
-
- `rapidkit workspace list` - List all registered workspaces and their projects
|
|
1541
|
-
- `rapidkit workspace sync` - Scan current workspace and register all projects
|
|
1542
|
-
|
|
1543
|
-
### Options
|
|
1544
|
-
|
|
1545
|
-
- `--skip-git` - Skip git initialization
|
|
1546
|
-
- `--skip-install` - Skip installing dependencies (for NestJS)
|
|
1547
|
-
- `--debug` - Enable verbose debug logging
|
|
1548
|
-
- `--dry-run` - Preview what would be created without creating it
|
|
1549
|
-
- `--no-update-check` - Skip checking for newer versions
|
|
1550
|
-
- `--help` - Display help information
|
|
1551
|
-
- `--version` - Show version number
|
|
1552
|
-
|
|
1553
|
-
## Project Commands
|
|
1554
|
-
|
|
1555
|
-
After creating a project, use these commands:
|
|
1556
|
-
|
|
1557
|
-
```bash
|
|
1558
|
-
cd my-api
|
|
1559
|
-
npx rapidkit init # Install dependencies (auto-activates environment)
|
|
1560
|
-
npx rapidkit dev # Start dev server with hot reload (port 8000)
|
|
1561
|
-
npx rapidkit start # Start production server
|
|
1562
|
-
npx rapidkit build # Build for production
|
|
1563
|
-
npx rapidkit test # Run tests
|
|
1564
|
-
npx rapidkit lint # Lint code
|
|
1565
|
-
npx rapidkit format # Format code
|
|
1566
|
-
|
|
1567
|
-
# AI Commands (new!)
|
|
1568
|
-
npx rapidkit ai recommend "query" # Get module recommendations
|
|
1569
|
-
npx rapidkit ai recommend "auth" --number 3 # Get top 3 results
|
|
1570
|
-
npx rapidkit ai generate-embeddings # Generate embeddings (one-time)
|
|
1571
|
-
npx rapidkit ai update-embeddings # Update embeddings
|
|
1572
|
-
npx rapidkit ai info # Show AI features info
|
|
1573
|
-
npx rapidkit config set-api-key # Configure OpenAI API key
|
|
1574
|
-
npx rapidkit config show # View current config
|
|
1575
|
-
|
|
1576
|
-
npx rapidkit --help # Show all commands
|
|
1577
|
-
```
|
|
1578
|
-
|
|
1579
|
-
### Adding Modules to Your Project
|
|
1580
|
-
|
|
1581
|
-
RapidKit's modular architecture lets you extend your project with pre-built modules. Install modules using:
|
|
1582
|
-
|
|
1583
|
-
```bash
|
|
1584
|
-
npx rapidkit add module <module-slug>
|
|
1585
|
-
```
|
|
1586
|
-
|
|
1587
|
-
**Examples:**
|
|
1588
|
-
|
|
1589
|
-
```bash
|
|
1590
|
-
# Add authentication module
|
|
1591
|
-
npx rapidkit add module auth
|
|
1592
|
-
|
|
1593
|
-
# Add caching module (Redis)
|
|
1594
|
-
npx rapidkit add module redis
|
|
1595
|
-
|
|
1596
|
-
# Add database module (PostgreSQL)
|
|
1597
|
-
npx rapidkit add module db_postgres
|
|
1598
|
-
```
|
|
1599
|
-
|
|
1600
|
-
**List available modules:**
|
|
1601
|
-
|
|
1602
|
-
```bash
|
|
1603
|
-
npx rapidkit list modules
|
|
1604
|
-
npx rapidkit list modules --json
|
|
1605
|
-
```
|
|
1606
|
-
|
|
1607
|
-
**View module details:**
|
|
1608
|
-
|
|
1609
|
-
```bash
|
|
1610
|
-
npx rapidkit info module auth
|
|
1611
|
-
npx rapidkit info module db_postgres
|
|
1612
|
-
```
|
|
1613
|
-
|
|
1614
|
-
> **💡 Tip:** Use the [RapidKit VS Code Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode) for a visual interface to browse and install modules!
|
|
1615
|
-
|
|
1616
|
-
> **Note:** `npx rapidkit` automatically detects when you're inside a RapidKit project and delegates to the local CLI. Works everywhere without any setup!
|
|
1617
|
-
|
|
1618
|
-
> **💡 Tip:** Install globally with `npm i -g rapidkit` to use `rapidkit` directly without `npx`.
|
|
1619
|
-
|
|
1620
|
-
### Alternative: Direct Commands
|
|
1621
|
-
|
|
1622
|
-
You can also run commands directly:
|
|
1623
|
-
|
|
1624
|
-
```bash
|
|
1625
|
-
./rapidkit dev # Using the wrapper script
|
|
1626
|
-
make dev # Using Makefile (FastAPI)
|
|
1627
|
-
poetry run dev # Using Poetry directly (FastAPI)
|
|
1628
|
-
npm run start:dev # Using npm directly (NestJS)
|
|
1629
|
-
```
|
|
1630
|
-
|
|
1631
|
-
## Project Structure
|
|
1632
|
-
|
|
1633
|
-
### FastAPI Project
|
|
1634
|
-
|
|
1635
|
-
```
|
|
1636
|
-
my-api/
|
|
1637
|
-
├── .rapidkit/
|
|
1638
|
-
│ ├── activate # Activation script
|
|
1639
|
-
│ ├── cli.py # Python CLI module
|
|
1640
|
-
│ └── rapidkit # Bash wrapper
|
|
1641
|
-
├── rapidkit # Main CLI entry point
|
|
1642
|
-
├── src/
|
|
1643
|
-
│ ├── main.py # FastAPI application
|
|
1644
|
-
│ ├── cli.py # CLI commands
|
|
1645
|
-
│ ├── routing/ # API routes
|
|
1646
|
-
│ └── modules/ # Module system
|
|
1647
|
-
├── tests/ # Test suite
|
|
1648
|
-
├── pyproject.toml # Poetry configuration
|
|
1649
|
-
├── Makefile # Make commands
|
|
1650
|
-
└── README.md
|
|
1651
|
-
```
|
|
1652
|
-
|
|
1653
|
-
### NestJS Project
|
|
1654
|
-
|
|
1655
|
-
```
|
|
1656
|
-
my-api/
|
|
1657
|
-
├── .rapidkit/
|
|
1658
|
-
│ ├── activate # Activation script
|
|
1659
|
-
│ └── rapidkit # Bash CLI wrapper
|
|
1660
|
-
├── rapidkit # Main CLI entry point
|
|
1661
|
-
├── src/
|
|
1662
|
-
│ ├── main.ts # Application entry point
|
|
1663
|
-
│ ├── app.module.ts # Root module
|
|
1664
|
-
│ ├── config/ # Configuration
|
|
1665
|
-
│ └── examples/ # Example module
|
|
1666
|
-
├── test/ # Test files
|
|
1667
|
-
├── package.json # Dependencies
|
|
1668
|
-
├── tsconfig.json # TypeScript config
|
|
1669
|
-
└── README.md
|
|
1670
|
-
```
|
|
1671
|
-
|
|
1672
|
-
## Requirements
|
|
1673
|
-
|
|
1674
|
-
- **Node.js**: 20.19.6+ (LTS recommended)
|
|
1675
|
-
- **Python**: Required for RapidKit Core commands (e.g. `list/info/create/add/...`). If Python is missing, the bridge fails with a clear error message.
|
|
1676
|
-
- For FastAPI projects: Python + Poetry (as required by the generated project)
|
|
1677
|
-
- For NestJS projects: Node + a package manager (npm/yarn/pnpm)
|
|
1678
|
-
- **Git**: For version control
|
|
1679
|
-
|
|
1680
|
-
> 💡 **Tip:** Use [RapidKit VS Code Extension](https://marketplace.visualstudio.com/items?itemName=rapidkit.rapidkit-vscode) - includes system checker to verify all requirements!
|
|
1681
|
-
|
|
1682
|
-
## How It Works (Under the Hood)
|
|
1683
|
-
|
|
1684
|
-
This CLI runs a Node entrypoint (`dist/index.js`) that makes these decisions:
|
|
1685
|
-
|
|
1686
|
-
1. If you're inside a RapidKit project:
|
|
1687
|
-
|
|
1688
|
-
- It detects the project (via `.rapidkit/project.json` or other signals).
|
|
1689
|
-
- It delegates `rapidkit init/dev/test/...` to the project-local launcher (`./rapidkit` or `.rapidkit/rapidkit`).
|
|
1690
|
-
|
|
1691
|
-
2. If you're not inside a project and run a global/core command (e.g. `rapidkit list --json`):
|
|
1692
|
-
|
|
1693
|
-
- It forwards the request to the Python Core via `python -m rapidkit ...`.
|
|
1694
|
-
- If Core is not installed in system Python, it bootstraps a cached venv and installs `rapidkit-core` there.
|
|
1695
|
-
|
|
1696
|
-
3. If you run `npx rapidkit <name>` without `--template`:
|
|
1697
|
-
|
|
1698
|
-
- It creates a "RapidKit environment" directory (Poetry/venv/pipx) so you're ready to create and run real projects.
|
|
1699
|
-
|
|
1700
|
-
### Bridge controls
|
|
1701
|
-
|
|
1702
|
-
- Override Core install target (dev/test): `RAPIDKIT_CORE_PYTHON_PACKAGE=/path/to/core`
|
|
1703
|
-
- Cache location: `XDG_CACHE_HOME=...`
|
|
1704
|
-
- Upgrade pip during bootstrap (optional): `RAPIDKIT_BRIDGE_UPGRADE_PIP=1`
|
|
1705
|
-
|
|
1706
|
-
### Workspace Markers
|
|
1707
|
-
|
|
1708
|
-
Workspaces created by the npm package include a `.rapidkit-workspace` marker file:
|
|
1709
|
-
|
|
1710
|
-
```json
|
|
1711
|
-
{
|
|
1712
|
-
"signature": "RAPIDKIT_WORKSPACE",
|
|
1713
|
-
"createdBy": "rapidkit-npm",
|
|
1714
|
-
"version": "0.15.1",
|
|
1715
|
-
"createdAt": "2026-02-01T...",
|
|
1716
|
-
"name": "my-workspace"
|
|
1717
|
-
}
|
|
1718
|
-
```
|
|
1719
|
-
|
|
1720
|
-
This marker enables:
|
|
1721
|
-
- Workspace auto-detection by VS Code Extension
|
|
1722
|
-
- Cross-tool workspace compatibility
|
|
1723
|
-
- Workspace validation and version tracking
|
|
1724
|
-
|
|
1725
|
-
## Development
|
|
1726
|
-
|
|
1727
|
-
```bash
|
|
1728
|
-
# Clone the repository
|
|
1729
|
-
git clone https://github.com/getrapidkit/rapidkit-npm.git
|
|
1730
|
-
cd rapidkit-npm
|
|
1731
|
-
|
|
1732
|
-
# Install dependencies
|
|
1733
|
-
npm install
|
|
1734
|
-
|
|
1735
|
-
# Build
|
|
1736
|
-
npm run build
|
|
1737
|
-
|
|
1738
|
-
# Run tests
|
|
1739
|
-
npm test
|
|
1740
|
-
|
|
1741
|
-
# Watch mode
|
|
1742
|
-
npm run dev
|
|
1743
|
-
```
|
|
1744
|
-
|
|
1745
|
-
## Related Projects
|
|
1746
|
-
|
|
1747
|
-
- **RapidKit Core (Python)** - The engine (PyPI: `rapidkit-core`)
|
|
1748
|
-
- **RapidKit Docs** - https://getrapidkit.com
|
|
1749
|
-
- **GitHub**: https://github.com/getrapidkit
|
|
1750
|
-
|
|
1751
|
-
## License
|
|
1752
|
-
|
|
1753
|
-
MIT
|
|
1754
|
-
|
|
1755
|
-
## Support
|
|
1756
|
-
|
|
1757
|
-
- 🐛 Report issues: [GitHub Issues](https://github.com/getrapidkit/rapidkit-npm/issues)
|
|
1758
|
-
- 📚 Docs: https://getrapidkit.com
|