User Self-Deletion Not Working

I’ve been trying for days to figure out user deletion. I’m a total noob at coding but I’m great at following direction and asking ChatGPT for help. I’ve been able to do everything so far:

  • Connected Github repo to netlify
  • added a deleteUser.ts function
  • calling my function properly

But I keep getting a 404 error meaning my function is not being found.

My filepath is project/netlify/functions

It just doesn’t work. I dont know what to do. Why is user management this difficult?

@ModyAssociates What specifically are you trying to delete?

In my experience most things in life are ‘difficult’ until you understand them, and then they’re ‘easy’.

I’m trying to allow User to delete their own account. But when the user delete’s the account, they are able to still log back in. All data related to that user should be instantly removed from supabase. Then if that user wants to sign up for a new account again using the same email, they should be able to. But it’s not working.

I’ve got the deleteUser functions down but it’s not deleting all user data. I think I’ve got a work around for now that gives the following message when the user deletes their account wants to sign up again for a new account: “An account with this email exists but was deleted. Please contact support if you need to recover it.”

Do I need to include edge functions?

@ModyAssociates Sorry, but I’m confused.

Are you having trouble with a specific Netlify feature?

Your most recent description sounds like you’re simply having general difficulty creating your web application due to inexperience, and if that’s the case then unfortunately this isn’t the right place for assistance.

Netlify’s staff operate within a ‘Scope of Support’:
https://www.netlify.com/support-scope/

Base functionality of Netlify’s build and deploy pipeline is supported, but we cannot help you debug any source code used either during build or after deployment.

So they won’t be able to assist.

Community members that answer questions (like myself) can help, but they won’t because your issue isn’t ‘easily understood’ or ‘small/simple enough’ for them to answer quickly.

If you are having trouble with a specific Netlify feature though feel free to provide more detail.