Amazon S3
What can you do with it?
Amazon S3 is a cloud storage service that allows you to store and retrieve any amount of data from anywhere. With this skill, you can:- File Management: Upload, download, and delete files of any type (text, images, PDFs, etc.)
- Folder Organization: Create and delete folders to organize your files
- Bucket Operations: List all buckets in your account
- Content Listing: List files and folders with metadata (size, last modified date, etc.)
- Binary File Access: Direct access to images, PDFs, and other binary files
- Presigned URLs: Generate temporary URLs for secure file sharing
- Text File Operations: Upload and view text/JSON files with content validation
How to use it?
To use Amazon S3, you’ll need to connect your S3 account first. Once connected, you can perform file operations using the command format:Tools
1. List Buckets
List all buckets in your S3 account. Parameters:- None required
2. Create Folder
Create an empty folder in an S3 bucket. Parameters:bucket
: The name of the bucketfolder_name
: The name of the folder to create
3. Delete Folder
Delete a folder and all its contents from an S3 bucket. Parameters:bucket
: The name of the bucketfolder_name
: The name of the folder to delete
4. Upload File
Upload a file to a specific bucket and folder. Parameters:bucket
: The name of the bucketfolder
: The folder path (optional)filename
: The name of the filecontent
: The file content (text or binary)content_type
: The MIME type of the file
5. Download File
Download a file from a specific bucket and folder. Parameters:bucket
: The name of the bucketfolder
: The folder path (optional)filename
: The name of the file to download
6. List Files
List all files and folders in a specific bucket and folder. Parameters:bucket
: The name of the bucketfolder
: The folder path to list (optional)prefix
: Filter files by prefix (optional)max_keys
: Maximum number of keys to return (default: 1000)
7. List Objects
List objects within a bucket with detailed metadata. Parameters:bucket
: The name of the bucketprefix
: Filter objects by prefix (optional)delimiter
: Delimiter for grouping (optional, default: ”/”)max_keys
: Maximum number of keys to return (default: 1000)
8. Upload Text/JSON Object
Upload a text or JSON file to S3. Parameters:bucket
: The name of the bucketfolder
: The folder path (optional)filename
: The name of the filecontent
: The JSON or text content
9. Delete File
Delete a file from S3. Parameters:bucket
: The name of the bucketfolder
: The folder path (optional)filename
: The name of the file to delete
10. View Object Content
View the content of an S3 object (JSON or text). Parameters:bucket
: The name of the bucketfolder
: The folder path (optional)filename
: The name of the file to view
11. View Text File Content
View the content of a text file from S3. Parameters:bucket
: The name of the bucketfolder
: The folder path (optional)filename
: The name of the text file to view
12. Access Binary Files
Access binary files (images, PDFs, etc.) directly for use in HTML or applications. Parameters:bucket
: The name of the bucketfolder
: The folder path (optional)filename
: The name of the binary file
13. Generate Presigned URL
Generate a presigned URL for temporary access to a file. Parameters:bucket
: The name of the bucketfolder
: The folder path (optional)filename
: The name of the fileexpires
: Expiration time in seconds (optional, default: 3600)
14. List Folder Contents
List contents of a specific folder in a bucket with detailed metadata. Parameters:bucket
: The name of the bucketfolder
: The folder path to listdelimiter
: Delimiter for grouping (optional, default: ”/”)
Notes
- Proxy Support: Amazon S3 supports both PinkConnect and Paragon proxy connections
- Binary Files: For binary file downloads, the
X-Paragon-Use-Raw-Response: 1
header is mandatory - Content Types: Proper content-type headers are important for file uploads and downloads
- Folder Structure: S3 uses a flat structure with keys that simulate folders using ”/” delimiters
- Presigned URLs: Generated URLs expire after the specified time and provide temporary access without credentials
- File Handling: Supports all file types including text, JSON, images, PDFs, and other binary formats
- Metadata: List operations return detailed metadata including size, last modified date, ETag, and storage class
- Error Handling: DELETE operations return 204 status with no content when successful