Skip to main content
Version: v1.7.0

User data deletion

Overview

Enterprise h2oGPTe allows users to irreversibly delete all their data from the platform. This permanent deletion process uses a two-step verification system to prevent accidental data loss.

What gets deleted

When a user requests data deletion, the following data is permanently removed:

  • Collections: All user-created collections and their metadata
  • Chat sessions: All conversation history and related data
  • Documents: All uploaded documents and their processed content
  • Processing jobs: All data processing tasks and their outputs
  • Prompt templates: User-created custom prompt templates
  • User preferences: Associated user content and application preferences

What does NOT get deleted

The deletion process removes user data but does not:

  • Delete the user account itself: The user account record remains in the system for administrative purposes, but all associated user data is irreversibly removed.
  • Affect system-wide configurations: Global settings and system configurations remain unchanged
  • Impact other users: No data belonging to other users is affected

Deletion process

User data deletion uses a two-step verification system.

Step 1: Request deletion

Initiate a deletion request to generate a unique delete_id.

Security features:

  • delete_id is tied to the specific user account
  • Cannot be used by other users
  • Expires automatically after 5 minutes

Step 2: Confirm deletion

Confirm the deletion within 5 minutes using the delete_id.

Upon confirmation:

  • All user data is processed and removed from the system
  • Deletion completes successfully
  • No response body is returned

Implementation methods

REST API

Self-deletion endpoints

Request deletion
DELETE /users/current
Authorization: Bearer <your-token>

Response:

{
"delete_id": "abc123def456"
}
Confirm deletion
POST /users/current/confirm-delete?timeout=300
Authorization: Bearer <your-token>
Content-Type: application/json

{
"delete_id": "abc123def456"
}

Response:

HTTP/1.1 204 No Content

Query parameters

  • timeout (optional): Timeout in seconds. Default: 300

HTTP response codes

CodeDescription
200Success (deletion request created)
204No Content (deletion completed successfully)
400Bad Request (invalid or expired deletion ID)
401Unauthorized (invalid authentication)
500Internal Server Error

Python client library

Synchronous implementation

from h2ogpte import H2OGPTE

# Initialize client
client = H2OGPTE(address="https://your-instance.com", api_key="your-api-key")

# Request deletion (returns deletion ID as string)
delete_id = client.request_current_user_deletion()
print(f"Delete ID: {delete_id}")

# Confirm deletion (within 5 minutes)
client.confirm_current_user_deletion(delete_id=delete_id)
print("Deletion request completed.")

Asynchronous implementation

import asyncio
from h2ogpte import H2OGPTEAsync

async def delete_user_data():
# Initialize async client
client = H2OGPTEAsync(address="https://your-instance.com", api_key="your-api-key")

try:
# Request deletion (returns deletion ID as string)
delete_id = await client.request_current_user_deletion()
print(f"Delete ID: {delete_id}")

# Confirm deletion (within 5 minutes)
await client.confirm_current_user_deletion(delete_id=delete_id)
print("Deletion request completed.")

finally:
await client.close()

# Run the async function
asyncio.run(delete_user_data())

Best practices

  • Verify before deletion: Ensure you want to irreversibly delete all your data
  • Export data first: Back up any data you want to preserve before initiating deletion
  • Complete within time limit: Confirm deletion within the 5-minute security window
  • Understand scope: Refer to the What gets deleted section to understand data impact

Troubleshooting

For troubleshooting issues with user data deletion, see User data deletion troubleshooting.

API reference

Endpoints

MethodEndpointDescription
DELETE/users/currentRequest self-deletion of user data
POST/users/current/confirm-deleteConfirm self-deletion request

Python client methods

MethodDescriptionParametersReturns
request_current_user_deletion()Request deletionNonestr (deletion ID)
confirm_current_user_deletion()Confirm deletiondelete_id: str, timeout: float | None = NoneNone

Support

If you encounter issues with user data deletion:

  1. Review troubleshooting guidance: See the troubleshooting section above
  2. Contact your system administrator: For infrastructure-related issues or enterprise deployment questions
  3. Reach out to support: Email cloud-feedback@h2o.ai for additional assistance

Feedback