
Hi there. Is there a way to set the function permission within the function itself or in the JSON file?
The problem: I am having to set permissions for the function in the console every time I redeploy the function via the CLI " appwrite deploy function" command. Is there a way to set it before deploying it via CLI?
Thanks in advance

Hi 👋 In appwrite.json
, there is functions
key and in your function definiton there you can find execute
array of permissions. Once set there, those will be applied on every redeploy

Here is an example: https://github.com/Meldiron/almost-wishlist/blob/main/appwrite.json#L71
Possible value is for example any
, users
, guests
, ..

Thank you. I will definately check this out.

@Meldiron Thank you. I got it. I just had to set the execute attribute in the function section of my appwrite.json to this "execute": ["users"]

Great job ✨

[SOLVED] Set function permissions before deploying
Recommended threads
- Appwrite functions can't connect to data...
I'm trying to create a function that queries my database, but all database operations timeout from within the function, even though CLI access works perfectly. ...
- Error
I'm trying to get sellerId using account.get() in my appwrite function and this is the error message I'm getting: "Failed to send notification to seller 6865bf...
- Is there a timeframe for updating dart r...
Dart 3.5 is already one year old, and the following versions have introduced very important features for the language. Is there a roadmap or timeframe for when...
