# Package.json Scripts Reference Guide

*Complete documentation for all build, development, and utility scripts*
*Last Updated: September 26, 2025*

## 📋 Table of Contents

1. [Overview](#overview)
2. [Build Scripts](#build-scripts)
3. [Development Scripts](#development-scripts)
4. [Testing Scripts](#testing-scripts)
5. [Extension Scripts](#extension-scripts)
6. [Zoom Bridge Scripts](#zoom-bridge-scripts)
7. [Demo Scripts](#demo-scripts)
8. [Backup & Data Scripts](#backup--data-scripts)
9. [Utility Scripts](#utility-scripts)
10. [Nx Commands](#nx-commands)
11. [Dependency Relationships](#dependency-relationships)
12. [Troubleshooting](#troubleshooting)

## 🎯 Overview

This document provides comprehensive documentation for all 77+ scripts available in the BuzzTrail monorepo. Scripts are organized by category with usage examples, purpose explanations, and dependency information.

### Script Categories
- **Build Scripts**: Production and development builds (17 scripts)
- **Development Scripts**: Development servers and workflows (12 scripts)
- **Testing Scripts**: Test execution and validation (8 scripts)
- **Extension Scripts**: Chrome/Firefox extension development (8 scripts)
- **Bridge Scripts**: Zoom integration utilities (8 scripts)
- **Demo Scripts**: Customer demo management (6 scripts)
- **Backup Scripts**: Data backup and management (7 scripts)
- **Utility Scripts**: Key management and configuration (11 scripts)

### Package Manager
**🚨 IMPORTANT**: All scripts use `pnpm` as the package manager. Do not use `npm` or `yarn`.

```bash
# Correct usage
pnpm run build
pnpm nx build extension

# Incorrect - will cause issues
npm run build
yarn build
```

## 🏗️ Build Scripts

### Core Build Commands

#### `build`
**Purpose**: Build all applications in the monorepo
**Usage**: `pnpm run build`
**Underlying Command**: `nx run-many --target=build --all`
**Build Time**: ~10-15 seconds (parallel execution)

**What it builds**:
- Extension (Chrome/Firefox packages)
- Chatbot (IIFE bundle for web injection)
- Demos (Web demos + Wix-optimized builds)
- Proxy Server (Vercel functions)
- Tavus Zoom Bridge (Node.js service)
- Backup Service (Node.js CLI application)
- Fake Tavus Server (Mock API server)

**Output Structure**:
```
dist/
├── apps/
│   ├── extension/           # Browser extension files
│   ├── chatbot/            # Chatbot bundle
│   ├── demos/              # Demo applications
│   ├── proxy-server/       # Vercel functions
│   ├── tavus-zoom-bridge/  # Zoom integration
│   ├── backup-service/     # Backup CLI
│   └── fake-tavus-server/  # Mock server
```

### Application-Specific Build Scripts

#### `build:extension`
**Purpose**: Build Chrome extension for production
**Usage**: `pnpm run build:extension`
**Underlying Command**: `nx build extension`
**Build System**: WXT Framework (Vite-based)
**Output**: Chrome Web Store ready package in `dist/apps/extension/`

**Features Built**:
- Manifest v3 configuration
- React-based side panel
- Content scripts for web injection
- Background service worker
- Camera permission handling
- Cross-browser compatibility preparation

#### `build:chatbot`
**Purpose**: Build chatbot widget for web embedding
**Usage**: `pnpm run build:chatbot`
**Underlying Command**: `nx build chatbot`
**Build System**: Vite with IIFE output
**Output**: Single JavaScript file for script injection

**Build Features**:
- Theme system integration (Sendcloud, default, neon)
- Base64 embedded assets
- Scoped CSS to prevent conflicts
- TypeScript compilation
- Minified production bundle (~150KB)

#### `build:demos`
**Purpose**: Build customer demo applications
**Usage**: `pnpm run build:demos`
**Underlying Command**: `nx build demos`
**Build System**: Vite + Custom Wix optimization
**Output**: Web demos + Wix custom code files

#### `build:proxy-server`
**Purpose**: Build Vercel serverless functions
**Usage**: `pnpm run build:proxy-server`
**Underlying Command**: `nx build proxy-server`
**Build System**: Vercel Functions
**Output**: Serverless API endpoints

#### `build:tavus-zoom-bridge`
**Purpose**: Build Zoom integration service
**Usage**: `pnpm run build:tavus-zoom-bridge`
**Underlying Command**: `nx build tavus-zoom-bridge`
**Build System**: TypeScript compilation
**Output**: Node.js service with JWT handling

### Specialized Build Scripts

#### `build:wix`
**Purpose**: Build Wix-optimized demo with production settings
**Usage**: `pnpm run build:wix`
**Underlying Command**: `pnpm nx build:wix demos`
**Character Limit**: 15,000 characters (currently 14,993/15,000)
**Environment**: Uses `.env.production` for optimized builds

**Optimization Features**:
- JavaScript minification
- CSS inlining and optimization
- Template literal compression
- Character count validation
- Production environment variable injection

#### `wix`
**Purpose**: Quick alias for Wix production build
**Usage**: `pnpm wix`
**Same as**: `pnpm build:wix`

## 🚀 Development Scripts

### Core Development Commands

#### `dev`
**Purpose**: Start all development servers
**Usage**: `pnpm run dev`
**Underlying Command**: `nx run-many --target=dev --all`
**Ports Used**: Multiple ports for different services

**Services Started**:
- Extension development server
- Chatbot development server
- Demo development server
- Proxy server development
- Zoom bridge development server

#### `dev:extension`
**Purpose**: Start extension development with hot reload
**Usage**: `pnpm run dev:extension`
**Underlying Command**: `nx dev extension`
**Hot Reload**: Yes (WXT framework)
**Browser**: Chrome (default)

**Development Features**:
- Automatic extension reloading
- React Fast Refresh for UI components
- TypeScript compilation on save
- Source maps for debugging

#### `dev:chatbot`
**Purpose**: Start chatbot development server
**Usage**: `pnpm run dev:chatbot`
**Underlying Command**: `nx serve chatbot`
**Port**: Typically 4200
**Hot Reload**: Yes (Vite HMR)

#### `dev:demos`
**Purpose**: Start demo development server
**Usage**: `pnpm run dev:demos`
**Underlying Command**: `nx serve demos`
**Features**: Live preview of Wix integration code

#### `dev:proxy-server`
**Purpose**: Start proxy server development
**Usage**: `pnpm run dev:proxy-server`
**Underlying Command**: `nx serve proxy-server`

#### `dev:tavus-zoom-bridge`
**Purpose**: Start Zoom bridge development
**Usage**: `pnpm run dev:tavus-zoom-bridge`
**Underlying Command**: `nx dev tavus-zoom-bridge`

### Advanced Development Workflows

#### `dev:with-logging`
**Purpose**: Start chatbot with comprehensive logging
**Usage**: `pnpm run dev:with-logging`
**Underlying Command**: `run-p log-server dev:chatbot`
**Dependencies**: Requires `log-server` script

**Features**:
- Real-time log streaming
- Tavus API call monitoring
- Error tracking and debugging
- Performance metrics

#### `dev:full`
**Purpose**: Full development environment with all services
**Usage**: `pnpm run dev:full`
**Underlying Command**: `run-p log-server dev:chatbot serve:chatbot:root`
**Services**: Log server + Chatbot + Root server

#### `dev:full-build`
**Purpose**: Full development build with optimizations
**Usage**: `pnpm run dev:full-build`
**Underlying Command**: `node scripts/dev-with-logging.js`
**Features**: Production-like build with development features

#### `dev:with-real-data`
**Purpose**: Development with real Tavus API data
**Usage**: `pnpm run dev:with-real-data`
**Dependencies**: `backup:tavus:all`, `fake-server:restart`
**⚠️ Caution**: Uses real API keys and data

#### `dev:setup`
**Purpose**: Complete development environment setup
**Usage**: `pnpm run dev:setup`
**Process**:
1. Runs `backup:tavus:all` to fetch latest data
2. Builds fake-tavus-server
3. Starts server with real data

## 🧪 Testing Scripts

### Core Testing Commands

#### `test`
**Purpose**: Run all Jest tests
**Usage**: `pnpm run test`
**Underlying Command**: `jest`
**Test Runner**: Jest with jsdom environment
**Coverage**: Optional (use `--coverage` flag)

#### `test:watch`
**Purpose**: Run tests in watch mode
**Usage**: `pnpm run test:watch`
**Underlying Command**: `jest --watch`
**Features**: Automatic re-run on file changes

### Specialized Testing Scripts

#### `test:logging`
**Purpose**: Test Tavus logging integration
**Usage**: `pnpm run test:logging`
**Underlying Command**: `node scripts/test-tavus-logging-simple.js`
**Tests**: Basic logging functionality and API connectivity

#### `test:logging-security`
**Purpose**: Test localhost security restrictions
**Usage**: `pnpm run test:logging-security`
**Underlying Command**: `node scripts/test-localhost-restriction.js`
**Tests**: Security policies and access restrictions

#### `test:browser-logging`
**Purpose**: Test browser-based logging
**Usage**: `pnpm run test:browser-logging`
**Underlying Command**: `node scripts/test-browser-logging.js`
**Tests**: Client-side logging and error reporting

### Testing Utilities

#### `log-server`
**Purpose**: Start logging server for development
**Usage**: `pnpm run log-server`
**Underlying Command**: `node scripts/tavus-log-server.js`
**Port**: Configurable (default varies)
**Usage**: Typically used with other development scripts

## 🔧 Extension Scripts

### Development Scripts

#### `extension:dev`
**Purpose**: Start extension development (Chrome)
**Usage**: `pnpm run extension:dev`
**Same as**: `dev:extension`
**Browser**: Chrome/Chromium

#### `extension:dev:firefox`
**Purpose**: Start extension development for Firefox
**Usage**: `pnpm run extension:dev:firefox`
**Underlying Command**: `nx dev:firefox extension`
**Browser**: Firefox Developer Edition recommended

### Build Scripts

#### `extension:build`
**Purpose**: Build extension for Chrome
**Usage**: `pnpm run extension:build`
**Same as**: `build:extension`
**Output**: Production-ready Chrome extension

#### `extension:build:firefox`
**Purpose**: Build extension for Firefox
**Usage**: `pnpm run extension:build:firefox`
**Underlying Command**: `nx build:firefox extension`
**Output**: Firefox-compatible extension package

### Packaging Scripts

#### `extension:zip`
**Purpose**: Create Chrome extension package for distribution
**Usage**: `pnpm run extension:zip`
**Underlying Command**: `nx zip extension`
**Output**: `.zip` file ready for Chrome Web Store
**Location**: `dist/apps/extension-chrome.zip`

#### `extension:zip:firefox`
**Purpose**: Create Firefox extension package
**Usage**: `pnpm run extension:zip:firefox`
**Underlying Command**: `nx zip:firefox extension`
**Output**: `.zip` file ready for Firefox Add-ons
**Location**: `dist/apps/extension-firefox.zip`

### Utility Scripts

#### `extension:preview`
**Purpose**: Preview built extension without installing
**Usage**: `pnpm run extension:preview`
**Underlying Command**: `nx preview extension`
**Features**: Test built extension functionality

#### `extension:type-check`
**Purpose**: TypeScript type checking for extension
**Usage**: `pnpm run extension:type-check`
**Underlying Command**: `nx type-check extension`
**No Build**: Only checks types, doesn't build

## 🌉 Zoom Bridge Scripts

### Development Scripts

#### `bridge:dev`
**Purpose**: Start Zoom bridge development server
**Usage**: `pnpm run bridge:dev`
**Underlying Command**: `nx dev tavus-zoom-bridge`
**Same as**: `dev:tavus-zoom-bridge`

#### `bridge:start`
**Purpose**: Start built Zoom bridge service
**Usage**: `pnpm run bridge:start`
**Underlying Command**: `nx serve tavus-zoom-bridge`
**Requires**: Built application in `dist/`

### Build Scripts

#### `bridge:build`
**Purpose**: Build Zoom bridge service
**Usage**: `pnpm run bridge:build`
**Underlying Command**: `nx build tavus-zoom-bridge`
**Same as**: `build:tavus-zoom-bridge`

### Demo Scripts

#### `bridge:demo`
**Purpose**: Run Zoom integration demo
**Usage**: `pnpm run bridge:demo`
**Underlying Command**: `nx demo tavus-zoom-bridge`
**Features**: Live Zoom API demonstration

#### `bridge:demo:test`
**Purpose**: Run Zoom demo in test mode
**Usage**: `pnpm run bridge:demo:test`
**Underlying Command**: `nx demo:test tavus-zoom-bridge`
**Features**: Safe testing without real Zoom calls

#### `bridge:working-demo`
**Purpose**: Run confirmed working demo
**Usage**: `pnpm run bridge:working-demo`
**Underlying Command**: `nx working-demo tavus-zoom-bridge`
**Features**: Tested demo configuration

### JWT Utilities

#### `bridge:generate-jwt`
**Purpose**: Generate JWT tokens for Zoom API
**Usage**: `pnpm run bridge:generate-jwt`
**Underlying Command**: `nx generate-jwt tavus-zoom-bridge`
**Output**: JWT token for API authentication

#### `bridge:jwt-server`
**Purpose**: Start JWT generation server
**Usage**: `pnpm run bridge:jwt-server`
**Underlying Command**: `nx jwt-server tavus-zoom-bridge`
**Features**: HTTP endpoint for JWT generation

## 🎨 Demo Scripts

### Development Servers

#### `serve:demos:buzztrail`
**Purpose**: Serve BuzzTrail-specific demo
**Usage**: `pnpm run serve:demos:buzztrail`
**Underlying Command**: `nx serve:buzztrail demos`
**Theme**: BuzzTrail branding and configuration

#### `serve:demos:sendcloud`
**Purpose**: Serve Sendcloud-specific demo
**Usage**: `pnpm run serve:demos:sendcloud`
**Underlying Command**: `nx serve:sendcloud demos`
**Theme**: Sendcloud branding and configuration

### Browser Opening

#### `open:demos:buzztrail`
**Purpose**: Open BuzzTrail demo in browser
**Usage**: `pnpm run open:demos:buzztrail`
**Underlying Command**: `nx open:buzztrail demos`
**Action**: Automatically opens browser to demo

#### `open:demos:sendcloud`
**Purpose**: Open Sendcloud demo in browser
**Usage**: `pnpm run open:demos:sendcloud`
**Underlying Command**: `nx open:sendcloud demos`
**Action**: Automatically opens browser to demo

## 💾 Backup & Data Scripts

### Tavus Data Backup

#### `backup:tavus:all`
**Purpose**: Backup all Tavus environments
**Usage**: `pnpm run backup:tavus:all`
**Underlying Command**: `node tavus-backup.js`
**Environments**: Production, staging, testing
**Output**: Local JSON files with API data

#### `backup:tavus:prod`
**Purpose**: Backup production Tavus data
**Usage**: `pnpm run backup:tavus:prod`
**Underlying Command**: `TAVUS_ENVIRONMENT=prod node tavus-backup.js`
**Environment**: Production only
**⚠️ Caution**: Uses production API keys

#### `backup:tavus:staging`
**Purpose**: Backup staging Tavus data
**Usage**: `pnpm run backup:tavus:staging`
**Underlying Command**: `TAVUS_ENVIRONMENT=staging node tavus-backup.js`
**Environment**: Staging environment

#### `backup:tavus:testing`
**Purpose**: Backup testing Tavus data
**Usage**: `pnpm run backup:tavus:testing`
**Underlying Command**: `TAVUS_ENVIRONMENT=testing node tavus-backup.js`
**Environment**: Testing environment

### Fake Server Data Management

#### `fake-server:build`
**Purpose**: Build fake Tavus server
**Usage**: `pnpm run fake-server:build`
**Same as**: `build` for fake-tavus-server

#### `fake-server:start`
**Purpose**: Start built fake server
**Usage**: `pnpm run fake-server:start`
**Underlying Command**: `node dist/apps/fake-tavus-server/main.js`
**Requires**: Built server in dist/

#### `fake-server:dev`
**Purpose**: Start fake server in development mode
**Usage**: `pnpm run fake-server:dev`
**Same as**: Development server with hot reload

#### `fake-server:restart`
**Purpose**: Kill and restart fake server
**Usage**: `pnpm run fake-server:restart`
**Process**: Kills existing process, starts new one
**Safe**: Uses `|| true` to handle missing process

#### `fake-server:refresh`
**Purpose**: Refresh server with latest backup data
**Usage**: `pnpm run fake-server:refresh`
**Process**:
1. Runs `backup:tavus:all`
2. Runs `fake-server:restart`

## 🔧 Utility Scripts

### Type Generation

#### `generate:types`
**Purpose**: Generate TypeScript types
**Usage**: `pnpm run generate:types`
**Underlying Command**: `pnpm --filter=types run generate`
**Scope**: Types workspace only

#### `validate:types`
**Purpose**: Validate generated types
**Usage**: `pnpm run validate:types`
**Underlying Command**: `pnpm --filter=types run validate`
**Checks**: Type consistency and completeness

#### `generate:python-schemas`
**Purpose**: Generate Python schema files
**Usage**: `pnpm run generate:python-schemas`
**Underlying Command**: `pnpm --filter=schemas run generate:python`
**Output**: Python type definitions

#### `generate:typescript-types`
**Purpose**: Generate TypeScript type definitions
**Usage**: `pnpm run generate:typescript-types`
**Underlying Command**: `pnpm --filter=schemas run generate:typescript`
**Output**: TypeScript type definitions

### Key Management

#### `keys:check`
**Purpose**: Check API key status
**Usage**: `pnpm run keys:check`
**Underlying Command**: `node scripts/tavus-key-manager.js check`
**Checks**: Key validity and permissions

#### `keys:list`
**Purpose**: List available API keys
**Usage**: `pnpm run keys:list`
**Underlying Command**: `node scripts/tavus-key-manager.js list`
**Output**: Non-sensitive key information

#### `keys:status`
**Purpose**: Show environment key status
**Usage**: `pnpm run keys:status`
**Underlying Command**: `node scripts/tavus-key-manager.js env`
**Shows**: Current environment configuration

#### `keys:validate`
**Purpose**: Validate all API keys
**Usage**: `pnpm run keys:validate`
**Underlying Command**: `node scripts/tavus-key-manager.js validate`
**Tests**: Key authentication with APIs

### Configuration

#### `s3:configure-recordings`
**Purpose**: Configure S3 for recording storage
**Usage**: `pnpm run s3:configure-recordings`
**Underlying Command**: `node scripts/configure-s3-recordings.js`
**Sets up**: S3 bucket and permissions for recordings

#### `type-check`
**Purpose**: TypeScript type checking across all projects
**Usage**: `pnpm run type-check`
**Underlying Command**: `tsc --noEmit`
**No Build**: Only validates types

### Backup Manager

#### `backup-manager:dev`
**Purpose**: Start backup manager in development
**Usage**: `pnpm run backup-manager:dev`
**Underlying Command**: `pnpm nx dev backup-manager`
**Features**: CLI interface for backup operations

#### `backup-manager:build`
**Purpose**: Build backup manager application
**Usage**: `pnpm run backup-manager:build`
**Underlying Command**: `pnpm nx build backup-manager`
**Output**: Node.js CLI application

## 📊 Nx Commands

### Core Nx Commands

#### `graph`
**Purpose**: Generate and view dependency graph
**Usage**: `pnpm run graph`
**Underlying Command**: `nx graph`
**Output**: Interactive web-based dependency visualization

#### `affected:build`
**Purpose**: Build only affected projects
**Usage**: `pnpm run affected:build`
**Underlying Command**: `nx affected:build`
**Efficiency**: Only builds changed projects

#### `affected:test`
**Purpose**: Test only affected projects
**Usage**: `pnpm run affected:test`
**Underlying Command**: `nx affected:test`
**Smart Testing**: Tests based on git changes

#### `affected:lint`
**Purpose**: Lint only affected projects
**Usage**: `pnpm run affected:lint`
**Underlying Command**: `nx affected:lint`
**Quality**: Code quality checks for changed files

### Linting Scripts

#### `lint`
**Purpose**: Lint all projects
**Usage**: `pnpm run lint`
**Underlying Command**: `nx run-many --target=lint --all`
**Tools**: ESLint with TypeScript support

#### Project-Specific Linting:
- `lint:extension`: `nx lint extension`
- `lint:chatbot`: `nx lint chatbot`
- `lint:demos`: `nx lint demos`
- `lint:proxy-server`: `nx lint proxy-server`
- `lint:tavus-zoom-bridge`: `nx lint tavus-zoom-bridge`

## 🔗 Dependency Relationships

### Script Dependencies

#### High-Level Dependencies:
```
dev:setup
├── backup:tavus:all
├── fake-server:build
└── fake-server:start

dev:with-real-data
├── fake-server:refresh
│   ├── backup:tavus:all
│   └── fake-server:restart
└── fake-server:start

extension:zip
├── extension:build
└── WXT packaging

build
├── build:extension
├── build:chatbot
├── build:demos
├── build:proxy-server
└── build:tavus-zoom-bridge
```

#### Development Workflow Dependencies:
```
1. Initial Setup:
   keys:check → backup:tavus:all → dev:setup

2. Extension Development:
   extension:build → extension:zip → Store Upload

3. Demo Development:
   build:demos → build:wix → Wix Deployment

4. Full Development:
   log-server + dev:chatbot + fake-server:dev
```

### Build Order Recommendations

#### For New Developers:
1. `pnpm run keys:check` - Verify API access
2. `pnpm run backup:tavus:all` - Get latest data
3. `pnpm run build` - Build all projects
4. `pnpm run dev:setup` - Start development environment

#### For Production Deployment:
1. `pnpm run type-check` - Validate types
2. `pnpm run lint` - Check code quality
3. `pnpm run test` - Run all tests
4. `pnpm run build` - Build for production
5. Deploy specific applications

#### For Extension Development:
1. `pnpm run extension:build` - Build extension
2. `pnpm run extension:dev` - Start development
3. Load in Chrome Extensions page
4. `pnpm run extension:zip` - Package for store

## 🚨 Troubleshooting

### Common Issues

#### Build Failures

**Issue**: `build:extension` fails with import errors
**Solution**:
```bash
# Clear nx cache and rebuild
npx nx reset
pnpm run build:extension
```

**Issue**: `build:wix` exceeds character limit
**Solution**:
```bash
# Check current character count
pnpm run build:wix
# Review build output for character count
# Optimize code comments and whitespace if needed
```

#### Development Server Issues

**Issue**: `dev:extension` doesn't reload changes
**Solution**:
```bash
# Restart development server
# Reload extension in browser
# Check browser console for errors
```

**Issue**: `fake-server:start` fails with port errors
**Solution**:
```bash
# Kill existing processes
pnpm run fake-server:restart
# Or use different port in configuration
```

#### Data and API Issues

**Issue**: `backup:tavus:all` fails with auth errors
**Solution**:
```bash
# Check API keys
pnpm run keys:check
pnpm run keys:validate

# Verify environment variables
pnpm run keys:status
```

**Issue**: `bridge:demo` fails with JWT errors
**Solution**:
```bash
# Generate new JWT token
pnpm run bridge:generate-jwt
# Check Zoom API credentials
```

### Script Execution Issues

#### Package Manager Issues

**Problem**: Scripts fail with package manager errors
**Solution**: Ensure using pnpm:
```bash
# Install pnpm if not available
npm install -g pnpm

# Use pnpm for all commands
pnpm run build  # ✅ Correct
npm run build   # ❌ Wrong
```

#### Permission Issues

**Problem**: Scripts fail with permission errors
**Solution**:
```bash
# On macOS/Linux, ensure proper permissions
chmod +x scripts/*.js

# For Node.js script execution
node --version  # Ensure Node.js 22+ installed
```

#### Environment Issues

**Problem**: Scripts fail with missing environment variables
**Solution**:
```bash
# Check environment setup
pnpm run keys:status

# Copy environment template
cp .env.example .env.local
# Fill in required variables
```

### Performance Issues

#### Slow Build Times

**Problem**: Builds taking too long
**Solutions**:
```bash
# Use affected builds instead of full builds
pnpm run affected:build

# Clear cache if builds are stale
npx nx reset

# Use parallel execution
pnpm run build  # Already uses parallel execution
```

#### Memory Issues

**Problem**: Out of memory during builds
**Solutions**:
```bash
# Increase Node.js memory limit
export NODE_OPTIONS="--max-old-space-size=8192"

# Build projects individually
pnpm run build:extension
pnpm run build:chatbot
# etc.
```

### Debug Information

#### Getting Detailed Output

```bash
# Verbose build output
pnpm run build --verbose

# Debug Nx execution
NX_VERBOSE_LOGGING=true pnpm run build

# Debug individual project
pnpm nx build extension --verbose
```

#### Log Files

- Build logs: Check terminal output
- Extension logs: Chrome DevTools Console
- Server logs: Terminal output from dev servers
- Test logs: Jest output with `--verbose` flag

### Emergency Recovery

#### Complete Reset

If all else fails, complete environment reset:
```bash
# 1. Clean all builds
rm -rf dist/
rm -rf node_modules/

# 2. Reinstall dependencies
pnpm install

# 3. Reset Nx cache
npx nx reset

# 4. Rebuild everything
pnpm run build

# 5. Verify functionality
pnpm run test
```

---

## 📚 Related Documentation

### Core Documentation
- [Build System Guide](../documentation/documentation/build-system-guide.md) - Architecture and build system details
- [Development Guide](../documentation/documentation/development-guide.md) - Setup and development workflows
- [Testing & Quality Guide](../documentation/documentation/testing-quality-guide.md) - Testing strategies and code quality

### Integration Guides
- [Tavus Integration Guide](../documentation/documentation/tavus-integration-guide.md) - Tavus API integration patterns
- [API Integration Guide](../documentation/documentation/api-integration-guide.md) - API integration details
- [Wix Integration Guide](../documentation/documentation/wix-integration-guide.md) - Wix demo integration

### UI & Development
- [UI/UX Guide](../documentation/documentation/ui-ux-guide.md) - Component architecture and theming
- [Dev Server Guide](../documentation/documentation/dev-server-guide.md) - Development server setup

---

**Script Count**: 77+ documented scripts
**Package Manager**: pnpm (required)
**Nx Version**: 21.4.0
**Last Updated**: September 26, 2025