@nuance-mix/mix-cli
v2.6.3
Published
Mix Command Line Interface
Downloads
136
Readme
mix-cli
mix-cli
is a command line tool that provides access to the Mix V4 API.
- Installing mix-cli
- Migrating to version 2 of mix-cli
- Configuring mix-cli
- Retrieving the access token
- Choosing a command output format
- Sorting and filtering
- Autocompleting commands
- Providing defaults for often-used command arguments
- Using the mix-cli client code
- Learning more about Mix
- Contributing
- Commands
Installing mix-cli
To install mix-cli
, simply type:
npm install -g @nuance-mix/mix-cli
mix-cli
requires Node.js version 14 or more recent.
Migrating to version 2 of mix-cli
mix-cli
introduces a few breaking changes. See the migration documentation
as those changes could disrupt automated workflows.
Configuring mix-cli
In order to configure mix-cli
, you need service credentials that give you
access to the Mix V4 API. These credentials can be found under your user profile
in the Mix.dashboard Tool.
To configure mix-cli
, simply type:
mix init
The init
command asks for a few pieces of configuration data. Defaults
are provided for the Mix production system in the US geography. Service
credentials are requested last.
The mix-cli
configuration is stored under ~/.config/@nuance-mix/mix-cli/
on Unix and
macOS systems and under %LOCALAPPDATA%\@nuance-mix\mix-cli\
on Windows systems. The
configuration is stored in a file named "config.json" that is accessible only to
the user who executed the init
command.
Using mix-cli with multiple Mix systems
When you run the init
command, mix-cli
detects the name of the Mix system by parsing
the hostname provided for the Mix API server. It suggests this name as an answer
when it prompts you for the "Mix system name".
Say you have initially run the init
command to configure mix-cli for the "us" Mix system.
You can run the init
command a second time to configure the "eu" system using the relevant
hostnames. mix-cli
stores the configuration of both systems.
You can then type mix auth --system us
to switch to and authenticate with the "us" Mix
system. Similarly, typing mix auth --system eu
does the same but with the "eu" Mix system.
mix-cli
remembers the last Mix system it authenticated with so using mix auth
with the
system
flag is only needed when switching to a different Mix system.
Finally, all mix-cli
commands complete their human-readable output by reporting
which Mix system the command was executed against.
Overriding the central configuration
Configuration elements can be overriden by using the following environment variables:
- MIX_API_SERVER: the Mix V4 API server fully-qualified domain name
- MIX_AUTH_SERVER: the Mix Authentication server fully-qualified domain name
- MIX_CLIENT_ID: your service credentials client ID
- MIX_CLIENT_SECRET: your service credentials client secret
- MIX_SCOPE: OAuth scope used to access the Mix V4 API
- MIX_TENANT: your Mix tenant
It is also possible to configure these environment variables using a .env
file.
mix-cli
looks for the .env
file in the current working directory when it
starts up.
Configuration values are read in the following order, where the last value assignment wins:
- central configuration file
.env
file in current working directory- environment variables already set in the execution environment
Experimental support for Device Code authentication flow
Experimental support for the Device Code authorization flow has been added to mix-cli
.
You can configure a Mix system for this authorization flow by answering "device" to the
"Authentication flow?" question that now comes first when running the init
command.
Retrieving the access token
With the relevant configuration in place, you first need to retrieve an access token before using any of the other cli commands. Simply type:
mix auth
mix-cli
stores the access token in a file named "access-token" in the same
directory it stores its central configuration. Like the configuration file,
the access token file is only accessible to the user who executed the auth
command.
Access tokens expire after 15 minutes. mix-cli
takes care of refreshing
the access token.
Choosing a command output format
Some commands offer up to 4 different types of output format.
- The human-readable format is the default output format and simply outputs text or tabular data.
- The "json" format provides the raw data returned by the remote server in JSON format.
- The "yaml" format provides the raw data returned by the remote server in YAML format.
- The "csv" output format provides multiple rows of comma-separated values with a header row and is meant to be consumed by spreadsheet applications.
Select the JSON or YAML output format to get the actual data returned the remote server. Note that some commands can only display a subset of the data available when "csv" output is chosen.
Sorting and filtering
Some commands offer the ability to filter and/or sort the output data. The filtering and sorting are done by the remote server when the functionality is supported by the endpoint. Otherwise, filtering and sorting are performed locally in mix-cli.
Autocompleting commands
Thanks to the oclif/plugin-autocomplete
plugin, commands can be autocompleted when mix-cli is used with the bash or zsh
shell. Type mix autocomplete bash
or mix autocomplete zsh
, follow the
instructions and then launch a new shell. You will then get autocompletion of
mix-cli commands by pressing the tab key.
Type mix autocomplete --refresh-cache
to rebuild the autocompletion cache, which
is useful when upgrading to a version of mix-cli that introduces new commands.
Finally, type mix autocomplete --help
to get help on using the autocomplete
setup command.
Providing defaults for often-used command arguments
Many commands require a project ID, organization ID and/or locale. mix-cli
will
default to the value contained in the following environment variables, if they
exist, or if they are provided in the .env
file:
- MIX_LOCALE: gets used as default for
--locale
- MIX_ORGANIZATION: gets used as default for
--organization
. - MIX_PROJECT: gets used as default for
--project
.
Using the mix-cli client code
The client code used by mix-cli
to communicate with the Mix V4 API can be
reused to write other applications that make use of the Mix V4 API.
You can view the API client documentation and there
is a short example in the examples
directory.
Please consult the Mix V4 API documentation
for additional information.
Learning more about Mix
Please visit the Mix product page and Mix documentation site to learn more about Mix.
Contributing
See our Contribution Guidelines.
Commands
mix app-configs:create
mix app-configs:deploy
mix app-configs:destroy
mix app-configs:export
mix app-configs:get
mix app-configs:list
mix app-configs:undeploy
mix app-configs:upgrade
mix app-credentials:list
mix applications:get
mix applications:list
mix auth
mix autocomplete [SHELL]
mix bot-configs:list
mix bot-credentials:list
mix bot-interfaces:export
mix bot-interfaces:get
mix bots:list
mix builds:destroy
mix builds:export
mix builds:get
mix builds:latest
mix builds:list
mix channels:activate
mix channels:configure
mix channels:create
mix channels:deactivate
mix channels:rename
mix data-hosts:latest
mix data-hosts:list
mix data-types:list
mix deployment-flows:list
mix engine-packs:list
mix entities:configure
mix entities:convert
mix entities:create
mix entities:destroy
mix entities:get
mix entities:list
mix entities:rename
mix entity-types:list
mix env-configs:configure
mix env-configs:destroy
mix env-configs:list
mix environments:list
mix geographies:list
mix grammars:export
mix grammars:replace
mix help [COMMANDS]
mix init
mix intents:create
mix intents:destroy
mix intents:get
mix intents:list
mix intents:rename
mix jobs:cancel
mix jobs:get
mix jobs:list
mix language-topics:list
mix literals:export
mix literals:import
mix locks:get
mix locks:list
mix ontology:export
mix ontology:import
mix organizations:list
mix projects:build
mix projects:configure
mix projects:create
mix projects:destroy
mix projects:export
mix projects:get
mix projects:list
mix projects:lock
mix projects:rename
mix projects:replace
mix projects:unlock
mix samples:export
mix samples:import
mix system:list
mix system:version
mix systems:list
mix voices:list
mix app-configs:create
create an application configuration
USAGE
$ mix app-configs:create -D <value> -M <value> -P <value> -T <value> [--json | | --yaml] [--use-project-data-hosts]
[--with-build-type asr|dialog|nlu] [--with-locale <value>]
FLAGS
-D, --deployment-flow=<value> (required) deployment flow ID
-M, --mix-app=<value> (required) Mix application ID
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
-T, --tag=<value> (required) context tag
--json output raw data in JSON format
--use-project-data-hosts use data hosts defined in project
--with-build-type=<option>... build types to include
<options: asr|dialog|nlu>
--with-locale=<value>... locale code; use format 'aa-AA'
--yaml output raw data in YAML format
DESCRIPTION
create an application configuration
Use this command to create an application configuration. The Mix Application ID
can be looked up using the applications:list command. The deployment flow ID
can be retrieved using the deployment-flows:list command. The context tag
should be unique.
EXAMPLES
Create an application configuration using latest builds from project without data hosts information
$ mix app-configs:create -M 233 -D 32 -T AC_20211028 -P 1922
Create an application configuration using latest builds from project but only for build type ASR
and locale en-US, without data hosts information
$ mix app-configs:create -M 233 -D 32 -T AC_20211028 -P 1922 --with-locale en-US --with-build-type asr
Create an application configuration using latest builds from project including data hosts defined in project
$ mix app-configs:create -M 233 -D 32 -T AC_20211028 -P 1922 --use-project-data-hosts
See code: src/commands/app-configs/create.ts
mix app-configs:deploy
deploy an application configuration
USAGE
$ mix app-configs:deploy -C <value> [--env-geo <value>] [--json | | --yaml]
FLAGS
-C, --config=<value> (required) application configuration ID
--env-geo=<value>... environment-geography ID
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
deploy an application configuration
Use this command to deploy an application configuration. The configuration ID
can be retrieved using the app-configs:list command.
A specific environment-geography can be specified using the 'env-geo' flag.
If none is specified, the application configuration will get deployed to the
next environment-geography defined in the deployment flow specified when
the application configuration was created.
EXAMPLES
Deploy an application configuration to the next environment-geography
$ mix app-configs:deploy -C 88
Deploy an application configuration to a specific environment-geography
$ mix app-configs:deploy -C 88 --env-geo 233
See code: src/commands/app-configs/deploy.ts
mix app-configs:destroy
destroy an application configuration
USAGE
$ mix app-configs:destroy -C <value> [-c <value>] [--json | | --yaml]
FLAGS
-C, --config=<value> (required) application configuration ID
-c, --confirm=<value> skip confirmation prompt by pre-supplying value
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
destroy an application configuration
Use this command to permanently delete an application configuration.
The deletion needs to be confirmed by re-typing the application configuration
ID when prompted. It can also be pre-confirmed by using the 'confirm' flag.
EXAMPLES
$ mix app-configs:destroy -C 3404
See code: src/commands/app-configs/destroy.ts
mix app-configs:export
export an application configuration
USAGE
$ mix app-configs:export -C <value> -R <value> [-f <value>] [--overwrite]
FLAGS
-C, --config=<value> (required) application configuration ID
-R, --runtime-app=<value> (required) fully-qualified runtime application ID
-f, --filepath=<value> output file path (defaults to "app-config-<configid>.zip")
--overwrite overwrite output file if it exists
DESCRIPTION
export an application configuration
Use this command to export an application configuration. The configuration ID
can be retrieved using the app-configs:list command. The runtime application ID
can be found with the app-credentials:list command.
The contents of the exported zip file depend on the role you have been granted
on the Mix platform.
EXAMPLES
Export an application configuration
$ mix app-configs:export -C 2269 -R NMDPTRIAL_alex_smith_company_com_20190919T190532 --overwrite
See code: src/commands/app-configs/export.ts
mix app-configs:get
get details about an application configuration
USAGE
$ mix app-configs:get -C <value> [--columns <value> ] [--filter <value> | [--json | --csv | --yaml] | ]
[--no-header | | ] [--no-truncate | | | ] [--sort <value>]
FLAGS
-C, --config=<value> (required) application configuration ID
--columns=<value> only show provided columns (comma-separated) (with 'csv' flag only)
--csv output to csv format
--filter=<value> filter property by partial string matching, ex: name=foo
--json output raw data in JSON format
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--sort=<value> property to sort by (prepend '-' for descending)
--yaml output raw data in YAML format
DESCRIPTION
get details about an application configuration
Use this command to get details about a particular application configuration.
The configuration ID can be retrieved using the app-configs:list command.
Use the 'json' or 'yaml' flag to get the full details as the human-readable
output is brief.
EXAMPLES
$ mix app-configs:get -C 3404
See code: src/commands/app-configs/get.ts
mix app-configs:list
list application configurations for a Mix application
USAGE
$ mix app-configs:list -M <value> [--exclude-overrides] [--live-only] [--columns <value> | | [--json | --csv |
--yaml] | ] [--filter <value> | | ] [--no-header | | ] [--no-truncate | | | ] [--sort <value>]
[--with-runtime-app <value>] [--with-tag <value>]
FLAGS
-M, --mix-app=<value> (required) Mix application ID
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--exclude-overrides exclude application configurations that are overridden
--filter=<value> filter property by partial string matching, ex: name=foo
--json output raw data in JSON format
--live-only include only the application configurations that are currently deployed
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--sort=<value> property to sort by (prepend '-' for descending)
--with-runtime-app=<value> filter results by fully-qualified runtime app ID
--with-tag=<value> filter results by context tag
--yaml output raw data in YAML format
DESCRIPTION
list application configurations for a Mix application
Use this command to list the application configurations in an organization.
The organization ID can be retrieved using the organizations:list command.
A number of flags can be used to constrain the returned results. The runtime
application IDs can be retrieved using the app-credentials:list command.
EXAMPLES
$ mix app-configs:list -M 164 --with-runtime-app NMDPTRIAL_alex_smith_company_com_20190919T190532
See code: src/commands/app-configs/list.ts
mix app-configs:undeploy
undeploy an application configuration
USAGE
$ mix app-configs:undeploy -C <value> [--env-geo <value>] [--json | | --yaml]
FLAGS
-C, --config=<value> (required) application configuration ID
--env-geo=<value>... environment-geography ID
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
undeploy an application configuration
Use this command to undeploy a specific application configuration.
The configuration ID can be retrieved using the app-configs:list command.
The environment-geographies relevant to an application configuration can be
found in the JSON output of the app-configs:get command.
EXAMPLES
Undeploy an application configuration to the next environment-geography
$ mix app-configs:undeploy -C 88
Undeploy an application configuration from a specific environment-geography
$ mix app-configs:undeploy -C 88 --env-geo 233
See code: src/commands/app-configs/undeploy.ts
mix app-configs:upgrade
update an application configuration to latest build versions
USAGE
$ mix app-configs:upgrade -C <value> [--json | | --yaml] [--use-project-data-hosts]
FLAGS
-C, --config=<value> (required) application configuration ID
--json output raw data in JSON format
--use-project-data-hosts use data hosts defined in project
--yaml output raw data in YAML format
DESCRIPTION
update an application configuration to latest build versions
Use this command to upgrade an application configuration to the latest build
versions. The configuration ID can be retrieved using the app-configs:list command.
EXAMPLES
Upgrade an application configuration using latest builds from project without data hosts information
$ mix app-configs:upgrade -C 334
Upgrade an application configuration using latest builds from project including data hosts defined in project
$ mix app-configs:upgrade -C 334 --use-project-data-hosts
See code: src/commands/app-configs/upgrade.ts
mix app-credentials:list
list application credentials for a Mix application
USAGE
$ mix app-credentials:list -M <value> [--with-geo-name <value>] [--full] [--json | | --yaml]
FLAGS
-M, --mix-app=<value> (required) Mix application ID
--full show all application credentials details
--json output raw data in JSON format
--with-geo-name=<value> geography name
--yaml output raw data in YAML format
DESCRIPTION
list application credentials for a Mix application
Use this command to list the application credentials for a Mix application.
This lets you retrieve the runtime application ID that is required in other
commands.
EXAMPLES
List application credentials for a Mix application
$ mix app-credentials:list -M 22
List application credentials for a Mix application that match a specific environment-geography
$ mix app-credentials:list -M 22 --with-geo-name "Production US"
See code: src/commands/app-credentials/list.ts
mix applications:get
get details about a Mix application
USAGE
$ mix applications:get -M <value> [--columns <value> | | [--json | | --yaml] | ] [--filter <value> | | ]
[--no-header | | ] [--no-truncate | | | ] [--sort <value>]
FLAGS
-M, --mix-app=<value> (required) Mix application ID
--columns=<value> only show provided columns (comma-separated)
--filter=<value> filter property by partial string matching, ex: name=foo
--json output raw data in JSON format
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--sort=<value> property to sort by (prepend '-' for descending)
--yaml output raw data in YAML format
DESCRIPTION
get details about a Mix application
Use this command to get details about a particular Mix application.
EXAMPLES
$ mix applications:get -M 94
See code: src/commands/applications/get.ts
mix applications:list
list Mix applications
USAGE
$ mix applications:list [--limit <value>] [--offset <value>] [-O <value>] [--columns <value> | | [--json | --csv |
--yaml] | ] [--filter <value> | | ] [--no-header | | ] [--no-truncate | | | ] [--sort <value>] [--live-only
--full] [--omit-overridden ] [--with-name <value>] [--with-runtime-app <value>]
FLAGS
-O, --organization=<value> organization ID
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--filter=<value> filter property by partial string matching, ex: name=foo
--full show all application details (permissions allowing)
--json output raw data in JSON format
--limit=<value> limit maximum results returned (defaults to Mix API behavior)
--live-only include only the application configurations that are currently deployed
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--offset=<value> to exclude e.g., the first 10 (sorted) results, set --offset=10
--omit-overridden omit application configurations that are overridden
--sort=<value> property to sort by (prepend '-' for descending)
--with-name=<value> filter results by Mix application name (case-sensitive)
--with-runtime-app=<value> filter results by fully-qualified runtime app ID
--yaml output raw data in YAML format
DESCRIPTION
list Mix applications
Use this command to list Mix applications.
A number of flags can be used to constrain the returned results.
EXAMPLES
List Mix applications to which you have access, across all organizations
$ mix applications:list
List Mix applications that are part of a particular organization
$ mix applications:list -O 64
See code: src/commands/applications/list.ts
mix auth
obtain a Mix access token
USAGE
$ mix auth [-S <value>]
FLAGS
-S, --system=<value> Mix system
DESCRIPTION
obtain a Mix access token
Use this command to retrieve an access token. Once mix-cli has acquired the
access token, it takes care of refreshing it automatically.
Use the 'system' flag to authenticate with a specific Mix system. mix-cli executes
commands against the last Mix system it successfully authenticated with.
Run the 'system:list' command to see your list of configured Mix systems.
EXAMPLES
Authenticate with last Mix system used
$ mix auth
Authenticate with and switch to the "us" Mix system
$ mix auth --system us
See code: src/commands/auth.ts
mix autocomplete [SHELL]
display autocomplete installation instructions
USAGE
$ mix autocomplete [SHELL] [-r]
ARGUMENTS
SHELL shell type
FLAGS
-r, --refresh-cache Refresh cache (ignores displaying instructions)
DESCRIPTION
display autocomplete installation instructions
EXAMPLES
$ mix autocomplete
$ mix autocomplete bash
$ mix autocomplete zsh
$ mix autocomplete --refresh-cache
See code: @oclif/plugin-autocomplete
mix bot-configs:list
list application configurations for a bot
USAGE
$ mix bot-configs:list -B <value> [--exclude-overrides] [--live-only] [--columns <value> | | [--json | --csv |
--yaml] | ] [--filter <value> | | ] [--no-header | | ] [--no-truncate | | | ] [--sort <value>]
[--with-runtime-app <value>] [--with-tag <value>]
FLAGS
-B, --bot=<value> (required) Bot ID
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--exclude-overrides exclude application configurations that are overridden
--filter=<value> filter property by partial string matching, ex: name=foo
--json output raw data in JSON format
--live-only include only the application configurations that are currently deployed
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--sort=<value> property to sort by (prepend '-' for descending)
--with-runtime-app=<value> filter results by fully-qualified runtime app ID
--with-tag=<value> filter results by context tag
--yaml output raw data in YAML format
DESCRIPTION
list application configurations for a bot
Use this command to list the application configurations for a bot.
A number of flags can be used to constrain the returned results. The runtime
bot IDs can be retrieved using the bot-credentials:list command.
Bots are used in certain integration scenarios. A bot is a Mix application
with configurations that include dialog builds.
See https://docs.nuance.com/mix/apis/mix-api/v4/reference/bots/ for details.
EXAMPLES
$ mix bot-configs:list -B 164 --with-runtime-app NMDPTRIAL_alex_smith_company_com_20190919T190532
See code: src/commands/bot-configs/list.ts
mix bot-credentials:list
list credentials for a bot
USAGE
$ mix bot-credentials:list -B <value> [--with-geo-name <value>] [--full] [--json | | --yaml]
FLAGS
-B, --bot=<value> (required) Bot ID
--full show all bot credentials details
--json output raw data in JSON format
--with-geo-name=<value> geography name
--yaml output raw data in YAML format
DESCRIPTION
list credentials for a bot
Use this command to list the credentials for a bot.
This lets you retrieve the runtime application ID that is required
in other commands.
Bots are used in certain integration scenarios. A bot is a Mix application
with configurations that include dialog builds.
See https://docs.nuance.com/mix/apis/mix-api/v4/reference/bots/ for details.
EXAMPLES
List bot credentials for a bot
$ mix bot-credentials:list -B 12
List bot credentials for a bot that match a specific environment-geography
$ mix bot-credentials:list -B 12 --with-geo-name "Production US"
See code: src/commands/bot-credentials/list.ts
mix bot-interfaces:export
export the interface of a bot
USAGE
$ mix bot-interfaces:export -B <value> -C <value> [-f <value>] [--overwrite]
FLAGS
-B, --bot=<value> (required) Bot ID
-C, --config=<value> (required) application configuration ID
-f, --filepath=<value> output file path
--overwrite overwrite output file if it exists
DESCRIPTION
export the interface of a bot
Use this command to export the interface of a bot.
The configuration ID can be retrieved using the bot-configs:list command.
Bots are used in certain integration scenarios. A bot is a Mix application
with configurations that include dialog builds.
See https://docs.nuance.com/mix/apis/mix-api/v4/reference/bots/ for details.
EXAMPLES
Export the interface of a bot
$ mix bot-interfaces:export -B 32 -C 54
See code: src/commands/bot-interfaces/export.ts
mix bot-interfaces:get
retrieve the interface of a bot
USAGE
$ mix bot-interfaces:get -B <value> -C <value> [--json | | --yaml]
FLAGS
-B, --bot=<value> (required) Bot ID
-C, --config=<value> (required) application configuration ID
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
retrieve the interface of a bot
Use this command to get the interface of a bot.
The configuration ID can be retrieved using the bot-configs:list command.
Bots are used in certain integration scenarios. A bot is a Mix application
with configurations that include dialog builds.
See https://docs.nuance.com/mix/apis/mix-api/v4/reference/bots/ for details.
EXAMPLES
Retrieve the interface of a bot
$ mix bot-interfaces:get -B 32 -C 54
See code: src/commands/bot-interfaces/get.ts
mix bots:list
list bots in an organization
USAGE
$ mix bots:list -O <value> [--live-only --full] [--columns <value> | | [--json | --csv | --yaml] | ]
[--filter <value> | | ] [--no-header | | ] [--no-truncate | | | ] [--sort <value>] [--omit-overridden ]
FLAGS
-O, --organization=<value> (required) organization ID
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--filter=<value> filter property by partial string matching, ex: name=foo
--full show all bot details
--json output raw data in JSON format
--live-only include only the application configurations that are currently deployed
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--omit-overridden omit application configurations that are overridden
--sort=<value> property to sort by (prepend '-' for descending)
--yaml output raw data in YAML format
DESCRIPTION
list bots in an organization
Use this command to list bots for a specific Mix organization.
Use flag 'full' to list all bot details, including the list of bot configs.
Use flag 'live-only' with flag 'full' to filter out
bot configs that are NOT deployed.
Use flag 'omit-overridden' with flag 'full' to filter out
bot configs that are overridden.
Flags 'live-only' and 'omit-overridden' cannot be used together.
Flags 'live-only' and 'omit-overridden' can only be used with flag 'full'.
EXAMPLES
$ mix bots:list -O 64
See code: src/commands/bots/list.ts
mix builds:destroy
destroy a build
USAGE
$ mix builds:destroy [--build-label <value> | --build-type asr|dialog|nlu | -P <value> | --build-version <value>]
[-c <value>] [--json | | --yaml]
FLAGS
-P, --project=<value> project ID
-c, --confirm=<value> skip confirmation prompt by pre-supplying value
--build-label=<value> build label (format is <buildType>_<projectId>_<buildVersion>)
--build-type=<option> build type
<options: asr|dialog|nlu>
--build-version=<value> build version
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
destroy a build
Use this command to permanently delete a build. The build can be specified
using the build label or the combination of project ID, build type and build
version.
The deletion needs to be confirmed by re-typing the build label when prompted.
It can also be pre-confirmed by using the 'confirm' flag.
EXAMPLES
Destroy a build
$ mix builds:destroy -P 1922 --build-type asr --build-version 11
Destroy a build using a build label
$ mix builds:destroy --build-label ASR_1922_11
Destroy a project and provide automatic confirmation
$ mix builds:destroy --build-label ASR_1922_11 --confirm ASR_1922_11
See code: src/commands/builds/destroy.ts
mix builds:export
export a project build
USAGE
$ mix builds:export [--build-label <value> | --build-type asr|dialog|nlu | -P <value> | --build-version <value>]
[-f <value>] [--overwrite]
FLAGS
-P, --project=<value> project ID
-f, --filepath=<value> output file path (defaults to "build-<buildLabel>.zip")
--build-label=<value> build label (format is <buildType>_<projectId>_<buildVersion>)
--build-type=<option> build type
<options: asr|dialog|nlu>
--build-version=<value> build version
--overwrite overwrite output file if it exists
DESCRIPTION
export a project build
Use this command to export a project build. The build can be specified using
the build label or the combination of project ID, build type and build version.
The contents of the exported zip file depend on the role you have been granted
on the Mix platform.
EXAMPLES
Export a build using a build label
$ mix builds:export --build-label ASR_29050_11
Export a build using project ID, build type and build version
$ mix builds:export -P 29050 --build-type asr --build-version 11 --overwrite
See code: src/commands/builds/export.ts
mix builds:get
get details about a build
USAGE
$ mix builds:get [--build-label <value> | --build-type asr|dialog|nlu | -P <value> | --build-version <value>]
[--columns <value> ] [--no-truncate | | [--json | --csv | --yaml] | ]
FLAGS
-P, --project=<value> project ID
--build-label=<value> build label (format is <buildType>_<projectId>_<buildVersion>)
--build-type=<option> build type
<options: asr|dialog|nlu>
--build-version=<value> build version
--columns=<value> only show provided columns (comma-separated) (with 'csv' flag only)
--csv output to csv format
--json output raw data in JSON format
--no-truncate do not truncate output to fit screen
--yaml output raw data in YAML format
DESCRIPTION
get details about a build
Use this command to get details about a particular build. The build can be
specified using the build label or the combination of project ID, build type
and build version.
EXAMPLES
$ mix builds:get -P 1922 --build-type nlu --build-version 1
See code: src/commands/builds/get.ts
mix builds:latest
list latest build of each type
USAGE
$ mix builds:latest -P <value> [--columns <value> | | --json | --yaml] [--csv | | --no-truncate | ] [--filter
<value> | | ] [--no-header | | ]
FLAGS
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--filter=<value> filter property by partial string matching, ex: name=foo
--json output raw data in JSON format
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--yaml output raw data in YAML format
DESCRIPTION
list latest build of each type
Use this command to list the latest version for each build type of a particular
project.
EXAMPLES
List latest builds
$ mix builds:latest -P 1922
See code: src/commands/builds/latest.ts
mix builds:list
list builds
USAGE
$ mix builds:list --build-type asr|dialog|nlu -P <value> [--limit <value>] [--offset <value>] [--sort <value>]
[--columns <value> | | [--json | --csv | --yaml] | ] [--filter <value> | | ] [--no-header | | ] [--no-truncate |
| | ]
FLAGS
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
--build-type=<option> (required) build type
<options: asr|dialog|nlu>
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--filter=<value> filter property by partial string matching, ex: name=foo
--json output raw data in JSON format
--limit=<value> limit maximum results returned (defaults to Mix API behavior)
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--offset=<value> to exclude e.g., the first 10 (sorted) results, set --offset=10
--sort=<value> comma-separated properties to sort by (prepend '+'/'-' for ascending/descending)
--yaml output raw data in YAML format
DESCRIPTION
list builds
Use this command to list all versions of a build type for a particular project.
EXAMPLES
$ mix builds:list -P 1922 --build-type nlu
See code: src/commands/builds/list.ts
mix channels:activate
activate a channel
USAGE
$ mix channels:activate -P <value> -C <value> [--json | | --yaml]
FLAGS
-C, --channel=<value> (required) channel ID
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
activate a channel
Use this command to activate a channel in a project.
EXAMPLES
$ mix channels:activate -P 1922 \
--channel bc40667c-e0f6-11ec-9d64-0242ac120003
See code: src/commands/channels/activate.ts
mix channels:configure
update channel details
USAGE
$ mix channels:configure -P <value> -C <value> -m <value> --color <value> [--json | | --yaml]
FLAGS
-C, --channel=<value> (required) channel ID
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
-m, --mode=<value>... (required) channel modes (audioscript|dtmf|interactivity|richtext|tts)
--color=<value> (required) channel color
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
update channel details
Configure the modalities and color of an existing channel in a Mix project.
A note on channel modes and colors:
For your convenience, you may enter modes and colors case-insensitively.
In particular, you can spell any given mode/color with lowercase or capital letters,
and with dashes ('-') in place of underscores ('_'). The value will be internally converted
into the format the Mix API expects before the request is made. As an example, the values
'light-pink', 'light_Pink', and 'LIGHT-PINK' are all equivalent to Mix's 'LIGHT_PINK'.
Acceptable channel modes are:
audioscript
dtmf
interactivity
richtext
tts
Acceptable channel colors are:
blue brown corn-flower
cyan green grey
indigo light-green light-grey
light-orange light-pink light-purple
orange pink purple
ruby salmon sky
teal yellow
IMPORTANT: Due to a current server-side limitation,
the command currently requires that both the
'mode' and 'color' flags are set.
EXAMPLES
$ mix channels:configure -P 1922 \
--channel bc40667c-e0f6-11ec-9d64-0242ac120003 \
--mode DTMF --mode TTS \
--color SALMON
See code: src/commands/channels/configure.ts
mix channels:create
create a new channel
USAGE
$ mix channels:create --color <value> -m <value> --name <value> -P <value> [--json | | --yaml]
FLAGS
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
-m, --mode=<value>... (required) channel modes (audioscript|dtmf|interactivity|richtext|tts)
--color=<value> (required) channel color
--json output raw data in JSON format
--name=<value> (required) channel name
--yaml output raw data in YAML format
DESCRIPTION
create a new channel
Use this command to create a new channel in your Mix project.
A channel defines a collection of different modalities through
which users interact with your application. The currently available
modalities are:
audioscript
dtmf
interactivity
richtext
tts
Note that, for your convenience, this command will automatically convert
inputs to the 'mode' flag as close to the format of the above modes as possible,
by converting upper-case letters to lower-case and removing deliminating punctuation
('-' and '_'). So, the modes 'audioscript', 'AUDIO-SCRIPT', and 'a_u-d_i-o----scriPT'
are all equivalent to the server-side value of 'AUDIO_SCRIPT'.
The same conversion is done for colours, except that dashes ('-') are replaced
with ('_') rather than being deleted. So, 'light-pink', 'light____pink', and
'LIGHT_PINK' are also equivalent.
Acceptable channel colors are:
blue brown corn-flower
cyan green grey
indigo light-green light-grey
light-orange light-pink light-purple
orange pink purple
ruby salmon sky
teal yellow
IMPORTANT: Due to a current server-side limitation,
the command currently requires that both the
'mode' and 'color' flags are set.
EXAMPLES
$ mix channels:create -P 1922 --name "New IVR channel" \
--mode tts --mode interactivity --color light-pink
See code: src/commands/channels/create.ts
mix channels:deactivate
deactivate a channel
USAGE
$ mix channels:deactivate -P <value> -C <value> [-c <value>] [--json | | --yaml]
FLAGS
-C, --channel=<value> (required) channel ID
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
-c, --confirm=<value> skip confirmation prompt by pre-supplying value
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
deactivate a channel
Use this command to deactivate a channel in a project.
EXAMPLES
$ mix channels:deactivate -P 1922 \
--channel bc40667c-e0f6-11ec-9d64-0242ac120003 \
--confirm bc40667c-e0f6-11ec-9d64-0242ac120003
See code: src/commands/channels/deactivate.ts
mix channels:rename
rename a channel
USAGE
$ mix channels:rename -P <value> -C <value> --new-name <value> [--json | | --yaml]
FLAGS
-C, --channel=<value> (required) channel ID
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
--json output raw data in JSON format
--new-name=<value> (required) new channel name
--yaml output raw data in YAML format
DESCRIPTION
rename a channel
Use this command to change the name of a channel in a project.
EXAMPLES
$ mix channels:rename -P 1922 \
--channel bc40667c-e0f6-11ec-9d64-0242ac120003 \
--new-name "voice channel"
See code: src/commands/channels/rename.ts
mix data-hosts:latest
list latest data host details
USAGE
$ mix data-hosts:latest -M <value> -P <value> [-D <value>] [--columns <value> | | [--json | --csv | --yaml] | ]
[--filter <value> | | ] [--no-header | | ] [--no-truncate | | | ] [--sort <value>]
FLAGS
-D, --deployment-flow=<value> deployment flow ID
-M, --mix-app=<value> (required) Mix application ID
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--filter=<value> filter property by partial string matching, ex: name=foo
--json output raw data in JSON format
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--sort=<value> property to sort by (prepend '-' for descending)
--yaml output raw data in YAML format
DESCRIPTION
list latest data host details
Use this command to retrieve the list of the data hosts
associated with the last generated dialog build.
EXAMPLES
$ mix data-hosts:latest -D 658 -M 34 -P 619090
See code: src/commands/data-hosts/latest.ts
mix data-hosts:list
list data host details
USAGE
$ mix data-hosts:list -M <value> [--build-label <value> | -P <value> | --build-version <value>] [-D <value>]
[--columns <value> | | [--json | --csv | --yaml] | ] [--filter <value> | | ] [--no-header | | ] [--no-truncate |
| | ] [--sort <value>]
FLAGS
-D, --deployment-flow=<value> deployment flow ID
-M, --mix-app=<value> (required) Mix application ID
-P, --project=<value> project ID
--build-label=<value> build label (format is <buildType>_<projectId>_<buildVersion>)
--build-version=<value> build version
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--filter=<value> filter property by partial string matching, ex: name=foo
--json output raw data in JSON format
--no-header hide table header from output
--no-truncate do not truncate output to fit screen
--sort=<value> property to sort by (prepend '-' for descending)
--yaml output raw data in YAML format
DESCRIPTION
list data host details
Use this command to list data host details for a particular Mix Application ID
and dialog build. The build can be specified using the build label or the
combination of project ID and build version. The Mix Application ID can be
retrieved using the applications:list command.
EXAMPLES
$ mix data-hosts:list -D 66 -M 62 -P 14990 --build-version 1
See code: src/commands/data-hosts/list.ts
mix data-types:list
list data types
USAGE
$ mix data-types:list [--json | | --yaml]
FLAGS
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
list data types
Use this command to list the available data types.
EXAMPLES
$ mix data-types:list
See code: src/commands/data-types/list.ts
mix deployment-flows:list
list deployment flows
USAGE
$ mix deployment-flows:list -O <value> [--limit <value>] [--offset <value>] [--sort <value>] [--columns <value> | |
[--json | --csv | --yaml] | ] [--no-truncate | | | ]
FLAGS
-O, --organization=<value> (required) organization ID (defaults to MIX_ORGANIZATION)
--columns=<value> only show provided columns (comma-separated)
--csv output to csv format
--json output raw data in JSON format
--limit=<value> limit maximum results returned (defaults to Mix API behavior)
--no-truncate do not truncate output to fit screen
--offset=<value> to exclude e.g., the first 10 (sorted) results, set --offset=10
--sort=<value> comma-separated properties to sort by (prepend '+'/'-' for ascending/descending)
--yaml output raw data in YAML format
DESCRIPTION
list deployment flows
Use this command to list all deployment flows for a specific organization.
The organization ID can be retrieved by using the organizations:list command.
EXAMPLES
$ mix deployment-flows:list -O 64
See code: src/commands/deployment-flows/list.ts
mix engine-packs:list
list engine packs
USAGE
$ mix engine-packs:list -O <value> [--json | | --yaml]
FLAGS
-O, --organization=<value> (required) organization ID (defaults to MIX_ORGANIZATION)
--json output raw data in JSON format
--yaml output raw data in YAML format
DESCRIPTION
list engine packs
Use this command to list the engine packs available to a specific organization.
EXAMPLES
$ mix engine-packs:list -O 64
See code: src/commands/engine-packs/list.ts
mix entities:configure
configure an entity
USAGE
$ mix entities:configure -E <value> --entity-type base|freeform|list|regex|relational|rule-based -P <value>
[--anaphora-type not-set|ref-moment|ref-person|ref-place|ref-thing] [--data-type
alphanum|amount|boolean|date|digits|distance|no-format|not-set|number|temperature|time|yes-no] [--dynamic] [--has-a
<value>] [--is-a <value>] [-L <value>] [--no-canonicalize] [--pattern <value>] [--sensitive] [--json | | --yaml]
FLAGS
-E, --entity=<value> (required) entity name
-L, --locale=<value> locale for regex entity
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
--anaphora-type=<option> anaphora type
<options: not-set|ref-moment|ref-person|ref-place|ref-thing>
--data-type=<option> data type of entity
<options: alphanum|amount|boolean|date|digits|distance|no-format|not-set|number|temperature|
time|yes-no>
--dynamic make list entity dynamic
--entity-type=<option> (required) entity type
<options: base|freeform|list|regex|relational|rule-based>
--has-a=<value>... define hasA relationship for relational entity
--is-a=<value> define isA relationship for relational entity
--json output raw data in JSON format
--no-canonicalize prevent canonicalization
--pattern=<value> regular expression for regex entity
--sensitive mask user sentitive data in logs
--yaml output raw data in YAML format
DESCRIPTION
configure an entity
Use this command to configure an entity in a project.
NOTE: This command cannot change the type of an entity.
When using this command, you must provide the current type
of the entity. Use command entities:convert to change the
type of an entity.
Mix supports several types of entities: freeform, list, regex,
relational and rule-based. There are many attributes that can
be configured for an entity and a good number of these attributes
are common to all entity types. However, certain attributes apply
to specific entity types only.
Regex entities make use of regular expressions specific to a single
locale. The 'pattern' and 'locale' flags matter only to entities
of type "regex". It is recommended to surround the pattern
value with quotes, especially if the escape character "\" is used
in the pattern. See examples below.
Relationial entities can have zero or one isA relation and
zero or many hasA relations. One 'is-a' or 'has-a' flag must be
set at a minimum for an entity of type "relational".
The examples below show how to configure each type of entity.
In each example, every allowed flag is used.
Note that when a value is not provided for a particular flag,
the corresponding property in the entity is not modified.
EXAMPLES
Configure a freeform entity
$ mix entities:configure -P 1922 -E MESSAGE --entity-type freeform \
--sensitive --no-canonicalize --data-type not-set
Configure a list entity
$ mix entities:configure -P 1922 -E DRINK_SIZE --entity-type list \
--dynamic --sensitive --no-canonicalize --anaphora-type not-set \
--data-type not-set
Configure a regex entity
$ mix entities:configure -P 1922 -E PHONE_NUMBER --entity-type regex \
--locale en-US --pattern "\d{10}" --sensitive --no-canonicalize \
--anaphora-type not-set --data-type digits
Configure a relational entity
$ mix entities:configure -P 1922 --E FROM_CITY --entity-type relational \
--is-a CITY --sensitive --no-canonicalize --anaphora-type not-set \
--data-type not-set
Configure a rule-based entity
$ mix entities:configure -P 1922 -E CARD_TYPE --entity-type rule-based \
--sensitive --no-canonicalize --anaphora-type not-set --data-type not-set
See code: src/commands/entities/configure.ts
mix entities:convert
convert an entity to a different type
USAGE
$ mix entities:convert -E <value> -P <value> --to-entity-type base|freeform|list|regex|relational|rule-based
[--has-a <value>] [--is-a <value>] [--pattern <value>] [--json | | --yaml]
FLAGS
-E, --entity=<value> (required) entity name
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
--has-a=<value>... define hasA relationship for relational entity
--is-a=<value> define isA relationship for relational entity
--json output raw data in JSON format
--pattern=<value> regular expression for regex entity
--to-entity-type=<option> (required) new entity type
<options: base|freeform|list|regex|relational|rule-based>
--yaml output raw data in YAML format
DESCRIPTION
convert an entity to a different type
Use this command to convert an entity to a different type.
Mix supports several types of entities: freeform, list, regex,
relational and rule-based. If converting to a regex or rule-based
entity type, you will have to provide additional information as
explained below.
Regex entities make use of regular expressions specific to a single
locale. Use the 'pattern' flag to provide the regular expression for
the converted entity. It is recommended to surround the pattern value
with quotes, especially if the escape character "\" is used in the
pattern (see examples below). The regular expression provided gets
applied to the entity across all locales in the project. If the regular
expression for the entity is locale-dependent, then use the entities:configure
command to update the regular expression for the relevant locales.
Relational entities can have zero or one isA relation and
zero or many hasA relations. One 'is-a' or 'has-a' flag must be
set at a minimum whent converting an entity to the "relational" type.
The examples below show how to convert an entity to each possible
type of entity.
EXAMPLES
Convert an entity to a freeform entity
$ mix entities:convert -P 1922 -E MY_ENTITY --to-entity-type freeform
Convert an entity to a list entity
$ mix entities:convert -P 1922 -E MY_ENTITY --to-entity-type list
Convert an entity to a regex entity
$ mix entities:convert -P 1922 -E MY_ENTITY --to-entity-type regex \
--pattern "\d{10}"
Convert an entity to a relational entity
$ mix entities:convert -P 1922 --E MY_ENTITY --to-entity-type relational
--is-a CITY
Convert an entity to a rule-based entity
$ mix entities:convert -P 1922 -E MY_ENTITY --to-entity-type rule-based
See code: src/commands/entities/convert.ts
mix entities:create
create a new entity
USAGE
$ mix entities:create --entity-type base|freeform|list|regex|relational|rule-based --name <value> -P <value>
[--anaphora-type not-set|ref-moment|ref-person|ref-place|ref-thing] [--data-type
alphanum|amount|boolean|date|digits|distance|no-format|not-set|number|temperature|time|yes-no] [--dynamic] [--has-a
<value>] [--is-a <value>] [-L <value>] [--no-canonicalize] [--pattern <value>] [--sensitive] [--json | | --yaml]
FLAGS
-L, --locale=<value> locale for regex entity
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
--anaphora-type=<option> [default: not-set] anaphora type
<options: not-set|ref-moment|ref-person|ref-place|ref-thing>
--data-type=<option> [default: not-set] data type of entity
<options: alphanum|amount|boolean|date|digits|distance|no-format|not-set|number|temperature|
time|yes-no>
--dynamic make list entity dynamic
--entity-type=<option> (required) entity type
<options: base|freeform|list|regex|relational|rule-based>
--has-a=<value>... define hasA relationship for relational entity
--is-a=<value> define isA relationship for relational entity
--json output raw data in JSON format
--name=<value> (required) new entity name
--no-canonicalize prevent canonicalization
--pattern=<value> regular expression for regex entity
--sensitive mask user sentitive data in logs
--yaml output raw data in YAML format
DESCRIPTION
create a new entity
Use this command to create a new entity in a project.
Mix supports several types of entities: freeform, list, regex,
relational and rule-based. There are many attributes that can
be passed for the creation of an entity and a good number of
these attributes are common to all entity types. However, certain
attributes are mandatory and apply to specific entity types only.
Regex entities make use of regular expressions specific to a single
locale. The 'pattern' and 'locale' flags must be set when creating
an entity of type "regex". It is recommended to surround the pattern
value with quotes, especially if the escape character "\" is used
in the pattern. See examples below.
Relationial entities can have zero or one isA relation and
zero or many hasA relations. One 'is-a' or 'has-a' flag must be
set at a minimum when creating an entity of type "relational".
The 'entity-type', 'name' and 'project' flags are mandatory for
the creation of any entity type.
The examples below show how to create each type of entity.
In each example, every allowed or mandatory flag is used.
Note that many flags have default values and do not need to be
explicitly provided.
EXAMPLES
Create a freeform entity
$ mix entities:create -P 1922 --entity-type=freeform --name MESSAGE \
--sensitive --no-canonicalize --data-type not-set
Create a list entity
$ mix entities:create -P 1922 --entity-type=list --name DRINK_SIZE \
--dynamic --sensitive --no-canonicalize --anaphora-type not-set \
--data-type not-set
Create a regex entity
$ mix entities:create -P 1922 --entity-type=regex --name PHONE_NUMBER \
--locale en-US --pattern "\d{10}" --sensitive --no-canonicalize \
--anaphora-type not-set --data-type digits
Create a relational entity
$ mix entities:create -P 1922 --entity-type=relational --name ARRIVAL_CITY \
--is-a CITY --sensitive --no-canonicalize --anaphora-type not-set \
--data-type not-set
Create a rule-based entity
$ mix entities:create -P 1922 --entity-type=rule-based --name CARD_TYPE \
--sensitive --no-canonicalize --anaphora-type not-set --data-type not-set
See code: src/commands/entities/create.ts
mix entities:destroy
destroy an entity
USAGE
$ mix entities:destroy -E <value> -P <value> [-c <value>] [--json | | --yaml]
FLAGS
-E, --entity=<value> (required) entity name
-P, --project=<value> (required) project ID (defaults to MIX_PROJECT)
-c, --confirm=<value> skip confirmation prompt by pre-supplying value
--json output raw data in JSON format
--yaml