# Can't delete a user with user management dashboard

**URL:** <https://community.auth0.com/t/cant-delete-a-user-with-user-management-dashboard/77516>\
**Category:** Get Help\
**Created:** [February 2, 2022, 5:52pm UTC](https://community.auth0.com/t/cant-delete-a-user-with-user-management-dashboard/77516 "2022-02-02T17:52:52Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![john20](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/john20/32/25424_2.png) [@john20](https://community.auth0.com/u/john20)\
**Post date:** [February 2, 2022, 5:52pm UTC](https://community.auth0.com/t/cant-delete-a-user-with-user-management-dashboard/77516/1 "2022-02-02T17:52:52Z")

</div>

I’m using a “custom” database, MongoDB to store users, and they’re showing up in the “User Management”.

I click delete on the user and get “Error: There was a problem deleting [theemail@domain.com](mailto:theemail@domain.com)”

I google and find this: [Can't delete a user - #2 by stephanie.chamblee](https://community.auth0.com/t/cant-delete-a-user/56673/2) which tells me to use this endpoint:

DELETE/api/v2/connections/{id}/users

So I get my api token and put it in the “Set api token” button. I enter the ID of the user, and click “TRY” underneath “test this endpoint”. My result is this:

request URL: [https://dev-ezr1rrj6.us.auth0.com/api/v2/connections/61f835e5b411680011aa7dc0/users?email=the-email%40gmail.com](https://dev-ezr1rrj6.us.auth0.com/api/v2/connections/61f835e5b411680011aa7dc0/users?email=the-email%40gmail.com)

Response code: 400  
Error: bad request

something about needing a connection id.

So I go and find the database connection id. enter that, and try deleting the user and I get 204 no content.

this is unbelievable it shouldn’t be this hard to delete a user.

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [February 5, 2022, 12:24am UTC](https://community.auth0.com/t/cant-delete-a-user-with-user-management-dashboard/77516/3 "2022-02-05T00:24:22Z")

</div>

Hi @john20,

Thanks for reaching out to the Auth0 Community!

Before we continue, could you please clarify if you have implemented the [Delete script](https://auth0.com/docs/authenticate/database-connections/custom-db/templates/delete) in your Custom Database Action scripts?

And could you please share the errors found in your Auth0 Tenant Logs caused by this event?

Thank you.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [February 20, 2022, 12:24am UTC](https://community.auth0.com/t/cant-delete-a-user-with-user-management-dashboard/77516/4 "2022-02-20T00:24:54Z")

</div>

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.
