greatstore
v0.2.3
Published
CLI for administering GreatStore stores and authoring custom components.
Readme
@greatstore/cli
Administer your GreatStore from the command line — store configuration, MCP connectors, and custom in-chat apps — and set up your AI coding agent to build with GreatStore.
npm install -g @greatstore/cli
gs skill # print how to set up your AI coding agent
gs login
gs configure # see your store's configuration
gs apps init --store <slug>
cd <project> && npm install
gs apps init my-widget
gs apps build
gs apps push
gs apps publish my-widgetThe CLI mirrors the admin dashboard: gs configure, gs connectors,
and gs apps correspond to the Configure, Connectors, and Apps panels,
with the same field names and behaviour.
Commands
Account
| Command | What it does |
| ----------- | --------------------------------------- |
| gs login | Sign in. |
| gs logout | Sign out. |
| gs whoami | Print the identity you're signed in as. |
Configure
| Command | What it does |
| ---------------------------------------- | ---------------------------------------------------------- |
| gs configure [--json] | Show the store configuration. |
| gs configure set --<field> <value> | Edit it. Same fields as the dashboard: --displayName, --assistantName, --storeLink, --extraOrigins a,b, --theme '<json>' (or --themeFile <path>), --cspScriptHosts a,b, --cspConnectHosts a,b. Pass "" to clear a field. |
| gs configure upload <kind> <file> | Upload icon, logoLight, or logoDark (.png/.jpg/.webp). |
| gs configure clear <kind> | Remove an uploaded asset. |
Connectors
| Command | What it does |
| ------------------------------------------------------------ | ------------------------------------------------------ |
| gs connectors [--json] | List the Maker MCP toggle and custom MCP connectors. |
| gs connectors add <name> --url <url> [--token <t>] [--profileUrl <u>] [--disabled] [--force] | Add a connector. It's probed for tool discovery first; --force saves it anyway. |
| gs connectors remove <name\|id> | Delete a connector. |
| gs connectors enable\|disable <name\|id> | Toggle a connector without deleting it. |
| gs connectors maker on\|off | Toggle the Maker MCP. |
| gs connectors health [<name\|id>] [--json] | Live-probe saved connectors. |
Apps
Custom in-chat app (remote component) commands. Each also works at the
top level (gs push == gs apps push), so existing scripts keep
working.
| Command | What it does |
| ------------------------------------------------------ | -------------------------------------------------- |
| gs apps init <name> [--out <dir>] [--store <s>] | Scaffold a working component project. |
| gs apps build [<name>] | Check and build component bundle(s); no args = all. |
| gs apps list [--json] | List components in the current store. |
| gs apps pull <name> [--draft\|--live\|--version N] [-o <dir>] | Download a component to disk. |
| gs apps push [<name>] [--manifest path] [--bundle path] | Upload local changes. |
| gs apps publish <name> [--version N] | Ship a component (optionally a previous version). |
| gs apps unpublish <name> | Hide a published component. |
| gs apps rename <old> <new> | Rename a component, keeping its versions and live state. |
| gs apps delete <name> [--yes] | Remove the component. |
Component checks
gs apps build and gs apps push check each component before they do
their work, and report what they find as either:
- error — a blocker. The component isn't built or uploaded until it's fixed.
- warning — the component builds and is ready to publish, but something is worth improving.
The checks cover the manifest (valid JSON, a name matching the folder,
an inputSchema simple enough for the agent to fill reliably) and
the component's props: every prop it declares should be a field in
inputSchema.properties, apart from the props GreatStore injects
(onSendMessage, onUpdateModelContext, onShowLightbox,
onClose, storeData, Image). A prop nothing
declares is a warning — nothing will ever pass it. A schema field the
component doesn't accept is an error. A component still declaring
onError gets a warning pointing at async components, which replaced it.
Agent skill
| Command | What it does |
| ---------- | ---------------------------------------------------------------- |
| gs skill | Print how to install the GreatStore agent skill, for the agent to follow. |
Agent skill
The GreatStore agent skill is a guide AI coding agents (Claude Code and friends) use to build with GreatStore: AI content for your own UI, chat entry points, page tools the agent can call, custom in-chat components, push notifications, and the store's MCP endpoints.
gs skill prints the steps to install it, addressed to the agent that
ran it — the agent knows its own skills directory, so it can set the
skill up there without the CLI guessing. Ask your agent to run
gs skill and follow what it prints; no sign-in or store needed.
The install is a link to a copy the CLI keeps in ~/.greatstore/skill/,
which any newer version of the CLI refreshes when it runs, so the skill
stays current with nothing to re-run.
Store selection
Every command except login, logout, whoami, and skill needs a
store.
- App commands read the slug from a
.gsrcin the current directory or any ancestor:{"store":"demo"}.gs apps init --store <slug>writes it for you, so commands inside a scaffolded project don't need a flag. - Admin commands (
configure,connectors) also accept--store <slug>directly, so they work outside a scaffolded project.
