DevOp.DK.Plus.Cli is a .NET 10 global tool installed as devop-dk.
dotnet tool install --global DevOp.DK.Plus.Cli
dotnet tool update --global DevOp.DK.Plus.Cli
devop-dk --version
The recommended login flow reads the token from a hidden terminal prompt, verifies it with a bounded read-only request, and stores it separately from ordinary configuration:
devop-dk login
devop-dk connection test
The explicit devop-dk login <token> form is supported, but arguments can appear in shell history and process listings. Prefer the hidden prompt. Use --skip-verify only when the API cannot be reached during setup. Remove the stored token with devop-dk logout.
For ephemeral or managed-secret environments, use an environment variable or mounted secret:
export DKPLUS_API_TOKEN="..."
export DKPLUS_API_TOKEN_FILE="/run/secrets/dkplus-token"
Credential precedence is DKPLUS_API_TOKEN, DKPLUS_API_TOKEN_FILE, then the locally stored login token. The stored token is permission-protected plaintext, not encrypted. It is written atomically and is readable only by the current user: mode 600 on Linux and macOS, and on Windows an owner-only access control list (no inherited entries; only the current user has access). If those permissions cannot be applied, the login fails and any earlier token file is kept unchanged.
token next to config.json, in $XDG_CONFIG_HOME/DevOp/devop-dk/ (usually ~/.config/DevOp/devop-dk/).%LOCALAPPDATA%\DevOp\devop-dk\token. This folder does not roam, so the token does not travel with a roaming domain profile; config.json stays in %APPDATA%\DevOp\devop-dk\. A token stored by an earlier version in %APPDATA%\DevOp\devop-dk\token is moved to the new folder, with the new permissions, the first time a command reads the stored login. If the move fails, the old file is used and left in place. devop-dk logout removes the token at both locations. Update the CLI and the PowerShell module together: the first read by a new version moves the token, and a 0.4.2 CLI or module reads only the roaming %APPDATA% copy, so it no longer finds the login.DKPLUS_CONFIG_HOME set, the token and config.json are both in that folder on every system.On Windows, writes of config.json and the token retry briefly (up to five times over about half a second) when another process, for example an antivirus scan or another devop-dk or PowerShell session, holds the file.
devop-dk config show
devop-dk config path
devop-dk config set baseUrl https://api.dkplus.is
devop-dk config set pageSize 100
devop-dk config set retryCount 3
devop-dk config set timeoutSeconds 30
devop-dk config set logLevel Warning
# Default salesperson for the sales create commands; an empty value removes it:
devop-dk config set salesPerson S-7
devop-dk config set salesPerson ""
DKPLUS_CONFIG_HOME overrides the configuration directory. Environment overrides are available as DKPLUS_BASE_URL, DKPLUS_ACCEPT_LANGUAGE, DKPLUS_PAGE_SIZE, DKPLUS_RETRY_COUNT, DKPLUS_TIMEOUT_SECONDS, and DKPLUS_LOG_LEVEL.
salesPerson (also accepted as sales-person) is the salesperson that sales invoice create and sales order|quote|recurring create use when --sales-person is not given. An explicit --sales-person wins; with --file, the document's own SalesPerson wins and the setting only fills a document that has none. Without any of them the member is not sent and DK Plus uses the sales person of the employee linked to the API user. There is no environment variable for it.
The defaults are three retries for eligible safe requests and a 30-second total operation timeout. Set retryCount to zero when a command must not retry. Mutating requests are not retried automatically.
devop-dk config language is-IS
devop-dk config set language icelandic
is, is-IS, icelandic, íslenska, and islenska select Icelandic. english selects English. The CLI applies the selected culture to interactive labels, numbers, and dates while JSON stays culture-independent. Icelandic requests send is-IS, en;q=0.8, retaining English as the fallback.
Logging is quiet by default. Enable it for one invocation or persist a level:
devop-dk --verbose connection test
DKPLUS_LOG_LEVEL=Debug devop-dk connection test
devop-dk config set logLevel Information
devop-dk config set logLevel None
--verbose is a global option and can appear before or after the command. There is intentionally no -v alias because generic table filters already use -v.
Next: Output, columns, and files or Command reference.