UNPKG

@swell/cli

Version:

Swell's command line interface/utility

1,659 lines (1,658 loc) 86.8 kB
{ "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" ] }, "schema": { "aliases": [], "args": { "type": { "description": "Schema type (e.g. model, content, setting, notification, webhook, function)", "name": "type", "required": false }, "file": { "description": "Path to file to validate (or use \"-\" for stdin)", "name": "file", "required": false } }, "examples": [ { "description": "List available schema types", "command": "<%= config.bin %> <%= command.id %>" }, { "description": "Output JSON Schema", "command": "<%= config.bin %> <%= command.id %> content --format=json-schema" }, { "description": "Output bundled JSON Schema (all $refs resolved)", "command": "<%= config.bin %> <%= command.id %> content --format=json-schema-bundle" }, { "description": "Output TypeScript declarations", "command": "<%= config.bin %> <%= command.id %> content --format=dts" }, { "description": "Validate a JSON config file", "command": "<%= config.bin %> <%= command.id %> content myfile.json" }, { "description": "Validate from stdin", "command": "cat myfile.json | <%= config.bin %> <%= command.id %> content -" }, { "description": "Validate a function file", "command": "<%= config.bin %> <%= command.id %> function myfunction.ts" } ], "flags": { "format": { "description": "Output format: json-schema (with $ref pointers), json-schema-bundle (all $refs resolved), or dts (TypeScript declarations)", "name": "format", "hasDynamicHelp": false, "multiple": false, "options": [ "json-schema", "json-schema-bundle", "dts" ], "type": "option" }, "yes": { "char": "y", "description": "Skip informational output and print schema directly (equivalent to --format=json-schema).", "name": "yes", "allowNo": false, "type": "boolean" } }, "hasDynamicHelp": false, "hiddenAliases": [], "id": "schema", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "strict": true, "summary": "View or validate Swell config schemas.", "enableJsonFlag": false, "isESM": true, "relativePath": [ "dist", "commands", "schema.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" ] }, "api:delete": { "aliases": [], "args": { "path": { "description": "API endpoint path (must start with /)", "name": "path", "required": true } }, "description": "Remove existing resources from the Swell Backend API.", "examples": [ "swell api delete /products/abc123", "swell api delete /functions/my-app/clear-cache" ], "flags": { "live": { "description": "Use live environment instead of test", "name": "live", "allowNo": false, "type": "boolean" } }, "hasDynamicHelp": false, "hiddenAliases": [], "id": "api:delete", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "strict": true, "summary": "Send a DELETE request to the Swell API.", "isESM": true, "relativePath": [ "dist", "commands", "api", "delete.js" ] }, "api:get": { "aliases": [], "args": { "path": { "description": "API endpoint path (must start with /)", "name": "path", "required": true } }, "description": "Retrieve data from the Swell Backend API.\n The command performs a GET request to the specified endpoint path.", "examples": [ "swell api get /products", "swell api get \"/products?limit=10&category=shoes\"", "swell api get /products/abc123", "swell api get /functions/my-app/get-inventory" ], "flags": { "live": { "description": "Use live environment instead of test", "name": "live", "allowNo": false, "type": "boolean" } }, "hasDynamicHelp": false, "hiddenAliases": [], "id": "api:get", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "strict": true, "summary": "Send a GET request to the Swell API.", "isESM": true, "relativePath": [ "dist", "commands", "api", "get.js" ] }, "api": { "aliases": [], "args": {}, "description": "Run Swell API requests directly from the command line.\n Supports GET, POST, PUT, and DELETE methods with optional test/live environments.\n Call app functions via /functions/<app_id>/<function_name> paths.", "examples": [ "swell api get /products", "swell api post /products --body '{\"name\":\"New product\"}'", "swell api put /products/abc123 --body ./update.json", "swell api delete /products/abc123", "swell api get /functions/my-app/get-inventory", "swell api post /functions/my-app/create-order --body '{\"items\":[\"sku-1\"]}'" ], "flags": {}, "hasDynamicHelp": false, "hiddenAliases": [], "id": "api", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "strict": true, "summary": "Send requests directly to the Swell Backend API.", "enableJsonFlag": false, "isESM": true, "relativePath": [ "dist", "commands", "api", "index.js" ] }, "api:post": { "aliases": [], "args": { "path": { "description": "API endpoint path (must start with /)", "name": "path", "required": true } }, "description": "Create new resources in the Swell Backend API.\n You can provide a JSON body directly or specify a file path containing JSON data.", "examples": [ "swell api post /products --body '{\"name\": \"Product\", \"price\": 100}'", "swell api post /products --body ./product.json", "swell api post /functions/my-app/create-order --body '{\"items\":[\"sku-1\"]}'" ], "flags": { "body": { "description": "Request body (inline JSON or file path)", "name": "body", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "live": { "description": "Use live environment instead of test", "name": "live", "allowNo": false, "type": "boolean" } }, "hasDynamicHelp": false, "hiddenAliases": [], "id": "api:post", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "strict": true, "summary": "Send a POST request to the Swell API.", "isESM": true, "relativePath": [ "dist", "commands", "api", "post.js" ] }, "api:put": { "aliases": [], "args": { "path": { "description": "API endpoint path (must start with /)", "name": "path", "required": true } }, "description": "Update existing resources in the Swell Backend API.\n You can provide a JSON body directly or specify a file path containing JSON data.", "examples": [ "swell api put /products/{id} --body '{\"id\": \"abc123\", \"name\": \"Updated\"}'", "swell api put /products/abc123 --body ./product.json", "swell api put /functions/my-app/update-stock --body '{\"sku\":\"abc\",\"qty\":10}'" ], "flags": { "body": { "description": "Request body (inline JSON or file path)", "name": "body", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "live": { "description": "Use live environment instead of test", "name": "live", "allowNo": false, "type": "boolean" } }, "hasDynamicHelp": false, "hiddenAliases": [], "id": "api:put", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "strict": true, "summary": "Send a PUT request to the Swell API.", "isESM": true, "relativePath": [ "dist", "commands", "api", "put.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", "swell app dev --port 3000 --frontend-port 4000" ], "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" }, "frontend-port": { "description": "specify the port for the frontend dev server when running with frontend", "name": "frontend-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": "App identifier (defaults to current directory name)", "name": "id" } }, "description": "Initialize app swell.json in the current directory.", "examples": [ "$ swell app init", "$ swell app init my-app", "$ swell app init -t admin -y", "$ swell app init my-app -t admin -y", "$ swell app init my-app -t admin --frontend astro -y", "$ swell app init my_theme -t theme --storefront-app proxima -y" ], "flags": { "frontend": { "description": "Framework: astro | angular | hono | nuxt | nextjs | none", "name": "frontend", "hasDynamicHelp": false, "multiple": false, "options": [ "astro", "angular", "hono", "nuxt", "nextjs", "none" ], "type": "option" }, "storefront-app": { "description": "Target storefront app ID", "name": "storefront-app", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "integration-type": { "description": "Integration: generic | payment | shipping | tax", "name": "integration-type", "hasDynamicHelp": false, "multiple": false, "options": [ "generic", "payment", "shipping", "tax" ], "type": "option" }, "integration-id": { "description": "Service ID (e.g., card, fedex)", "name": "integration-id", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "yes": { "char": "y", "description": "Skip prompts, require all arguments", "name": "yes", "allowNo": false, "type": "boolean" }, "pkg": { "char": "p", "description": "Package manager: npm | yarn | none", "name": "pkg", "default": "npm", "hasDynamicHelp": false, "multiple": false, "options": [ "npm", "yarn", "none" ], "type": "option" }, "type": { "char": "t", "description": "App type: admin | storefront | theme | integration", "name": "type", "hasDynamicHelp": false, "multiple": false, "options": [ "admin", "integration", "storefront", "theme" ], "type": "option" }, "name": { "char": "n", "description": "Display name (default: capitalized ID)", "name": "name", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "version": { "char": "v", "description": "Version (default: 1.0.0)", "name": "version", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "description": { "char": "d", "description": "Description", "name": "description", "hasDynamicHelp": false, "multiple": false, "type": "option" } }, "hasDynamicHelp": false, "hiddenAliases": [], "id": "app:init", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "strict": true, "enableJsonFlag": false, "helpMeta": { "typeSection": { "title": "APP TYPES", "types": [ { "name": "admin", "description": "Dashboard extension", "optional": [ "--frontend" ] }, { "name": "storefront", "description": "Hosted storefront", "optional": [ "--frontend" ] }, { "name": "theme", "description": "Theme for existing storefront", "requires": [ "--storefront-app" ] }, { "name": "integration", "description": "Third-party service", "requires": [ "--integration-type", "--integration-id (for payment | shipping | tax)" ] } ] }, "typeFlags": [ "frontend", "storefront-app", "integration-type", "integration-id" ], "usageDirect": "[id] -t <type> [...] -y" }, "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" }, "force-create-files": { "description": "do not use files from previous versions", "name": "force-create-files", "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": "App identifier (e.g., my-app)", "name": "id" } }, "description": "Create an app.", "examples": [ "$ swell create app", "$ swell create app my_app -t admin -y", "$ swell create app my_app -t admin --frontend astro -y", "$ swell create app my_theme -t theme --storefront-app proxima -y", "$ swell create app my_payment -t integration --integration-type payment --integration-id card -y", "$ swell create app my_shipping -t integration --integration-type shipping --integration-id fedex -y" ], "flags": { "frontend": { "description": "Framework: astro | angular | hono | nuxt | nextjs | none", "name": "frontend", "hasDynamicHelp": false, "multiple": false, "options": [ "astro", "angular", "hono", "nuxt", "nextjs", "none" ], "type": "option" }, "storefront-app": { "description": "Target storefront app ID", "name": "storefront-app", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "integration-type": { "description": "Integration: generic | payment | shipping | tax", "name": "integration-type", "hasDynamicHelp": false, "multiple": false, "options": [ "generic", "payment", "shipping", "tax" ], "type": "option" }, "integration-id": { "description": "Service ID (e.g., card, fedex)", "name": "integration-id", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "yes": { "char": "y", "description": "Skip prompts, require all arguments", "name": "yes", "allowNo": false, "type": "boolean" }, "pkg": { "char": "p", "description": "Package manager: npm | yarn | none", "name": "pkg", "default": "npm", "hasDynamicHelp": false, "multiple": false, "options": [ "npm", "yarn", "none" ], "type": "option" }, "type": { "char": "t", "description": "App type: admin | storefront | theme | integration", "name": "type", "hasDynamicHelp": false, "multiple": false, "options": [ "admin", "integration", "storefront", "theme" ], "type": "option" }, "name": { "char": "n", "description": "Display name (default: capitalized ID)", "name": "name", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "version": { "char": "v", "description": "Version (default: 1.0.0)", "name": "version", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "description": { "char": "d", "description": "Description", "name": "description", "hasDynamicHelp": false, "multiple": false, "type": "option" } }, "hasDynamicHelp": false, "hiddenAliases": [], "id": "create:app", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "strict": true, "enableJsonFlag": false, "helpMeta": { "typeSection": { "title": "APP TYPES", "types": [ { "name": "admin", "description": "Dashboard extension", "optional": [ "--frontend" ] }, { "name": "storefront", "description": "Hosted storefront", "optional": [ "--frontend" ] }, { "name": "theme", "description": "Theme for existing storefront", "requires": [ "--storefront-app" ] }, { "name": "integration", "description": "Third-party service", "requires": [ "--integration-type", "--integration-id (for payment | shipping | tax)" ] } ] }, "typeFlags": [ "frontend", "storefront-app", "integration-type", "integration-id" ], "usageDirect": "<id> -t <type> [...] -y" }, "isESM": true, "relativePath": [ "dist", "commands", "create", "app.js" ] }, "create:content": { "aliases": [], "args": { "collection": { "default": "", "description": "Collection ID to create or extend (e.g., products)", "name": "collection" } }, "description": "Interactive mode lets you choose to create a new collection or extend a standard one.\nTo discover standard collections: swell inspect models", "examples": [ "$ swell create content", "$ swell create content products -y", "$ swell create content visitors -v list,edit,new -f name:short_text,verified:boolean -y" ], "flags": { "app-path": { "description": "path to your app directory", "name": "app-path", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "label": { "char": "l", "description": "Display label (default: capitalized collection)", "name": "label", "default": "", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "description": { "char": "d", "description": "Description", "name": "description", "default": "", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "fields": { "char": "f", "description": "Fields as id:type pairs (e.g., name:short_text,verified:boolean)", "name": "fields", "default": "", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "views": { "char": "v", "description": "Views to enable: list | edit | new", "name": "views", "default": "", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "overwrite": { "description": "Overwrite existing file", "name": "overwrite", "allowNo": false, "type": "boolean" }, "yes": { "char": "y", "description": "Skip prompts, require all arguments", "name": "yes", "allowNo": false, "type": "boolean" } }, "hasDynamicHelp": false, "hiddenAliases": [], "id": "create:content", "pluginAlias": "@swell/cli", "pluginName": "@swell/cli", "pluginType": "core", "summary": "Create a content UI model configuration in the content folder.", "helpMeta": { "usageDirect": "<collection> [...] -y" }, "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": "Framework: astro | angular | hono | nuxt | nextjs | none", "name": "frontend", "hasDynamicHelp": false, "multiple": false, "options": [ "astro", "angular", "hono", "nuxt", "nextjs", "none" ], "type": "option" }, "storefront-app": { "description": "Target storefront app ID", "name": "storefront-app", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "integration-type": { "description": "Integration: generic | payment | shipping | tax", "name": "integration-type", "hasDynamicHelp": false, "multiple": false, "options": [ "generic", "payment", "shipping", "tax" ], "type": "option" }, "integration-id": { "description": "Service ID (e.g., card, fedex)", "name": "integration-id", "hasDynamicHelp": false, "multiple": false, "type": "option" }, "yes": { "char": "y", "description": "Skip prompts, require all arguments", "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,