Skip to content

DocsApps

The developer CLI and SDK

Updated Sep 15, 2026

Everything you can do by hand in the App Store, the Agents app, and Sites, you can also do from your own terminal with the nextos command-line tool, or from your own code with the companion SDK package. Both talk to the same public API your account already uses - there is no separate developer surface to learn.

Installing

You don't need to install anything up front - run it with npx:

npx @kumin-consulting/nextos --help

If you'll use it often, install it globally so the nextos command is always available:

npm install -g @kumin-consulting/nextos

Signing in

Create a gateway key from Settings > Developer, then sign in once:

nextos login

You'll be prompted to paste the key. It's saved to a local config file in your home directory and reused by every other command - nothing is sent anywhere except this product's own API. Run nextos login --key <your key> to skip the prompt (handy in a script or a CI job), or nextos whoami any time to confirm which account a saved key belongs to.

Scaffolding an app

nextos init app my-todo-list

This writes a new folder with a working starter app - the same starter templates the in-app assistant uses when you ask it to build you an app. Pass --template to choose a different starting point:

  • static - a single HTML file, no build step. The default.
  • vite-react - a real React app built with Vite.
  • native-react - a component that runs inside the operating system's own process, with the same access as a built-in app (this one needs an explicit approval step when installed).
  • hosted-next - a real Next.js app with its own dev server, for anything that needs server-side rendering or API routes.

nextos init agent <name> scaffolds a starter agent configuration (a name, a system prompt, a model, and a starting tool list) as a plain JSON file you can edit by hand and later import from the Agents app. nextos init department <name> --department <engineering|marketing|sales|support> does the same for a Company department's configuration.

Developing with live reload

cd my-todo-list
nextos dev

This watches your app's files and pushes every change straight to your own account, the same filesystem your signed-in browser tab already syncs against - so an already-open window in your Home Screen or Field picks up the edit and reloads itself automatically, the same way it would if you'd edited the file by hand from inside the operating system. Open the app once (from the App Store's Installed tab, or by asking the assistant to open it) and leave this command running while you work.

Testing and publishing

nextos test

Runs the same manifest and build checks the App Store itself runs before letting you install something, so a mistake shows up in your terminal instead of as a confusing error later.

nextos publish

Zips your app and publishes it to your own personal catalogue - a shareable link anyone can add as a Source in their App Store (Settings > Apps > Sources, or the Sources tab inside the App Store app) to install straight from you. Publishing again with a new version number updates the same catalogue entry in place.

Agents, sites, and data from the command line

nextos agents run <agent-id> "Summarize this week's activity"
nextos sites publish <your-site-slug>
nextos db query <table-name>

agents run starts a background run of one of your synced agents and prints the result (add --wait to block until it finishes, or leave it out to get a run id back immediately and poll it). sites publish publishes your current site files as a new version, the same as clicking Publish in the Site Editor. db query reads rows from one of a site's live tables - the same data the Database app shows - so you can pull them into a script or another tool.

The SDK

If you're writing your own tooling rather than using the command line directly, @kumin-consulting/nextos-sdk is a small, typed client for the same API the CLI itself uses:

import { NextOS } from '@kumin-consulting/nextos-sdk';

const client = new NextOS({ apiKey: myGatewayKey });

const { agents } = await client.agents.list();
const run = await client.agents.run('daily-digest', 'What changed today?');
const site = await client.sites.publish('my-site', files);

Every method maps to one documented API call, and every response is the same JSON shape you'd get calling the API directly - the SDK just saves you writing the request headers and error handling by hand.