Reputation: 2693
How Can I use boto 3 to generate a accelerated transfer signedURL?
I can generate a standard signedURL by
client = boto3.client('s3')
parameters = {
'Bucket' : bucket,
'Key' : key
}
signed_url = client.generate_presigned_url(
'get_object',
Params = parameters,
ExpiresIn = 300000
)
But I can't find anywhere in the amazon boto3 document if there is an option to use an accelerated endpoint
Upvotes: 1
Views: 1207
Reputation: 76
Pass it on the client config like follows:
client = boto3.client(
's3',
config = botocore.client.Config(
s3 = {
'use_accelerate_endpoint': True
}
)
)
Upvotes: 6