Deploys a UI bundle app to a Salesforce org with ordered setup: auth, build, metadata deploy, permission/role assignment, self-registration, social login/SSO, logout URL, seed data, and GraphQL schema fetch + codegen.
Ships in sf-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Deploy order is load-bearing: a step's output is the next step's precondition
(deploy before schema fetch; permissions before schema fetch; role/self-reg
before the schema the guest user must see). This is the canonical setup sequence,
ported from the reference org-setup.mjs. The org-setup.mjs line
citations in references/ are port-provenance (why each rule exists) pointing at
that external reference script — not files shipped with this skill — so you don't
need to open them to run the steps.
Run each step in order. Every optional step is presence-driven: if its convention file is absent, no-op cleanly and move on — do not fabricate config. For the two destructive/expensive steps (self-registration, data import), ask the user before running.
Read these from the project; ask the user only for what's missing:
--target-org. Ask if not obvious.scripts/get-source-root.sh to resolve the metadata
source dir from sfdx-project.json (packageDirectories[0].path + /main/default).
It exits non-zero if the project file is missing or malformed. Never hardcode
force-app/main/default.org-setup.config.json (optional) — drives permset assignment, role,
self-registration, and social login. Absent keys mean "skip that step".
Exception: if the file is missing but permissionsets/ has permsets to
assign, don't silently skip — scaffold the config or gather equivalent inputs
(see step 4).data-plan.json (optional, in the project's data/ dir) — presence enables the data step.Unconditional precondition; cannot be skipped. If the org is already connected
(sf org display --target-org <org> --json succeeds), no-op. Otherwise:
sf org login web --alias <org>
A failed login aborts the whole setup before deploy.
Build every UI bundle so dist/ exists before metadata deploy (UI bundle
entities deploy the built output). For each bundle dir under uiBundles/:
npm install
npm run build
Run when deploying UI bundles and dist/ is missing or source changed.
If self-registration is configured:
references/license-checks.md) — it
blocks the deploy with a clear, license-naming message instead of a cryptic
failure.networkMemberGroups on the local source —
apply Edit A of assets/network-selfreg-xml-recipe.md. This must happen
before this deploy so the profile ships as a recognised site member; do
NOT deploy the network file on its own here (this deploy ships it). Best-effort
and idempotent — skip if already a member.Then deploy the whole project (all metadata) by pointing --source-dir at the
resolved source root:
sf project deploy start --source-dir <sourceRoot> --target-org <org>
<sourceRoot> is the value from scripts/get-source-root.sh (e.g.
force-app/main/default). Always pass --source-dir. Do NOT run bare
sf project deploy start with no path: that command relies on source-tracking to
decide what to deploy, and on an org without source-tracking (most non-scratch
orgs) it aborts with "This org does not have source-tracking enabled … specify
the files or a manifest to deploy." Passing --source-dir deploys the same full
set on both source-tracked and non-tracked orgs and never emits that hint. If the
deploy reports conflicts on a source-tracked org, re-run with --ignore-conflicts
— do NOT roll back or reduce the deployed set.
Do NOT hand-build a package.xml, assemble a --metadata-dir mdapi zip, or
otherwise convert to metadata-format — none of that is needed and it is not part
of this flow.
Timeout 180s. Must complete before permission assignment and schema fetch — objects, fields, and permission sets appear in the org only after deploy.
Run only when org-setup.config.json has a top-level logoutUrl. If absent,
no-op cleanly and say so. Non-destructive and idempotent — no ask needed.
Runs here, after the deploy (not folded into it) because the platform rejects
a relative logout URL ("The logout page URL must be an absolute URL."), and a
shipped site-relative path (e.g. /propertyrentalapp/) is resolved to absolute
against the site's Experience Cloud origin — which only exists once the site is
deployed.
Why it matters: a site with no <logoutUrl> sends a logging-out member to the
org default-site login page — in a multi-site org that's a different
community, so Sign Out lands on the wrong site's login page. Setting it steers
logout back to this site (reload as Guest).
Steps:
Read logoutUrl from config; absent → skip.
Derive the site — scripts/derive-site-name.sh (single *.network-meta.xml;
skip if zero/ambiguous).
Resolve, set, and deploy — one command. Invoke the helper, which resolves
the value to an absolute URL (site-relative → matched against the community
siteUrl path, never guessing), writes <logoutUrl> idempotently in the
canonical position, and deploys only that file:
node scripts/set-logout-url.mjs \
--logout-url "<logoutUrl from config>" \
--network-file <sourceRoot>/networks/<site>.network-meta.xml \
--target-org <org> --site <site> --deploy
Best-effort: the helper exits 0 on success or already-set, and 3 on a
recoverable skip (network file missing, origin unresolvable, XML-special char, or
deploy failure). Treat exit 3 as a loud skip, not a setup failure — continue
the rest of setup and tell the user to set the logout URL manually in the site's
Administration settings. Usage, exit-code contract, and port-provenance:
references/logout-url.md.
Discover permission sets under <packageDir>/main/default/permissionsets/. If
none exist and none were passed explicitly, skip.
If permsets exist but org-setup.config.json is missing, do NOT silently
skip. A missing config makes every discovered permset resolve to skip, so
nothing gets assigned and the later GraphQL schema comes back incomplete (the
caller lacks FLS). Instead, help the user supply the assignments — either scaffold
org-setup.config.json from assets/org-setup.config.template.json or gather the
per-permset assignee inputs for a one-off run. Full schema + scaffolding flow:
references/config-scaffold.md. Confirm intent before writing the file or
assigning — don't fabricate assignees.
Otherwise assign each per its config assignee (org-setup.config.json →
permsetAssignments), where each assignee is one of currentUser, guestUser,
or skip (default skip):
sf org assign permset --name <permset> --target-org <org> [--on-behalf-of <guestUsername>]
--on-behalf-of.references/self-registration.md). If the site can't be derived or
no guest user resolves, skip that permset and record the reason — don't
abort the others.Required so GraphQL introspection returns the correct schema (the caller needs FLS on custom fields).
Run only when org-setup.config.json has role: { assignee: "currentUser", roleName: "<UserRole>" }. Assigning a role to the current user is what lets
Experience Cloud self-registration work. Idempotent — skip if the user already
has a role. Detail + exact queries: references/role-assignment.md.
Run only when org-setup.config.json has
selfRegistration: { selfRegProfile, accountName }. Ask the user before
running. Sequence (full detail in references/self-registration.md):
references/license-checks.md.scripts/derive-site-name.sh; it outputs the site
name (the base name of the single *.network-meta.xml) or exits non-zero when
zero or more than one exist (ambiguous — stop).assets/network-selfreg-xml-recipe.md (set selfRegistration=true, inject
<selfRegProfile>), then redeploy only that one file. Idempotent — skip both
if already enabled. (Edit A, the member-group add, already happened in step 3.)assets/network-selfreg.apex (idempotent; both are query-then-create; run 4a
and 4b as two separate sf apex run invocations).Run only when org-setup.config.json has a socialLogin block. If the block is
absent, loadSocialLoginConfig returns null and the step is hidden — no-op
cleanly and say so. This step is non-destructive and idempotent (it only adds
missing links/members), so — unlike self-registration and data import — it does
not require asking first.
This links the site's configured Auth Providers (OAuth) and SAML SSO
configs to the site so the built-in Social Login component renders their
buttons on the React login page. On React (Site Container) sites the SSO admin UI
is hidden, so the linking is done programmatically via AuthConfig /
AuthConfigProviders records — you cannot do it by clicking through Setup. Full
detail, sub-steps, and port-provenance: references/social-login.md.
Config shape (see references/config-scaffold.md for the full schema):
{ "socialLogin": {
"communityMemberProfile": "Customer Community User",
"authProviderNames": ["Google", "My_SAML_Provider"],
"communityUserPermset": "myapp_Guest_User_Api_Access"
} }
Sequence (mirrors reference org-setup.mjs main() social-login step, which runs
after self-registration and before the data/GraphQL steps):
Apply the assets/ templates verbatim (like the self-reg/data steps) — full
runnable commands for each sub-step are in references/social-login.md:
scripts/derive-site-name.sh (single
*.network-meta.xml; stop if zero/ambiguous). Social login needs the site to
resolve its AuthConfig.assets/Communities.settings-meta.xml via Metadata API (from a throwaway
minimal project; see the reference). Required so the SSO registration handler
can create users on standard community profiles; without it auth providers fail
user insert with FIELD_INTEGRITY_EXCEPTION. A "already active" warning is a
non-fatal skip.AuthConfig — run
assets/social-login-auth-providers.apex verbatim (substitute <siteName>,
<ProviderNamesList>, <ApiVersion>) to create the missing
AuthConfigProviders junctions, then read its |DEBUG| lines (table in the
reference). All-or-nothing: if any configured authProviderNames entry has no
matching AuthProvider (OAuth) or SamlSsoConfig (SAML) record, it emits
MISSING_PROVIDERS and links nothing — create/fix them in Setup first.
Already-linked providers are skipped (idempotent).NetworkMemberGroup — resolve the
Network + Profile Ids and create the membership if absent (sf data commands in
the reference). Without it, SSO-registered users hit NO_ACCESS: User was not authorized for the community.communityUserPermset to community users — only when
configured. Grants ApiEnabled so getCurrentUser() (/chatter/users/me)
works for SSO-created users.IMPORTANT: A
socialLoginblock present but skipped is a silent-failure trap — the app deploys fine, but no social-login buttons ever appear on the login page and there is no error explaining why. Do not silently skip: run the step when the block is present, or state clearly that it was absent.
Run scripts/find-data-plan.sh first. If it exits non-zero, skip this step —
do not prompt and do not error; just move on to step 8 (a brief "no data plan,
skipping data import" note is fine). There is nothing to import without a plan.
On success it prints the plan's path (it searches recursively, so both a
project-root data/ and a <packageDir>/main/default/data/ layout resolve).
When it exists: always ask the user before importing or cleaning data — it deletes existing records first. Apply the verbatim templates; do not improvise Apex:
scripts/find-prep-script.sh. If it succeeds, it prints the path of a
prepare-import-unique-fields.js that ships with the app — run that first; it
deduplicates re-runs by stamping stable unique keys on the record files.
Invoke it the way that copy expects (its interface varies —
see references/data-import.md). If it exits non-zero, there is no prep
script — skip to the clean step.assets/data-delete.apex.assets/data-import.apex, resolving
@referenceId refs and batching by measured size.Protocol, @referenceId resolution, measured batching, and the
SETUP_RESULT_JSON parse-and-hard-fail rule: references/data-import.md.
Run from the UI bundle directory, after deploy and permission assignment (the schema reflects org state and the caller's FLS):
npm install
SF_TARGET_ORG=<org> npm run graphql:schema
npm run graphql:codegen
npm run build
Detail: references/graphql.md. Re-run schema fetch + codegen after every deploy
that changes objects, fields, or permissions.
Setup ends here — the steps above (including the config-gated 6b social login)
are the complete sequence. Local dev preview (npm run dev:preview) is a separate
developer action, not part of setup; if the user asks to preview the site, see
references/dev-preview.md.
socialLogin block means no login buttons appear with no
error to explain it.sfdx-project.json; never hardcode
force-app/main/default.assets/ Apex and XML templates verbatim — they encode
duplicate-rule bypass, allOrNone=false deletes, idempotency, SOQL-safety, and
(for social login) the all-or-nothing provider pre-check and the
DML-not-allowed-on-AuthConfigProviders REST-callout insert — all easy to get
wrong by hand.logoutUrl configured — post-deploy, idempotent, best-effort)socialLogin configured — idempotent, no ask needed)assets/Communities.settings-meta.xml (opens in a new tab)assets/data-delete.apex (opens in a new tab)assets/data-import.apex (opens in a new tab)assets/network-selfreg-xml-recipe.md (opens in a new tab)assets/network-selfreg.apex (opens in a new tab)assets/org-setup.config.template.json (opens in a new tab)assets/prepare-import-unique-fields.js (opens in a new tab)assets/social-login-auth-providers.apex (opens in a new tab)references/config-scaffold.md (opens in a new tab)references/data-import.md (opens in a new tab)references/dev-preview.md (opens in a new tab)references/graphql.md (opens in a new tab)references/license-checks.md (opens in a new tab)references/logout-url.md (opens in a new tab)references/role-assignment.md (opens in a new tab)references/self-registration.md (opens in a new tab)references/social-login.md (opens in a new tab)scripts/derive-site-name.sh (opens in a new tab)scripts/find-data-plan.sh (opens in a new tab)scripts/find-prep-script.sh (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
/sf-skills:experience-ui-bundle-deployfrom sf-skills
sf-skills@sf-skills-plugin is listed by ccmalcom/sf-skills-plugin — review the source before installing
npx claudepluginhub ccmalcom/sf-skills-plugin --plugin sf-skills266 skills in this plugin
/afcc-setup-coordinateOrchestrates end-to-end headless setup of Agentforce Contact Center (AFCC) on a Salesforce org. Scans the org first, presents a delta plan for approval, then sequentially provisions demo users, Omni-Channel base settings, a human queue with routing config and members, presence statuses, permission sets, a PSTN voice number, and an active PstnVoice MessagingChannel wired to the queue. Interactive at key decision points — never assumes country, number type, queue names, or user counts. TRIGGER: set up AFCC, configure Agentforce Contact Center, stand up voice contact center, AFCC migration setup, provision AFCC org headlessly./agentforce-architecture-analyzeDeclared architecture snapshot for one Agentforce agent: planner, topics, actions, flows, Apex, prompt templates, and NGA plugins. Renders a human-readable architecture document and Mermaid invocation graph from design-time metadata (not runtime audit rows). TRIGGER when user asks to describe, diagram, inventory, audit, document, or diff (e.g. v3 vs v5) the architecture / action tree / topic structure / tool inventory of a specific agent by agent API name in a specific org. DO NOT TRIGGER for runtime session traces, conversation transcripts, generation timings, or gateway audit chains — this skill reads design-time metadata only (use agentforce-d360-analyze for session traces)./agentforce-bot-upgradeUse this skill to upgrade Einstein Bots into Agentforce agents end-to-end in a single pass, orchestrating per-bot Agent Spec generation, agentforce-generate authoring, and post-conversion .agent enhancements. TRIGGER when: user asks to migrate, upgrade, or convert one or more Einstein Bots (BotDefinition/BotVersion chatbots) to Agentforce agents; runs a multi-bot bot-to-agent upgrade; needs Einstein Bot metadata turned into Agent Spec handoffs and generated .agent agents; convert bots to agents; upgrade my service bots; move bots to Agentforce. DO NOT TRIGGER when: user already has an approved Agent Spec and only wants direct .agent authoring, deploy, test, or observe flows; user wants to migrate or upgrade an EXISTING Agentforce agent from a legacy GenAiPlannerBundle to an NGA aiAuthoringBundle (that is agentforce-generate's 'Migrate a Legacy Agent to Agent Script' flow, not an Einstein Bot upgrade); the request is unrelated to Einstein Bot migration./agentforce-d360-analyzeData Cloud 360° view of a single Agentforce session. TRIGGER when user asks to trace, inspect, summarize, or describe a specific Agentforce session by session id (Agent Session UUID `019d…` or MessagingSession id `0Mw…`). Also triggers on session discovery — find/list/search sessions by time, agent, channel, outcome, or conversation text — when the user has no session id yet. DO NOT TRIGGER for design-time architecture questions (use agentforce-architecture-analyze instead) or for runtime perf/latency/SLO questions that require platform telemetry beyond Data Cloud./agentforce-generateBuild, modify, audit, repair, optimize, debug, and deploy agents with Agentforce Agent Script. TRIGGER when: user creates, reviews, or changes .agent files or aiAuthoringBundle metadata; asks to fix AgentScript, audit an existing agent, run an AgentScript health check, common-pitfall review, or baseline-versus-candidate repair loop; changes a response, action, subagent, route, state flow, or Agent Spec; migrates or upgrades a legacy GenAiPlannerBundle Agentforce agent (NOT an Einstein Bot) to an aiAuthoringBundle (Agent Script) agent; previews, debugs, deploys, publishes, or tests agents; uses sf agent generate/preview/publish/test; or manages Agentforce MCP servers, tools, assets, or authentication. DO NOT TRIGGER when: Apex, Flow, Prompt Template, Experience Cloud, or general Salesforce CLI work is unrelated to Agent Script; the source is an Einstein Bot (BotDefinition/BotVersion) — use agentforce-bot-upgrade; or the primary input is a production session or trace ID rather than an agent artifact./agentforce-hyperclassifier-configureOnboard a customer org and evaluate or improve Agentforce HyperClassifier routing descriptions against labeled utterances. TRIGGER for classifier evaluation, expected-versus-actual routing reports, repeated regressions, or description optimization with customer ECA authentication. DO NOT TRIGGER for general agent conversation testing, runtime session tracing, or automatic agent deployment.3 plugins in 2 repositories ship this exact skill · first indexed Sep 11, 2026
Other plugins' skills for the same job