Deploy and run
Starters
Deploy a working Next.js, FastAPI, Discord bot or cron worker app in one click, then make it your own.
Starters are small, real apps you can deploy with one click and open a minute later: a landing page, a waitlist, an AI chatbot, a Discord bot, Next.js with Postgres and more. They're the quickest way to see CLI work, and a good base for your own thing.
How to do it: under Put something online, pick a starter, fill in anything it asks for, and press Deploy. Then change its code like any other app.
"Deploy the waitlist starter and call it Launchpad."
Starters are small, real apps you can deploy with one click, open a minute later, and then change. They're the quickest way to see CLI work end to end, and a good base for something of your own.
The starters
| Starter | What you get | Needs |
|---|---|---|
| Next.js + Postgres | A Next.js app (App Router) with a notes page stored in Postgres | Nothing |
| FastAPI + Postgres | A Python API with GET and POST /items stored in Postgres, and interactive docs at /docs | Nothing |
| Discord bot | A discord.js bot that answers /ping | Your bot's token and application id |
| Cron worker | A Python job that runs every hour, with its output and failures in the dashboard | Optionally, a URL for the example job to check |
| Landing page | A fast one-page site with a headline, three features and a sign-up button. Plain HTML and CSS you edit in public/ | Optionally, the site's name |
| Waitlist + Postgres | A sign-up page that saves emails to Postgres, plus /admin to see them and download a CSV. Its password is the ADMIN_KEY variable, made for you | Optionally, what people sign up for |
| SaaS starter | A Next.js app where people sign in with an emailed code, keep private notes in Postgres, and get a welcome email. CLI's sign-in and email are set up for you | Nothing. For welcome emails, a sending domain and EMAIL_FROM |
| AI chatbot | A chat page that talks to an AI model with your instructions | Nothing when the server offers AI models (billed from project credit, see /docs/ai-gateway); otherwise your OpenAI key |
Every starter answers GET /health, so CLI knows when it's up, and the ones with a database get DATABASE_URL wired in for them.
Deploy one
In the dashboard: press + New project and pick a starter under Put something online. Each shows what it costs a month, and asks its questions (the Discord bot's token, say) before it starts. Inside a project, they're also under Templates, Start from working code. New accounts can also start from Try a demo.
Ask your agent:
"Deploy the FastAPI starter in my shop project."
With the API:
POST /v1/projects/:id/templates/starter-fastapi{ "inputs": {} }The ids are starter-nextjs-postgres, starter-saas, starter-fastapi, starter-discord-bot, starter-cron-worker, starter-landing-page, starter-waitlist and starter-ai-chat. With CLI's AI models on, the chatbot gets an AI key for the project (OPENAI_BASE_URL, OPENAI_API_KEY, AI_MODEL); without them it needs {"inputs": {"openaiKey": "sk-…"}}. GET /v1/templates lists them with "starter": true.
Make it yours
The code lives in the public clicloud-app/starters repository, one folder per starter. To edit it, put your own copy in your GitHub:
- When you deploy it: choose Put the code in my GitHub and a repository name (private by default). CLI makes the repository in your account with the starter's code and deploys from it.
- Already running one: open the app's Settings → Make the code yours and choose Copy the code to my GitHub. What's running doesn't change.
Either way, every push to the repository's main branch redeploys the app. Link GitHub first (Account settings); CLI's GitHub app needs permission to create repositories, and GitHub asks you to approve that once.
POST /v1/projects/:id/templates/starter-fastapi {"inputs": {}, "copyToGitHub": {"name": "my-api", "private": true}}
POST /v1/services/:id/copy-to-github {"name": "my-api", "private": true}Agents pass copyToGitHub to cli_deploy_template. If the name is taken you get GITHUB_CANT_CREATE_REPO; if CLI's app is installed on selected repositories only, the repository is still made and GITHUB_REPO_NOT_ACCESSIBLE links to it and to where to give the app access.
You can also fork clicloud-app/starters yourself and point the app's source at your fork (keep the root directory, for example fastapi).
The SaaS starter
Deploying it turns on sign-in for the project (if it isn't on already) and fills in the app's variables:
| Variable | What it is |
|---|---|
CLI_AUTH_ISSUER | The project's sign-in address. The app asks it to email a code (/email/start), checks the code (/email/verify) and checks a session (/me) |
CLI_EMAIL_URL, CLI_EMAIL_KEY | An email key for the project, when the server can send email |
EMAIL_FROM | Where welcome emails come from. Empty until you add a sending domain under the project's Email; until then the app skips them and says so in its logs |
DATABASE_URL | The project's Postgres |
Everyone who signs in shows up under the project's Sign-in, where you can disable or remove them. The session is an httpOnly cookie holding CLI's token, and every page asks CLI whether it's still good, so a forged or expired cookie is simply signed out.
If a new project has no credit yet, the starter waits on the project page with a way to add credit and a Start button, rather than leaving an empty project.
For the Discord bot, invite it to a server from the Discord developer portal (OAuth2 → URL generator, scopes applications.commands and bot), then type /ping. For the cron worker, edit job.py; run it any time from the service's cron jobs.