dversedev

Reference

CLI commands

All 18 of them. The CLI talks to the Dataverse Web API directly — no Windows dependency, nothing to install on a server, and no Microsoft.PowerPlatform.Dataverse.Client in the way.

Choosing an environment

Every command that touches Dataverse accepts --env. Resolution order is fixed, and dverse never prompts — a non-interactive run with nothing resolved is a hard error, not a guess.

--env flag → DVERSE_ENV → dataverse.local.yaml default → dataverse.yaml default

dataverse.local.yaml is gitignored, which is how each developer points at their own sandbox without touching the committed file.

Commands

dverse version

Print the installed tool version and the commit it was built from.

dverse version

dverse auth login

Interactive device-code sign-in. Prints a URL and a code; every later run is silent.

dverse auth login [--env <name>]
--env <name> Environment from dataverse.yaml to target.

Tokens are cached per organization under ~/.dverse, keyed by host. Never in the repository.

dverse auth logout

Remove the persisted sign-in for an organization, or for all of them.

dverse auth logout [--env <name> | --all]
--env <name> Environment from dataverse.yaml to target.
--all Remove every persisted sign-in, not just this environment's.

dverse auth list

Show persisted sign-ins — organization and account.

dverse auth list

dverse whoami

Verify the connection and print the signed-in user and organization.

dverse whoami [--env <name>]
--env <name> Environment from dataverse.yaml to target.

The cheapest way to confirm auth and environment resolution are both working.

dverse model sync

Refresh dataverse.snapshot.json from live metadata.

dverse model sync [--entities a,b] [--env <name>]
--entities <a,b,…> One-off entity list; otherwise the entities come from model: entities: in dataverse.yaml.
--env <name> Environment from dataverse.yaml to target.

Optional in normal use — plan and apply refresh the snapshot themselves and print a schema diff. The file is deterministic (sorted, no timestamps) so it produces clean git diffs. Commit it.

dverse plan

Diff desired registration against the live environment. Writes nothing.

dverse plan [--json] [--no-prune[=kinds]] [--no-build] [--all] [--assembly <dll>] [--package [--package-id <id>]] [--env <name>]
--json Machine-readable plan on stdout instead of the rendered block.
--no-prune[=kinds] Keep environment-only components instead of deleting them — every kind, or just the named ones: steps, apis, webresources, commands.
--no-build Diff the existing build output; do not build first.
--all Widen to the full configured scope from anywhere in the repo.
--assembly <dll> Diff exactly this built assembly instead of discovering projects.
--package Treat the deployment as a plugin package (nupkg with dependent assemblies).
--package-id <id> Package unique id; implies --package. Defaults to the assembly name.
--env <name> Environment from dataverse.yaml to target.

Exit codes 0 = no changes · 2 = changes pending · 1 = error

Without --assembly the scope is what lives at or below the current directory: the repository root covers everything configured, a project directory covers just that project.

dverse apply

Build, diff, and write only the deltas to the environment.

dverse apply [--no-prune[=kinds]] [--no-build] [--no-batch] [--no-bump] [--all] [--assembly <dll>] [--package [--package-id <id>]] [--env <name>]
--no-prune[=kinds] Keep environment-only components instead of deleting them. A kind you declare nothing for is never pruned anyway.
--no-build Deploy the existing build output; do not build first.
--no-batch One request per write instead of parallel $batch changesets.
--no-bump Skip the automatic source-version increment on content changes.
--all Widen to the full configured scope from anywhere in the repo.
--assembly <dll> Deploy exactly this built assembly.
--package Deploy as a plugin package. Inferred from the project's <DversePluginPackage> / <DversePackageId> when omitted.
--package-id <id> Package unique id; implies --package.
--env <name> Environment from dataverse.yaml to target.

The assembly uploads only when its sha256 changed. Version bumps are automatic: when content changed but the version did not increase, apply bumps the source (AssemblyVersion revision, or a PCF manifest patch), rebuilds once, and re-plans — commit the bumped files with your change. Everything converges in dependency order and ends in exactly one PublishXml.

dverse adopt

Scaffold [Step] attributes from a live assembly's existing registration. Read-only.

