Did you put only the hostname of your flutter app with no leading it trailing spaces?
Would you please share the full logs from the browser console?
Yes, and since it's firebase hosting, the link looks like myapp.web.app. so I just put that in the hostname when adding flutter web platform
Could you elaborate a little more?
Browser dev tools
I do see this ed Content: The page at 'https://myapp.web.app/#/' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'http://XXX/v1/account/sessions/email'. This request has been blocked; the content must be served over HTTPS.
though I tried calling over https as well,
Please switch to https for your endpoint and share the new logs
main.dart.js:38098
POST https://XXX/v1/account/sessions/email net::ERR_FAILED``` I notice that now over an https my antivirus blocks the connection!
I can somehow establish a connection now, but as soon as it happens the browser treats my app as insecure even tho it's on https
that happens after appwrite's auth, I wonder if this is supposed to be like that or am missing something
What do the details say when you click on Not Secure
this popup
And if you click on learn more?
That's if I'm on chrome, on safari it still throws the same exception as mentioned earlier
Weird...usually it shows this if certificate is invalid, but it says certificate is valid
What's showing in the browser console logs?
Appwrite is using localStorage for session management. Increase your security by adding a custom domain as your API endpoint. Just that 🤔
Not sure then. If you share your URL, I can try to test on my end
Circling back here...the problem was due to a self signed certificate on the Appwrite instance.
Hey @Steven! I have the exact same problem. I am hosting my appwrite backend with DigitalOcean and for the web app I am using Firebase hosting. When I am running my web app locally (but the appwrite endpoint is my Droplet from DigitalOcean), it works just fine. But as soon as I am hosting it on Firebase Hosting and accessing it there, I also get XMLHttpRequest error. Can you explain what you mean with self signed certificate on the Appwrite instance and how to solve it?
please create a new post instead of posting in an old thread
[SOLVED] Flutter Web - AppwriteException: null, XMLHttpRequest error. (0)
Recommended threads
- type generation on same columns in table
is there way to prevent this ? or only need to update column name like table prefix?
- Unable to send verification email
Hi! I’m trying to access my project on Appwrite Cloud (fra.cloud.appwrite.io), but I keep getting this popup saying: “To continue using Appwrite Cloud, please...
- Converting circularstructure to JSON
Hello 👋, when this will be fixed on Appwrite Sites? It's draining our quotas for Sentry, it must be a problem with the default logger which is always on for Ap...