Specify a webhook-driven task for OpenClaw
Describe event inputs, validation, deduplication, and intended actions before integration work.
Scaffold Express+Prisma API app in Turborepo. Express 5, Pino, Zod env, JWKS auth, rate-limit, res.success/error, tsup.
---
name: project-setup-fa033ac2dc15
description: Scaffold Express+Prisma API app in Turborepo. Express 5, Pino, Zod env, JWKS auth, rate-limit, res.success/error, tsup.
---
# Project Setup — 23 files
Load `references/templates.md` only after preflight passes.
## Preflight
| Check | Pass | Fail |
|---|---|---|
| `turbo.json` + `apps/` at root | ✅ | STOP: "Requires Turborepo monorepo." |
| `packages/typescript-config/base.json` has `"moduleResolution":"Bundler"` | ✅ | load `references/missing-packages.md` §A |
| `packages/biome-config/base.json` | ✅ Biome shared | — |
| Root `biome.json` `"root":true` only | ✅ Biome root-only | — |
| ESLint / no linter found | ⚠️ | load `references/missing-packages.md` §B |
| `packages/vitest-config/` base export | ✅ shared | use standalone `vitest.config.ts`, drop `{scope}/vitest-config` devDep |
**Variables**
- `{app}` — user input; if missing ask: *"App name? (e.g. api, server)"*
- `{scope}` — extract prefix from any `packages/*/package.json` `"name"`; if ambiguous ask: *"Workspace scope? (e.g. @repo)"*
- `{pkg}` = `{scope}/{app}`
- `{db-pkg}` — `prisma_client_import` from `references/project.config.md`; else `{scope}/db`
- `{ws}` = `workspace:*` (pnpm) | `*` (yarn/npm) — infer from root `package.json` or lockfile
- `apps/{app}/` exists → ask: *"Overwrite / skip existing / cancel?"*
**Confirm before generating:**
```
scope:{scope} app:{app} pkg:{pkg} db-pkg:{db-pkg} vitest:shared|standalone files:23 — Generate? [Y/n]
```
## File Generation
Load `references/templates.md`. Replace `{app}` `{pkg}` `{scope}` `{db-pkg}` `{ws}` throughout.
All paths are under `apps/{app}/`:
```
README.md · package.json · tsconfig.json · biome.json · vitest.config.ts · tsup.config.ts · .env.example
src/types/express.d.ts
src/config/env.ts · logger.ts · db.ts
src/utils/http-error.ts · http-error.test.ts
src/middlewares/response-formatter.ts · error-handler.ts · auth.middleware.ts · http-logger.ts · validate.ts · rate-limit.ts
src/routes/index.ts · src/app.ts · src/server.ts
```
**After all files created**, run:
```bash
pnpm --filter {pkg} add compression cors dotenv express helmet jose pino pino-http zod
pnpm --filter {pkg} add -D @types/compression @types/cors @types/express @types/node pino-pretty tsup tsx typescript vitest
```
Print:
```
✅ apps/{app}/ — 23 files, deps installed.
1. cp apps/{app}/.env.example apps/{app}/.env
2. pnpm --filter {pkg} dev
```
## Resume
"resume project setup for {app}" → check each file: exists → skip, missing → create.
## JS Mode
Strip `: Type` `import type` `z.infer<>` `satisfies` `as Type`. Omit `src/types/express.d.ts`. Rename `.ts`→`.js`.
---
name: project-setup-fa033ac2dc15
description: Scaffold Express+Prisma API app in Turborepo. Express 5, Pino, Zod env, JWKS auth, rate-limit, res.success/error, tsup.
---
# Project Setup — 23 files
Load `references/templates.md` only after preflight passes.
## Preflight
| Check | Pass | Fail |
|---|---|---|
| `turbo.json` + `apps/` at root | ✅ | STOP: "Requires Turborepo monorepo." |
| `packages/typescript-config/base.json` has `"moduleResolution":"Bundler"` | ✅ | load `references/missing-packages.md` §A |
| `packages/biome-config/base.json` | ✅ Biome shared | — |
| Root `biome.json` `"root":true` only | ✅ Biome root-only | — |
| ESLint / no linter found | ⚠️ | load `references/missing-packages.md` §B |
| `packages/vitest-config/` base export | ✅ shared | use standalone `vitest.config.ts`, drop `{scope}/vitest-config` devDep |
**Variables**
- `{app}` — user input; if missing ask: *"App name? (e.g. api, server)"*
- `{scope}` — extract prefix from any `packages/*/package.json` `"name"`; if ambiguous ask: *"Workspace scope? (e.g. @repo)"*
- `{pkg}` = `{scope}/{app}`
- `{db-pkg}` — `prisma_client_import` from `references/project.config.md`; else `{scope}/db`
- `{ws}` = `workspace:*` (pnpm) | `*` (yarn/npm) — infer from root `package.json` or lockfile
- `apps/{app}/` exists → ask: *"Overwrite / skip existing / cancel?"*
**Confirm before generating:**
```
scope:{scope} app:{app} pkg:{pkg} db-pkg:{db-pkg} vitest:shared|standalone files:23 — Generate? [Y/n]
```
## File Generation
Load `references/templates.md`. Replace `{app}` `{pkg}` `{scope}` `{db-pkg}` `{ws}` throughout.
All paths are under `apps/{app}/`:
```
README.md · package.json · tsconfig.json · biome.json · vitest.config.ts · tsup.config.ts · .env.example
src/types/express.d.ts
src/config/env.ts · logger.ts · db.ts
src/utils/http-error.ts · http-error.test.ts
src/middlewares/response-formatter.ts · error-handler.ts · auth.middleware.ts · http-logger.ts · validate.ts · rate-limit.ts
src/routes/index.ts · src/app.ts · src/server.ts
```
**After all files created**, run:
```bash
pnpm --filter {pkg} add compression cors dotenv express helmet jose pino pino-http zod
pnpm --filter {pkg} add -D @types/compression @types/cors @types/express @types/node pino-pretty tsup tsx typescript vitest
```
Print:
```
✅ apps/{app}/ — 23 files, deps installed.
1. cp apps/{app}/.env.example apps/{app}/.env
2. pnpm --filter {pkg} dev
```
## Resume
"resume project setup for {app}" → check each file: exists → skip, missing → create.
## JS Mode
Strip `: Type` `import type` `z.infer<>` `satisfies` `as Type`. Omit `src/types/express.d.ts`. Rename `.ts`→`.js`.
Imported from the listed AgentSkill.sh category. Complete supplied package files and notices are retained. Required external tools and credentials are not installed. No bundled code was executed during import. Individual agent task behavior has not been tested.