Account management commands
Account commands take the action as a flag. Run dg keys --help, dg projects --help, or dg members --help for the full set.
Projects
Set a project first
Key, member, usage, billing, and request commands act on one project: run dg projects --list, then dg projects --set-default <project-id>, or export DEEPGRAM_PROJECT_ID. Without one they exit 1 with Project ID is required for this command. To target another project for one command, pass -p (--project-id) to dg keys, dg members, dg usage, dg billing, or dg requests.
List projects
Show, switch, and create projects
API keys
List and show keys
Create Key
--scopes takes comma-separated scope names and defaults to member. See Working with roles & API scopes for what each scope grants. Add --dry-run to preview a create without making the key.
--ttl sets the new key’s time to live in seconds; --expiration-date takes an ISO date. A time-limited key suits a CI job:
Delete key
Without --yes, a non-interactive session (CI, an agent, a pipe) exits 1 with Refusing to delete key ... without confirmation. Pass --yes to confirm.; on a terminal, the CLI asks first.
Use --dry-run to preview:
Team Members
List members
If dg members --list fails with validation errors for MemberInfo, list members through the API: dg api /v1/projects/<project-id>/members.
Invite Member
--scope takes a role, for example member (the default) or admin. Available scopes: owner, admin, member. See Working with roles & API scopes. Add --dry-run to preview an invite without sending it.
Remove Member
Usage
View usage
dg usage with no dates covers the current month. Replace each YYYY-MM-DD with a start and end date to choose a range; -s (--start-date) and -e (--end-date) also take ISO datetimes.
Export usage
The JSON holds the per-period buckets alongside the totals.
Billing
View balance
Billing breakdown
--grouping takes accessor, deployment, line_item, or tags.
Request history
dg requests lists the project’s API requests, 10 per page by default. You can obtain up to 90 days of request logs; see Logs & Usage Data.
Models
dg models lists the models your key can use, with each model’s canonical name, ID, languages, and architecture, and flags deprecated models.
-t is the short form of --type, which takes stt or tts. dg models --type tts and dg speak --list-voices list the Aura-2 voices. For Flux TTS voices, see Flux TTS Voices & Languages.
Direct API Access
dg api calls any Deepgram API endpoint with your stored credentials. The endpoint is positional; -X sets the method and -f sets body fields:
--jq EXPRapplies a jq filter to the response and needsjqon your PATH, for exampledg api /v1/projects --jq '.projects[0].name'.--rawprints the response without formatting.-H(--header) adds a header as'Key: Value'.--input FILEreads the request body from a file, or from stdin with--input -.-f key=valuesends a string field, and-f key:=jsonsends raw JSON, for example-f scopes:='["member"]'.
-o works before the subcommand (dg -o json usage) or after it on most commands (dg usage -o json). On dg speak, -o/--output after the subcommand still sets the output file path but is deprecated; use --out-file instead. On dg plugin and dg skills subcommands, put -o before the subcommand.