project list
Return a list of projects that meet the provided query parameters. By default, the list returns projects of which the authenticated user is a member. The command lists only Analytics projects (Data Quality projects are not supported).
Syntax
cpd-cli project list \
--profile=<cpd-profile-name> \
[--bookmark=<pagination-bookmark>] \
[--bss-account-id=<bss-account-id>] \
[--guids=<comma-separated-list-of-project-ids>] \
[--include=<comma-separated-list-of-project-metadata-sections>] \
[--jmes-query=<jmespath-query>] \
[--limit=<project-limit>] \
[--match=<text-matching-type>] \
[--member=<project-member-filter>] \
[--name=<full-or-partial-project-name>] \
[--output=json|yaml|table] \
[--output-file=<output-file-location>] \
[--raw-output=true|false] \
[--roles=<comma-separated-list-of-project-roles>]
Arguments
The project list command has no
arguments.
Options
Table 1: Command options
| Option | Description |
|---|---|
--bookmark |
Specify a bookmark for
results
pagination.
|
--bss-account-id |
Specify the BSS account ID.
Filtering by 'bss_account_id' is allowed only for accredited
services.
|
--guids |
Specify a list of comma-separated
project IDs to use to filter the query results.
|
|
|
Display command
help.
|
--include |
Specify list of
comma-separated project metadata sections to include in the query
results.
|
--jmes-query |
Provide a JMESPath query to
customize the output.
|
--limit |
Specify a value that is
used to specify the maximum number of projects that are returned in the query results. The option is
used for pagination in conjunction with the 'bookmark' query
parameter.
|
--match |
Specify the text matching type to
perform. This query parameter must be used in conjunction with the 'name' query parameter. The
'exact' value matches projects if the specified text matches the exact project name. The 'keyword'
value matches projects if the specified text matches any keyword that is parsed from the project
name.
|
--member |
Specify a project member to use
when filtering the query results by membership.
|
--name |
Specify a full or
partial project name to use when filtering the query results. This option must be used with the
'bss_account_id' option. Use the 'match' option to control what type of text matching is performed.
Project names are not unique and should not be used in place of project IDs.
|
--output |
Specify an output
format.
|
--output-file |
Specify a file path where all
output is redirected.
|
--profile |
The name of the profile that you
created to store information about an instance of Cloud Pak for Data and your credentials for the
instance.
|
--raw-output |
When set to true, single values
are not surrounded by quotation marks in
JSON output
mode.
|
--roles |
Specify a list of comma-separated
project roles to use when filtering the query results. The option must be used in conjunction with
the 'member' option.
|
Examples
Note: The following examples use environment variables. Use a script to create
environment variables with the correct values for your environment. You can add the listed
environment variables to the installation variables script. For more information, see Setting up installation environment variables.
- List available projects for the specified Cloud Pak for Data configuration profile name.
-
cpd-cli project list \ --profile=${CPD_PROFILE_NAME} - Example results.
-
ID Name Created Description Tags 0cabb425-56d9-48fc-a178-f30d22737778 git-demo-project 2021-02-19T13:47:11.811Z [] 45f48375-4cdf-4354-8f51-3dbe933dc0aa Clustering Demo (git integrated) 2021-05-20T06:31:48.099Z [] 7fb76cf7-25be-435d-818e-bd6e9b5254f5 cpdctl-demo 2021-01-29T08:01:23.363Z []