The ChatGPT App framework.
Quickstart, build, test, and ship your ChatGPT App locally!
Demo (Hosted) ~ Demo (Video) ~ Discord (NEW) ~ Documentation ~ GitHub
Requirements: Node (20+), pnpm (10+)
pnpm add -g sunpeak
sunpeak newTo add sunpeak to an existing project, refer to the documentation.
sunpeak is an npm package consisting of:
- The
sunpeaklibrary (./src). An npm package for running & testing ChatGPT Apps. This standalone library contains:- Runtime APIs - Strongly typed, multi-platform APIs for interacting with the ChatGPT runtime, architected to support future platforms (Gemini, Claude).
- ChatGPT simulator - React component replicating ChatGPT's runtime.
- MCP server - Mock data MCP server for testing local UIs (resources) in the real ChatGPT.
- The
sunpeakframework (./template). Next.js for ChatGPT Apps. This templated npm package includes:- Project scaffold - Complete development setup with build, test, and mcp tooling, including the sunpeak library.
- UI components - Production-ready components following ChatGPT design guidelines and using OpenAI apps-sdk-ui React components.
- Convention over configuration - Create UIs (resources) by simply creating a
resources/NAME-resource.tsxReact file andresources/NAME-resource.jsonmetadata file.
- The
sunpeakCLI (./bin). Commands for managing ChatGPT Apps. Includes a client for the sunpeak Resource Repository (ECR for ChatGPT Apps). The repository helps you & your CI/CD decouple your App from your client-agnostic MCP server:- Tag your app builds with version numbers and environment names (like
v1.0.0andprod) pushbuilt Apps to a central locationpullbuilt Apps to be run in different environments
- Tag your app builds with version numbers and environment names (like
Note that each sunpeak component can be used in isolation if preferred, though the most seamless experience combines all 3.
import { Card } from '../card';
export function MCPResource() {
return (
<Card
image="https://images.unsplash.com/photo-1520950237264-dfe336995c34"
imageAlt="Lady Bird Lake"
header="Lady Bird Lake"
metadata="⭐ 4.5 • Austin, TX"
button1={{ children: 'Visit', isPrimary: true, onClick: () => {} }}
button2={{ children: 'Learn More', onClick: () => {} }}
>
Scenic lake perfect for kayaking, paddleboarding, and trails.
</Card>
);
}