Project

Operate on the sfdx project in the current repository

sfp project browser-sessions delete

Stop (release) a running browser session.

USAGE
  $ sfp project browser-sessions delete --session-id <value> --api-key <value> [--json] [--project-id <value>] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  --api-key=<value>     (required) [env: BROWSERBASE_API_KEY] Browserbase API key (defaults to BROWSERBASE_API_KEY).
  --loglevel=<option>   [default: info] logging level for this command invocation
                        <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
  --project-id=<value>  [env: BROWSERBASE_PROJECT_ID] Browserbase project id (defaults to BROWSERBASE_PROJECT_ID).
  --session-id=<value>  (required) The id of the session to stop.

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Stop (release) a running browser session.

EXAMPLES
  $ sfp project browser-sessions delete --session-id <id> --api-key $BROWSERBASE_API_KEY

sfp project browser-sessions extend

Extend a running browser session by a number of minutes. Server mode only — calls the SFP server's browser-session extend endpoint, which extends the underlying Browserbase session and updates the session row's expiry.

USAGE
  $ sfp project browser-sessions extend --session-id <value> [--json] [--repository <value>] [-e <value>] [-t <value>]
    [--sfp-server-url <value>] [--minutes <value>] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -e, --email=<value>              Email address for authenticated user. Ignored if --application-token is provided. Can
                                   be set via SFP_SERVER_USER env var.
  -t, --application-token=<value>  Application token for CI/CD authentication. Can be set via SFP_SERVER_TOKEN env var
                                   (CLI flags take precedence over env vars).
      --loglevel=<option>          [default: info] logging level for this command invocation
                                   <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --minutes=<value>            Minutes to extend the session by (server default applies when omitted).
      --repository=<value>         The repository identifier. E.g `owner/repo` for GitHub/GitLab or `org/project/repo`
                                   for Azure DevOps
      --session-id=<value>         (required) The sfp_browser_sessions row id of the session to extend.
      --sfp-server-url=<value>     URL of the SFP server. Can be set via SFP_SERVER_URL env var or config: sfp
                                   config:set server-url

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Extend a running browser session by a number of minutes. Server mode only — calls the SFP server's browser-session
  extend endpoint, which extends the underlying Browserbase session and updates the session row's expiry.

EXAMPLES
  $ sfp project browser-sessions extend --session-id <id> --minutes 15 --sfp-server-url $SFP_SERVER_URL

sfp project browser-sessions list

List browser sessions for the configured Browserbase project (direct mode). The sfp server exposes the session registry — with PR / review-environment binding — via its API; this direct view lists the provider's sessions for ops and debugging.

USAGE
  $ sfp project browser-sessions list --api-key <value> [--json] [--project-id <value>] [--status <value>] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  --api-key=<value>     (required) [env: BROWSERBASE_API_KEY] Browserbase API key (defaults to BROWSERBASE_API_KEY).
  --loglevel=<option>   [default: info] logging level for this command invocation
                        <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
  --project-id=<value>  [env: BROWSERBASE_PROJECT_ID] Browserbase project id that scopes the listing (defaults to
                        BROWSERBASE_PROJECT_ID).
  --status=<value>      Filter by session status (e.g. RUNNING, COMPLETED, ERROR, TIMED_OUT).

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  List browser sessions for the configured Browserbase project (direct mode). The sfp server exposes the session
  registry — with PR / review-environment binding — via its API; this direct view lists the provider's sessions for ops
  and debugging.

EXAMPLES
  $ sfp project browser-sessions list --api-key $BROWSERBASE_API_KEY --status RUNNING

sfp project integrations restore

Restore the original Named Credential endpoints that were switched by 'sfp project integrations virtualize --switch', using the workspace's backup.

