- Documentation
Torch Object Storage
SDK Reference
Python
Bucket interface
Basic bucket interface
Create a bucket (Python SDK)
Basic bucket interface
Create a bucket (Python SDK)
Create a bucket (Python SDK)
Bucket is the globally unique namespace of TOS, which is equivalent to a data container and is used to store object data. Provided to the user to create a new bucket with the specified bucket name, the newly created bucket name must be unique in TOS. This article describes how to create a bucket.
Precautions
- Only lowercase letters a to z, numbers, and dashes (-) can be included.
- The beginning and end can only be numbers or letters.
- The length must be between 3 and 63 characters.
- When accessing TOS through other Volcano Engine products in the same region as TOS, it is recommended that you use the intranet endpoint. For more information on regions and endpoints, see Region and Endpoint.
- Before creating a bucket, you need to ensure that your account has tos: CreateBucketpermission. You can grant appropriate permissions through IAM policies. For specific steps, see Overview.
Sample code
The following code is used to create a bucket-test.
Related documentation
For API documentation on creating buckets, see CreateBucket. Last updated: 2025.09.17 18:22:12