Configuration
dinio keeps connection settings in profiles — a name, a URL and an API key. Use one
profile per account or environment, and pick one per command with --profile.
Profiles
Section titled “Profiles”dinio profile set-key prod # store the key (hidden prompt or stdin)dinio profile set prod --core-url https://api-dinio.bitelex.comdinio profile set prod --email me@example.com # optional, the user the personal key belongs todinio profile listdinio profile show proddinio profile use prod # make it the defaultdinio profile rm old| Command | |
|---|---|
profile set NAME [--core-url URL] [--email E | --clear-email] |
Create or update a profile. Without --core-url the default https://api-dinio.bitelex.com is used. |
profile set-key NAME |
Store the API key. Read hidden from the terminal, or from the first line of stdin. Warns about a key without the du_/dz_ prefix, which Dinio would reject. |
profile list |
All profiles; the default is marked *. |
profile show [NAME] |
One profile (default: the active one), with the key masked as …a1b2. |
profile use NAME |
Make NAME the default profile. |
profile rm NAME |
Delete a profile and its key. |
The first profile you create becomes the default. Without any profile, the CLI uses one
called default.
The key is never accepted as an argument to profile set-key, so it never lands in your shell
history. To store it from a secret manager, pipe it in:
pass show dinio/prod | dinio profile set-key prod| File | Holds |
|---|---|
config.toml |
Profiles: URL, email, the default profile. Safe to share. |
credentials.toml |
API keys per profile. Created with mode 0600. |
Both live in the config directory: ~/.config/dinio on Linux, the platform’s config
directory on macOS and Windows (dinio profile show prints it). DINIO_CONFIG_DIR overrides
it.
default_profile = "prod"
[profiles.prod]url = "https://api-dinio.bitelex.com"email = "me@example.com"Environment and flags
Section titled “Environment and flags”Settings are resolved in this order, first match wins:
- the flag:
--profile,--url,--api-key - the environment:
DINIO_PROFILE,DINIO_API_URL,DINIO_API_KEY - the profile from
config.toml/credentials.toml - the default URL
In CI, set DINIO_API_KEY (and DINIO_API_URL if needed) as secrets and skip profiles
entirely:
DINIO_API_KEY=$ZONE_KEY dinio record add example.com _acme-challenge TXT "$TOKEN" --ttl 60Global options
Section titled “Global options”These work with every command, before or after it:
| Option | |
|---|---|
--profile NAME |
Use this profile. |
--url URL |
Use this API URL for this call. |
--api-key KEY |
Use this key for this call. |
-o, --output table|json |
Output format, see Output. |
-y, --yes |
Don’t ask for confirmation on destructive commands. |
Check a profile
Section titled “Check a profile”dinio auth statusdinio --profile staging auth statusShows the profile, the URL, whether Dinio is reachable, and whether the key works and which
kind it is (personal or zone). Its exit code is the outcome — 0 when the key works, 3 when it is missing or rejected, 7 when
Dinio is unreachable — so it doubles as a check in scripts.