USAGE
  $ sfp project integrations restore --workspace <value> [--json] [--force [--server | -o <value>]] [-e <value> |
    --application-token <value>] [--sfp-server-url <value>] [-g <value>...] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -e, --email=<value>               Email for sfp server authentication (uses the locally stored token).
  -g, --logsgroupsymbol=<value>...  Symbol used by CICD platform to group/collapse logs in the console. Provide an
                                    opening group, and an optional closing group symbol.
  -o, --targetusername=<value>      Username or alias of the target org.
      --application-token=<value>   [env: SFP_SERVER_TOKEN] Application token for sfp server authentication.
      --force                       Continue past per-credential failures instead of stopping at the first error.
      --loglevel=<option>           [default: info] logging level for this command invocation
                                    <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --server                      Restore via the sfp server, which holds the switch state and resolves
                                    review-environment auth itself (works from anywhere).
      --sfp-server-url=<value>      [default: http://localhost:3029, env: SFP_SERVER_URL] URL of the sfp server
                                    (defaults to SFP_SERVER_URL).
      --workspace=<value>           (required) Workspace whose credential switch should be reverted.

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Restore the original Named Credential endpoints that were switched by 'sfp project integrations virtualize --switch',
  using the workspace's backup.

EXAMPLES
  $ sfp project integrations restore --workspace pr-123 --server --application-token $TOKEN

  $ sfp project integrations restore --workspace pr-123 -o reviewOrg

sfp project integrations scan

Discover the project's external integrations (Named Credentials, External Credentials, External Services) across all packages and generate per-package mocks/mocks.yaml declarations for service virtualization. Provide an org to also reveal credentials that exist only in the org.

USAGE
  $ sfp project integrations scan [--json] [--scaffold-rules | --dry-run] [-o <value>] [-g <value>...] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -g, --logsgroupsymbol=<value>...  Symbol used by CICD platform to group/collapse logs in the console. Provide an
                                    opening group, and an optional closing group symbol.
  -o, --targetusername=<value>      Username or alias of the target org.
      --dry-run                     Preview what would be generated without writing mocks/mocks.yaml files.
      --loglevel=<option>           [default: info] logging level for this command invocation
                                    <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --scaffold-rules              Scaffold a <Service>.rules.yaml per service from the package's OpenAPI spec (happy +
                                    error responses) or Apex callout paths; existing rules files are never touched.

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Discover the project's external integrations (Named Credentials, External Credentials, External Services) across all
  packages and generate per-package mocks/mocks.yaml declarations for service virtualization. Provide an org to also
  reveal credentials that exist only in the org.

EXAMPLES
  $ sfp project integrations scan

  $ sfp project integrations scan --dry-run

  $ sfp project integrations scan -o myorg

  $ sfp project integrations scan --json

sfp project integrations virtualize

Activate service virtualization for a workspace: registers WireMock stubs for every service declared in mocks/mocks.yaml files, generated deterministically from OpenAPI specs (from source or the target org) with catch-all fallbacks. Re-running replaces the workspace's stubs.

