@authon/create-app
v0.1.4
Published
Create a new project with Authon authentication pre-configured
Maintainers
Readme
@authon/create-app
Scaffold a new project with Authon authentication pre-configured.
Prerequisites
Before using this CLI, create an Authon project and get your API keys:
Create a project at Authon Dashboard
- Click "Create Project" and enter your app name
- Select the authentication methods you want (Email/Password, OAuth providers, etc.)
Get your API keys from Project Settings → API Keys
- Publishable Key (
pk_live_...) — use in your frontend code - Test Key (
pk_test_...) — for development, enables Dev Teleport
- Publishable Key (
Configure OAuth providers (optional) in Project Settings → OAuth
- Add Google, Apple, GitHub, etc. with their respective Client ID and Secret
- Set the redirect URL to
https://api.authon.dev/v1/auth/oauth/redirect
Test vs Live keys: Use
pk_test_...during development. Switch topk_live_...before deploying to production. Test keys use a sandbox environment with no rate limits.
Usage
npx @authon/create-appNon-interactive
npx @authon/create-app my-app --template nextjs-app --yesTemplates
| Template | Framework | SDK |
|----------|-----------|-----|
| nextjs-app | Next.js (App Router) | @authon/nextjs |
| nextjs-pages | Next.js (Pages Router) | @authon/nextjs |
| react-vite | React + Vite | @authon/react |
| vue-vite | Vue 3 + Vite | @authon/vue |
| nuxt | Nuxt 3 | @authon/nuxt |
| svelte | SvelteKit | @authon/svelte |
What's included
Each generated project includes:
- Framework-specific configuration
- Authon authentication setup (provider, middleware)
- Landing page with sign-in
- Protected dashboard page
.env.examplewith Authon configurationCLAUDE.mdfor AI agent context
Options
-t, --template <template> Use a specific template (skip framework prompt)
-y, --yes Skip prompts and use defaults
-h, --help Show help
-v, --version Show version