Closed monil-panchal closed 2 years ago
Thank you for your request. Fortunately, this information is already available through the Resource Configuration API. Here is the Node.js SDK: https://www.npmjs.com/package/ibm-cos-sdk-config. You can see the bucket information currently available here: https://github.com/IBM/ibm-cos-sdk-js-config/blob/master/resource-configuration/v1.ts#L260.
If this answers your question, please close this ticket.
Closing this ticket as resolved.
As of today, the COS UI or the APIs do not support viewing the bucket size or the number of objects in a bucket.
ibmcloud cos objects
CLI command and jq to calculate the returned array size using theContents
field. However, this approach is quite heavy, the more the objects in a bucket, the slower the command execution time.Can this feature of getting the number of objects in a buckets and/or total size of the bucket be expected to roll-out anytime soon in the SDK?