For AI agents: the complete documentation index is available at /en/llms.txt, the full documentation bundle is available at /en/llms-full.txt, and this page is available as Markdown at /en/guide/modules.md.
  • English
  • Modules

    Modules are SFMC business feature packages built on vanilla BDS. Artifacts ship on npm (@sfmc-bds/module-<id> or @<author>/sfmc-module-<id>).
    sfmc-modules is a thin search index only; it does not contain business source.

    Install and enable

    sfmc> mod search
    sfmc> mod install afk economy
    sfmc> mod uninstall afk
    sfmc> mod list
    sfmc> mod enable afk
    sfmc> mod disable afk

    mod list output and status indicators

    Running mod list scans modules under <SFMC_ROOT>/modules/packages/ and displays:

    SymbolColorMeaningDescription
    ●GreenOfficial & EnabledListed in first-party registry (sfmc-modules), and locked on in module-lock.json.
    ○GrayOfficial & DisabledListed in first-party registry, but locked off in module-lock.json.
    ?YellowUnknown publisherInstalled locally, but not published in the first-party registry index. A verification warning is shown at REPL startup.
    ○YellowManifest issueLocal sapi/manifest.json is missing or unparseable.
    • If folder name differs from manifest logical ID, it appears as folderId(logicalId) (e.g. my-mod(feature-my-mod)).
    • In the interactive REPL with running services (prompt like bds> ), prefix commands with / (e.g. /mod list).

    enable / disable write modules/module-lock.json first (no db-server required). When db is online, memory state is best-effort synced; without db the write still succeeds, with a note to start db next. For in-game behavior, you usually need mod reload or a BDS restart.

    Behavior pack assembly

    Enabled modules are bundled into one behavior pack (and companion resource pack) deployed to the current world.

    sfmc> mod build
    sfmc> mod reload
    sfmc> mod reload --build-only
    CommandPurpose
    mod buildBuild only; no deploy
    mod reloadBuild, deploy, and request BDS reload (common in dev)
    mod reload --build-onlyBuild and deploy only; run reload in-game afterward

    Before start bds, the load catalog is compared automatically: on mismatch the full pack is rebuilt and deployed; BDS starts only after success.

    Paths

    StageLocation
    Build artifactspacks/_build/sfmc-modules/ (and companion RP)
    Deploy target BP<BDS>/worlds/<level>/behavior_packs/sfmc-modules/
    Deploy target RP<BDS>/worlds/<level>/resource_packs/sfmc-modules-rp/
    Load catalogsfmc-deploy-catalog.json inside the BP

    Third-party add-ons use packs / inbox flow (see Add-ons). World BP/RP assets shipped via packs follow the add-on path, separate from the assembled sfmc-modules pack.

    Flow summary: scan modules/packages/*/sapi → bundle only modules enabled in lock → esbuild → assemble BP/RP → copy to world and write enable manifest. With zero modules enabled, an empty but valid pack is still produced.

    Authors use the VS Code/Cursor SFMC Module extension: Start Watch / Reload to BDS / Enable / Disable Module (set sfmc.root to the workspace with configs/ and modules/; the extension writes ${sfmc.root}/modules/module-lock.json, same as CLI). On the server:

    sfmc mod install <id> --from dir:<absolute-path-to-author-repo> --link
    sfmc mod enable <id>
    sfmc mod reload

    sfmc mod install requires the module short id. Template and publish flow: Module authoring.

    Artifact sources

    SourceUse
    npm:@scope/nameDefault (npm field in index wins)
    dir: / local:Local directory or archive; use --link for dev

    Official module catalog

    The list below is generated at build time from the sfmc-modules registry (local sibling repo preferred; fallback otherwise).

    来源:https://raw.githubusercontent.com/Tanya7z/sfmc-modules/main/index.json · 17 个模块

    idtag安装
    activity-log—sfmc> mod install activity-log
    afk—sfmc> mod install afk
    area—sfmc> mod install area
    chat—sfmc> mod install chat
    chat-sounds—sfmc> mod install chat-sounds
    clean—sfmc> mod install clean
    coop—sfmc> mod install coop
    data-backup—sfmc> mod install data-backup
    economy—sfmc> mod install economy
    fly-area—sfmc> mod install fly-area
    gamemode-area—sfmc> mod install gamemode-area
    inventory-switcher—sfmc> mod install inventory-switcher
    land—sfmc> mod install land
    online-time—sfmc> mod install online-time
    peace-area—sfmc> mod install peace-area
    qa—sfmc> mod install qa
    spawn-protect—sfmc> mod install spawn-protect

    Module install and catalog projection are done by sfmc mod install (the monorepo does not host business modules).

    Official module service index: Module services.