# Delete current user

This action deleted the current authenticated user from the Firebase authentication service and also gives the option to delete the related user document on the users collection.

***

## <mark style="color:blue;">Inputs and Settings</mark>

<div align="left"><figure><img src="https://284736847-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FiWu3FezEjWxrPbkf8zIP%2Fuploads%2Fof2kfL2kuTDwYJNGv9Ge%2Fimage.png?alt=media&#x26;token=339e95c5-99f8-4c6b-9f8b-d03461f7b95d" alt=""><figcaption></figcaption></figure></div>

### Password

The user must provide the current account password to confirm the delete operation.

### Delete user firestore document

If you check this box, the user document related to the current user will also be deleted.

### Users Collection

The name or ID of the collection where user's data is stored. The related document will have the same ID that user has on the authentication service.

### Trigger ID (optional)

This will link the action with a [Action Listener](https://estare.gitbook.io/firebase-auth-firestore-and-storage-plugin/plugin-elements/firebase-action-listener) of the same ID.&#x20;

If left blank, all listener on the page with blank ID's will be triggered at the same time, so we suggest to always define a Trigger ID.

When there is an error running the function, it will trigger the [Error in Action](https://estare.gitbook.io/firebase-auth-firestore-and-storage-plugin/plugin-elements/firebase-action-listener#error-in-action) event.

***

## <mark style="color:blue;">Triggered events</mark>

Those events are triggered by an [Action Listener](https://estare.gitbook.io/firebase-auth-firestore-and-storage-plugin/plugin-elements/firebase-action-listener) with the same ID as the [Trigger ID](#trigger-id-optional) provided on the action.

* Error in Action (if an error occurs)
