b2c-code
БесплатноБез исполняемых скриптовНе проверенDeploy, download, and manage cartridge code versions on B2C Commerce instances. Use this skill whenever the user needs to upload or download cartridges…
от SalesforceCommerceCloud★ 58 звёзд на GitHubОб этом скилле
B2C Code Skill
Use the b2c CLI to deploy, download, and manage code versions on Salesforce B2C Commerce instances.
Tip: If
b2cis not installed globally, usenpx @salesforce/b2c-cliinstead (e.g.,npx @salesforce/b2c-cli code deploy).
MCP equivalent
Prefer cartridge_deploy for cartridge upload. Set codeVersion explicitly when
needed; files selects up to 100 local files (64 MiB total), relative to
projectDirectory, within discovered cartridges. Omit files for whole cartridges.
Matching remote files are overwritten; selected-file mode preserves other files.
reload may activate the target; keep upload success/warnings if reload fails.
Code mode builtin/code-version-inspect reads active/rollback and activation metadata;
builtin/site-cartridge-inspect reads site cartridge order and checks expected names.
SCAPI dx/scripts/v1 provides version management; site/sites/v1 manages site paths.
Use the CLI for watches, recursive downloads, and extra deployment flags.
Configuration & Authentication
The CLI auto-discovers the target instance and credentials from SFCC_* environment variables (including project .env), the selected project-local or shared dw.json, and configuration plugins. package.json supplies only non-sensitive defaults. Flags like --server, --client-id, --client-secret, --username, and --password are usually unnecessary — only pass them to override what's auto-detected.
With only a server configured, the first command opens a browser for the user to sign in with their Account Manager account and waits until they do; tell the user to finish signing in. Their Business Manager roles decide access, and a 403 names the missing permission (for example WebDAV_Manage_Customization for Cartridges). Code goes to the active code version; activating one (code activate, --activate, --reload) needs an API client.
Staging code upload needs a client certificate. Staging instances normally require two-factor (mTLS) code upload, so a deploy without a certificate fails, usually with 403 Forbidden on writes under Cartridges. Set certificate and certificate-passphrase (SFCC_CERTIFICATE, SFCC_CERTIFICATE_PASSPHRASE). Legacy realms use a certificate signed by a CA bundle from Salesforce Support and the cert.staging.* WebDAV hostname. Hyperforce realms use a CA the user registers through eCDN (b2c-cli:b2c-ecdn, b2c ecdn mtls). See Two-Factor Authentication.
Reload needs a second code version. --reload toggles activation through another code version. If the instance has only one, create an empty one first (b2c webdav mkdir --root cartridges version2).
Run b2c setup inspect to see the resolved configuration and which source provided each value (use --json for scripting; secrets stay masked by default). For precedence rules and troubleshooting, see the b2c-cli:b2c-config skill.
Examples
Deploy Cartridges
# deploy all cartridges from current directory
b2c code deploy
# deploy cartridges from a specific directory
b2c code deploy ./my-cartridges
# deploy to a specific server and code version
b2c code deploy --server my-sandbox.demandware.net --code-version v1
# deploy and reload (re-activate) the code version
b2c code deploy --reload
# delete existing cartridges before upload and reload
b2c code deploy --delete --reload
# deploy only specific cartridges
b2c code deploy -c app_storefront_base -c plugin_applepay
# deploy every discovered cartridge, ignoring a `cartridges` list in dw.json or SFCC_CARTRIDGES
b2c code deploy --all
# exclude specific cartridges from deployment
b2c code deploy -x test_cartridge
# replace the directory names skipped inside cartridges (default: node_modules,.git,coverage,.cache,tmp,temp)
b2c code deploy --cartridge-ignore-dirs node_modules,.git,build
# large code versions are split into archives of up to 200 MiB automatically;
# lower the limit if uploads are rejected (413) or keep dropping
b2c code deploy --max-archive-size 100mb
Download Cartridges
# download all cartridges from the active code version
b2c code download
# download to a specific directory
b2c code download -o ./downloaded
# download from a specific server and code version
b2c code download --server my-sandbox.demandware.net --code-version v1
# download only specific cartridges
b2c code download -c app_storefront_base -c plugin_applepay
# exclude specific cartridges from download
b2c code download -x test_cartridge
# mirror: extract to local cartridge project locations
b2c code download --mirror
Watch for Changes
# watch cartridges and upload changes automatically
b2c code watch
# watch a specific directory
b2c code watch ./my-cartridges
# watch with specific server and code version
b2c code watch --server my-sandbox.demandware.net --code
Установить b2c-code в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл b2c-code?
Deploy, download, and manage cartridge code versions on B2C Commerce instances. Use this skill whenever the user needs to upload or download cartridges to/from a sandbox, activate or delete code versions, watch for local file changes during development, or deploy a subset of cartridges. Also use when pushing code to an instance, pulling code from an instance, or setting up a dev workflow with live reload -- even if they just say 'push my code to the sandbox', 'download the code', or 'how do I activate the new version'.
Как установить скилл b2c-code?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл b2c-code запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
mcp-builder
Guide for creating high-quality MCP (Model Context Protocol) servers that enable LLMs to interact with external services through well-designed tools. Use when…
от Anthropicclaude-api
Reference for the Claude API / Anthropic SDK — model ids, pricing, params, streaming, tool use, MCP, agents, caching, token counting, model migration. TRIGGER…
от Anthropicalgorithmic-art
Creating algorithmic art using p5.js with seeded randomness and interactive parameter exploration. Use this when users request creating art using code…
от Anthropicmcp-integration
This skill should be used when the user asks to "add MCP server", "integrate MCP", "configure MCP in plugin", "use .mcp.json", "set up Model Context…
от Anthropic