Skip to end of metadata
Go to start of metadata

The AMPLIFY CLI config command manages configuration values.

Settings

NameTypeDefaultDescription
auth.clientId string"amplify-cli" The global client ID to use when authenticating. You can be logged into multiple different client IDs at the same time.
auth.serverHost string"localhost" The hostname the local web server should listen on and await the successful login browser redirect.
auth.serverPort number3000 The port number the local web server should listen on and await the successful login browser redirect. The value must be between 1024 and 65535.
auth.tokenRefreshThreshold number0 The number of seconds before the access token expires and should be refreshed. As long as the refresh token is not expired, a new access token can be retrieved. This setting is only useful if the access token is still valid, but almost expired and you need a valid access token for an operation in the near future. The value must be a non-negative integer.
auth.tokenStoreType string"secure" 

The type of store to persist the access token after authenticating.

Allowed values:

  • "auto" - Attempts to use the "secure" store, but falls back to "file" if secure store is unavailable.
  • "secure" - Encrypts the access token using a generated key which is stored in the system's keychain.
  • "file" - Encrypts the access token using the embedded key.
  • "memory" - Stores the access token in memory instead of on disk. The access tokens are lost when the process exits. This is intended for testing purposes only.
  • "null" - Disables all forms of token persistence and only returns the access token. Subsequent calls to login in the same process will force the authentication flow. This is intended for migration scripts and testing purposes only.
network.httpProxy string 

The proxy server URL. This proxy server is used for both HTTP and HTTPS outbound requests.

Icon

If the proxy server uses a self-signed certificate, you must set the environment variable NODE_TLS_REJECT_UNAUTHORIZED=0.

Usage

Actions

  • get - Display a specific config setting
  • ls, list - Display all config settings
  • pop - Remove the last value in a list
  • push - Add a value to the end of a list
  • rmdelete  - Remove a config setting
  • set - Change a config setting
  • shift - Remove the first value in a list
  • unshift - Add a value to the beginning of a list

Options

  • --json - Output the value as JSON

get

Returns a config setting.

ls, list

Displays a list of all installed packages.

pop

Removes a value from the end of a list.

rm, delete

Deletes a config setting.

push

Adds a value to the end of a list. If there is no existing value, a new list is created. If a non-list value exists, it is converted to a list and the new value is appended.

set

Sets a config value. If a value already exists, the existing value is overwritten.

shift

Removes a value from the beginning of a list.

unshift

Adds a value to the beginning of a list. If there is no existing value, a new list is created. If a non-list value exists, it is converted to a list and the new value is prepended.

  • No labels