commerce-b2b-open-code…
Integrate Salesforce B2B Commerce open source components from GitHub into B2B Commerce stores. Use when users mention \"integrate open code components\",…
Use this skill to generate a package.xml (and optionally destructiveChanges.xml, destructiveChangesPre.xml, or destructiveChangesPost.xml) from a local source directory, an explicit component list, or org introspection. Trigger when the user says \"generate a package.xml from
$ npx -y skills add forcedotcom/sf-skills --skill platform-manifest-generate --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/platform-manifest-generateContext preview
The summary Claude sees to decide when to auto-load this skill.
Use this skill to generate a package.xml (and optionally destructiveChanges.xml, destructiveChangesPre.xml, or destructiveChangesPost.xml) from a local source directory, an explicit component list, or org introspection. Trigger when the user says \"generate a package.xml from
name: platform-manifest-generate
description: "Use this skill to generate a package.xml (and optionally destructiveChanges.xml, destructiveChangesPre.xml, or destructiveChangesPost.xml) from a local source directory, an explicit component list, or org introspection. Trigger when the user says \"generate a package.xml from this folder\", \"create a manifest for these classes\", \"I need a deploy manifest\", \"build package.xml for the contacts changes\", or \"create both package.xml and destructiveChanges.xml for these deletions\". Encodes which metadata types accept a wildcard member and which must be enumerated, avoiding the common \"Wildcards are not supported for this metadata type\" deploy failure. DO NOT TRIGGER for executing a deploy (use platform-metadata-deploy), performing the deletion in destructiveChanges.xml (use platform-destructive-deploy), or retrieving metadata (use platform-metadata-retrieve)."
metadata:
version: "1.0"
relatedSkills:
- "platform-metadata-deploy"
- "platform-metadata-retrieve"
- "platform-destructive-deploy"
- "platform-deploy-validate"
cliTools:
- tool: ["sf"]
semver: ">=2.0.0"Produce a Salesforce metadata manifest — `package.xml` (or one of the destructive variants) — from local source, an org, or an explicit component list. This skill is purely about authoring the manifest file. Hand off to `platform-metadata-deploy` or `platform-destructive-deploy` once the file exists.
---
**Use ONLY the Bash tool** to run `sf project generate manifest`, and the `Write` tool for the hand-built fallback path. Do NOT use MCP tools.
---
Use `platform-manifest-generate` when the work involves any of:
Delegate elsewhere when the user is:
---
Wrap `sf project generate manifest`. Always prefer this path; it knows about every metadata type and produces canonical XML — and never emits `*`, sidestepping the wildcard hazard entirely.
The CLI offers three input modes (mutually exclusive):
| Input | Flag | Use when | |---|---|---| | Source directory | `--source-dir` (`-p`) | User points to a folder containing already-on-disk metadata | | Component list | `--metadata` (`-m`) | User names specific components, e.g. `ApexClass:AccountService CustomObject:Account` | | Org introspection | `--from-org` | User wants every component currently in an org (or a filtered subset) |
You can specify either `--source-dir` or `--metadata`, not both. `--from-org` may be combined with `--metadata` (filter included types) or `--excluded-metadata` (filter out types).
**Verified flags** (do not invent flags — verify with `sf project generate manifest --help` if unsure):
| Flag | Purpose | |---|---| | `--source-dir`, `-p` | Local source paths to scan | | `--metadata`, `-m` | Component names to include (e.g. `ApexClass:AccountService`) | | `--from-org` | Username or alias of org to introspect | | `--name`, `-n` | Custom output filename (mutually exclusive with `--type`) | | `--type`, `-t` | Predefined manifest kind: `package` \| `pre` \| `post` \| `destroy` | | `--output-dir`, `-d` | Directory to write the manifest into | | `--api-version` | Override the API version for the request | | `--include-packages`, `-c` | Include `managed` and/or `unlocked` package metadata when using `--from-org` | | `--excluded-metadata` | Types to exclude when using `--from-org` | | `--json` | Machine-readable output |
**Manifest filename by `--type`:**
| `--type` | Output file | |---|---| | `package` (default) | `package.xml` | | `pre` | `destructiveChangesPre.xml` | | `post` | `destructiveChangesPost.xml` | | `destroy` | `destructiveChanges.xml` |
You can specify either `--type` or `--name`, not both.
# Build package.xml from a source dir sf project generate manifest \ --source-dir force-app/main/default \ --name package.xml \ --output-dir manifest \ --json # Build package.xml from an explicit component list sf project generate manifest \ --metadata ApexClass:AccountService \ --metadata ApexClass:ContactSelector \ --metadata CustomObject:Account \ --name package.xml \ --output-dir manifest \ --json # Build destructiveChanges.xml from a component list sf project generate manifest \ --metadata CustomField:Account.OldField__c \ --metadata CustomField:Account.OldStatus__c \ --type destroy \ --output-dir manifest \ --json # Build a manifest by introspecting an org (filtered) sf project generate manifest \ --from-org <alias> \ --metadata ApexClass,CustomObject,CustomLabels \ --output-dir manifest \ --json
If both a `package.xml` and a destructive manifest are needed, run the CLI twice — once with `--type package` (or default), once with `--type destroy` / `pre` / `post`.
Use this only when the CLI cannot express the user's intent — e.g. they want "just the Apex classes I changed today" and the change set is derived from `git diff` rather than a clean directory or component list. In that case:
1. Resolve the components yourself (e.g. parse `git diff --name-
This repository provides a curated collection of Salesforce agent skills for building applications.
Repo: forcedotcom/sf-skills
Integrate Salesforce B2B Commerce open source components from GitHub into B2B Commerce stores. Use when users mention \"integrate open code components\",…
Replace OOTB (out-of-the-box) B2B Commerce components with open source equivalents in site metadata content.json files, or look up the equivalent open code…
Use this skill to diagnose and resolve what blocks a DevOps Center promotion of a work item's feature branch: Git merge conflicts and deployment failures.…
Use this skill to manage the full lifecycle of a DevOps Center pipeline — list all pipelines, get a single pipeline's details, create a new pipeline linked to…
Analyzes DevOps Center test failures and Code Analyzer violations in plain language — failure category, offending file/class/method/line, rule violated, fix…
Configures DevOps Center pipeline testing infrastructure: enables a test provider so its suites become available, re-syncs a configured provider to pull in new…