Starter Kit • Free

Full‑Stack Coding Agent Starter Kit

An AI-powered coding assistant that writes, executes, and previews code in isolated E2B sandboxes. Built with Cedar-OS for chat UI, Mastra for orchestration, and E2B for secure execution.

Full‑Stack Coding Agent Starter Kit illustration

Get the Free Starter Kit

Free • Open source. Includes full source code and setup instructions.

Opens GitHub repository

What you get

A production-ready AI coding agent that generates, executes, and previews code across multiple languages and frameworks with secure sandbox isolation.

The stack

  • Cedar-OS
  • Mastra
  • E2B
  • OpenAI
  • TypeScript
  • Next.js

What's included

Cedar-OS chat interface with streaming

Mastra agent orchestration

E2B sandboxes with multiple templates (Next.js, Python, Streamlit, Gradio, Vue)

AI-powered code generation (Python, JavaScript, TypeScript, React, Vue)

Complete file management (read, write, edit, delete)

Live code execution with real-time output

Code preview with syntax highlighting

Live web preview for web applications

Thread-scoped sandboxes with persistence

Sandbox management (create, list, reconnect, terminate)

Full‑Stack Coding Agent Starter Kit

An AI-powered coding assistant that writes, executes, and previews code in isolated E2B sandboxes. Built with Cedar-OS for chat UI, Mastra for agent orchestration, and E2B for secure, ephemeral execution.

What's inside the kit

This production-ready starter kit includes everything you need to build an AI coding agent that can generate complete applications with natural language. You'll get:

  • Cedar-OS chat interface - Beautiful, production-ready chat UI with real-time streaming support
  • Mastra agent orchestration - Powerful agent framework with tools, planning, and state management
  • E2B sandbox execution - Secure, isolated environments for running code with multiple pre-configured templates
  • Multi-language support - Generate and execute Python, JavaScript, TypeScript, React, Next.js, Vue, Streamlit, and Gradio apps
  • Complete file management - Full CRUD operations on files and directories within sandboxes
  • Live code execution - Run code with real-time output streaming and error handling
  • Code preview - Syntax-highlighted code viewer with file tree navigation
  • Live web preview - See your web applications running in real-time with iframe preview
  • Thread-scoped sandboxes - Each conversation has its own isolated development environment
  • State persistence - File trees, code, and sandbox info persist across page refreshes

Prerequisites

  • Node.js 18+ (20+ recommended)
  • OpenAI API key - For the AI model
  • E2B API key - For secure sandbox execution
  • Familiarity with TypeScript, Node, and React
  • Basic terminal skills
  • Understanding of async/await patterns

What you'll build

An AI coding agent that can:

  • Generate complete applications from natural language descriptions
  • Choose the right environment - Automatically selects from multiple E2B templates (Python, Next.js, Streamlit, Gradio, Vue)
  • Manage project files - Create, read, update, and delete files and directories
  • Execute code safely - Run code in isolated sandboxes with automatic timeout management
  • Preview live applications - Display running web apps with real-time updates
  • Stream responses - Real-time token streaming with server-sent events (SSE)
  • Persist across sessions - Maintain sandbox state and file trees between conversations
  • Handle errors gracefully - Production-ready error boundaries and retry logic

Key Features

🎯 AI-Powered Code Generation

  • Natural language to code across multiple languages and frameworks
  • Smart template selection based on project requirements
  • Complete project setup with dependencies and build tools

🔐 Secure E2B Sandboxes

  • code-interpreter-v1 - Python data analysis and notebook-style execution
  • nextjs-developer - Next.js apps with TypeScript and Tailwind
  • streamlit-developer - Python UI apps with live reload
  • gradio-developer - Python demo applications
  • vue-developer - Vue/Nuxt applications
  • Automatic resource cleanup and timeout management

💻 Complete Development Workflow

  • File operations (create, read, edit, delete files and directories)
  • Command execution (npm/pip install, build commands, dev servers)
  • Real-time code execution with output streaming
  • Build automation and package management

🎨 Modern UI & Preview

  • Code preview with syntax highlighting and file tree
  • Live web preview for running applications
  • Dual view modes (Code/Web) with seamless switching
  • Sandbox status tracking with expiration timers

Safety & Production-Ready

This starter kit includes enterprise-grade safety features:

  • Execution timeouts - Automatic sandbox cleanup after inactivity
  • Resource isolation - Each conversation runs in its own E2B sandbox
  • Error boundaries - Production-ready error handling throughout the app
  • Secure API key management - Environment variables and best practices
  • Rate limiting ready - Built-in patterns for managing API costs
  • Auth integration - Optional Auth0 for AI Agents support

Get Started

Clone the repository and follow the Quick Start guide to launch your AI coding agent in minutes. The kit includes:

  • Complete monorepo setup with Next.js frontend and Mastra backend
  • Development environment configuration
  • API key setup instructions
  • Example prompts to test the agent
  • Deployment guide for production