I have been struggling to find out the error in writing the principal correctly. From Aws console I am trying AWS polly and want to save the output to s3 bucket. The IAM user is created with the following permissions:
{
"AttachedPolicies": [
{
"PolicyName": "AdministratorAccess",
"PolicyArn": "arn:aws:iam::aws:policy/AdministratorAccess"
},
{
"PolicyName": "AmazonPollyFullAccess",
"PolicyArn": "arn:aws:iam::aws:policy/AmazonPollyFullAccess"
},
{
"PolicyName": "AmazonS3FullAccess",
"PolicyArn": "arn:aws:iam::aws:policy/AmazonS3FullAccess"
}
]
}
On S3 Bucket permission tab I trying to add the given policy:
{
"Id": "Policy1720073611620",
"Version": "2012-10-17",
"Statement": [
{
"Sid": "Stmt1720071547531",
"Action": "s3:*",
"Effect": "Allow",
"Resource": "arn:aws:s3:::mytest2-text-to-speech/*",
"Principal": {
"AWS": [
"polly.amazonaws.com"
]
}
}
]
}