zbh45
September 9, 2024, 5:54pm
1
I currently have an S3 resource configured to add photo files to an S3 bucket.
The resource is fully connected and okay when tested (picture below).
Also, it seems that in my query to add the photo file, all fields are properly pulling in to the query config (photo below).
There are two core issues:
When I press preview, I simply get a "failed to fetch" error with no additional information.
When I run the query, I just get an "S3 Upload Error: ____" return error code.
Does anyone have an idea on how to troubleshoot / fix this?
gonzalo
September 16, 2024, 9:42pm
2
Hi @zbh45 ,
Everything seems correctly set up on the Retool side, but you may need to adjust a few settings in AWS.
First, please check if the CORS policy for your S3 bucket is configured to allow Retool access to write or modify data. You can find more info here: Connect to Amazon S3 and S3-compatible services | Retool Docs
Also, for Retool to add or modify objects in your bucket, it needs permission to perform the s3:PutObject action. Without this permission in your S3 bucket policy, Retool won't be able to upload files.
The "Create Access Credentials" section on that page has an example of the required policy. You can also find more examples of bucket policies here: Examples of Amazon S3 bucket policies - Amazon Simple Storage Service
Hope this helps! Let me know if you need more details.