Index of every page on this site: llms.txt
All skills
base44 avatar

/base44-cli

@5bb6707
by base44base44/skills94 stars
21
Run it yourself

The base44 CLI is used for EVERYTHING related to base44 projects: resource configuration (entities, backend functions, realtime actors, ai agents), initialization and actions (resource creation, deployment), and any other operation on an existing app or workspace through the Base44 public API (settings, domains, users, members, source export). This skill is the place for learning about how to configure resources, including actors — the realtime/WebSocket primitive behind multiplayer, collaborative boards, presence and live cursors, in-room chat, and live auctions. When you plan or implement a feature, you must learn this skill

Use this Skill: https://skilld.dev/gh/base44/skills/base44-cli

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

referencesexec.md

≈1k tokens on demand. Your agent reads this file only when SKILL.md points to it.

base44 exec

Run a script with the Base44 SDK pre-authenticated as the current user. Reads the script from stdin.

Syntax

cat ./script.ts | npx base44 exec [options]
echo "<code>" | npx base44 exec [options]

Options

Option Description Required Default
--local Run against the local base44 dev server instead of the deployed app No false
--port <number> Port the local dev server is on. Only valid with --local No 4400
--privileged Run with admin privileges (bypass RLS). Requires app owner/editor role No false
--data-env <environment> Data environment to run against (e.g. dev, prod) No -

How It Works

The exec command reads a script from stdin and runs it server-side with the Base44 SDK pre-authenticated as the currently logged-in user. This allows you to run one-off scripts against your app's data without writing a full function.

By default the script runs against your deployed app. Pass --local to run it against a base44 dev server running on your machine instead — useful for testing scripts before they touch production data.

Available Globals

base44 — a preinitialized SDK client, available as a global variable in every exec script. You do not need to import or configure it — it is ready to use immediately.

Use it to interact with your app's resources:

  • base44.entities.<EntityName> — CRUD operations on entities (.list(), .get(id), .create(data), .update(id, data), .delete(id))
  • base44.functions.invoke(name, data?) — call a backend function
  • base44.agents.<AgentName> — invoke AI agents
  • For more available resources and methods, see the Base44 SDK reference

Examples

# Run a script file
cat ./script.ts | npx base44 exec

# Inline script
echo "const users = await base44.entities.User.list(); console.log(users)" | npx base44 exec

# Run against a specific app without a local project checkout
cat ./script.ts | npx base44 exec --app-id app_123

# Or resolve the app from the environment
BASE44_APP_ID=app_123 npx base44 exec < ./script.ts

# Against the local dev server (base44 dev must already be running)
echo "await base44.entities.Task.create({ title: 'seed' })" | npx base44 exec --local

# Against a local dev server on a non-default port
echo "..." | npx base44 exec --local --port 4500

# With privileged access (bypass RLS)
echo "const all = await base44.entities.Task.list()" | npx base44 exec --privileged

# Against a specific data environment
echo "..." | npx base44 exec --data-env prod

Requirements

  • Must be authenticated (npx base44 login)
  • Must run in one of these contexts:
    • from a linked Base44 project directory, or
    • with --app-id <id>, or
    • with BASE44_APP_ID set
  • Script must be piped via stdin (non-interactive mode)
  • --port requires --local to also be set

Running Against the Local Dev Server

--local targets a base44 dev server already running on your machine instead of the deployed app:

  • The SDK authenticates as your current user via a locally-minted token — the dev server decodes it and seeds your user as an admin, so this matches your local session
  • Defaults to port 4400 (the same default base44 dev binds to); pass --port if you started base44 dev on a different port
  • base44 dev must already be running in another terminal — exec --local does not start it for you

Notes

  • The script runs with the Base44 SDK pre-authenticated — you can use base44.entities, base44.functions, etc. directly
  • --app-id is useful when you want to inspect app data without switching into a linked local project
  • --privileged bypasses row-level security (RLS); requires the app owner or editor role
  • Exit code from the script is forwarded as the CLI process exit code
  • This command requires stdin to be piped (it does not accept input in interactive TTY mode)

Source: SKILL.md on GitHub

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

1 warning20d5 checks · Risk SAFE
  • Gen Agent Trust Hub21d

    The skill provides a comprehensive interface for managing Base44 projects using the base44 CLI tool. It includes detailed instructions for project initialization, resource configuration (entities, functions, actors, agents, connectors), authentication, and deployment. All identified behaviors are consistent with the tool's intended role as a developer utility and utilize vendor-controlled resources.

  • Socket20d

    No alerts

  • Snyk21d

    Risk: LOW · No issues

  • Runlayer8mo

    5/27 files flagged

  • ZeroLeaks7mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at 5bb6707. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 3 weeks ago
metadata
{
  "sourcePackage": {
    "name": "base44",
    "version": "0.1.7"
  }
}
  • CLI
  • TypeScript
  • base44
  • project-management
  • deployment
  • entities
  • authentication
  • backend-functions
  • nodejs

README badge

README badge for base44/skills/base44-cli

Manage Base44 projects using the Base44 CLI tool via npm (npx base44). Covers project creation, authentication, entity schema configuration, deployment, and resource management for Base44 apps that combine frontend code with a base44/ configuration directory.

Generated from the current SKILL.md.

Should I use base44-cli or base44-sdk for my task?
Use base44-cli if you are creating a new project, initializing a project, deploying, or running CLI commands like `npx base44 login`. Use base44-sdk if you already have a `base44/config.jsonc` file and are building features or writing code in an existing project.
Do I need to install base44 globally or can I use npx?
Install base44 as a dev dependency (`npm install --save-dev base44`) and access it via `npx base44 <command>`. Never call `base44` directly or install it globally.
What should I do if I have an existing Base44 app that was provisioned externally?
Run `npx base44 scaffold` to set up local files for that existing app. Do not run `npx base44 create`, which would create a duplicate app.
What is the mandatory authentication check I need to perform?
At the start of each session, run `npx base44 whoami` to check if you are authenticated. If the command fails, run `npx base44 login` and wait for confirmation before proceeding with other CLI operations.
What goes in base44/config.jsonc?
The project name (required), description, directory paths for entities, functions, agents, and connectors, and optional site configuration including build command, install command, serve command, and output directory.

Generated from the current SKILL.md. These answers refresh after source changes.