AWS S3 Bucket Policy
Copy this bucket policy into your S3 bucket's permissions to allow ImpossibleFX to upload rendered videos without passing AWS keys in every request.
Bucket policy
In the AWS Console, go to S3 → your bucket → Permissions → Bucket policy and paste the following. Replace my-videos with your bucket name.
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "AllowImpossibleFXUploads",
"Effect": "Allow",
"Principal": {
"CanonicalUser": "1ea9f667f8ec65aa76ca17cbacfda01ba70493b59f7124a810823def30e10216"
},
"Action": [
"s3:AbortMultipartUpload",
"s3:ListMultipartUploadParts",
"s3:PutObject",
"s3:PutObjectAcl"
],
"Resource": "arn:aws:s3:::my-videos/*"
}
]
} Render request
Once the policy is in place, set aws_use_policy: true in your render request instead of providing access keys:
curl -X POST https://render-eu-west-1.impossible.io/v2/render/YOUR_PROJECT_ID \
-H "Content-Type: application/json" \
-d '{
"movie": "welcome",
"params": { "name": "Alex" },
"upload": {
"extension": "mp4",
"destination": {
"type": "s3",
"bucket": "my-videos",
"filename": "renders/welcome.mp4",
"aws_use_policy": true,
"contenttype": "video/mp4",
"acl": "public-read"
}
}
}' Response
On success, the response includes the public S3 URL:
{
"token": "v2:eu-west-1:abc123",
"upload": "https://my-videos.s3.amazonaws.com/renders/welcome.mp4"
}