Back

Delete all auth users

  • 1
  • Accounts
Karthik
16 Feb, 2023, 08:40

How to delete all users from console

TL;DR
The user wants to delete all authenticated users from their application. They received a link to the Appwrite documentation on deleting users programmatically using the Server SDK. The user suggests opening a feature request on GitHub for an easier way to delete multiple users at once. Another user suggests writing a script that uses the list users function to get all user IDs and then calls the delete method for each ID. The original user mentions having 130 users. No solution to deleting all users from the console is provided in the thread.
joeyouss
16 Feb, 2023, 08:44

Hi πŸ‘‹ how many users do you have? one way is to click manually on user name and scroll down to delete the user but let me check if there is a way to delete all of them in one go,

Karthik
16 Feb, 2023, 08:44

i have 130 users

joeyouss
16 Feb, 2023, 09:13

got it, lemme have a look and get back

Karthik
16 Feb, 2023, 10:03

ok , thanks

joeyouss
16 Feb, 2023, 10:37

so, seems like the API accepts only manually inserted User IDs i.e. manually deleting users one by one. One way could be to write a function in code for loop and that loop uses list users to get all user IDs and each time the loop runs, the delete method is called for that particular UserID - i.e. write a script

joeyouss
16 Feb, 2023, 10:39

Also, if you want, can you open an issue on Github for this as a feature request so our team can see the feedback? You can create an issue here: https://github.com/appwrite/appwrite/issues

joeyouss
16 Feb, 2023, 14:54

Does this solve your query? if not, let us know so we can help you more

VincentGe
16 Feb, 2023, 14:54

@Karthik Sever SDK allows you to delete them programmatically.

Karthik
23 Feb, 2023, 18:11

ok thanks

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more