@swell/cli
Version:
Swell's command line interface/utility
1,638 lines • 58.3 kB
JSON
{
"commands": {
"env": {
"aliases": [],
"args": {
"name": {
"description": "name of the environment (production, staging, local, review)",
"name": "name"
},
"reviewBranch": {
"description": "name of a review branch",
"name": "reviewBranch"
}
},
"description": "Internal: Display the current environment configuration.",
"examples": [
"<%= config.bin %> <%= command.id %>"
],
"flags": {},
"hasDynamicHelp": false,
"hidden": true,
"hiddenAliases": [],
"id": "env",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"env.js"
]
},
"login": {
"aliases": [],
"args": {},
"description": "\nIf you are not already logged in, this command will open your browser to the\nSwell Admin login page, otherwise it will show you the stores you still\nhave available for logging in to.\n",
"examples": [
"<%= config.bin %> <%= command.id %>"
],
"flags": {
"force": {
"char": "f",
"description": "show all available stores and switch the current session if needed",
"name": "force",
"allowNo": false,
"type": "boolean"
},
"store": {
"char": "s",
"description": "store to login to",
"name": "store",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "login",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Login to your Swell user account.",
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"login.js"
]
},
"logout": {
"aliases": [],
"args": {},
"description": "Log out of all stores available in your current session.",
"examples": [
"<%= config.bin %> <%= command.id %>"
],
"flags": {
"local": {
"description": "clear local authentication data",
"name": "local",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "logout",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"logout.js"
]
},
"logs": {
"aliases": [],
"args": {},
"examples": [
"swell logs",
"swell logs -f -p -n 10 -c date,req,data",
"swell logs -s accounts",
"swell logs --after 2023-08-25T16:01:02.697Z -c date",
"swell logs --after 2023-08-27"
],
"flags": {
"after": {
"description": "expected is Javascript Date Time String Format: YYYY-MM-DDTHH:mm:ss.sssZ",
"name": "after",
"summary": "show logs created on or after this date/time (utc)",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"app": {
"description": "filter logs by app id",
"name": "app",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"before": {
"description": "expected is Javascript Date Time String Format: YYYY-MM-DDTHH:mm:ss.sssZ",
"name": "before",
"summary": "show logs created on or before this date/time (utc)",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"columns": {
"char": "c",
"description": "available columns: app, data, date, env, ip, request, req, status, time, type",
"name": "columns",
"summary": "comma separated list of columns to display",
"default": "date,request,data,status,time",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"env": {
"description": "filter logs by environment id",
"name": "env",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"follow": {
"char": "f",
"description": "stream logs in real time",
"exclusive": [
"before"
],
"name": "follow",
"allowNo": false,
"type": "boolean"
},
"number": {
"char": "n",
"description": "number of log lines to return",
"name": "number",
"default": 100,
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"output": {
"char": "o",
"description": "how to display the logs",
"name": "output",
"default": "line",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"table",
"line"
],
"type": "option"
},
"pretty": {
"char": "p",
"description": "note that this flag will take more space in the terminal and require more time to load",
"name": "pretty",
"summary": "pretty print json data",
"allowNo": false,
"type": "boolean"
},
"search": {
"char": "s",
"description": "search logs by keyword",
"name": "search",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"status": {
"description": "filter logs by request status",
"name": "status",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"type": {
"description": "filter logs by type",
"name": "type",
"hasDynamicHelp": false,
"multiple": true,
"options": [
"api",
"function",
"webhook"
],
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "logs",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Output or stream store logs to the terminal.",
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"logs.js"
]
},
"switch": {
"aliases": [],
"args": {
"store-id": {
"description": "store id you want to switch to",
"name": "store-id"
}
},
"description": "\nIf you have access to more than one store, this command will\ndefine the store that all other commands will apply to by default.\n",
"examples": [
"<%= config.bin %> <%= command.id %>",
"<%= config.bin %> <%= command.id %> <store-id>"
],
"flags": {},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "switch",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Switch your default current store.",
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"switch.js"
]
},
"whoami": {
"aliases": [],
"args": {},
"description": "Display the current logged-in user and available stores.",
"examples": [
"<%= config.bin %> <%= command.id %>"
],
"flags": {},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "whoami",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"whoami.js"
]
},
"app:_uninstall": {
"aliases": [],
"args": {},
"description": "Uninstalls an existing App",
"examples": [
"<%= config.bin %> <%= command.id %>"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"env": {
"description": "environment to uninstall the app from",
"name": "env",
"default": "test",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"store": {
"char": "s",
"description": "store id to uninstall the app from",
"name": "store",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:_uninstall",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"delayOrientation": false,
"orientation": {
"env": "test"
},
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"_uninstall.js"
]
},
"app:dev": {
"aliases": [],
"args": {},
"examples": [
"swell app dev",
"swell app dev --storefront-id <id>",
"swell app dev --port 3000"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"no-push": {
"description": "skip pushing app files initially",
"name": "no-push",
"allowNo": false,
"type": "boolean"
},
"port": {
"char": "p",
"description": "override the default port to run the app locally",
"name": "port",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"storefront-id": {
"description": "for storefront apps, identify a storefront to preview and push theme files to",
"name": "storefront-id",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"storefront-select": {
"description": "for storefront apps, prompt to select a storefront to preview",
"name": "storefront-select",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:dev",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Run an app in dev mode from your local machine.",
"delayOrientation": true,
"orientation": {
"env": "test"
},
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"dev.js"
]
},
"app:info": {
"aliases": [],
"args": {
"versions": {
"description": "list all app versions",
"name": "versions"
}
},
"description": "The command shows the latest information about your app including the name,\ndescription, version, public ID, test store, and more. If the versions argument is passed,\nit will output all versions of the app instead.",
"examples": [
{
"command": "swell app info",
"description": "Show general information about the app."
},
{
"command": "swell app info versions",
"description": "Show all established versions of the app."
}
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:info",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Show information about your Swell app.",
"enableJsonFlag": false,
"delayOrientation": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"info.js"
]
},
"app:init": {
"aliases": [],
"args": {
"id": {
"default": "",
"description": "id of the app to create",
"name": "id"
}
},
"description": "Initialize app swell.json in the current directory.",
"examples": [
{
"command": "swell app init",
"description": "Initialize app following command prompts."
},
{
"command": "swell app init -y",
"description": "Initialize app and accept all default values."
}
],
"flags": {
"frontend": {
"description": "create a starter framework for a hosted frontend",
"name": "frontend",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"nextjs",
"astro"
],
"type": "option"
},
"storefront-app": {
"description": "id of an installed storefront app to create a theme for, if applicable",
"name": "storefront-app",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"yes": {
"char": "y",
"description": "accept all default values",
"name": "yes",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:init",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"init.js"
]
},
"app:install": {
"aliases": [],
"args": {},
"description": "Without a version specified, install the latest version of the app.\n\nWithout a store specified, install the app in the Live environment of the current store.",
"examples": [
"swell app install",
"swell app install -v 3.2.7",
"swell app install -v 1.0.0 -s my-store-id"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"env": {
"char": "e",
"description": "target environment to install the app, defaults to live",
"name": "env",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"store": {
"char": "s",
"description": "target store id to install the app, defaults to the current store",
"name": "store",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"version": {
"char": "v",
"description": "version of the app to install, defaults to latest",
"name": "version",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:install",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Install an existing app in another store environment.",
"enableJsonFlag": false,
"delayOrientation": false,
"orientation": {
"env": "test"
},
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"install.js"
]
},
"app:pull": {
"aliases": [],
"args": {
"appId": {
"default": "",
"description": "app id to pull",
"name": "appId"
},
"targetPath": {
"default": "",
"description": "path to download app files into",
"name": "targetPath"
}
},
"description": "Pull all app files, a specific file, or a specific configuration\ntype from an app in your store's test environment to your local machine.\n\nIf APPID is not specified, you will be prompted with a list of apps to choose from.\n\nApp file directories:\nassets/\ncontent/\nfrontend/\nfunctions/\nmodels/\nnotifications/\nsettings/\ntheme/\nwebhooks/\nfrontend/",
"examples": [
"swell app pull",
"swell app pull example_app",
"swell app pull example_app example-folder",
"swell app pull --force"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"force": {
"description": "force pull all files",
"name": "force",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:pull",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Pull app files from Swell to your local machine.",
"orientation": {
"env": "test"
},
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"pull.js"
]
},
"app:push": {
"aliases": [],
"args": {
"file": {
"description": "relative path to a configuration file or directory to push",
"name": "file"
}
},
"description": "Push all app files, a specific file, or a specific configuration\ntype to an app in your store's test environment.\n\nIf the app does not exist, it will be created and its global ID saved to a .swellrc file.\n\n- If no file is specified, all configuration files will be pushed to the store.\n This includes the app icon (assets/icon.png) and swell.json.\n- If a file is specified, only that file will be pushed to the store.\n- If a directory is specified, only files in that directory will be pushed.\n\nApp file directories:\nassets/\ncontent/\nfrontend/\nfunctions/\nmodels/\nnotifications/\nsettings/\ntheme/\nwebhooks/",
"examples": [
"swell app push",
"swell app push content",
"swell app push models/products.json"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"force": {
"description": "force push all configurations",
"name": "force",
"allowNo": false,
"type": "boolean"
},
"no-deploy": {
"description": "skip deploying app frontend",
"name": "no-deploy",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:push",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Push local files to your Swell app.",
"delayOrientation": true,
"orientation": {
"env": "test"
},
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"push.js"
]
},
"app:release": {
"aliases": [],
"args": {
"version": {
"description": "semver version to release",
"name": "version"
}
},
"description": "App released are reviewed by the Swell team for quality and functionality before publishing.\n\nIf the version does not exist, you will be prompted to create it.\n\nUse the --amend flag to update the description or release notes of an existing release version.\n\nUse the --supported=false flag to indicate the version is not officially supported by the developer.\n \nThe app must be connected to a partner account with access to publish.",
"examples": [
"swell app release",
"swell app release 2.0.0",
"swell app release 2.0.0 --amend --release-notes ./releases/v2.0.0.md",
"swell app release 2.0.0 -y"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"amend": {
"description": "amend the description or release notes of an existing release",
"name": "amend",
"allowNo": false,
"type": "boolean"
},
"message": {
"char": "m",
"description": "description of the changes in this version for internal use",
"name": "message",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"no-git-tag": {
"description": "if the version is being created, do not create a git tag",
"name": "no-git-tag",
"allowNo": false,
"type": "boolean"
},
"not-supported": {
"description": "indicates the version is not officially supported by the developer",
"name": "not-supported",
"allowNo": false,
"type": "boolean"
},
"release-notes": {
"description": "relative path to a file containing release notes",
"name": "release-notes",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"yes": {
"char": "y",
"description": "skip confirmation prompt",
"name": "yes",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:release",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Release a new version of your an app for publishing to the App Store.",
"orientation": {
"env": "test"
},
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"release.js"
]
},
"app:version": {
"aliases": [],
"args": {
"nextVersion": {
"description": "semver version or release type: <next.version>|major|premajor|minor|preminor|patch|prepatch|prerelease",
"name": "nextVersion"
}
},
"description": "When executed without specifying NEXTVERSION, the command will display the current\nversion of your app.\n\nIf a NEXTVERSION is provided, the command will validate and compute the version\naccording to Semver rules by only allowing incremental updates.\n\nThe version change will be committed to the Git repository using the provided\nmessage or a default similar to the tag, e.g. \"v1.0.1\".\n\nBy default, it creates a Git tag for the specified version. You can disable this\nbehavior by using the --no-git-tag option.",
"examples": [
"swell app version",
"swell app version minor",
"swell app version 1.0.0 -m \"First release\"",
"swell app version patch -y"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"amend": {
"description": "amend the description an existing version",
"name": "amend",
"allowNo": false,
"type": "boolean"
},
"message": {
"char": "m",
"description": "description of the changes in this version for internal use",
"name": "message",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"no-git-tag": {
"description": "do not create a git tag for this version",
"name": "no-git-tag",
"allowNo": false,
"type": "boolean"
},
"yes": {
"char": "y",
"description": "skip confirmation prompt",
"name": "yes",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:version",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Increment the version of your Swell app.",
"orientation": {
"env": "test"
},
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"version.js"
]
},
"app:watch": {
"aliases": [],
"args": {},
"description": "Watches configuration files including functions, and automatically pushes\nto the remote store.\n\nOptionally synchronize all configs on change.",
"examples": [
"swell app watch",
"swell app watch -a",
"swell app watch --sync-all"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"sync-all": {
"char": "a",
"description": "synchronize all app configurations on file change",
"name": "sync-all",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "app:watch",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Watch for changes and push app configurations.",
"orientation": {
"env": "test"
},
"isESM": true,
"relativePath": [
"dist",
"commands",
"app",
"watch.js"
]
},
"create:app": {
"aliases": [],
"args": {
"id": {
"default": "",
"description": "id of the app to create",
"name": "id"
}
},
"description": "Create an app.",
"examples": [
{
"command": "swell create app",
"description": "Create app following command prompts."
},
{
"command": "swell create app my_app -y",
"description": "Create app and accept all default values."
},
{
"command": "swell create app -p yarn",
"description": "Create app with yarn package manager instead of npm by default."
},
{
"command": "swell create app -p none",
"description": "Create app without installing TypeScript bindings, etc."
}
],
"flags": {
"frontend": {
"description": "create a starter framework for a hosted frontend",
"name": "frontend",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"nextjs",
"astro"
],
"type": "option"
},
"storefront-app": {
"description": "id of an installed storefront app to create a theme for, if applicable",
"name": "storefront-app",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"yes": {
"char": "y",
"description": "accept all default values",
"name": "yes",
"allowNo": false,
"type": "boolean"
},
"pkg": {
"char": "p",
"description": "use npm or yarn to install default dependencies, or none to disable",
"name": "pkg",
"default": "npm",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"npm",
"yarn",
"none"
],
"type": "option"
},
"type": {
"char": "t",
"description": "create a specific app type",
"name": "type",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"admin",
"integration",
"storefront",
"theme"
],
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "create:app",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"create",
"app.js"
]
},
"create:content": {
"aliases": [],
"args": {
"collection": {
"default": "",
"description": "collection to create or apply to, i.e. products",
"name": "collection"
}
},
"description": "This command assists in generating UI model configuration files. CLI will prompt for values when flags are not present.",
"examples": [
{
"command": "swell create content",
"description": "Create content model interactively."
},
{
"command": "swell create content visitors -v list,edit,new",
"description": "Specify views delimited by semicolons."
},
{
"command": "swell create content visitors -f name:short_text,description:long_text,verified:boolean,visitor_count:integer,photo:image,orders:collection",
"description": "Specify fields with types delimited by semicolons"
},
{
"command": "swell create content visitors -o -f verified:short_text -v list,edit,new -d \"Visitor Views\"",
"description": "Specify fields, views, and description."
}
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"description": {
"char": "d",
"description": "content model description",
"name": "description",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"fields": {
"char": "f",
"description": "list of content model fields delimited by commas",
"name": "fields",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"label": {
"char": "l",
"description": "content model label",
"name": "label",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"overwrite": {
"description": "overwrite existing content model configuration file",
"name": "overwrite",
"allowNo": false,
"type": "boolean"
},
"views": {
"char": "v",
"description": "list of content model views delimited by commas, i.e. list,edit,new",
"name": "views",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "create:content",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"summary": "Initialize a content UI model config file with properties in the content folder.",
"isESM": true,
"relativePath": [
"dist",
"commands",
"create",
"content.js"
]
},
"create:frontend": {
"aliases": [],
"args": {},
"description": "Initialize a frontend app framework and folder structure.",
"examples": [
{
"command": "swell create frontend",
"description": "Create frontend app following command prompts."
},
{
"command": "swell create frontend -y",
"description": "Create frontend app and accept all default values."
}
],
"flags": {
"frontend": {
"description": "create a starter framework for a hosted frontend",
"name": "frontend",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"nextjs",
"astro"
],
"type": "option"
},
"storefront-app": {
"description": "id of an installed storefront app to create a theme for, if applicable",
"name": "storefront-app",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"yes": {
"char": "y",
"description": "accept all default values",
"name": "yes",
"allowNo": false,
"type": "boolean"
},
"pkg": {
"char": "p",
"description": "use npm or yarn to install default dependencies, or none to disable",
"name": "pkg",
"default": "npm",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"npm",
"yarn",
"none"
],
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "create:frontend",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"create",
"frontend.js"
]
},
"create:function": {
"aliases": [],
"args": {
"functionName": {
"description": "function name, used in an http route if applicable",
"name": "functionName"
},
"trigger": {
"description": "function trigger type",
"name": "trigger",
"options": [
"cron",
"model",
"route"
]
}
},
"description": "This command assists in generating functions scripts. CLI will prompt for values when flags are not present.",
"examples": [
{
"command": "swell create function",
"description": "Create function script interactively."
},
{
"command": "swell create function orders-subscriptions-created.ts model --events order.created,subscription.created",
"description": "Specify model event trigger of the function."
},
{
"command": "swell create function get-frontend-data.ts route --route public",
"description": "Specify public API access."
},
{
"command": "swell create function process-metrics.ts cron --schedule \"0 0 * * *\"",
"description": "Specify schedule of the cron function."
}
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"description": {
"char": "d",
"description": "function description",
"name": "description",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"events": {
"char": "e",
"description": "list of data model events used with model trigger, delimited by commas",
"name": "events",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"overwrite": {
"description": "overwrite existing function file",
"name": "overwrite",
"allowNo": false,
"type": "boolean"
},
"route": {
"char": "r",
"description": "access type used with route trigger",
"name": "route",
"default": "public",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"public",
"private"
],
"type": "option"
},
"schedule": {
"char": "s",
"description": "crontab value used with cron trigger",
"name": "schedule",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "create:function",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Initialize a functions script in JavaScript or TypeScript.",
"isESM": true,
"relativePath": [
"dist",
"commands",
"create",
"function.js"
]
},
"create": {
"aliases": [],
"args": {},
"description": "Scaffold apps, models, functions, and notifications.",
"examples": [
"<%= config.bin %> <%= command.id %>"
],
"flags": {},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "create",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"create",
"index.js"
]
},
"create:model": {
"aliases": [],
"args": {
"collection": {
"default": "",
"description": "collection to create or apply to, i.e. products",
"name": "collection"
}
},
"description": "This command assists in generating data model configuration files. CLI will prompt for values when flags are not present.",
"examples": [
{
"command": "swell create model",
"description": "Create data model configuration interactively."
},
{
"command": "swell create model visitors -e created,updated,deleted.",
"description": "Specify events of the data model."
},
{
"command": "swell create model visitors -f first_name:string,last_name:string,photo:file,visit_count:int,visits:link",
"description": "Specify fields of the data model."
},
{
"command": "swell create model visitors -f first_name:string,last_name:string,photo:file,visit_count:int,visits:link -d \"Visitors Tracking\" -o -e created,updated,deleted",
"description": "Scaffold a data model configuration with args and flags."
}
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"description": {
"char": "d",
"description": "data model description",
"name": "description",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"events": {
"char": "e",
"description": "list of data model events delimited by commas",
"name": "events",
"default": "created,updated,deleted",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"fields": {
"char": "f",
"description": "list of data model fields delimited by commas",
"name": "fields",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"label": {
"char": "l",
"description": "data model label, i.e. Products",
"name": "label",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"overwrite": {
"description": "Overwrite existing data model configuration file.",
"name": "overwrite",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "create:model",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"summary": "Initialize a data model config file with properties in the models folder.",
"isESM": true,
"relativePath": [
"dist",
"commands",
"create",
"model.js"
]
},
"create:notification": {
"aliases": [],
"args": {
"model": {
"description": "data model to trigger the notification by",
"name": "model"
},
"name": {
"description": "internal name for the notification",
"name": "name"
}
},
"description": "This command assists in generating notifications configuration files. This CLI command will prompt for values when flags are not present.",
"examples": [
{
"command": "swell create notification",
"description": "Create notification configuration interactively."
},
{
"command": "swell create notification subscriptions confirmed --event subscription.created --once --s \"Your subscription has been confirmed\" -d \"Send a confirmation email when subscription is created\"",
"description": "Specify the model, name, event, subject, and description."
},
{
"command": "swell create notification orders paid --event paid\"",
"description": "Specify the event to trigger the notification."
}
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"admin": {
"char": "a",
"description": "indicate when the notification is sent to store admins only",
"name": "admin",
"allowNo": false,
"type": "boolean"
},
"description": {
"char": "d",
"description": "notification description",
"name": "description",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"event": {
"char": "e",
"description": "data model event to trigger the notification event, i.e. created",
"name": "event",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"once": {
"char": "o",
"description": "indicate the notification should be sent only once when conditions are met, instead of repeating",
"name": "once",
"allowNo": false,
"type": "boolean"
},
"overwrite": {
"description": "overwrite existing notification configuration file",
"name": "overwrite",
"allowNo": false,
"type": "boolean"
},
"subject": {
"char": "s",
"description": "notification email subject",
"name": "subject",
"default": "",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "create:notification",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Initialize notification files and configuration with properties in the notifications folder.",
"isESM": true,
"relativePath": [
"dist",
"commands",
"create",
"notification.js"
]
},
"theme:dev": {
"aliases": [],
"args": {},
"examples": [
"swell theme dev",
"swell theme dev --local",
"swell theme dev --bundle",
"swell theme dev --storefront-select",
"swell theme dev --storefront-id <id>"
],
"flags": {
"app-path": {
"description": "path to your app directory",
"name": "app-path",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"bundle": {
"description": "bundle assets",
"name": "bundle",
"allowNo": false,
"type": "boolean"
},
"force": {
"description": "force push all configurations",
"name": "force",
"allowNo": false,
"type": "boolean"
},
"local": {
"description": "connect to a running local storefront app dev server",
"name": "local",
"allowNo": false,
"type": "boolean"
},
"no-push": {
"description": "skip pushing theme files initially",
"name": "no-push",
"allowNo": false,
"type": "boolean"
},
"storefront-id": {
"description": "identify a storefront to preview and push theme files to",
"name": "storefront-id",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"storefront-select": {
"description": "prompt to select a storefront to preview and push theme files to",
"name": "storefront-select",
"allowNo": false,
"type": "boolean"
},
"env": {
"char": "e",
"description": "target environment to push to, defaults to live",
"name": "env",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "theme:dev",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"summary": "Run a theme in dev mode from your local machine.",
"isESM": true,
"relativePath": [
"dist",
"commands",
"theme",
"dev.js"
]
},
"theme:init": {
"aliases": [],
"args": {
"id": {
"default": "",
"description": "id of the app to create",
"name": "id"
}
},
"description": "Initialize theme swell.json in the current directory.",
"examples": [
{
"command": "swell theme init",
"description": "Initialize theme following command prompts."
},
{
"command": "swell theme init -y",
"description": "Initialize theme and accept all default values."
}
],
"flags": {
"frontend": {
"description": "create a starter framework for a hosted frontend",
"name": "frontend",
"hasDynamicHelp": false,
"multiple": false,
"options": [
"nextjs",
"astro"
],
"type": "option"
},
"storefront-app": {
"description": "id of an installed storefront app to create a theme for, if applicable",
"name": "storefront-app",
"hasDynamicHelp": false,
"multiple": false,
"type": "option"
},
"yes": {
"char": "y",
"description": "accept all default values",
"name": "yes",
"allowNo": false,
"type": "boolean"
}
},
"hasDynamicHelp": false,
"hiddenAliases": [],
"id": "theme:init",
"pluginAlias": "@swell/cli",
"pluginName": "@swell/cli",
"pluginType": "core",
"strict": true,
"enableJsonFlag": false,
"isESM": true,
"relativePath": [
"dist",
"commands",
"theme",
"init.js"
]
},
"theme:pull": {
"aliases": [],
"args": {
"appId": {
"default": "",
"description": "theme app id to pull",
"name": "appId"
},
"targetPath": {
"default": "",
"description": "path to download theme files into",
"name": "targetPath"
}
},
"description": "Pull all theme files, a specific file, or a specific configuration\ntype from a theme in your store's test environment to your local machine.\n\nIf APPID is not specified, you will be prompted with a list of themes to choose from.\n\nTheme file directories:\nassets/\ntheme/",
"examples": [
"swell theme pull",
"swell theme pull mytheme",
"swell theme pull m