Skip to Content
CLIConfiguration

Configuration

Running sfdt init creates a .sfdt/ directory in your project root. Every command reads it.

The .sfdt/ directory

    • config.json
    • environments.json
    • test-config.json
    • pull-config.json
    • *.local.json
    • feature-flags.json
    • telemetry-snapshot.json
    • bridge-token
FileWhat it holds
config.jsonCore settings: org aliases, feature flags, AI provider, coverage threshold (see below)
environments.jsonNamed environments and org aliases
test-config.jsonTest classes, coverage threshold, test level
pull-config.jsonMetadata types to pull from the org (see Incremental Pull)
*.local.jsonOptional environment-specific overrides — git-ignore these
plugins/Optional local CLI plugins (.js/.mjs) — see Plugins
cache/Pull delta cache (SQLite) and parked MCP results
data/Data-set definitions for sf data tree
feature-flags.jsonKill-switch list for Chrome extension features
telemetry-snapshot.jsonLatest opt-in extension telemetry snapshot
bridge-tokenAuto-created 0600 bearer token for the local bridge

Add .sfdt/*.local.json to your .gitignore so machine-specific overrides never get committed.

config.json reference

A representative config.json:

{ "projectName": "My Salesforce Project", "defaultOrg": "my-dev-org", "deployment": { "coverageThreshold": 75, "backupBeforeRollback": true, "preflight": { "enforceTests": false, "enforceBranchNaming": false, "enforceChangelog": false } }, "features": { "ai": true, "notifications": false, "releaseManagement": true }, "ai": { "provider": "claude", "model": "" }, "pullCache": { "enabled": true, "parallelism": 5, "batchSize": 100 }, "mcp": { "enabled": false, "parking": { "enabled": true } }, "plugins": [] }

Top-level keys

KeyTypeDescription
projectNamestringDisplay name used in logs and notifications
defaultOrgstringDefault Salesforce org alias
releaseNotesDirstringRelease-notes output directory (default release-notes)
manifestDirstringManifest output directory (default manifest/release)
manifestLayoutenumflat (default) or subpath for per-package subdirectories
changelogDirstringPer-package changelog directory (default changelogs)
logDirstringCLI log directory (default logs)
pluginsarraynpm package names to load as plugins
pluginOptions.autoDiscoverbooleanAuto-load sfdt-plugin-* packages and .sfdt/plugins/*.js (default false)

deployment

KeyTypeDefaultDescription
deployment.coverageThresholdnumber75Minimum Apex test coverage percent
deployment.backupBeforeRollbackbooleantrueCapture an org snapshot before sfdt rollback
deployment.preflight.enforceTestsbooleanfalsePromote “no tests” from warning to failure
deployment.preflight.enforceBranchNamingbooleanfalseEnforce branch-naming convention
deployment.preflight.enforceChangelogbooleanfalseRequire an [Unreleased] changelog entry

features

Feature toggles. All default to true except notifications.

KeyDescription
features.aiAI-powered commands
features.notificationsSlack integration
features.releaseManagementRelease workflow
features.monitoringOrg monitoring
features.auditAudit-trail analysis
features.docsDocs generation
features.dataData import/export
features.scratchScratch-org management

ai

KeyTypeDescription
ai.providerenumclaude (default), gemini, or openai
ai.modelstringOptional model override (the provider CLI handles selection)

See AI Providers for full setup.

pullCache

KeyTypeDefaultDescription
pullCache.enabledbooleantrueEnable the SQLite-backed incremental pull cache
pullCache.parallelismnumber5Concurrent retrieval threads
pullCache.batchSizenumber100Components per retrieve batch
pullCache.retrieveTimeoutSecondsnumber360Retrieve timeout

mcp

KeyTypeDefaultDescription
mcp.enabledbooleanfalseEnable the MCP server
mcp.parking.enabledbooleantruePark oversized tool results
mcp.parking.thresholdBytesnumber50000Size limit before a result is parked
mcp.parking.ttlSecondsnumber86400TTL before parked cache files are deleted
mcp.parking.cacheScopeenumsessionSEP-2549 cache scope: global, user, or session

See the MCP Server page for details.

audit, monitoring, docs, data, scratch

KeyDefaultDescription
audit.auditTrailLookbackDays30Setup-audit-trail lookback window
audit.licenseWarnThreshold0.9License-usage warn threshold (0–1)
audit.inactiveUserDays90Days before a user is “inactive”
audit.minApiVersion45Minimum acceptable API version
monitoring.backupDirmonitoring-backupMetadata-backup output directory
monitoring.limitWarnThreshold0.8Governor-limit warn threshold (0–1)
monitoring.errorLookbackDays7Apex-error lookback window
monitoring.healthMinScore80Minimum acceptable Security Health Check score
docs.outputDirdocsGenerated-docs output directory
docs.aitrueInclude an AI overview in generated docs
docs.diagramstrueGenerate Mermaid diagrams
data.dir.sfdt/dataData-set definition directory
scratch.definitionFileconfig/project-scratch-def.jsonScratch-org definition
scratch.durationDays7Scratch-org lifetime
scratch.poolSize0Pre-created scratch-org pool size

notifications

{ "features": { "notifications": true }, "notifications": { "slack": { "webhookUrl": "https://hooks.slack.com/services/T.../B.../..." } } }

Reading & writing config

Use dot notation from the command line:

sfdt config get defaultOrg sfdt config get deployment.coverageThreshold sfdt config set deployment.coverageThreshold 80 sfdt config set features.ai true

Values are coerced automatically: "true"/"false" become booleans, numeric strings become numbers, everything else stays a string.

Last updated on