List S3 Bucket Objects
s3_list_objectsList objects in an S3 bucket with optional prefix filtering and pagination to browse contents or find specific files in large datasets.
Instructions
List objects in an S3 bucket with optional prefix filtering and pagination.
This tool retrieves a list of objects (files) from an S3 bucket. Use it to:
Browse bucket contents
Find specific files by prefix
Paginate through large result sets
Args: bucket_name: S3 bucket name (3-63 characters, lowercase, numbers, hyphens, dots) prefix: Filter objects by key prefix (e.g., 'logs/2024/' to find all logs from 2024) limit: Max objects to return per request (1-1000, default: 20) continuation_token: Token from previous response to get next page response_format: Output format - 'markdown' (default) or 'json'
Returns: Formatted list of objects with key, size, last modified date, and storage class. If more results exist, includes continuation token for next page.
Error Handling: - Bucket not found: Returns error with suggestion to verify bucket name - Access denied: Returns error with IAM permission suggestions - Invalid input: Returns validation error with specific field issues
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"bucket_name": "<bucket_name>"
},
"name": "s3_list_objects"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| limit | No | ||
| prefix | No | ||
| bucket_name | Yes | ||
| response_format | No | markdown | |
| continuation_token | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |