I created a bucket with name “my-bucket”, cloudformation creates it as “StackName-my-bucket-{random text}”. I want to read from this bucket in the java code, what would be the right way to access provided I cannot touch anything in cloudformation. Answer Assuming you cannot modify the CloudFormation template and it does not have the bucket as an output variable – You