Devine development work starts from documented sprint cards and ends with a verified running app.
- Scenario 1: Set up a new checkout
- Scenario 2: Pick up a sprint card
- Scenario 3: Implement a backend card
- Scenario 4: Implement a frontend card
- Scenario 5: Implement an API contract card
- Scenario 6: Wire a feature end-to-end
- Scenario 7: Reset local state
- Scenario 8: Review a PR
- Scenario 9: Prepare a release update
Use this when you have just cloned the repository.
- Install dependencies.
bun install --frozen-lockfile- Create local environment configuration.
cp .env.example .env.local-
Fill
.env.localwith local values. Use .env.example and docs/technical-specs/11-environment-configuration.md as the source of truth. -
Run migrations and local seed data.
bun run db:migrate
bun run db:seed:dev- Start the app.
bun run dev-
Open
http://localhost:3000and confirm the landing page renders. -
Confirm health.
curl "$NEXT_PUBLIC_APP_URL/api/health"- Run the full verification gate.
bun run complete-checkUse this for any planned feature, fix, or scaffold-completion task.
-
Open docs/TASK_BREAKDOWN.md.
-
Choose one card. Note its card ID, owner role, acceptance criteria, and linked docs.
-
Read the acceptance criteria under docs/business/.
-
Read the linked API specs, module specs, architecture specs, and security docs.
-
Inspect the current implementation in
app/,lib/,components/, andtests/. -
Decide whether the task is backend, frontend, tech-lead contract, or wiring work.
-
Keep scope to the card. Do not add future sprint behavior unless the card requires it.
-
Before handoff, run the checks that match the change and then the full gate.
bun run complete-checkUse this for persistence, domain logic, route handlers, server actions, auth, daily.dev, scoring, quest, power-up, demo, share, reset, or health behavior.
-
Start from the card in docs/TASK_BREAKDOWN.md.
-
Read the relevant API contract in docs/api-specs/ if the work touches a route or server action.
-
Read the relevant module spec in docs/technical-specs/05-module-definitions.md.
-
Add or update slice tests in
features/<slice>/tests/. -
Implement product behavior under the relevant
features/<slice>/layer. -
Keep direct database access in
lib/db/. -
Keep route handlers and server actions thin. They should validate input, authorize the caller, call public feature APIs, and map results to responses.
-
Run focused checks.
bun run type-check
bun run test- If the change affects formatting or lint rules, run:
bun run lint
bun run format- Run the full gate before handoff.
bun run complete-check- Update the relevant docs if contracts, environment variables, architecture, or verification commands changed.
Use this for landing, auth, dashboard, settings, share pages, components, loading states, empty states, error states, or visual polish.
-
Start from the card in docs/TASK_BREAKDOWN.md.
-
Read the relevant route, UI, and acceptance criteria docs.
-
Inspect the current page or component under
app/andcomponents/. -
Add or update Playwright coverage in
tests/e2e/for user-visible golden paths. -
Implement the UI with existing component and styling patterns.
-
Start the running app.
bun run dev-
Manually verify the changed route in the browser. Include golden path, empty state, error state, and nearby navigation where applicable.
-
Run focused checks.
bun run type-check
bun run test:e2e- Run the full gate before handoff.
bun run complete-check- Update docs when route behavior, UI flow, or verification instructions changed.
Use this for Tech Lead cards that specify contracts before implementation work.
-
Open the relevant sprint section in docs/TASK_BREAKDOWN.md.
-
Read the cited acceptance criteria under docs/business/.
-
Read related module and integration specs under docs/technical-specs/.
-
Add or update the matching contract document under docs/api-specs/.
-
Define request shapes, response shapes, status codes, validation rules, authorization rules, privacy constraints, failure envelopes, and test expectations.
-
Cross-link the API spec to the technical source documents instead of restating long architecture sections.
-
Run documentation index checks if the changed docs affect generated or linked indexes.
python scripts/check_index.py- If code changed, run the relevant code checks and then:
bun run complete-checkUse this for wiring cards where backend and frontend work must be proven together.
-
Confirm all prerequisite backend and frontend cards are complete or present in the branch.
-
Start the app.
bun run dev- Prepare local state.
bun run db:migrate
bun run db:seed:dev-
Execute the acceptance path in the browser from the user's point of view.
-
Confirm server behavior with route checks where useful.
curl "$NEXT_PUBLIC_APP_URL/api/health"-
Add or update Playwright coverage for the full path.
-
Verify privacy-sensitive output manually. Public share pages must show only documented public projection fields.
-
Run the full gate.
bun run complete-checkUse this when local data needs to return to a known development seed.
-
Confirm
.env.localis pointed at a disposable local database or safe development database. -
Confirm reset is enabled only outside production.
APP_ENV=development
ENABLE_RESET_API=true
RESET_STATE_SECRET=replace-with-local-reset-secret- Start the app.
bun run dev- Call the reset endpoint.
curl -X POST "$NEXT_PUBLIC_APP_URL/api/admin/reset-state" \
-H "Authorization: Bearer $RESET_STATE_SECRET" \
-H "Content-Type: application/json" \
-d '{"seed":"dev"}'-
Restart the development server.
-
Verify health.
curl "$NEXT_PUBLIC_APP_URL/api/health"If the reset API is unavailable, use the project migration and seed runners against a disposable local database.
bun run db:migrate
bun run db:seed:devDo not use ad hoc destructive SQL against shared or production-like data.
Use this when reviewing another contributor's change.
-
Read the PR summary and identify the sprint card or acceptance criteria it claims to satisfy.
-
Read docs/CODE_REVIEW_CHECKLIST.md and docs/CODING_STANDARD.md.
-
Confirm the change stays inside the card scope.
-
Check that domain logic is in
lib/, route handlers are thin, and reusable UI components remain presentation-only. -
Check security and privacy boundaries:
- daily.dev tokens are server-only.
- private user data is owner-scoped.
- public share snapshots are allowlisted.
- reset endpoints are absent or unreachable in production.
-
Run or verify the full gate.
bun run complete-check- For UI changes, run the app and verify the affected route in a browser.
bun run dev- Request changes for correctness, security, privacy, contract drift, missing tests, or broken acceptance criteria.
Use this when a change is going to main and Vercel will deploy it.
-
Read docs/DEPLOYMENT_PLAN.md.
-
Run the full local gate.
bun run complete-check-
If schema changes are included, create a Neon branch or snapshot before applying migrations.
-
Run migrations against the intended target database only after confirming
DATABASE_URL.
bun run db:migrate-
Merge or push to
mainthrough the project's approved GitHub flow. -
Confirm Vercel deploys the selected commit.
-
Verify hosted health.
curl "$NEXT_PUBLIC_APP_URL/api/health"- Inspect Vercel logs and Neon status for runtime or database errors.
Rollback and database recovery procedures live in docs/DEPLOYMENT_PLAN.md.