List Buckets

The following SDK method will return all the buckets present in the project. The Stratus reference used in the below code snippet is the component instance.

Info: To use this SDK method, you need intialize it with Admin scope. You can learn more about this requirement from this section

Ensure the following packages are imported:

    
copy
import java.util.List; import com.zc.component.stratus.ZCStratus; import com.zc.component.stratus.ZCBucket;
    
copy
ZCStratus stratus = ZCStratus.getInstance(); List<ZCBucket> buckets = stratus.listBuckets(); // will return all the buckets in the organization

Last Updated 2025-06-20 16:21:48 +0530 +0530