Skip to contents

Sends a DELETE request to the MotherDuck REST API to permanently remove a user from your organization. This operation requires administrative privileges and a valid MotherDuck access token.

Usage

delete_md_user(user_name, motherduck_token = "MOTHERDUCK_TOKEN")

Arguments

user_name

A character string specifying the MotherDuck user name whose tokens should be listed.

motherduck_token

Character. Either the name of an environment variable containing your MotherDuck access token (default "MOTHERDUCK_TOKEN") or the token itself.

Value

A tibble summarizing the API response, including the username and deletion status.

Details

This function calls the MotherDuck Users API endpoint to delete the specified user. The authenticated user (associated with the provided token) must have sufficient permissions to perform user management actions.

Examples

if (FALSE) { # \dontrun{
# Delete a user named "bob_smith" using an admin token stored in an environment variable
delete_md_user("bob_smith", "MOTHERDUCK_TOKEN")
} # }