dverse adopt --assembly <name> [--env <name>] [--out <file.cs>] [--namespace <ns>] [--force]
--assembly <name> Name of the registered plugin assembly to read.
--out <file.cs> Write to a file. Default: print to stdout.
--namespace <ns> Namespace for the generated partial classes.
--force Overwrite an existing output file.
--env <name> Environment from dataverse.yaml to target.

Ids are pinned in the generated attributes, so adopting an existing registration and then running plan reports no changes — the entry point for moving an existing project onto dverse.

dverse schema adopt

Emit schema YAML from live metadata. Read-only.

dverse schema adopt --entities <a,b,…> [--out <schema/core.yaml>] [--env <name>]
--entities <a,b,…> Tables to capture.
--out <file> Destination YAML file. Default: stdout.
--env <name> Environment from dataverse.yaml to target.

Full table declarations for prefixed tables; an extensions: block (prefixed columns and keys only) for standard tables, so the host table is never claimed. adopt → plan exits 0.

dverse forms pull

Capture designer-authored forms into the configured forms: sets as committed files. Read-only.

dverse forms pull [--entities <a,b,…>] [--env <name>] [--force]
--entities <a,b,…> Tables to pull. Default: the folders already present.
--force Overwrite local files that differ.
--env <name> Environment from dataverse.yaml to target.

pull → plan exits 0. Unsafe file names are skipped loudly rather than mangled.

dverse views pull

Capture saved queries into the configured views: sets as committed files. Read-only.

dverse views pull [--entities <a,b,…>] [--env <name>] [--force]
--entities <a,b,…> Tables to pull. Default: the folders already present.
--force Overwrite local files that differ.
--env <name> Environment from dataverse.yaml to target.

dverse commands pull

Capture the modern commands each configured commands: set's prefix manages into committed YAML. Read-only.

dverse commands pull [--env <name>] [--set <path>] [--force]
--set <path> Pull only the set at this path.
--force Overwrite local files that differ.
--env <name> Environment from dataverse.yaml to target.

Commands the platform will not let dverse author are skipped with the reason — and are never pruned either.

dverse webresources pull

Download each configured set's environment web resources into its local path. Read-only.

dverse webresources pull [--env <name>] [--set <path>] [--force]
--set <path> Pull only the set at this path.
--force Overwrite differing local files.
--env <name> Environment from dataverse.yaml to target.

Resources whose unique names do not follow the prefix convention get a ready-to-paste map: snippet, so legacy names can be managed without renaming them and breaking every form reference.

dverse sign init

Create a self-signed code-signing certificate and print the signing: block to add.

dverse sign init [--out certs/plugins.pfx] [--subject "CN=…"] [--years 3] [--password-env DVERSE_SIGN_PASSWORD] [--force]
--out <file.pfx> Certificate path. Default: certs/plugins.pfx.
--subject "CN=…" Certificate subject.
--years <n> Validity in years. Default: 3.
--password-env <VAR> Environment variable holding the certificate password.
--force Overwrite an existing certificate.

Authenticode, not the strong-name key — they are different things. Managed identity requires an Authenticode signature; Dataverse refuses the bind without one. Signing is deterministic (no signing time, no timestamp) so an unchanged assembly still skips its upload. Self-signed is for development.

dverse sign info

Show the configured certificate and the exact Azure federated credential to create for it.

dverse sign info [--env <name>]
--env <name> Environment from dataverse.yaml to target.

Prints the issuer, audience and subject identifier — the three values the Azure app registration needs.

dverse pcf init

Scaffold a PCF control project in the standard pcf-scripts layout.

dverse pcf init --name <ControlName> [--namespace <ns>] [--template field|dataset] [--path <dir>] [--install]
--name <ControlName> Control name.
--namespace <ns> Namespace. Defaults to the control name.
--template field|dataset Control template.
--path <dir> Destination. Defaults to pcfcontrols/<name>.
--install Run npm install after scaffolding.

Deployed by plan and apply once the project is listed under pcf: in dataverse.yaml.

dverse --help

Print the usage summary. Also the default when no arguments are given.

dverse --help