I want to write a function in Dart for my Appwrite project, but I can't grasp the logic of it. My request is, could you please explain how I can do the following to use as a reference for the functions I will create in the future: When a user wants to create a team, the system should check if they have a premium label. For premium users, there will be a limit of 20 teams, and for non-premium users, a limit of 200 teams. The system should check how many teams the user is a member of and, if it's below the limit, create a team with the name the user desires.
Recommended threads
- Project in AppWrite Cloud doesn't allow ...
I have a collection where the data can't be opened. When I check the functions, there are three instances of a function still running that can't be deleted. The...
- Get team fail in appwrite function
I try to get team of a user inside appwrite function, but i get this error: `AppwriteException: User (role: guests) missing scope (teams.read)` If i try on cl...
- Function in Node.JS to monitor events ar...
Hello everyone. I'm creating my first Node.JS function, but I don't have much experience with node and javascript. I'm trying to create a function, that monito...