s3.bucket objects filter top 10 code example
Example: s3.bucket objects filter top 10
import boto3
client = boto3.client('s3')
paginator = client.get_paginator('list_objects')
for result in paginator.paginate(Bucket='edsu-test-bucket', Delimiter='/'):
for prefix in result.get('CommonPrefixes'):
print(prefix.get('Prefix'))