wx-data bucket create

Create a new bucket.

Syntax

cpd-cli wx-data bucket create \
--bucket-type=<placeholder-text> \
--description=<description> \
--managed-by=<managed-by> \
[--associated-catalog=<associated-catalog>] \
[--associated-catalog-catalog-name=<associated-catalog-catalog-name>] \ 
[--associated-catalog-catalog-tags=<associated-catalog-catalog-tags>] \
[--associated-catalog-catalog-type=<associated-catalog-catalog-type>] \ 
[--bucket-details=<placeholder-text>] \ 
[--bucket-access-key=<placeholder-text>] \
[--bucket-details-bucket-name=<placeholder-text>] \ 
[--bucket-details-endpoint=<placeholder-text>] \--bucket-details-endpoint (string) : Cos endpoint. 
[--bucket-details-key-file=<placeholder-text>] \
[--bucket-details-provider=<placeholder-text>] \ --bucket-details-provider (string) : bucket provider.
[--bucket-details-region=<placeholder-text>] \ --bucket-details-region (string) : Region where the bucket is located.
[--bucket-details-secret-key=<placeholder-text>] \ 
[--bucket-display-name=<placeholder-text>] \
[--instance-id=<instance-id>] \
[--region=<region>] \
[--storage-details=<storage-details>] \ 
[--storage-details-access-key=<storage-details-access-key>] \
[--storage-details-application-id=<storage-details-application-id>] \
[--storage-details-auth-mode=<storage-details-auth-mode>] \
[--storage-details-container-name=<storage-details-container-name>] \ 
[--storage-details-sas-token=<storage-details-sas-token>] \  
[--storage-details-secret-key=<storage-details-secret-key>] \
[--storage-details-storage-account=<storage-details-storage-account>] \ 

Options

