Gets the bucket list.
// You need to assign your bucket in your code string bucket = "TestBucket"; // You need to assign your app key and your secret key in your code var client = new BaiduBCSClient("your app key", "your secret key"); // According to bucket naming rule by Baidu, all bucket names would be changed to lower case inside client for any bucket operation. client.CreateBucket(bucket); // Get bucket list and output summary via Console. var bucketList = client.GetBucketList(); foreach (var one in bucketList) { Console.WriteLine(string.Format("{Bucket: {0}, TotalCapacity: {1}.", one.Name, one.TotalCapacity)); } // Delete bucket. client.DeleteBucket(bucket);