- Node.js version: The project requires Node.js 20 (see
.nvmrc) - Install dependencies: Run
npm installfrom the root directory
This is a monorepo with multiple packages. The recommended pipeline is:
- Demo App (the target website to test)
- Express Backend + Dashboard (run together)**
- SDK CLI (optional, for command-line usage)
Step 1: Start the Demo App (Next.js app on port 3000):
cd packages/demo-app
npm run devStep 2: Start Express Backend + Dashboard together (from root directory):
npm run start:servicesThis single command runs:
- Express API Backend on port 3002
- Dashboard on port 3001
The Express backend provides API endpoints for the dashboard to communicate with the browser agent.
Demo App (Next.js app on port 3000):
cd packages/demo-app
npm run devExpress API Backend (runs on port 3002):
cd packages/darwin-sdk/core
npm run start:dev # Development mode with hot reloadDarwin Dashboard (Next.js app on port 3001):
cd packages/darwin-sdk/dashboard
npm run devDarwin SDK CLI (browser automation):
cd packages/darwin-sdk
npm run dev init # Initialize config
npm run dev run # Run the agentFrom the root directory:
npm run devThis runs the dev script for all workspaces.
From the root directory:
npm run run-sdk-on-demoThis runs the Darwin SDK against the demo app.
From the root directory:
npm run evolveFor the Darwin SDK to work, you'll need to set up environment variables. Create a .env file in packages/darwin-sdk:
# Required for LOCAL mode (choose one model):
GOOGLE_GENERATIVE_AI_API_KEY=your_key_here
# OR
ANTHROPIC_API_KEY=your_key_here
# OR
OPENAI_API_KEY=your_key_here
# Optional for BROWSERBASE mode:
BROWSERBASE_API_KEY=your_key_here
BROWSERBASE_PROJECT_ID=your_project_id_here- Install dependencies:
npm install(from root) - Start demo app:
cd packages/demo-app && npm run dev(runs on http://localhost:3000) - Start services:
npm run start:services(from root - runs Express API on http://localhost:3002 and Dashboard on http://localhost:3001) - (Optional) Run SDK CLI:
cd packages/darwin-sdk && npm run dev run(requires config and API keys)
Note: The dashboard requires the Express API backend to be running on port 3002 to function properly. Use npm run start:services to run both together.
The demo app is a Next.js e-commerce site, the dashboard is a Next.js UI for managing the Darwin SDK, and the Express backend provides the API endpoints that the dashboard uses to control browser agents.