Table 1: Command options
Option Description
--associated-catalog Bucket catalog object that includes catalog name, catalog tags, and catalog type.
Status
Optional.
Syntax
--associated-catalog=<associated-catalog>
Input
string
Default value
No default.
--associated-catalog-catalog-name Bucket catalog object that includes catalog name, catalog tags, and catalog type.
Status
Optional.
Syntax
--associated-catalog-catalog-name=<associated-catalog-catalog-name>
Input
string
Default value
No default.
--associated-catalog-catalog-tags Catalog tags. This option provides a value for a sub-field of the JSON option associated-catalog. The associated-catalog-catalog-tags option is mutually exclusive with the associated-catalog option.
Status
Optional.
Syntax
--associated-catalog-catalog-tags=<associated-catalog-catalog-tags>
Input
string
Default value
No default.
--associated-catalog-catalog-type Catalog type. This option provides a value for a sub-field of the JSON option associated-catalog. The associated-catalog-catalog-type option is mutually exclusive with the associated-catalog-catalog-type option.
Status
Optional.
Syntax
--associated-catalog-catalog-type=<associated-catalog-catalog-type>
Input
string
Default value
No default.
--bucket-details Provide adhoc bucket details if the bucket is not already registered.
Status
Optional.
Syntax
--bucket-details=<placeholder-text>
Input
string
Default value
No default.
--bucket-details-access-key Access key ID that is encrypted during bucket registration. This option provides a value for a sub-field of the JSON option bucket-details. The bucket-details-access-key option is mutually exclusive with the option bucket-details.
Status
Optional.
Syntax
--bucket-details-access-key=<placeholder-text>
Input
string
Default value
No default.
--bucket-details-bucket-name Bucket name. This option provides a value for a sub-field of the JSON option bucket-details. The bucket-details-bucket-name option is mutually exclusive with the bucket-details option.
Status
Optional.
Syntax
--bucket-details-bucket-name=<placeholder-text>
Input
string
Default value
No default.
--bucket-details-endpoint Cos endpoint. This option provides a value for a sub-field of the JSON option bucket-details. The bucket-details-endpoint option is mutually exclusive with the bucket-details option.
Status
Optional.
Syntax
--bucket-details-endpoint=<placeholder-text>
Input
string
Default value
No default.
--bucket-details-key-file Key file that is encrypted during bucket registration. This option provides a value for a sub-field of the JSON option bucket-details. The bucket-details-key-file option is mutually exclusive with the bucket-details option.
Status
Optional.
Syntax
--bucket-details-key-file=<placeholder-text>
Input
string
Default value
No default.
--bucket-details-provider Bucket provider. This option provides a value for a sub-field of the JSON option bucket-details. The bucket-details-provider option is mutually exclusive with the bucket-details option.
Status
Optional.
Syntax
--bucket-details-provider=<placeholder-text>
Input
string
Default value
No default.
--bucket-details-region Region where the bucket is located. This option provides a value for a sub-field of the JSON option bucket-details. The bucket-details-region option is mutually exclusive with the bucket-details option.
Status
Optional.
Syntax
--bucket-details-region=<placeholder-text>
Input
string
Default value
No default.
--bucket-details-secret-key Region where the bucket is located. This option provides a value for a sub-field of the JSON option bucket-details. The bucket-details-region option is mutually exclusive with the bucket-details option.
Status
Optional.
Syntax
--bucket-details-secret-key=<placeholder-text>
Input
string
Default value
No default.
--bucket-display-name Bucket display name.
Status
Optional.
Syntax
--bucket-display-name=<placeholder-text>
Input
string
Default value
No default.
--bucket-type Bucket type.
Status
Required.
Syntax
--bucket-type=<placeholder-text>
Input
string
Default value
No default.
Valid values
amazon_s3, aws_s3, minio, ibm_cos, ibm_ceph, adls_gen1, adls_gen2, google_cs, ibm_storage_scale, ozone
--description Bucket description.
Status
Required.
Syntax
--description=<description>
Input
string
Default value
No default.
--instance-id watsonx.data instance ID for IBM Software Hub or CRN for SaaS.
Status
Optional.
Syntax
--instance-id=<instance-id>
Input
string
Default value
No default.
--managed-by [Needs description].
Status
Required.
Syntax
--managed-by=<managed-by>
Input
string
Default value
No default.
Valid values
Allowable values include ibm and customer.
--region Region of the bucket location.
Status
Optional.
Syntax
--region=<region>
Input
string
Default value
No default.
--storage-details Storage details. This JSON option can instead be provided by setting individual fields with other options. The storage-details option is mutually exclusive with those options.
Status
Optional.
Syntax
--storage-details=<storage-details>
Input
string
Default value
No default.
Valid values
Provide a JSON string option or specify a JSON file to read from by providing a filepath option that begins with a @, such as --storage-details=@path/to/file.json .
--storage-details-access-key Access key ID that is encrypted during bucket registration. The storage-details-access-key option provides a value for a sub-field of the JSON option storage-details. The storage-details-access-key option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-access-key=<storage-details-access-key>
Input
string
Default value
No default.
--storage-details-application-id Application ID for bucket registration. The storage-details-application-id option provides a value for a sub-field of the JSON option storage-details. The storage-details-application-id option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-application-id=<storage-details-application-id>
Input
string
Default value
No default.
--storage-details-auth-mode Auth mode types. The storage-details-auth-mode option provides a value for a sub-field of the JSON option storage-details. The storage-details-auth-mode option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-auth-mode=<storage-details-auth-mode>
Input
string
Default value
No default.
--storage-details-container-name Auth container name. The storage-details-container-name option provides a value for a sub-field of the JSON option storage-details. The storage-details-container-name option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-container-name=<storage-details-container-name>
Input
string
Default value
No default.
--storage-details-directory-id Directory ID for bucket registration. The storage-details-directory-id option provides a value for a sub-field of the JSON option storage-details. The storage-details-directory-id option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-directory-id=<storage-details-directory-id>
Input
string
Default value
No default.
--storage-details-endpoint ADLS (Azure Data Lake Storage) endpoint. The storage-details-endpoint option provides a value for a sub-field of the JSON option storage-details. The storage-details-endpoint option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-endpoint=<storage-details-endpoint>
Input
string
Default value
No default.
--storage-details-sas-token Shared access signature (SAS) token that is encrypted during bucket registration. The storage-details-sas-token option provides a value for a sub-field of the JSON option storage-details. The storage-details-sas-token option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-sas-token=<storage-details-sas-token>
Input
string
Default value
No default.
--storage-details-secret-key Secret access key that is encrypted during bucket registration. The storage-details-secret-key option provides a value for a sub-field of the JSON option storage-details. The storage-details-secret-key option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-secret-key=<storage-details-secret-key>
Input
string
Default value
No default.
--storage-details-storage-account Actual storage name. The storage-details-storage-account option provides a value for a sub-field of the JSON option storage-details. The storage-details-storage-account option is mutually exclusive with the storage-details option.
Status
Optional.
Syntax
--storage-details-storage-account=<storage-details-storage-account>
Input
string
Default value
No default.
--tags Specify the data asset tags. Multiple tags can be specified.
Status
Optional.
Syntax
--tags=<tag1,tag2,...>
Input
string
Default value
No default.

Examples

cpd-cli wx-data bucket create \
--bucket-type ibm_cos \
--description 'COS bucket for customer data' \
--managed-by ibm \
--associated-catalog '{"catalog_name": "sampleCatalog", "catalog_tags": ["catalog_tag_1","catalog_tag_2"], "catalog_type": "iceberg"}' \
--bucket-details '{"access_key": "b9cbf248ea5c4c96947e64407108559j", "bucket_name": "sample-bucket", "endpoint": "https://s3.<region>.cloud-object-storage.appdomain.cloud/", "key_file": "key_file", "provider": "ibm_cos", "region": "us-south", "secret_key": "13b4045cac1a0be54c9fjbe53cb22df5fn397cd2c45b66c87"}' \
--bucket-display-name sample-bucket-displayname \
--region us-south \
--storage-details '{"access_key": "<access_key>", "application_id": "<application_id>", "auth_mode": "<account_key/sas/service_principle>", "container_name": "sample-container", "directory_id": "<directory_id>", "endpoint": "abfss://<container_name>@<storage_account_name>.dfs.core.windows.net/", "sas_token": "<sas_token>", "secret_key": "secret_key", "storage_account_name": "sample-storage"}' \
--tags bucket-tag1,bucket-tag2 \
--instance-id 1735472262311515