> ## Documentation Index
> Fetch the complete documentation index at: https://docs.drdj.me/llms.txt
> Use this file to discover all available pages before exploring further.

# Development Workflow

> Daily engineering workflow and merge gates for DealDash contributors and agents.

## Daily Command Set

```bash theme={null}
pnpm dev:full
DISABLE_BACKGROUND_JOBS=true pnpm dev:full
pnpm check
pnpm test:unit
pnpm test:integration
pnpm docs:check
```

Add `pnpm test:e2e` for auth/public/UI-routing changes.

Use `DISABLE_BACKGROUND_JOBS=true` for local UI smoke tests against shared or
production-like credentials so the backend does not process Sheets sync queues,
two-way Sheets imports, reminders, or recurring task checks during validation.
Production Render does not set this flag.

## Required Merge Gates

1. typecheck passes
2. relevant tests pass
3. docs updated in same change
4. risk note and rollback note included

## drdj.me Shortener Development

The standalone shortener uses the same backend data model as DealDash, but gives
agents a tiny URL/photo short-link surface:

* API route: `/server/routes/shortener-v1.ts`
* Shared logic: `/server/lib/short-links.ts`
* MCP server: `/plugins/drdj-shortener/scripts/server.ts`
* Skill: `/plugins/drdj-shortener/skills/drdj-shortener/SKILL.md`
* Dashboard: `/client/src/pages/Links.tsx`
* Public landing page: `/client/src/pages/marketing/AiLinkShortener.tsx`

Apply `/migrations/extend-shortener-for-ai-agents.sql` before real
`/api/shortener/v1/*` traffic. The migration adds shortener ownership,
customization, status, privacy-safe analytics, and agent metadata fields.

Useful environment variables:

* `SHORT_LINK_DOMAIN`
* `SHORTENER_GUEST_CREATE_RATE_LIMIT`
* `SHORTENER_GUEST_DEFAULT_EXPIRY_DAYS`
* `DRDJ_SHORTENER_BASE_URL`
* `DRDJ_SHORTENER_ACCESS_TOKEN`
* `DRDJ_SHORTENER_CHANNEL`
* `DRDJ_SHORTENER_ACTOR_ID`

Photo links require registered-agent access and the existing screenshot storage
configuration.

## Branch and Scope Rules

* keep one logical change per PR
* avoid mixed feature + refactor + schema bundles
* escalate risky auth/public changes for manager review

## Extension Workflow

WhatsApp:

```bash theme={null}
cd /whatsapp-extension-react
pnpm dev
pnpm build
```

LinkShot:

```bash theme={null}
cd /linkshot-extension
pnpm build
```
