AWS Wrappers is a straightforward .NET 8 C# class library to perform basic operations AWS S3 from the .NET core application which is built on top of AWS libraries, which Amazon Web Services provide.
The AWS libraries provide all the features needed to perform operations with AWS, but they are sometimes not straight forward to use and we need to implement them in our application.
So, AWS Wrappers S3 is designed to do basic operations such as creating buckets, uploading files, creating folders, etc. with the AWS Simple Storage Services (S3) with simple, user-readable methods that already implement the codes required to perform the operation.
- .NET 8
- AWSSDK.S3 [Version 3.7.304.10]
Clone the code from the master branch or download stable release from the release area.
var s3Client = new AmazonS3Client();
Refer: How to create AmazonS3Client
IBucketOperations bucketOperations = new BucketOperations(s3Client);
await bucketOperations.CreateBucketAsync("my-bucket");
Note: While this wrapper provides a familiar way to interact with Amazon S3, it's important to remember that S3 doesn't have the same concept of files and directories like a traditional file system. Instead, it functions based on key-value pairs. In S3, the key is used to represent the file path or object name, while the value corresponds to the actual file content. However, you can structure the key to resemble a directory path, allowing for a hierarchical organization of objects within the S3 bucket.
Please find the available methods below