But how bots will have access to your team?
By signing?
Prevent other users in a team getting email
Votes
0
Replies
24
Participants
Unknown
Messages
25
Moderator
Yes, there will be public teams, so anyone can join. The architecture is like a discord clone
Moderator
There are some public servers you can join, others are private, requiring an invitation. You can see users profile, but you can't see their emails
Moderator
So my idea was making all public server like if it was a team, and the user joins the severe by join the team
Admin
If I were you, I would:
- Create a collection for each entity like users, servers, posts, requests etc.
- Use teams only for access
- Disable the teams service to prevent end users from using the teams service.
I think the teams service was designed for the use case where someone who owns a resource wants to invite someone to view/update/delete it. Since your use case is kind of the opposite, there's no need to use the invite system
Moderator
So then for example, If I have a post, should I create a database for users and the associate the post to the user?
Moderator
And in the case of saved pages, having a separate database that associates both users and saved pages?
Moderator
Definitely, yes, I think I'm using teams for a thing it's not designed to
Admin
So multiple databases? Why exactly?
Moderator
I mean collections 😅
Admin
how so and why?
Moderator
Discord example:
User wants to join a server:
Then in the "saved servers" collection, creating a new document with the user ID and the corresponding server
I'm not sure if there's a better approach
Admin
so 1 collection per object type, right?
All of the above 😉
Moderator
1 document per server saved that contains that:
- ServerID/relationship
- UserID
That way when the app is loaded, the users gets all documents containing it's userID, and then it search the servers containing such ID's
Moderator
I have another problem with that, who is basically that data in the server will be publicly available, so how I could limit it to only allow read access to users that saved the server?
You can create a team, and each server message will be tied to a Team. then set the permissions of the server message only to a Team memebers.
Moderator
Emails will be revealed to every member
Moderator
I would like to achieve exactly the same or something similar as teams but without revealing emails to everyone
Ohh, right.
You try what Steven suggested here.
Work with Teams but disable them in the project settings
I think doing so will block it from the Client sdk but not the logic behind it.
If you look here
https://github.com/appwrite/appwrite/blob/master/app/controllers/general.php#L352-L356
It's seems like when a service is disabled then it won't be available only to regular users, that means all the Teams Client SDK requests.
It looks like this would be a great solution for your use-case
Moderator
Thanks, I will try that! Definitely that should be the best solution
Moderator
I thought that disabling teams from console meant disabling it for everything, both client and server side
That was my thought too