hello all, I have a function with execution permissions attributed to "Any", but the user cannot execute it ((role: users) missing scope (functions.write)).
Is there a way to solve this ?
What endpoint you're accessing?
a custom domain mapped to cloud instance
seems to work in production, but broken in local dev
I mean. How are you executing the function?
Also whatever is a user or a guest?
oh, I call createExecution from the client; user is authenticated, but should also work without authentication
Agreed
Sometime after deploying a function without setting Execute Access then the value will cleared from the Admin panel
Can you verify that and share the code?
yeah, but weird thing is it works in production. could it be a domain issue ?
Seems that swithing the endpoint to https://cloud.appwrite.io seems to fix the issue in local
I see
And the settings and versions are the same as the cloud
?
yes
I'll recommend to add this in your appwrite.json
"execute": [
"any"
],
Then redeploy to your local Appwrite
make sure your api key has the functions.write scope
I think is through a Client sdk
yes yes, but the function itself uses an API key which needs to have the right scopes
Recommended threads
- Appwrite docs mcp server 502 bad gateway
I added the appwrite docs mcp server to vscode following the docs https://appwrite.io/docs/tooling/mcp/vscode#step-1 but upon start it gives the following error...
- Appwrite 1.8.1 TablesDB Permissions Issu...
Hi - I'm migrating a newer VueJS web application from Supabase to Appwrite. I'm looking for an experienced Appwrite Developer to help me solve a permissions iss...
- Functions not executing after usage rese...
Hi team, Last month my project hit 100% usage and functions stopped working (expected). Now the new month has started and usage has reset, requests are going ...