Help Center/ Koo Command Line Interface/ FAQs/ Parameters/ What Are KooCLI System Parameters?
Updated on 2023-10-16 GMT+08:00

What Are KooCLI System Parameters?

System Parameters

KooCLI system parameters are internal parameters. The following table describes the system parameters and their usage.

Table 1 KooCLI's new system parameters

Parameter

Description

How to Use

help

Prints help information.

Use it directly in a command.

debug

Prints debugging information.

Use it directly in a command.

dryrun

Prints the request message after verification, without execution.

Use it directly in a command.

interactive

Puts you into the interactive mode.

Use it directly in a command.

cli-region

Region.

Configure it in a profile or use it directly in a command.

cli-access-key

Access key ID required in AK/SK mode.

Configure it in a profile or use it directly in a command.

cli-secret-key

Secret access key required in AK/SK mode.

Configure it in a profile or use it directly in a command.

cli-domain-id

Account ID.

Configure it in a profile or use it directly in a command.

cli-project-id

Project ID

Configure it in a profile or use it directly in a command.

cli-profile

Profile. If not specified, the default one is used.

Configure it in a profile or use it directly in a command.

cli-mode

Authentication mode (AKSK or ecsAgency).

Configure it in a profile or use it directly in a command.

cli-jsonInput

Passes API parameters using a JSON file.

Use it directly in a command.

cli-output

Response data output format (json, table, or tsv).

Use it directly in a command.

cli-query

JMESPath for filtering response data.

Use it directly in a command.

cli-output-num

Whether to print the row numbers during table output. The value can be true (default) or false.

Use it directly in a command.

cli-endpoint

Custom domain name.

Use it directly in a command.

cli-connect-timeout

Request connection timeout, in seconds. The default value is 5s, and the minimum value is 1s.

Configure it in a profile or use it directly in a command.

cli-read-timeout

I/O timeout, in seconds. The default value is 10s, and the minimum value is 1s.

Configure it in a profile or use it directly in a command.

cli-retry-count

Number of connection attempts. The value ranges from 0 to 5. The default value is 0.

Configure it in a profile or use it directly in a command.

cli-security-token

Specifies a temporary token, which must be used together with a temporary AK/SK.

Configure it in a profile or use it directly in a command.

cli-lang

Language, which can be cn or en.

Configure it in a profile.

cli-offline

Specifies whether to use offline mode. The value can be true or false. The default value is true.

Configure it in a profile.

cli-skip-secure-verify

Specifies whether to skip HTTPS certificate verification (not recommended). The value can be true or false (default).

Configure it in a profile or use it directly in a command.

cli-agree-privacy-statement

Whether to agree to the privacy statement. The value can be true or false (default).

Configure it in a profile.

cli-warning

Whether to display warnings during command execution. The value can be true (default) or false.

Configure it in a profile.

The ways parameters listed in the preceding table can be used are described as follows:

  • Configure it in a profile.

    The parameter can be used only after being configured in a profile by running hcloud configure set --key1=value1 --key2=value2 ... The profile name can be specified using --cli-profile=${profileName}. KooCLI parses and uses the parameter values configured in the profile during the running process.

    If you use the parameter directly in a command, the following error message is displayed:

    [USE_ERROR] Invalid parameter: *

  • Use it directly in a command.

    The parameter can be used only in a command in the format of --key1=value1 --key2=value2 ....

    If you configure the parameter in a profile, the following error message is displayed:

    [USE_ERROR] Invalid parameter: *

  • Configure it in a profile or use it directly in a command.

    The parameter can be used after being configured in a profile by running hcloud configure set --key1=value1 --key2=value2 .... Alternatively, it can be directly used in a command in the format of --key1=value1 --key2=value2 ... KooCLI preferentially uses the parameter value specified in the command. If the parameter is not specified in the command, its value in the current profile is used.

For details about the old KooCLI system parameters, see Table 1.