Documentation ¶
Index ¶
- type R2Client
- func (c *R2Client) DeleteObject(ctx context.Context, key string) error
- func (c *R2Client) GetObjectMetadata(ctx context.Context, key string) (*s3.HeadObjectOutput, error)
- func (c *R2Client) ListObjects(ctx context.Context) (*s3.ListObjectsV2Output, error)
- func (c *R2Client) UploadFile(ctx context.Context, file io.Reader, key string) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type R2Client ¶
type R2Client struct {
// contains filtered or unexported fields
}
R2Client wraps the AWS S3 client for Cloudflare R2 operations
var R2 *R2Client
Global R2Client instance
func NewR2Client ¶
NewR2Client creates a new R2Client with the specified configuration
func (*R2Client) DeleteObject ¶
DeleteObject deletes an object from the R2 bucket
func (*R2Client) GetObjectMetadata ¶
GetObjectMetadata retrieves the metadata of an object from the R2 bucket
func (*R2Client) ListObjects ¶
ListObjects lists objects in the R2 bucket
Click to show internal directories.
Click to hide internal directories.