Versions in this module Expand all Collapse all v1 v1.0.1 Aug 3, 2026 Changes in this version + const DefaultMaxObjects + const DefaultTimeout + const ExitApiError + const ExitAuthError + const ExitNetworkError + const ExitPermissionError + const ExitSuccess + const ExitUsageError + var ErrApiError = errors.New("API operation error") + var ErrAuthFailed = errors.New("authentication failed") + var ErrBucketAccess = errors.New("bucket access denied or not found") + var ErrInvalidConfig = errors.New("invalid configuration") + var ErrNetworkFailed = errors.New("network connectivity error") + func ClassifyError(err error) int + func NewClient(ctx context.Context, cfg Config) (*storage.Client, error) + type Config struct + AllowADC bool + BucketName string + BucketPrefix string + CredFile string + CredJSON []byte + MasterKey string + MasterKeyEnv string + MasterKeyFile string + MaxObjects int + ProjectID string + Timeout time.Duration + func (c Config) Clean() Config + func (c Config) Validate() error + type Result struct + BucketAttrs *storage.BucketAttrs + BucketName string + ObjectNames []string + TotalListed int + func TestConnection(ctx context.Context, cfg Config) (*Result, error) + func TestConnectionWithClient(ctx context.Context, client *storage.Client, cfg Config) (*Result, error) + func TestConnectionWithStorageClient(ctx context.Context, client StorageClient, cfg Config) (*Result, error) + func (r *Result) ToJSON() (string, error) + type StorageClient interface + BucketAttrs func(ctx context.Context, bucketName string) (*storage.BucketAttrs, error) + ListObjects func(ctx context.Context, bucketName, prefix string, maxObjects int) ([]string, error) + func NewStorageClient(client *storage.Client) StorageClient