Skip to main content

Overview

The sunpeak CLI commands support a complete development lifecycle, from project creation to production deployment. This page explains how the commands work together.

Development Lifecycle

1. Create

Install sunpeak globally:
pnpm add -g sunpeak
Then start a new project:
sunpeak new
This scaffolds a complete sunpeak project with all the configuration and structure you need.

2. Develop

Run the development server with hot reload:
sunpeak dev
This starts the ChatGPT simulator at http://localhost:6767, letting you iterate quickly on your App UI. For testing with the real ChatGPT, start the MCP server:
sunpeak mcp

3. Build

Create production-ready bundles:
sunpeak build
This compiles and optimizes your Resources for deployment.

4. Push

Push your built Resources to the sunpeak repository:
sunpeak login        # Authenticate (once)
sunpeak push         # Push to repository
sunpeak push --tag v1.0.0  # Push with version tag
Tags let you version your builds and reference specific versions later.

5. Deploy

Deploy to production:
sunpeak deploy
This is equivalent to sunpeak push --tag prod, marking the current build as the production version.

CI/CD Integration

The push/pull commands enable CI/CD workflows where your MCP server can pull the latest Resources without rebuilding:
# In your MCP server deployment:
sunpeak pull -r my-repo -t prod

Dive Deeper

CLI API Reference

Detailed documentation for all CLI commands and options.