This skill helps you initialize new Base44 projects and manage CLI workflows using the base44-cli, guiding setup and authentication.
npx playbooks add skill base44/skills --skill base44-cli
Create and manage Base44 apps (projects) using the Base44 CLI tool.
This skill activates on ANY mention of "base44" or when a base44/ folder exists. DO NOT read documentation files or search the web before acting.
Your first action MUST be:
base44/config.jsonc exists in the current directorybefore starting a dev server: one way of running hits production data.
BASE44_APP_ID (or BASE44_PROJECTS_BASE44_APP_ID) is present in the environment or a .env/.env.local file:npx base44 scaffold to set up local files for that existing appnpx base44 create — that creates a second, duplicate app. See [scaffold.md](references/scaffold.md).npx base44 createNEVER call base44 directly. The CLI is installed locally as a dev dependency and must be accessed via a package manager:
npx base44 <command> (npm - recommended)yarn base44 <command> (yarn)pnpm base44 <command> (pnpm)WRONG: base44 login
RIGHT: npx base44 login
CRITICAL: At the very start of every AI session when this skill is activated, you MUST:
npx base44 whoami
npx base44 login
This check is mandatory and must happen before executing any other Base44 CLI commands.
Provisioned via Stripe Projects / projects.dev? When the app was provisioned through that flow, the CLI seeds authentication from the BASE44_ACCESS_TOKEN / BASE44_REFRESH_TOKEN environment variables it injects (the BASE44_PROJECTS_*-prefixed names are normalized automatically). In that case npx base44 whoami already succeeds and you do not need an interactive npx base44 login.
Workspace API key set? If the BASE44_API_KEY environment variable is set to a workspace API key (prefixed b44k_), the CLI authenticates with it directly — npx base44 whoami and other commands succeed without an interactive login.
The Base44 CLI provides command-line tools for authentication, creating projects, managing entities, and deploying Base44 applications. It is framework-agnostic and works with popular frontend frameworks like Vite, Next.js, and Create React App, Svelte, Vue, and more.
Use base44-cli when:
scaffoldbase44/config.jsoncnpx base44 ...)Use base44-sdk when:
base44/config.jsonc already existsSkill Dependencies:
base44-cli is a prerequisite for base44-sdk in new projectsbase44-cli firstbase44-sdk assumes a Base44 project is already initializedState Check Logic:
Before selecting a skill, check:
base44/config.jsonc exists):→ Use base44-sdk (project exists, build features)
BASE44_APP_ID/BASE44_PROJECTS_BASE44_APP_ID set, or a Stripe Projects / projects.dev flow just ran):→ Use base44-cli → npx base44 scaffold (set up local files for the existing app; do NOT create)
→ Use base44-cli → npx base44 create (new project initialization needed)
A Base44 project combines a standard frontend project with a base44/ configuration folder:
my-app/
├── base44/ # Base44 configuration (created by CLI)
│ ├── config.jsonc # Project settings, site config
│ ├── .types/ # Auto-generated TypeScript types (created by `types generate`)
│ │ └── types.d.ts # Module augmentation for @base44/sdk
│ ├── entities/ # Entity schema definitions
│ │ ├── task.jsonc
│ │ └── board.jsonc
│ ├── functions/ # Backend functions (optional)
│ │ └── my-function/
│ │ └── entry.ts
│ ├── actors/ # Realtime actors (optional)
│ │ └── ChatRoom/
│ │ └── entry.ts
│ ├── agents/ # Agent configurations (optional)
│ │ └── support_agent.jsonc
│ ├── agent-skills/ # Agent skill instructions (optional)
│ │ └── pdf-export.md
│ └── connectors/ # OAuth connector configurations (optional)
│ └── googlecalendar.jsonc
├── src/ # Frontend source code
│ ├── api/
│ │ └── base44Client.js # Base44 SDK client
│ ├── pages/
│ ├── components/
│ └── main.jsx
├── index.html # SPA entry point
├── package.json
└── vite.config.js # Or your framework's config
Key files:
base44/config.jsonc - Project name, description, site build settingsbase44/entities/*.jsonc - Data model schemas (see Entity Schema section)base44/functions/*/entry.ts - Backend function entry pointbase44/actors/*/entry.ts - Realtime actor entry point (optional)base44/agents/*.jsonc - Agent configurations (optional)base44/agent-skills/*.md - Agent skill instructions (optional)base44/.types/types.d.ts - Auto-generated TypeScript types for entities, functions, and agents (created by npx base44 types generate)base44/connectors/*.jsonc - OAuth connector configurations (optional)src/api/base44Client.js - Pre-configured SDK client for frontend useconfig.jsonc example:
{
"name": "My App", // Required: project name
"description": "App description", // Optional: project description
"visibility": "public", // Optional: "public" | "private" | "workspace"
"entitiesDir": "./entities", // Optional: default "entities"
"functionsDir": "./functions", // Optional: default "functions"
"actorsDir": "./actors", // Optional: default "actors"
"agentsDir": "./agents", // Optional: default "agents"
"agentSkillsDir": "./agent-skills", // Optional: default "agent-skills"
"connectorsDir": "./connectors", // Optional: default "connectors"
"site": { // Optional: site deployment config
"installCommand": "npm install", // Optional: install dependencies
"buildCommand": "npm run build", // Optional: build command
"serveCommand": "npm run dev", // Optional: local dev server
"outputDirectory": "./dist" // Optional: build output directory
}
}
Config properties:
| Property | Description | Default |
|----------|-------------|---------|
| name | Project name (required) | - |
| description | Project description | - |
| visibility | App visibility: public, private, or workspace | - |
| entitiesDir | Directory for entity schemas | "entities" |
| functionsDir | Directory for backend functions | "functions" |
| actorsDir | Directory for realtime actors | "actors" |
| agentsDir | Directory for agent configs | "agents" |
| agentSkillsDir | Directory for agent skill instructions | "agent-skills" |
| connectorsDir | Directory for connector configs | "connectors" |
| site.installCommand | Command to install dependencies | - |
| site.buildCommand | Command to build the project | - |
| site.serveCommand | Command to run dev server | - |
| site.outputDirectory | Build output directory for deployment | - |
Install the Base44 CLI as a dev dependency in your project:
npm install --save-dev base44
Important: Never assume or hardcode the base44 package version. Always install without a version specifier to get the latest version.
Then run commands using npx:
npx base44 <command>
Note: All commands in this documentation use npx base44. You can also use yarn base44, or pnpm base44 if preferred.
--app-id OptionThe CLI has a global --app-id <id> option for commands that only need an app context, not local project files.
Resolution order: --app-id flag → BASE44_APP_ID environment variable → local base44/.app.jsonc
This is useful when you want to inspect or operate on an app without switching into a linked project directory. Common examples:
# Run a one-off script against a specific app
cat ./script.ts | npx base44 exec --app-id app_123
# Fetch logs for a deployed app without a local checkout
npx base44 logs --app-id app_123 --level error
Use --app-id for app-scoped commands like exec and logs.
Do not use --app-id for commands that need local project files:
base44 create creates a new app, so it rejects --app-idbase44 dev runs from a linked local project, so it rejects --app-idbase44 deploy still requires a local project directory because it reads local resources--json OptionThe CLI has a global --json option that makes commands emit a machine-readable JSON document on stdout instead of human-oriented output. It also forces non-interactive mode (spinners/status messages/logs move to stderr), so stdout stays pure JSON — safe to pipe into jq or another program.
npx base44 connectors list-available --json
npx base44 logs --app-id app_123 --json
| Command | Description | Reference |
| --------------- | ----------------------------------------------- | ------------------------------------------- |
| base44 login | Authenticate with Base44 using device code flow | [auth-login.md](references/auth-login.md) |
| base44 logout | Logout from current device | [auth-logout.md](references/auth-logout.md) |
| base44 whoami | Display current authenticated user | [auth-whoami.md](references/auth-whoami.md) |
| Command | Description | Reference |
|---------|-------------|-----------|
| base44 create | Create a new Base44 project from a template | [create.md](references/create.md) ⚠️ MUST READ |
| base44 scaffold | Scaffold a local project for an existing Base44 app (by app ID) | [scaffold.md](references/scaffold.md) |
| base44 link | Link an existing local project to Base44 | [link.md](references/link.md) |
| base44 eject | Download the code for an existing Base44 project | [eject.md](references/eject.md) |
| base44 dashboard open | Open the app dashboard in your browser | [dashboard.md](references/dashboard.md) |
| base44 visibility <level> | Set the app's visibility on the server (public, private, or workspace) | [visibility.md](references/visibility.md) |
Workspaces (a.k.a. organizations) group apps under shared membership. By default base44 create/base44 link --create use your personal workspace; pass -w, --workspace <id> to target another one.
| Command | Description | Reference |
|---------|-------------|-----------|
| base44 workspace list | List the workspaces you belong to | [workspace-list.md](references/workspace-list.md) |
| base44 workspace get <workspace-id> | Show details for a single workspace by ID | [workspace-get.md](references/workspace-get.md) |
| base44 workspace move [workspace-id] | Move the current app to another workspace | [workspace-move.md](references/workspace-move.md) |
| Command | Description | Reference |
|---------|-------------|-----------|
| base44 dev | Start local development for your Base44 backend, and your frontend too when site.serveCommand is configured | [dev.md](references/dev.md) |
| base44 dev --remote | Serve the frontend locally against the production backend | [dev.md](references/dev.md) |
| Command | Description | Reference |
|---------|-------------|-----------|
| base44 build | Build the site with its app id injected — use instead of a bare npm run build | — |
| base44 deploy | Deploy all resources (entities, functions, actors, agents, agent skills, connectors, auth config, and site); asks whether to build first, or pass --build / --no-build | [deploy.md](references/deploy.md) |
| Action / Command | Description | Reference |
| ---------------------- | ------------------------------------------- | --------------------------------------------------- |
| Create Entities | Define entities in base44/entities folder | [entities-create.md](references/entities-create.md) |
| base44 entities push | Push local entities to Base44 | [entities-push.md](references/entities-push.md) |
| RLS Patterns | Row-level security examples and operators | [rls-examples.md](references/rls-examples.md) ⚠️ READ FOR RLS |
ALWAYS follow this exact structure when creating entity files:
File naming: base44/entities/{kebab-case-name}.jsonc (e.g., team-member.jsonc for TeamMember)
Schema template:
{
"name": "EntityName",
"type": "object",
"properties": {
"field_name": {
"type": "string",
"description": "Field description"
}
},
"required": ["field_name"]
}
Field types: string, number, integer, boolean, array, object, binary
String formats: date, date-time, time, email, uri, hostname, ipv4, ipv6, uuid, file, regex, richtext
For enums: Add "enum": ["value1", "value2"] and optionally "default": "value1"
Entity names: Must be alphanumeric only (pattern: /^[a-zA-Z0-9]+$/)
For complete documentation, see [entities-create.md](references/entities-create.md).
| Action / Command | Description | Reference |
| ------------------------- | --------------------------------------------- | ------------------------------------------------------- |
| Create Functions | Define functions in base44/functions | [functions-create.md](references/functions-create.md) |
| base44 functions deploy [names...] [--force] | Deploy local functions to Base44; optionally target specific functions or prune removed ones | [functions-deploy.md](references/functions-deploy.md) |
| base44 functions delete <names...> | Delete one or more deployed functions from Base44 | [functions-delete.md](references/functions-delete.md) |
| base44 functions list | List all deployed functions on Base44 remote | [functions-list.md](references/functions-list.md) |
| base44 functions pull [name] | Pull deployed functions from Base44 to local files | [functions-pull.md](references/functions-pull.md) |
Workflows are the automation system (cron schedules, entity triggers, connector events, in-app agent actions). These commands are read-only: they answer "what workflows exist" and "did my scheduled work fail, and why".
| Command | Description | Reference |
|---------|-------------|-----------|
| base44 workflows list | List this app's workflows with status and run summary | [workflows-list.md](references/workflows-list.md) |
| base44 workflows runs [--status <s>] [--since <t>] | List workflow runs, newest first; failed runs include the underlying error | [workflows-runs.md](references/workflows-runs.md) |
Actors are stateful realtime server rooms over WebSockets — one live instance per room id, shared by every client connected to that id. Use them for multiplayer sessions, collaborative boards, presence and live cursors, in-room chat, and live auctions.
Actors use direct connections with SDK-managed authentication. Use verified conn.identity for user attribution and this.client.asServiceRole to persist validated room results. Actors receive no app secrets; put secret-dependent operations in a backend function. See [actors-create.md](references/actors-create.md) for the authoring contract.
| Action / Command | Description | Reference |
| ---------------- | ----------- | --------- |
| Create Actors | Define actors in base44/actors | [actors-create.md](references/actors-create.md) |
| base44 actors deploy [names...] | Deploy local actors to Base44; optionally target specific actors | [actors-deploy.md](references/actors-deploy.md) |
| base44 actors delete <names...> | Tear down deployed actors (destroys the published script) | [actors-deploy.md](references/actors-deploy.md#deleting-a-deployed-actor) |
File naming: base44/actors/{ActorName}/entry.ts — the folder is the actor's identity.
// base44/actors/ChatRoom/entry.ts
import { Actor } from "base44:runtime/actors";
export default class ChatRoom extends Actor {
handleConnect(conn) { conn.send({ type: "welcome" }); } // this client only
handleMessage(conn, msg) {
// Always validate: the payload is attacker-controlled and msg can even be null.
if (msg?.type !== "message" || typeof msg.text !== "string") return;
this.broadcast({ type: "message", text: msg.text.slice(0, 2000) }); // the whole room
}
handleClose(conn) {}
}
Naming rules: actor names become a JavaScript class binding and the WebSocket connect handler — they must match [A-Za-z_][A-Za-z0-9_]* (max 128 chars, no /, -, . or :), must not be a JS reserved word, must not collide with a backend function name, and cannot be nested in subfolders. The CLI checks all of this locally before uploading; a folder with a dot in its name is skipped instead (so ChatRoom.bak/ is safe scratch space).
ChatRoom, BoardRoom, Lobbychat-room, games/Arena, classRequired: entry.ts (or entry.js) that default-exports a class extending Actor from base44:runtime/actors. In TypeScript, also declare handleTick() {} — it is an abstract member of Actor.
Differs from functions: only the actor's own folder is uploaded (no base44/shared/), no --force prune, no list/pull commands, no local base44 dev runtime, names cannot be path-like, and aut
Weekly roundup of top Claude Code skills, MCP servers, and AI coding tips.