USAGE
  $ sfp project integrations virtualize --workspace <value> [--json] [--wiremock-url <value> | --server] [-e <value> |
    --application-token <value>] [--sfp-server-url <value>] [--packages <value>] [--public-url <value> [--switch -o
    <value>]] [--repository <value>] [--pr-number <value>] [--branch <value>] [--environment <value>] [--watch] [--fresh
    ] [-g <value>...] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -e, --email=<value>               Email for sfp server authentication (uses the locally stored token).
  -g, --logsgroupsymbol=<value>...  Symbol used by CICD platform to group/collapse logs in the console. Provide an
                                    opening group, and an optional closing group symbol.
  -o, --targetusername=<value>      Username or alias of the target org.
      --application-token=<value>   [env: SFP_SERVER_TOKEN] Application token for sfp server authentication.
      --branch=<value>              Git branch recorded as workspace context.
      --environment=<value>         Review environment name recorded as workspace context.
      --fresh                       Force-restart the session: restore switched credentials and drop the previous
                                    workspace (including overrides and scenarios) before activating.
      --loglevel=<option>           [default: info] logging level for this command invocation
                                    <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --packages=<value>            Comma-separated package names to activate (default: every package with a
                                    mocks.yaml).
      --pr-number=<value>           Pull request number recorded as workspace context.
      --public-url=<value>          Base URL the org should call out to, when WireMock is reachable via a different
                                    address than --wiremock-url (e.g. a tunnel).
      --repository=<value>          Repository identifier (owner/repo) recorded as workspace context.
      --server                      Push the workspace to the sfp server's control plane instead of a directly reachable
                                    WireMock (the server hosts the mocks and the session becomes editable via
                                    API/UI/agents).
      --sfp-server-url=<value>      [default: http://localhost:3029, env: SFP_SERVER_URL] URL of the sfp server
                                    (defaults to SFP_SERVER_URL).
      --switch                      Rewrite each service's Named Credential in the target org to point at its mock
                                    (original endpoints are backed up for restore).
      --watch                       Stay running and re-virtualize the workspace whenever a mocks/ file is saved — edit
                                    rules and test live.
      --wiremock-url=<value>        Base URL of the WireMock instance to register stubs against.
      --workspace=<value>           (required) Logical workspace the stubs belong to (e.g. the PR or review environment
                                    id).

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Activate service virtualization for a workspace: registers WireMock stubs for every service declared in
  mocks/mocks.yaml files, generated deterministically from OpenAPI specs (from source or the target org) with catch-all
  fallbacks. Re-running replaces the workspace's stubs.

EXAMPLES
  $ sfp project integrations virtualize --workspace pr-123 --wiremock-url http://localhost:8080

  $ sfp project integrations virtualize --workspace pr-123 --wiremock-url http://localhost:8080 --packages payments,identity

  $ sfp project integrations virtualize --workspace pr-123 --server --application-token $TOKEN --sfp-server-url https://tenant.example.dev

  $ sfp project integrations virtualize --workspace pr-123 --server -o reviewOrg --switch

  $ sfp project integrations virtualize --workspace pr-123 --wiremock-url http://localhost:8080 --watch

sfp project layout-assignments extract

Extract layout assignments from an object package into a YAML file in a UI package

USAGE
  $ sfp project layout-assignments extract -s <value> -t <value> [--json] [--strip] [--force] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -s, --source-package=<value>  (required) Path of the package whose object-meta.xml files are the starting point (the
                                dependency magnet)
  -t, --target-package=<value>  (required) Path of the package that will own the generated layout-assignments.yml
                                (typically the UI package)
      --force                   Overwrite the target `mutators/layout-assignments.yml` if it already exists. Without
                                this flag, the command fails when the target file is present so hand-curated entries
                                aren't silently lost on re-run.
      --loglevel=<option>       [default: info] logging level for this command invocation
                                <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --strip                   Also remove the extracted entries from the source package's object-meta.xml files. Use
                                this as a one-shot migration; routine stripping should happen at build time via the
                                `ignoreLayoutAssignments` descriptor flag.

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Extract layout assignments from an object package into a YAML file in a UI package

  Scan the object-meta.xml files in a source package and write every strippable actionOverride (Flexipage, Visualforce,
  LightningComponent) and every recordType compactLayoutAssignment into postDeploy/layout-assignments.yml under the
  target package. The target package becomes the source of truth; pair this with the `ignoreLayoutAssignments`
  descriptor flag on the source package and `applyLayoutAssignments` on the target package to decouple the dependency
  between the two.

EXAMPLES
  $ sfp project layout-assignments extract --source-package src/core-crm --target-package src/ui-crm

  $ sfp project layout-assignments extract --source-package src/core-crm --target-package src/ui-crm --strip

  $ sfp project layout-assignments extract --source-package src/core-crm --target-package src/ui-crm --force

sfp project preflight

Prepare a Salesforce project for sfp

USAGE
  $ sfp project preflight [--json] [--repository <value>] [-e <value>] [-t <value>] [--sfp-server-url <value>] [--type
    diff|source] [-c <value>] [--validate] [--branch <value>] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -c, --configdir=<value>          [default: config] Directory containing release configs
  -e, --email=<value>              Email address for authenticated user. Ignored if --application-token is provided. Can
                                   be set via SFP_SERVER_USER env var.
  -t, --application-token=<value>  Application token for CI/CD authentication. Can be set via SFP_SERVER_TOKEN env var
                                   (CLI flags take precedence over env vars).
      --branch=<value>             Branch to register package baselines against. When omitted, the nearest tracked
                                   branch for the checked-out commit is resolved from the project configuration (never
                                   assumes the repository default branch)
      --loglevel=<option>          [default: info] logging level for this command invocation
                                   <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --repository=<value>         The repository identifier. E.g `owner/repo` for GitHub/GitLab or `org/project/repo`
                                   for Azure DevOps
      --sfp-server-url=<value>     URL of the SFP server. Can be set via SFP_SERVER_URL env var or config: sfp
                                   config:set server-url
      --type=<option>              [default: diff] Package type for new packages (diff or source)
                                   <options: diff|source>
      --validate                   Check-only mode: verify project configuration without making changes

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Prepare a Salesforce project for sfp

  Analyze and configure a vanilla SFDX project for use with sfp. Adds package names, version numbers, and release
  configs to unconfigured package directories. Use --validate to check configuration without making changes.

EXAMPLES
  $ sfp project preflight

  $ sfp project preflight --type source

  $ sfp project preflight --validate

sfp project version list

List package version state from server and sfdx-project.json

USAGE
  $ sfp project version list [--json] [--repository <value>] [-e <value>] [-t <value>] [--sfp-server-url <value>]
    [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -e, --email=<value>              Email address for authenticated user. Ignored if --application-token is provided. Can
                                   be set via SFP_SERVER_USER env var.
  -t, --application-token=<value>  Application token for CI/CD authentication. Can be set via SFP_SERVER_TOKEN env var
                                   (CLI flags take precedence over env vars).
      --loglevel=<option>          [default: info] logging level for this command invocation
                                   <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --repository=<value>         The repository identifier. E.g `owner/repo` for GitHub/GitLab or `org/project/repo`
                                   for Azure DevOps
      --sfp-server-url=<value>     URL of the SFP server. Can be set via SFP_SERVER_URL env var or config: sfp
                                   config:set server-url

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  List package version state from server and sfdx-project.json

  Shows the current version state for all packages: the version in sfdx-project.json, the latest published version
  tracked by the server, the last version intent, and when it was last updated.

EXAMPLES
  $ sfp project version list --repository flxbl-io/sf-core

sfp project version restore

Restore concrete package versions to sfdx-project.json (reverse of version seed)

USAGE
  $ sfp project version restore [--json] [--repository <value>] [-e <value>] [-t <value>] [--sfp-server-url <value>] [-p
    <value>...] [--keep-enabled] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -e, --email=<value>              Email address for authenticated user. Ignored if --application-token is provided. Can
                                   be set via SFP_SERVER_USER env var.
  -p, --packages=<value>...        Restore only the named packages (repeatable). Without this flag, all seeded packages
                                   are restored and version management is disabled in the project configuration.
  -t, --application-token=<value>  Application token for CI/CD authentication. Can be set via SFP_SERVER_TOKEN env var
                                   (CLI flags take precedence over env vars).
      --keep-enabled               Do not disable version management in the project configuration when performing a full
                                   restore
      --loglevel=<option>          [default: info] logging level for this command invocation
                                   <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --repository=<value>         The repository identifier. E.g `owner/repo` for GitHub/GitLab or `org/project/repo`
                                   for Azure DevOps
      --sfp-server-url=<value>     URL of the SFP server. Can be set via SFP_SERVER_URL env var or config: sfp
                                   config:set server-url

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Restore concrete package versions to sfdx-project.json (reverse of version seed)

  Writes the last published version (major.minor.patch + .NEXT) back into sfdx-project.json for server-managed
  (0.0.0.NEXT) packages, sourcing versions from the server with git tags as fallback, then commits and pushes the
  change. A full restore also disables version management in the server project configuration; restoring selected
  packages keeps it enabled and the restored packages simply become user-managed overrides.

EXAMPLES
  $ sfp project version restore --repository flxbl-io/sf-core

  $ sfp project version restore --repository flxbl-io/sf-core --packages core,sales-app --keep-enabled

sfp project version seed

Seed package version state on the server and strip versions from sfdx-project.json

USAGE
  $ sfp project version seed [--json] [--repository <value>] [-e <value>] [-t <value>] [--sfp-server-url <value>] [-v
    <value>] [--loglevel trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -e, --email=<value>                 Email address for authenticated user. Ignored if --application-token is provided.
                                      Can be set via SFP_SERVER_USER env var.
  -t, --application-token=<value>     Application token for CI/CD authentication. Can be set via SFP_SERVER_TOKEN env
                                      var (CLI flags take precedence over env vars).
  -v, --targetdevhubusername=<value>  DevHub alias for resolving unlocked package versions (optional, used when git tags
                                      are not available)
      --loglevel=<option>             [default: info] logging level for this command invocation
                                      <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --repository=<value>            The repository identifier. E.g `owner/repo` for GitHub/GitLab or
                                      `org/project/repo` for Azure DevOps
      --sfp-server-url=<value>        URL of the SFP server. Can be set via SFP_SERVER_URL env var or config: sfp
                                      config:set server-url

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Seed package version state on the server and strip versions from sfdx-project.json

  Resolves the current published version for each package from git tags, DevHub, or sfdx-project.json, records them on
  the server, strips version numbers from sfdx-project.json (set to 0.0.0.NEXT), creates -BASELINED tags to prevent full
  rebuilds, and commits + pushes the changes.

EXAMPLES
  $ sfp project version seed --devhub myDevHub --repository flxbl-io/sf-core

  $ sfp project version seed --repository flxbl-io/sf-core

sfp project version suggest

Analyze a pull request with AI and suggest (or apply) server-managed package version intents

USAGE
  $ sfp project version suggest [--json] [--repository <value>] [-e <value>] [-t <value>] [--sfp-server-url <value>]
    [--pr-number <value>] [--base-ref <value>] [--head-ref <value>] [--changed-files <value>] [--provider <value>]
    [--opencode-server <value>] [--apply] [--loglevel
    trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL]

FLAGS
  -e, --email=<value>              Email address for authenticated user. Ignored if --application-token is provided. Can
                                   be set via SFP_SERVER_USER env var.
  -t, --application-token=<value>  Application token for CI/CD authentication. Can be set via SFP_SERVER_TOKEN env var
                                   (CLI flags take precedence over env vars).
      --apply                      Post or edit the sticky /version comment on the PR
      --base-ref=<value>           Base commit/branch for the git diff (e.g. origin/main)
      --changed-files=<value>      Comma-separated changed files (overrides the git diff)
      --head-ref=<value>           [default: HEAD] Head commit/branch for the git diff
      --loglevel=<option>          [default: info] logging level for this command invocation
                                   <options: trace|debug|info|warn|error|fatal|TRACE|DEBUG|INFO|WARN|ERROR|FATAL>
      --opencode-server=<value>    External opencode server URL (skip local spawn)
      --pr-number=<value>          Pull request number (required to --apply the sticky comment)
      --provider=<value>           AI provider override (e.g. anthropic). Defaults to the project/default integration.
      --repository=<value>         The repository identifier. E.g `owner/repo` for GitHub/GitLab or `org/project/repo`
                                   for Azure DevOps
      --sfp-server-url=<value>     URL of the SFP server. Can be set via SFP_SERVER_URL env var or config: sfp
                                   config:set server-url

GLOBAL FLAGS
  --json  Format output as json.

DESCRIPTION
  Analyze a pull request with AI and suggest (or apply) server-managed package version intents

  codev Package Version Assessment (DR-019). Reads the changed files, scores each impacted server-managed (0.0.0.NEXT)
  package, and prints a /version directive. With --apply, posts or edits a single sticky /version comment on the PR
  (authored by the app) that the build reads as the AI tier — a human /version comment always overrides it. Advisory:
  never fails the run.

EXAMPLES
  $ sfp project version suggest --repository flxbl-io/sf-core --pr-number 42 --base-ref origin/main

  $ sfp project version suggest --repository flxbl-io/sf-core --pr-number 42 --base-ref origin/main --apply

On this page