Services Plugins FAQs

Server responded with 0 code

I’m having a problem uploading to s3 aws. I configured everything according to the tutorial and I’m having a message: “Server responded with code 0.”

Can someone help me? thank you so much!

my bucket access:

{
“Version”: “2012-10-17”,
“Id”: “http referer policy example”,
“Statement”: [
{
“Sid”: “”,
“Effect”: “Allow”,
“Principal”: {
“AWS”: “arn:aws:iam::713387987884:role/Cognito_pagewapUnauth_Role”
},
“Action”: “s3:",
“Resource”: "arn:aws:s3:::pagewap/

},
{
“Sid”: “”,
“Effect”: “Allow”,
“Principal”: {
“AWS”: “"
},
“Action”: [
“s3:DeleteObject”,
“s3:GetObject”,
“s3:PutObject”
],
“Resource”: "arn:aws:s3:::pagewap/

}
]
}

iam:

{
“Version”: “2012-10-17”,
“Statement”: [
{
“Effect”: “Allow”,
“Action”: [
“cognito-sync:",
"cognito-identity:
”,
“S3:"
],
“Resource”: [
"

]
}
]
}

image.png

Hi @elvis.scorpioni,

Thanks for reaching out. This error appears when setting up the JSON wrongly. Please copy and paste the following codes into their respective blocks.


Bucket policy

{

"Version": "2012-10-17",

"Statement": [

{

"Sid": "AddPerm",

"Effect": "Allow",

"Principal": "*",

"Action": "s3:GetObject",

"Resource": "YOUR_ARN_HERE/*",

"Condition": {

"StringLike": {

"aws:Referer": "YOUR_DOMAIN_HERE/*"

}

}

},

{

"Sid": "AddPerm2",

"Effect": "Allow",

"Principal": "*",

"Action": "*",

"Resource": "YOUR_ARN_HERE/*"

}

]

} 

ACL


CORS

[

{

"AllowedHeaders": [

"*"

],

"AllowedMethods": [

"GET",

"PUT",

"DELETE",

"POST"

],

"AllowedOrigins": [

"YOUR_DOMAIN_HERE"

],

"ExposeHeaders": [

"ETag"

],

"MaxAgeSeconds": 30000

}

]

Save the setups, then give it a try again.

Best,
Alex

hi Alex, thanks for responding. It worked!!! thank you so much!!!

2 Likes

Thanks @elvis.scorpioni for getting back! I’m glad it is working on your side as well.

If you like our plugin so far, could you please rate it by going to Plugins tab in Bubble editor? You can find the plugin by name and give it as many stars as it deserves. The more feedback we get, the more motivated we are to build great plugins!

Best,
Alex

Leave it, I will evaluate it. Another question, is it possible to remove an item from the file upload through the workfloow?

another question, is it possible to limit the number of files selected in the file upload when it is configured for multiple selection?

Hi @elvis.scorpioni,

Thanks for feedback.

Sure, you can use the Reset Input action.

Unfortunately, it is not possible, but you can set the Max file size (in MB):

image

Hope it helps.

Best,
Alex