I have set the user read only permission for my bucket. It is working on mac and android for my vue app. However, it doesn't work on IOS. I got an 401 error saying the current user is not authorized to perform the requested action. Not really sure how to solve this issue.
This is a website?
Are you using cloud or self-hosted?
I am using appwrite cloud.
Are you sure permissions are set correctly?
I believe so. Because I have set user read only permission for the bucket. On Mac and android when visit my app after they are authenticated using createEmailSession(), users are able to download the file from the bucket. However, when users access my app from IOS device, it shows users are not authorized to download. It looks like the sdk does not grab the session data from the client, because when I add bucket policy with guest access, users are able to download the file then
I assume you are also creating a session with createEmailSession()
in iOS?
And is this a website? Or an app?
It is an web application using Nuxt 3 as the frontend. And yes, I am using createEmailSession() in IOS.
So this is the same codebase between iOS and Android/Desktop?
Yes, it is same. That's why I found it really real wired.
probably a 3rd party cookie problem. do you have a custom domain configured?
I don't think so. My web app is deployed on render.com. And I did not add any custom domain name.
Then you will need to be sure third party cookies are allowed in your browser
for more info, see https://appwrite.io/docs/advanced/platform/custom-domains
Thank you @Steven @D5. I think that might be the cause. I will give it try.
Recommended threads
- Invalid document structure: missing requ...
I just pick up my code that's working a week ago, and now I got this error: ``` code: 400, type: 'document_invalid_structure', response: { message: 'Inv...
- custom domain with CloudFlare
Hi all, it seems that CloudFlare has blocked cross-domain CNAME link which made my app hostname which is in CloudFlare, unable to create a CNAME pointing to clo...
- Custom emails
What happen if I use a third party email provider to customize my emails and my plan run out of emails/month? Appwrite emails are used as fallback sending emai...